/* Nuclear Archive — SpaceX-inspired clean layout */

:root {
  --black: #000000;
  --near-black: #0b0b0b;
  --white: #ffffff;
  --off-white: #f5f5f5;
  --gray-100: #f0f0f0;
  --gray-200: #e5e5e5;
  /* Body secondary text — kept dark enough for comfortable reading */
  --gray-400: #6e6e6e;
  --gray-600: #4a4a4a;
  --gray-800: #2a2a2a;
  --accent: #7b4dff; /* purple from MSBR core logo */
  --nav-h: 64px;
  --max: 1280px;
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  color: var(--black);
  background: var(--white);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ——— Nav (SpaceX shop style) ——— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--black);
  color: var(--white);
  height: var(--nav-h);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  height: 100%;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  background: #111;
}

.brand-name {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Keep underscore tight so NUCLEAR_ARCHIVE reads as one mark */
.brand-name,
.footer-brand,
.hero h1 {
  font-variant-ligatures: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px 28px;
  list-style: none;
  flex: 1;
  justify-content: center;
}

.nav-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  transition: color 0.15s ease;
  padding: 8px 0;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--white);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

.nav-right a {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.15s ease;
}

.nav-right a:hover {
  color: var(--white);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  cursor: pointer;
  padding: 8px;
  width: 40px;
  height: 40px;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--white);
  margin: 4px auto;
  transition: 0.2s;
}

/* ——— Main ——— */
main {
  flex: 1;
}

/* ——— Hero ——— */
.hero {
  position: relative;
  min-height: calc(100vh - var(--nav-h));
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--near-black);
  color: var(--white);
  overflow: hidden;
  text-align: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(123, 77, 255, 0.18), transparent 60%),
    radial-gradient(ellipse 50% 40% at 70% 70%, rgba(255, 80, 40, 0.08), transparent 50%),
    var(--near-black);
  z-index: 0;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("../assets/hero-banner.png?v=7");
  background-size: cover;
  background-position: center 30%;
  opacity: 0.28;
  mix-blend-mode: screen;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 820px;
  padding: 80px 24px;
}

.hero-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 28px;
  border-radius: 50%;
  object-fit: cover;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 48px rgba(123, 77, 255, 0.28);
}

.hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.2;
  margin-bottom: 20px;
}

.hero-mission {
  font-size: clamp(16px, 2.2vw, 20px);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.78);
  letter-spacing: 0.02em;
  max-width: 560px;
  margin: 0 auto 40px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.btn-primary {
  background: var(--white);
  color: var(--black);
  border-color: var(--white);
}

.btn-primary:hover {
  background: transparent;
  color: var(--white);
}

.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.45);
}

.btn-ghost:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}

.btn-dark {
  background: var(--black);
  color: var(--white);
  border-color: var(--black);
}

.btn-dark:hover {
  background: var(--gray-800);
  border-color: var(--gray-800);
}

.btn-outline {
  background: transparent;
  color: var(--black);
  border-color: var(--black);
}

.btn-outline:hover {
  background: var(--black);
  color: var(--white);
}

/* ——— Page shell (inner pages) ——— */
.page {
  padding: 64px 24px 96px;
}

.page-header {
  max-width: var(--max);
  margin: 0 auto 56px;
  text-align: center;
}

.page-header h1 {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 400;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

/* Mission-style page title (About): sentence case, tighter tracking */
.page-header.mission h1 {
  letter-spacing: 0.02em;
  text-transform: none;
  font-size: clamp(22px, 3.5vw, 32px);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.35;
}

.page-header p {
  font-size: 15px;
  color: var(--gray-600);
  max-width: 520px;
  margin: 0 auto;
  font-weight: 300;
  line-height: 1.6;
}

/* ——— Card grid (Accessories-style) ——— */
.card-grid {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px 16px;
}

@media (max-width: 1024px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .card-grid {
    grid-template-columns: 1fr;
  }
}

.card {
  display: flex;
  flex-direction: column;
}

.card-media {
  aspect-ratio: 1;
  /* Black stage so letterboxed models never show a white/gray border */
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  margin-bottom: 16px;
}

.card-media img {
  width: 100%;
  height: 100%;
  /* Show entire image — no tight crop that clips reactors */
  object-fit: contain;
  transition: transform 0.4s ease;
}

/* Research boards / documents — paper stage, zoomed fill (like Master Text) */
.card-media--paper {
  background: #f4f1ea;
}

.card-media--paper img {
  object-fit: cover;
}

.card:hover .card-media img {
  transform: scale(1.02);
}

.card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background:
    linear-gradient(145deg, #ececec 0%, #f8f8f8 50%, #e8e8e8 100%);
  color: var(--gray-600);
  padding: 24px;
  text-align: center;
}

.card-placeholder .icon {
  width: 48px;
  height: 48px;
  border: 1px solid var(--gray-400);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--accent);
  border-color: rgba(123, 77, 255, 0.4);
}

