/* ==========================================================================
   Saba LT — design system (black & white)
   Space Grotesk (display) · IBM Plex Sans (body) · IBM Plex Mono (labels)
   Ported from the Claude Design project "Saba LT".
   ========================================================================== */

:root {
  --bg: #ffffff;
  --ink: #0a0a0a;
  --muted: #555555;
  --muted-2: #666666;
  --accent: #111111;
  --accent-hover: #333333;
  --sky: #e6e6e6; /* light accent on dark sections */
  --dark: #0a0a0a;
  --dark-ink: #f2f2f2;
  --dark-muted: #b4b4b4;
  --dark-faint: #8a8a8a;
  --line: #e2e2e2;
  --line-dark: rgba(255, 255, 255, 0.12);

  --display: "Space Grotesk", system-ui, sans-serif;
  --sans: "IBM Plex Sans", system-ui, -apple-system, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; overscroll-behavior: none; }

/* Hide the scrollbar entirely (the page still scrolls). Avoids the white
   track/column on the right, and — since the bar never reserves width —
   keeps the layout from shifting between short and long pages. */
html, body { scrollbar-width: none; -ms-overflow-style: none; }
html::-webkit-scrollbar, body::-webkit-scrollbar { width: 0; height: 0; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

/* sticky footer: the content region grows so the footer sits at the bottom
   even on short pages */
body > main,
body > .home-hero { flex: 1 0 auto; }
.site-footer { flex-shrink: 0; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
::selection { background: #111111; color: #ffffff; }

/* --- shared bits --------------------------------------------------------- */

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 22px;
}

.wordmark { font-family: var(--display); font-weight: 700; letter-spacing: -0.01em; }

.lede { color: var(--muted); font-size: 18px; line-height: 1.62; }

.page { max-width: 1080px; margin: 0 auto; padding: 40px; }

/* --- header -------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
  background: rgba(255, 255, 255, 0.82);
  border-bottom: 1px solid var(--line);
}

.site-header > .bar,
.site-header {
  /* the header's inner row */
}

.site-header {
  display: block;
}

.site-header .bar {
  max-width: 1080px;
  margin: 0 auto;
  padding: 16px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
}
.brand:hover { color: var(--ink); }

/* Logo mark, rendered black directly (no square background). */
.brand-logo { height: 20px; width: auto; display: block; filter: brightness(0); }

.brand .wordmark { font-size: 19px; }

.site-nav { display: flex; align-items: center; gap: 28px; }

.site-nav a {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--muted-2);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a[aria-current="page"] { color: var(--ink); }

.site-nav a.nav-cta {
  font-weight: 600;
  color: var(--bg);
  background: var(--accent);
  padding: 9px 18px;
}
.site-nav a.nav-cta:hover { background: var(--accent-hover); color: var(--bg); }

/* tighten the header on phones so the brand and nav don't collide */
@media (max-width: 40rem) {
  .site-header .bar { padding: 12px 18px; }
  .brand { gap: 9px; }
  .brand .wordmark { font-size: 17px; }
  .site-nav { gap: 15px; }
  .site-nav a { font-size: 13.5px; }
  .site-nav a.nav-cta { padding: 8px 13px; }
}
@media (max-width: 22rem) {
  .site-nav { gap: 11px; }
  .brand .wordmark { display: none; } /* logo alone if it's really tight */
}

/* --- dark hero (home) with fractal --------------------------------------- */

.home-hero {
  position: relative;
  /* No fixed min-height: as a flex:1 0 auto child of the 100vh body column it
     grows to fill exactly header→footer, so the page is one screen, no scroll. */
  min-height: 0;
  background: var(--bg);
  overflow: hidden;
  display: flex;
}

#fractal { position: absolute; inset: 0; width: 100%; height: 100%; }

/* fade the white fractal to solid white on the left so the copy stays legible */
.home-hero .scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 255, 255, 0.78) 42%, rgba(255, 255, 255, 0.1) 72%);
}

.home-hero .inner {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  width: 100%;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--ink);
}

.home-hero .eyebrow { color: var(--muted); margin-bottom: 26px; }

.home-hero h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 58px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin: 0;
  max-width: 15ch;
  text-shadow: 0 2px 30px rgba(255, 255, 255, 0.9);
}

.home-hero .lede {
  max-width: 540px;
  color: var(--muted);
  font-size: 19px;
  margin: 28px 0 30px;
  text-shadow: 0 1px 14px rgba(255, 255, 255, 0.9);
}