.card-placeholder .tag {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gray-400);
}

.card-body {
  text-align: center;
  padding: 0 8px;
}

.card-title {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.card-meta {
  font-size: 13px;
  color: var(--gray-600);
  font-weight: 300;
}

.card-badge {
  display: inline-block;
  margin-top: 8px;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(123, 77, 255, 0.35);
  padding: 4px 10px;
}

/* ——— About ——— */
.about-layout {
  max-width: 720px;
  margin: 0 auto;
}

.about-block {
  margin-bottom: 56px;
  text-align: center;
}

.about-label {
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gray-400);
  margin-bottom: 16px;
}

.about-block h2 {
  font-size: clamp(22px, 3.5vw, 32px);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.35;
  margin-bottom: 20px;
}

.about-block p {
  font-size: 16px;
  color: var(--gray-600);
  font-weight: 300;
  line-height: 1.7;
}

.about-block h2.about-proverb {
  font-size: clamp(18px, 2.6vw, 24px);
  max-width: 34em;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 12px;
  line-height: 1.45;
}

.about-label-aside {
  display: block;
  margin-top: 8px;
  letter-spacing: 0.06em;
  text-transform: none;
  font-size: 11px;
  color: var(--gray-600);
  font-weight: 300;
}

.about-block p.about-proverb-note {
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--gray-400);
}

.about-divider {
  width: 40px;
  height: 1px;
  background: var(--gray-200);
  margin: 0 auto 56px;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 720px;
  margin: 0 auto 64px;
  text-align: center;
}

@media (max-width: 600px) {
  .about-stats {
    grid-template-columns: 1fr;
  }
}

.stat-value {
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 13px;
  color: var(--gray-600);
  font-weight: 300;
}

/* ——— Feature strip (home) ——— */
.feature-strip {
  background: var(--white);
  padding: 96px 24px;
  border-top: 1px solid var(--gray-200);
}

.feature-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

@media (max-width: 800px) {
  .feature-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

.feature-copy h2 {
  font-size: clamp(20px, 2.5vw, 26px);
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.feature-copy p {
  font-size: 15px;
  color: var(--gray-600);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 28px;
}

.feature-visual {
  aspect-ratio: 4 / 3;
  background: var(--near-black);
  position: relative;
  overflow: hidden;
}

.feature-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.9;
}

/* ——— Footer ——— */
.site-footer {
  background: var(--black);
  color: rgba(255, 255, 255, 0.55);
  padding: 40px 24px;
  margin-top: auto;
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 500;
}

.footer-brand img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: color 0.15s;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-meta {
  font-size: 11px;
  letter-spacing: 0.06em;
  width: 100%;
  text-align: center;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.35);
}

/* ——— Mobile nav ——— */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--black);
    flex-direction: column;
    align-items: stretch;
    padding: 16px 24px 28px;
    gap: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: none;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 14px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-right {
    display: none;
  }

  .brand-name {
    font-size: 11px;
    letter-spacing: 0.12em;
  }
}

/* ——— Project cards as links ——— */
a.card {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.15s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}

a.card:hover {
  opacity: 0.92;
}

a.card .card-title {
  text-decoration: none;
}

a.card--playable .card-badge {
  border-color: var(--black);
  color: var(--black);
}

a.card--playable:hover .card-badge {
  background: var(--black);
  color: var(--white);
}

/* ——— Drawing / pan-zoom viewer ——— */
.project-page {
  padding: 32px 24px 64px;
  max-width: none;
}

.project-page .page-header {
  margin-bottom: 24px;
}

.project-page .page-header .back-link {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray-600);
  margin-bottom: 20px;
  transition: color 0.15s;
}

.project-page .page-header .back-link:hover {
  color: var(--black);
}

.drawing-viewer {
  max-width: 1400px;
  margin: 0 auto;
  border: 1px solid var(--gray-200);
  background: var(--near-black);
  user-select: none;
  -webkit-user-select: none;
}

.drawing-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: var(--black);
  color: rgba(255, 255, 255, 0.7);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.drawing-toolbar .hint {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.drawing-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.drawing-controls button {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: transparent;
  color: var(--white);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 12px;
  cursor: pointer;
  min-width: 40px;
  transition: background 0.15s, border-color 0.15s;
}

.drawing-controls button:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.5);
}

.drawing-controls .zoom-label {
  font-size: 12px;
  letter-spacing: 0.08em;
  min-width: 52px;
  text-align: center;
  color: rgba(255, 255, 255, 0.65);
}

.drawing-stage {
  position: relative;
  width: 100%;
  height: min(72vh, 720px);
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  background:
    radial-gradient(circle at center, #1a1a1a 0%, #0b0b0b 70%);
}

.drawing-stage.is-panning {
  cursor: grabbing;
}

.drawing-canvas {
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: 0 0;
  will-change: transform;
}

.drawing-canvas img {
  display: block;
  max-width: none;
  height: auto;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

/* Soft notice under viewer */
.drawing-note {
  max-width: 1400px;
  margin: 12px auto 0;
  font-size: 12px;
  color: var(--gray-400);
  letter-spacing: 0.04em;
  text-align: center;
}

/* ——— Hire / retainer ——— */
.page--compact {
  padding-top: 40px;
  padding-bottom: 64px;
}

.hire-layout {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.hire-layout--split {
  max-width: 1100px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 48px;
  align-items: start;
  text-align: left;
}

.hire-layout--split .hire-col {
  margin: 0;
  min-width: 0;
}

.hire-layout--split .hire-col--retainer {
  padding-left: 48px;
  border-left: 1px solid var(--gray-200);
}

.hire-layout--split .hire-title,
.hire-layout--split .hire-price,
.hire-layout--split .hire-label {
  text-align: left;
}

.hire-layout--split .hire-lead,
.hire-layout--split .hire-note {
  margin-left: 0;
  margin-right: 0;
  max-width: none;
}

.hire-layout--split .hire-actions {
  justify-content: flex-start;
}

.hire-layout--split .hire-points {
  margin-left: 0;
  margin-right: 0;
  max-width: none;
}

.hire-layout--split .hire-email-display {
  text-align: left;
}

.hire-offer {
  margin-bottom: 8px;
}

.hire-title--sm {
  font-size: clamp(22px, 3vw, 28px);
}

@media (max-width: 860px) {
  .hire-layout--split {
    grid-template-columns: 1fr;
    gap: 40px;
    max-width: 520px;
    text-align: center;
  }

  .hire-layout--split .hire-col--retainer {
    padding-left: 0;
    border-left: none;
    padding-top: 40px;
    border-top: 1px solid var(--gray-200);
  }

  .hire-layout--split .hire-title,
  .hire-layout--split .hire-price,
  .hire-layout--split .hire-label,
  .hire-layout--split .hire-email-display {
    text-align: center;
  }

  .hire-layout--split .hire-actions {
    justify-content: center;
  }

  .hire-layout--split .hire-lead,
  .hire-layout--split .hire-note {
    margin-left: auto;
    margin-right: auto;
  }
}

.hire-label {
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gray-400);
  margin-bottom: 16px;
}

.hire-title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.hire-price {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 28px;
}

.hire-price span {
  font-size: 0.65em;
  color: var(--gray-600);
  font-weight: 300;
  letter-spacing: 0.06em;
}

.hire-lead {
  font-size: 16px;
  font-weight: 300;
  color: var(--gray-600);
  line-height: 1.7;
  margin-bottom: 36px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.hire-points {
  list-style: none;
  text-align: left;
  max-width: 420px;
  margin: 0 auto 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hire-points li {
  font-size: 15px;
  font-weight: 300;
  color: var(--gray-600);
  line-height: 1.5;
  padding-left: 0;
  border-top: 1px solid var(--gray-200);
  padding-top: 18px;
}

.hire-points li strong {
  display: block;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--black);
  margin-bottom: 4px;
}

.hire-actions {
  margin-bottom: 20px;
}

.hire-note {
  font-size: 13px;
  color: var(--gray-400);
  font-weight: 300;
  line-height: 1.6;
  max-width: 400px;
  margin: 0 auto;
}

.hire-secondary {
  margin-top: 8px;
  margin-bottom: 24px;
}

.hire-secondary-text {
  font-size: 15px;
  font-weight: 300;
  color: var(--gray-600);
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto;
}

.hire-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 20px;
}

.hire-email-display {
  margin-top: 20px;
  font-size: 13px;
  color: var(--gray-600);
}

.hire-reveal {
  appearance: none;
  background: none;
  border: none;
  border-bottom: 1px solid var(--gray-400);
  color: var(--gray-600);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 4px 0;
  font-family: inherit;
}

.hire-reveal:hover {
  color: var(--black);
  border-bottom-color: var(--black);
}

.hire-email-text {
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--gray-800);
  user-select: all;
}

.hire-steps {
  margin-bottom: 8px;
}

.hire-steps-list {
  list-style: none;
  text-align: left;
  max-width: 440px;
  margin: 0 auto 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hire-steps-list li {
  font-size: 15px;
  font-weight: 300;
  color: var(--gray-600);
  line-height: 1.5;
  border-top: 1px solid var(--gray-200);
  padding-top: 16px;
}

.hire-steps-list li strong {
  display: block;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--black);
  margin-bottom: 4px;
}

/* ——— Ask Salt ——— */
.salt-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 24px;
  text-align: left;
}