.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.btn {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 15px;
  padding: 14px 26px;
  border: 0;
  cursor: pointer;
  display: inline-block;
}
.btn-primary { background: var(--accent); color: var(--bg); }
.btn-primary:hover { background: var(--accent-hover); color: var(--bg); }
.btn-ghost { border: 1px solid rgba(10, 10, 10, 0.28); color: var(--ink); padding: 13px 24px; }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }

/* --- light heros / sections --------------------------------------------- */

.hero { padding: 88px 0 8px; }
.hero h1, .hero .wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.2rem, 5vw, 44px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0;
  color: var(--ink);
}
.hero .lede { max-width: 620px; margin-top: 22px; }
.hero .role-location {
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.06em;
  color: var(--accent);
  margin: 14px 0 0;
}

.section-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 32px;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}

/* --- about statement ----------------------------------------------------- */

.about-page { }
.statement { max-width: 760px; }
.statement-lead {
  font-family: var(--display);
  font-weight: 500;
  font-size: 27px;
  line-height: 1.3;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--ink);
}
.statement .rule { display: none; }
.statement ul { list-style: none; margin: 30px 0 0; padding: 0; border-top: 1px solid var(--line); }
.statement li {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 17px;
  padding-left: 0;
}
.statement li::before { content: none; }
.statement-link {
  display: inline-block;
  margin-top: 28px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--accent);
}

/* --- culture cards ------------------------------------------------------- */

.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); margin: 32px 0; }
@media (max-width: 40rem) { .cards { grid-template-columns: 1fr; } }
.card { background: var(--bg); padding: 28px; }
.card h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
  color: var(--ink);
}
.card p { margin: 0; color: var(--muted); font-size: 15.5px; }

/* --- panels (role postings, form) ---------------------------------------- */

.panel { margin-top: 40px; }
.hero + .panel { margin-top: 24px; }
.panel h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 24px;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  color: var(--ink);
}
.panel > p { color: var(--muted); font-size: 17px; }
.panel > .lede { margin: 0 0 20px; }
.panel ul { margin: 14px 0 0; padding-left: 1.15rem; color: var(--muted); }
.panel li { margin: 8px 0; }
.panel form { display: flex; flex-direction: column; gap: 18px; margin-top: 8px; }
.panel .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 40rem) { .panel .row { grid-template-columns: 1fr; } }

/* --- role list (overview) ------------------------------------------------ */

.role-list { display: flex; flex-direction: column; margin-top: 28px; border-top: 1px solid var(--line); }
.big-link {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 20px;
  padding: 26px 4px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  transition: padding-left 0.15s ease;
}
.big-link:hover { padding-left: 12px; color: var(--ink); }
.big-link-title { font-family: var(--display); font-weight: 600; font-size: 22px; letter-spacing: -0.02em; }
.big-link-sub { font-family: var(--mono); font-size: 12.5px; letter-spacing: 0.04em; color: var(--muted-2); }
.big-link-arrow { margin-left: auto; color: var(--accent); font-family: var(--mono); }

/* --- CTA (Interested?) --------------------------------------------------- */

.cta-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-top: 40px;
  padding: 28px 30px;
  background: var(--dark);
  color: var(--dark-ink);
}
.cta-strip:hover { color: var(--dark-ink); }
.cta-strip-prompt { font-family: var(--display); font-weight: 600; font-size: 20px; letter-spacing: -0.02em; }
.cta-link { color: var(--sky); font-family: var(--mono); font-size: 13px; letter-spacing: 0.04em; }
.cta-strip:hover .cta-link { color: #ffffff; }

/* --- benefits / note ----------------------------------------------------- */

.benefits { margin-top: 44px; }
.benefits h2 { font-family: var(--display); font-weight: 700; font-size: 24px; letter-spacing: -0.02em; margin: 0 0 18px; }
.benefit-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; }
@media (max-width: 40rem) { .benefit-grid { grid-template-columns: 1fr; } }
.benefit-grid li {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 15.5px;
}
.benefit-grid li::before { content: "\2192"; color: var(--accent); font-family: var(--mono); }

.note { margin-top: 44px; }
.note h2 { font-family: var(--display); font-weight: 700; font-size: 24px; letter-spacing: -0.02em; margin: 0 0 8px; }
.note p { margin: 0; max-width: 620px; color: var(--muted); }

/* --- forms --------------------------------------------------------------- */