.salt-form label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gray-600);
  margin-top: 8px;
}

.salt-form input,
.salt-form textarea {
  font-family: var(--font);
  font-size: 15px;
  letter-spacing: 0.02em;
  padding: 12px 14px;
  border: 1px solid var(--gray-200);
  background: var(--white);
  color: var(--black);
  width: 100%;
}

.salt-form input:focus,
.salt-form textarea:focus {
  outline: none;
  border-color: var(--black);
}

.salt-form .hire-actions {
  margin-top: 16px;
}

.salt-error {
  font-size: 13px;
  color: #b00020;
}

/* Ask Salt — full-height background figure (dark page) */
.salt-page {
  position: relative;
  overflow: hidden;
  background: var(--black);
  color: var(--white);
  min-height: calc(100vh - var(--nav-h));
}

/* Figure sits right; the core Salt holds is on the figure's left edge,
   so text is kept in a narrow left column that stops before it. */
.salt-figure {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 56%;
  pointer-events: none;
}

/* Slideshow: stacked slides crossfade (js/ask-salt.js) */
.salt-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
}

.salt-slide.is-active {
  opacity: 1;
}

.salt-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: left top;
}

.salt-figure::after {
  z-index: 1;
}

/* short soft edges only — keeps the core clear */
.salt-figure::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, #000 0%, rgba(0, 0, 0, 0) 6%),
    linear-gradient(to top, #000 0%, rgba(0, 0, 0, 0) 14%);
}

.salt-content {
  position: relative;
  z-index: 1;
}

.salt-layout {
  max-width: none;
  margin: 0;
  width: 42%;
  padding-left: clamp(24px, 5vw, 96px);
  text-align: left;
}

.salt-layout .hire-lead,
.salt-layout .hire-note,
.salt-layout .hire-points {
  margin-left: 0;
  margin-right: 0;
  max-width: none;
}

.salt-layout .hire-actions {
  justify-content: flex-start;
}

.salt-how {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.salt-page .hire-title,
.salt-page .hire-points li strong {
  color: var(--white);
}

.salt-page .hire-lead,
.salt-page .hire-points li {
  color: #d6d6d6;
}

.salt-page .hire-label,
.salt-page .hire-note,
.salt-page .salt-form label {
  color: #a8a8a8;
}

.salt-page .hire-note a {
  color: var(--white);
}

.salt-page .hire-points li {
  border-color: rgba(255, 255, 255, 0.18);
}

.salt-page .salt-form input,
.salt-page .salt-form textarea {
  background: rgba(0, 0, 0, 0.6);
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--white);
}

.salt-page .salt-form input:focus,
.salt-page .salt-form textarea:focus {
  border-color: var(--white);
}

.salt-page .btn-dark {
  background: var(--white);
  color: var(--black);
  border-color: var(--white);
}

.salt-page .btn-dark:hover {
  background: transparent;
  color: var(--white);
}

.salt-page .salt-error {
  color: #ff8a8a;
}

/* Mobile: figure stacks on top at full strength, text below */
@media (max-width: 860px) {
  .salt-figure {
    position: relative;
    width: 100%;
    height: 0;
    padding-top: 92%;
  }

  .salt-slide img {
    object-fit: cover;
    object-position: left top;
  }

  .salt-figure::after {
    background: linear-gradient(to top, #000 0%, rgba(0, 0, 0, 0) 22%);
  }

  .salt-content {
    margin-top: -24px;
  }

  .salt-layout {
    width: auto;
    padding: 0 20px;
    text-align: center;
  }

  .salt-layout .hire-actions {
    justify-content: center;
  }
}

/* Ask Salt — dictation mic */
.salt-question-wrap {
  position: relative;
}

.salt-question-wrap textarea {
  padding-right: 60px;
}

.salt-mic {
  position: absolute;
  right: 10px;
  bottom: 12px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.7);
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.salt-mic[hidden] {
  display: none;
}

.salt-mic:hover,
.salt-mic:focus-visible {
  border-color: var(--white);
  outline: none;
}

.salt-mic.is-listening {
  background: #d32f2f;
  border-color: #ff6b6b;
  animation: salt-mic-pulse 1.3s ease-out infinite;
}

@keyframes salt-mic-pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 82, 82, 0.6); }
  100% { box-shadow: 0 0 0 16px rgba(255, 82, 82, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .salt-mic.is-listening { animation: none; }
  .salt-slide { transition: none; }
}

.salt-mic-status {
  min-height: 1.2em;
  font-size: 12px;
  color: #ff9d9d;
  letter-spacing: 0.04em;
}

.salt-mic-status:empty {
  min-height: 0;
}

/* Ask Salt — master texts section */
.salt-master-intro {
  font-size: 15px;
  font-weight: 500;
  color: var(--white);
  margin: -12px 0 16px;
}

.salt-steps {
  list-style: none;
  counter-reset: salt-step;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0 0 28px;
  text-align: left;
}

.salt-steps li {
  counter-increment: salt-step;
  position: relative;
  padding: 16px 18px 16px 60px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  font-size: 15px;
  font-weight: 300;
  line-height: 1.6;
  color: #d6d6d6;
}

.salt-steps li::before {
  content: counter(salt-step, decimal-leading-zero);
  position: absolute;
  left: 18px;
  top: 16px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.salt-steps li strong {
  color: var(--white);
  font-weight: 500;
}

.salt-master-status {
  border-left: 3px solid var(--accent);
  background: rgba(123, 77, 255, 0.1);
  padding: 16px 18px;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.7;
  color: #e6e6e6;
  text-align: left;
}

/* Ask Salt — slim notes under the form */
.salt-notes {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.salt-notes p {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.7;
  color: #d6d6d6;
}

.salt-notes a {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.salt-notes .hire-note {
  margin: 0;
  max-width: none;
}

/* Master texts explainer on the light project page */
.master-explainer {
  max-width: 760px;
  margin: 64px auto 0;
  text-align: left;
}

.master-explainer h2 {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.master-explainer > p {
  font-size: 16px;
  font-weight: 300;
  color: var(--gray-600);
  line-height: 1.7;
  margin-bottom: 20px;
}

.master-explainer .salt-master-intro {
  color: var(--black);
  margin: 0 0 16px;
}

.master-explainer .salt-steps li {
  background: var(--off-white);
  border-color: var(--gray-200);
  color: var(--gray-600);
}

.master-explainer .salt-steps li strong {
  color: var(--black);
}

.master-explainer .salt-master-status {
  color: var(--gray-800);
  background: rgba(123, 77, 255, 0.07);
  margin-bottom: 32px;
}

.master-explainer .hire-points {
  max-width: none;
  margin: 0;
}

/* Master text page: explainer is the whole page */
.project-page .master-explainer {
  margin-top: 24px;
}

.master-explainer h1 {
  font-size: clamp(26px, 4vw, 36px);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.project-page > .back-link {
  display: block;
  max-width: 760px;
  margin: 0 auto;
  text-align: left;
}

/* Master text page — dark, matching Ask Salt */
.master-page {
  background: var(--black);
  color: var(--white);
  min-height: calc(100vh - var(--nav-h));
}

.master-page .back-link {
  color: #a8a8a8;
}

.master-page .back-link:hover {
  color: var(--white);
}

.master-page .master-explainer h1 {
  color: var(--white);
}

.master-page .master-explainer > p {
  color: #d6d6d6;
}

.master-page .master-explainer .salt-master-intro {
  color: var(--white);
}

.master-page .master-explainer .salt-steps li {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.16);
  color: #d6d6d6;
}

.master-page .master-explainer .salt-steps li strong {
  color: var(--white);
}

.master-page .master-explainer .salt-master-status {
  background: rgba(123, 77, 255, 0.1);
  color: #e6e6e6;
}

/* Ask Salt — topic picker (dark theme) */
.salt-part {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 1rem;
  padding: 0.7rem 2.4rem 0.7rem 0.8rem;
  font: inherit;
  font-size: 1rem;
  color: #fff;
  background: #000 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath fill='%23fff' d='M0 0l6 8 6-8z'/%3E%3C/svg%3E") no-repeat right 0.9rem center;
  border: 1px solid rgba(255,255,255,0.45);
  border-radius: 6px;
  -webkit-appearance: none;
  appearance: none;
}
.salt-part:focus { outline: 2px solid #fff; outline-offset: 2px; }
.salt-part option { color: #fff; background: #000; }
.salt-part optgroup { color: #fff; background: #000; font-weight: 700; font-style: normal; }
.salt-design-note { margin: -0.5rem 0 1rem; font-size: 0.9rem; color: rgba(255,255,255,0.75); font-style: italic; }
#salt-part-wrap[hidden], .salt-design-note[hidden] { display: none; }

/* Ask Salt: designs under development are shown but not selectable */
#salt-design option:disabled { color: #777; }

/* Research gallery: uniform square boxes, whole image shown, padded with white (no crop) */
.card-media--letterbox {
  background: #ffffff;
}

.card-media--letterbox img {
  object-fit: contain;
}

/* Footer: wrap links on narrow screens (no sideways scroll) + X / YouTube logo links (2026-11-02) */
.footer-links { flex-wrap: wrap; gap: 12px 24px; align-items: center; }
.footer-icon-link { display: inline-flex; align-items: center; line-height: 0; padding: 2px; }
.footer-icon { width: 20px; height: 20px; display: block; }
@media (max-width: 768px) {
  .footer-inner { justify-content: center; text-align: center; }
  .footer-links { justify-content: center; gap: 12px 18px; }
}

/* ORNL Master Text: Salt's video notes (2026-11-02) */
.master-videos { margin-top: 2.5rem; }
.master-videos-lead { font-style: italic; margin-bottom: 1.25rem; }
.master-video-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 24px; }
.master-video-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.master-video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.master-video-caption { font-size: 0.92rem; margin-top: 0.5rem; line-height: 1.45; }
.master-video-caption a { text-decoration: underline; }
.footer-links li { display: flex; align-items: center; min-height: 24px; }
.master-video-lite { display: block; cursor: pointer; }
.master-video-lite img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.9; transition: opacity 0.15s; }
.master-video-lite:hover img, .master-video-lite:focus-visible img { opacity: 1; }
.master-video-play { position: absolute; left: 50%; top: 50%; width: 64px; height: 44px; margin: -22px 0 0 -32px; border-radius: 10px; background: rgba(0,0,0,0.75); }
.master-video-play::after { content: ""; position: absolute; left: 26px; top: 13px; border-style: solid; border-width: 9px 0 9px 15px; border-color: transparent transparent transparent #fff; }
.master-video-lite:hover .master-video-play { background: #c00; }

/* Hidden Ask Salt tab + secret purple dot (js/salt-unlock.js), 2026-11-14.
   Dot sits at the far right of the menu bar; click to show/hide the Ask Salt tab. */
.salt-nav-tab[hidden] { display: none !important; }
.salt-unlock {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255, 255, 255, 0.22);
  font-size: 36px;
  line-height: 28px;
  cursor: pointer;
}
.salt-unlock:hover,
.salt-unlock:focus-visible,
.salt-unlock[aria-pressed="true"] {
  color: var(--accent);
  outline: none;
}
/* keep the dot on phones, where the @Nuclear_Archive link is hidden */
@media (max-width: 768px) {
  .nav-right { display: flex; order: 2; margin-left: auto; margin-right: 8px; }
  .nav-right a { display: none; }
  .nav-toggle { order: 3; }
}