.field { display: flex; flex-direction: column; gap: 7px; }
.field label {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
  order: -1;
}
.field input, .field textarea, .field select {
  width: 100%;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 2px;
  color: var(--ink);
  font: inherit;
}
.field textarea { resize: vertical; min-height: 6rem; }
.field input::placeholder, .field textarea::placeholder { color: transparent; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.12);
}
.select-field { position: relative; }
.select-field::after {
  content: "\25BE"; position: absolute; right: 14px; bottom: 13px;
  color: var(--muted-2); pointer-events: none;
}
.field select { appearance: none; -webkit-appearance: none; cursor: pointer; }
.field select option { color: var(--ink); background: #fff; }

.checks { border: 0; margin: 0; padding: 0; }
.checks legend {
  padding: 0;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
  margin-bottom: 10px;
}
.check-row { display: flex; flex-wrap: wrap; gap: 8px; }
.check {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
}
.check input { accent-color: var(--accent); width: 15px; height: 15px; margin: 0; }
.check:hover { border-color: var(--muted-2); color: var(--ink); }
.check:has(input:checked) { border-color: var(--accent); background: #f2f2f2; color: var(--ink); }

.file-field {
  position: relative;
  display: flex; align-items: center; gap: 14px;
  padding: 16px;
  border: 1.5px dashed var(--line);
  background: #fff;
  color: var(--muted-2);
}
.file-field:hover, .file-field:focus-within { border-color: var(--accent); }
.file-field input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.file-field .doc { font-size: 1.2rem; }
.file-field .file-name { color: var(--ink); }

button[type="submit"], .btn-submit {
  align-self: flex-start;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 26px;
  border: 0;
  background: var(--accent);
  color: var(--bg);
  cursor: pointer;
}
button[type="submit"]:hover { background: var(--accent-hover); }
button[type="submit"]:disabled { opacity: 0.6; cursor: wait; }

.error { color: #c0392b; margin: 0; font-size: 0.95rem; }
.ok { color: #1a7f4b; margin: 0; }
#apply-status.ok { font-family: var(--display); font-size: 1.15rem; }

/* --- gate: frozen fractal that scales with scroll; password modal reveals -- */

/* Fixed single screen — scroll/drag is captured by fractal.js and turned into
   fractal zoom depth, so the page itself never scrolls (endless zoom). */
.gate-journey { position: fixed; inset: 0; touch-action: none; }

.gate-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--bg);
  display: grid;
  place-items: center;
}
.gate-stage #fractal {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
/* soft white glow behind the wordmark so it stays legible over the fractal */
.gate-stage .scrim {
  position: absolute;
  inset: 0;
  background: radial-gradient(52% 52% at 50% 50%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 60%);
}

.gate-hero-content { position: relative; z-index: 1; text-align: center; color: var(--ink); }
.gate-wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.6rem, 9vw, 84px);
  letter-spacing: 0.02em;
  margin: 0;
  text-shadow: 0 2px 40px rgba(255, 255, 255, 0.95);
}
.scroll-cue {
  display: block;
  margin-top: 34px;
  color: var(--ink);
  font-size: 1.4rem;
  cursor: pointer;
  animation: bob 2.2s ease-in-out infinite;
}
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(9px); } }

/* password modal — fades/rises in as you reach the bottom of the scroll */
.gate-modal {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
}
.gate-card {
  width: min(22rem, 90%);
  padding: 34px 30px;
  /* smoked translucent glass — reads on the white fractal, and the zoom origin
     shows through behind the card */
  background: rgba(10, 10, 10, 0.34);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--dark-ink);
  text-align: center;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
.gate-lockup { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 22px; }
.gate-lockup .wordmark { font-size: 1.5rem; color: var(--dark-ink); }
.gate-card .brand-logo { filter: brightness(0) invert(1); } /* white logo on the dark glass */
.gate-card form { display: flex; flex-direction: column; gap: 12px; }
.gate-card input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--dark-ink);
  font: inherit;
}
.gate-card input::placeholder { color: rgba(255, 255, 255, 0.55); }
.gate-card input:focus { outline: none; border-color: var(--dark-ink); box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.16); }
.gate-card button[type="submit"] { width: 100%; align-self: auto; background: #fff; color: var(--dark); }
.gate-card button[type="submit"]:hover { background: var(--sky); }
.shake { animation: shake 0.4s; }

/* --- footer -------------------------------------------------------------- */

.site-footer {
  background: transparent;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
}
.site-footer .bar,
.site-footer {
  font-family: var(--mono);
  font-size: 12px;
}
.site-footer .bar {
  max-width: 1080px; margin: 0 auto; padding: 24px 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.site-footer a { color: var(--muted-2); }
.site-footer a:hover { color: var(--ink); }

/* --- motion -------------------------------------------------------------- */

@keyframes riseIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes shake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-3px); }
  40%, 60% { transform: translateX(3px); }
}
.reveal { animation: riseIn 0.6s ease both; }

/* Note: we intentionally do NOT gate animations on prefers-reduced-motion —
   the site plays its motion regardless of the OS setting (per product choice). */
