/* ════════════════════════════════════════════════════════════════
   Parikalp — style.css
   Palette: deep navy (tuned toward the logo) · YC orange · off-white.
   Orange is used sparingly: it marks "the answer" and the main action.
   ════════════════════════════════════════════════════════════════ */

/* ── Fonts (self-hosted from Google Fonts, SIL Open Font License) ── */
@font-face {
  font-family: 'Geologica'; font-style: normal; font-weight: 300 700; font-display: swap;
  src: url(fonts/geologica-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geologica'; font-style: normal; font-weight: 300 700; font-display: swap;
  src: url(fonts/geologica-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'B612'; font-style: normal; font-weight: 400; font-display: swap;
  src: url(fonts/b612-400.woff2) format('woff2');
}
@font-face {
  font-family: 'B612'; font-style: normal; font-weight: 700; font-display: swap;
  src: url(fonts/b612-700.woff2) format('woff2');
}

:root {
  --ground:      #11253F;
  --ground-2:    #163050;
  --ground-3:    #0C1C32;
  --ink:         #F5F2EC;
  --ink-2:       #C8C6CC;
  --ink-3:       #8E9DB0;
  --rule:        rgba(245, 242, 236, 0.13);
  --rule-2:      rgba(245, 242, 236, 0.26);
  --signal:      #FF6600;
  --signal-text: #FF7A26;
  --signal-mark: #FF6600;
  --error:       #FF8A7A;
  --field-border: #64758D;
  --control-border: #6B7C94;
  --chevron:     url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5l5 5 5-5' stroke='%238E9DB0' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --on-signal:   #11253F;
  --field:       #0D1F36;
  --shadow:      0 30px 60px -30px rgba(4, 8, 24, 0.7);
  --sheen:       rgba(245, 242, 236, 0.07);
  --grid:        rgba(245, 242, 236, 0.06);

  --f-sans: 'Geologica', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-tech: 'B612', 'Segoe UI', system-ui, sans-serif;
  --w-body: 380;

  --nav-h: 68px;
  --gutter: 16px;
  --r-lg: 18px;
  --r-md: 12px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  color-scheme: dark;
}

:root[data-theme="light"] {
  --ground:      #F5F2EC;
  --ground-2:    #ECE7DD;
  --ground-3:    #FFFFFF;
  --ink:         #11253F;
  --ink-2:       #3C4D63;
  --ink-3:       #56657A;
  --rule:        rgba(17, 37, 63, 0.13);
  --rule-2:      rgba(17, 37, 63, 0.26);
  --signal:      #FF6600;
  --signal-text: #A84000;
  --signal-mark: #D65400;
  --error:       #B42318;
  --field-border: #7D8899;
  --control-border: #748093;
  --chevron:     url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5l5 5 5-5' stroke='%2356657A' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --on-signal:   #11253F;
  --field:       #FFFFFF;
  --shadow:      0 30px 60px -34px rgba(17, 37, 63, 0.3);
  --sheen:       rgba(255, 255, 255, 0.9);
  --grid:        rgba(17, 37, 63, 0.07);
  --w-body: 380;
  color-scheme: light;
}

@media (min-width: 768px) { :root { --gutter: 32px; } }

/* ── Base ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 12px);
  -webkit-text-size-adjust: 100%;
}
body {
  background: var(--ground);
  color: var(--ink);
  font-family: var(--f-sans);
  font-weight: var(--w-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  transition: background-color 0.3s ease, color 0.3s ease;
}
[hidden] { display: none !important; }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
strong { font-weight: 560; color: var(--ink); }

h1, h2, h3 { font-weight: 500; line-height: 1.1; letter-spacing: -0.015em; text-wrap: balance; }
h2 { font-size: clamp(1.9rem, 1.3rem + 2.4vw, 2.85rem); letter-spacing: -0.022em; }
h3 { font-size: 1.125rem; font-weight: 560; line-height: 1.3; letter-spacing: -0.005em; }
p { text-wrap: pretty; }

:focus-visible { outline: 2px solid var(--signal-mark); outline-offset: 3px; border-radius: 4px; }
::selection { background: color-mix(in srgb, var(--signal) 38%, transparent); color: var(--ink); }

/* Drafting grid behind page headers: the one piece of atmosphere, faded out toward the copy */
.hero, .page-hero, .paper-hero { position: relative; isolation: isolate; }
.hero::before, .page-hero::before, .paper-hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 60% 75% at 78% 45%, #000 15%, transparent 72%);
  mask-image: radial-gradient(ellipse 60% 75% at 78% 45%, #000 15%, transparent 72%);
}
@media (max-width: 900px) {
  .hero::before, .page-hero::before, .paper-hero::before {
    -webkit-mask-image: radial-gradient(ellipse 90% 60% at 60% 70%, #000 10%, transparent 75%);
    mask-image: radial-gradient(ellipse 90% 60% at 60% 70%, #000 10%, transparent 75%);
  }
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--gutter); top: -100px; z-index: 200;
  background: var(--signal); color: var(--on-signal);
  padding: 10px 16px; border-radius: 999px; font-weight: 560; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.wrap { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: var(--gutter); }

/* ── Buttons ───────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 24px;
  border-radius: 999px; border: 1px solid transparent;
  font-size: 1rem; font-weight: 520; letter-spacing: -0.005em;
  text-decoration: none; white-space: nowrap;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s var(--ease);
}
.btn-primary { background: var(--signal); color: var(--on-signal); }
.btn-primary:hover { background: color-mix(in srgb, var(--signal) 88%, var(--ink)); }
.btn-primary:active { transform: translateY(1px); }
.btn-primary:disabled { opacity: 0.6; cursor: progress; }
.btn-quiet { border-color: var(--control-border); color: var(--ink); }
.btn-quiet:hover { border-color: var(--ink-2); }
.btn-block { width: 100%; }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--rule); background: transparent; color: var(--ink-2);
  transition: color 0.2s ease, border-color 0.2s ease;
}
.icon-btn:hover { color: var(--ink); border-color: var(--rule-2); }

/* Language switch: two links in one pill, the current language filled */
.lang-switch {
  display: inline-flex; align-items: center; gap: 2px;
  height: 40px; padding: 3px;
  border: 1px solid var(--rule); border-radius: 999px;
}
.lang-switch a {
  display: inline-grid; place-items: center;
  height: 100%; min-width: 34px; padding: 0 10px; border-radius: 999px;
  font-size: 0.8125rem; font-weight: 520; line-height: 1; letter-spacing: 0.01em;
  color: var(--ink-3); text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease;
}
.lang-switch a:hover { color: var(--ink); }
.lang-switch a[aria-current="true"] { color: var(--ink); background: color-mix(in srgb, var(--ink) 13%, transparent); }

/* ── Nav ───────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
.nav.is-scrolled {
  background: color-mix(in srgb, var(--ground) 86%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom-color: var(--rule);
}
.nav-inner { height: 100%; display: flex; align-items: center; gap: 12px; }

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.brand img { border-radius: 50%; }
.brand span { font-size: 1.2rem; font-weight: 560; letter-spacing: -0.02em; }

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
  padding: 8px 12px; border-radius: 999px;
  font-size: 0.9375rem; color: var(--ink-2); text-decoration: none;
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a.nav-cta { margin-left: 8px; border: 1px solid var(--control-border); color: var(--ink); padding-inline: 16px; }
.nav-links a.nav-cta:hover { border-color: var(--signal); }

.theme-toggle .i-sun { display: none; }
[data-theme="light"] .theme-toggle .i-sun { display: block; }
[data-theme="light"] .theme-toggle .i-moon { display: none; }

.nav-toggle { display: none; flex-direction: column; align-items: center; justify-content: center; gap: 5px; }
.nav-toggle span { display: block; width: 16px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform 0.25s var(--ease); }
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.25px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child  { transform: translateY(-3.25px) rotate(-45deg); }

/* 44px touch targets on phones and tablets */
@media (max-width: 900px) {
  .icon-btn { width: 44px; height: 44px; }
  .chip { min-height: 44px; }
}

@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--ground);
    border-bottom: 1px solid var(--rule);
    box-shadow: var(--shadow);
    visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.25s var(--ease), visibility 0s linear 0.25s;
  }
  .nav-links.is-open { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
  .nav-links a { padding: 14px 4px; border-radius: 0; border-bottom: 1px solid var(--rule); font-size: 1.0625rem; }
  .nav-links a.nav-cta { margin: 16px 0 0; text-align: center; border-radius: 999px; border: 1px solid var(--signal); padding: 12px; }
  .nav.is-open { background: var(--ground); border-bottom-color: var(--rule); }
}

/* ── Hero ──────────────────────────────────────────────────────── */
.hero { position: relative; margin-top: calc(var(--nav-h) * -1); padding-top: var(--nav-h); }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  align-items: center;
  gap: 24px;
  min-height: min(calc(100vh - var(--nav-h)), 900px);
  min-height: min(calc(100svh - var(--nav-h)), 900px);
}
.hero-copy { padding-block: 48px; position: relative; z-index: 2; }
.hero h1 {
  font-size: clamp(2.75rem, 1.6rem + 4.6vw, 5.25rem);
  font-weight: 480;
  line-height: 0.98;
  letter-spacing: -0.035em;
  max-width: 11ch;
}
.lede {
  margin-top: 28px;
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 34rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero-note { margin-top: 28px; font-size: 0.875rem; color: var(--ink-3); max-width: 30rem; }

.hero-figure { position: relative; align-self: stretch; min-height: 560px; margin: 0; }
#treeCanvas { position: absolute; inset: 0; width: 100%; height: 100%; }

.callout {
  position: absolute; left: 0; top: 0; z-index: 2;
  display: flex; flex-direction: column; gap: 2px;
  max-width: 250px;
  padding: 9px 13px 10px;
  border: 1px solid var(--rule-2);
  border-radius: var(--r-md);
  background: color-mix(in srgb, var(--ground) 84%, transparent);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  font-family: var(--f-tech);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.45s ease, transform 0.45s var(--ease);
  pointer-events: none;
}
.callout.is-shown { opacity: 1; transform: none; }
.callout-k { font-size: 0.72rem; color: var(--ink-3); letter-spacing: 0.01em; }
.callout-v { font-size: 0.86rem; line-height: 1.4; color: var(--ink); }
.callout-a { border-color: color-mix(in srgb, var(--signal-mark) 70%, transparent); }
.callout-a .callout-k { color: var(--signal-text); }

.ground-label {
  position: absolute; left: 4px; top: var(--ground-y, 60%);
  font-family: var(--f-tech); font-size: 0.72rem; color: var(--ink-3);
  pointer-events: none;
}
.ground-label-up   { transform: translateY(calc(-100% - 8px)); }
.ground-label-down { transform: translateY(8px); }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; min-height: 0; gap: 0; }
  .hero-copy { padding-block: 40px 8px; }
  .hero-figure { min-height: 470px; }
  .callout { max-width: 210px; }
}
@media (max-width: 560px) { .ground-label { display: none; } }

/* ── Sections ──────────────────────────────────────────────────── */
.section { padding-block: clamp(80px, 10vw, 136px); }
.section-alt { background: var(--ground-2); border-block: 1px solid var(--rule); }
.section-lede { font-size: 1.125rem; line-height: 1.6; color: var(--ink-2); max-width: 36rem; }

.split {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 24px; row-gap: 20px;
  align-items: end;
  margin-bottom: clamp(48px, 6vw, 72px);
}
.split > :first-child { grid-column: 1 / span 6; max-width: 17ch; }
.split > :last-child  { grid-column: 8 / -1; }
.split-top { align-items: start; margin-bottom: 0; }
.split-top > :first-child { grid-column: 1 / span 5; }
.split-top > :last-child  { grid-column: 6 / -1; }
@media (max-width: 860px) {
  .split, .split-top { grid-template-columns: 1fr; }
  .split > :first-child, .split > :last-child,
  .split-top > :first-child, .split-top > :last-child { grid-column: 1 / -1; }
}

/* Ruled columns, shared by problems / capabilities / sectors / security */
.problems, .capabilities, .sectors, .security {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 32px;
}
/* Each column opens with a hairline and a short heavier tick, like a dimension line */
.problems > li, .capabilities > article, .sectors > article, .security > div {
  border-top: 1px solid var(--rule-2); padding-top: 24px;
  background: linear-gradient(var(--ink-2), var(--ink-2)) left top / 28px 2px no-repeat;
}
.problems h3, .capabilities h3, .sectors h3, .security dt { margin-bottom: 10px; font-size: 1.25rem; letter-spacing: -0.012em; }
.problems p, .capabilities p, .sectors p, .security dd { color: var(--ink-2); font-size: 1.03rem; line-height: 1.62; }
@media (max-width: 860px) {
  .problems, .capabilities, .sectors, .security { grid-template-columns: 1fr; gap: 32px; }
}

/* ── Cost calculator ───────────────────────────────────────────── */
.calc {
  margin-top: clamp(64px, 8vw, 96px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px;
  padding: clamp(28px, 4vw, 48px);
  background: var(--ground-2);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: inset 0 1px 0 var(--sheen);
}
.calc-inputs { display: flex; flex-direction: column; gap: 26px; }
.calc-inputs h3 { font-size: 1.25rem; }
.field-range label { display: flex; justify-content: space-between; gap: 16px; font-size: 0.9375rem; color: var(--ink-2); margin-bottom: 10px; }
.field-range output { font-family: var(--f-tech); color: var(--ink); font-variant-numeric: tabular-nums; }

input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 22px; background: transparent; cursor: pointer;
  --pct: 50%;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 3px; border-radius: 3px;
  background: linear-gradient(to right, var(--signal-mark) var(--pct), var(--rule-2) var(--pct));
}
input[type="range"]::-moz-range-track { height: 3px; border-radius: 3px; background: var(--rule-2); }
input[type="range"]::-moz-range-progress { height: 3px; border-radius: 3px; background: var(--signal-mark); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; margin-top: -7.5px; border-radius: 50%;
  background: var(--ink); border: 4px solid var(--signal-mark);
}
input[type="range"]::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: var(--ink); border: 4px solid var(--signal-mark); }
input[type="range"]:focus-visible { outline-offset: 6px; }

.calc-result { display: flex; flex-direction: column; justify-content: flex-end; gap: 14px; border-left: 1px solid var(--rule); padding-left: 48px; }
.calc-figure {
  font-size: clamp(2.75rem, 1.8rem + 3.6vw, 4.5rem);
  font-weight: 460; letter-spacing: -0.035em; line-height: 1;
  font-variant-numeric: tabular-nums;
}
.calc-caption { color: var(--ink-2); max-width: 26rem; }
@media (max-width: 860px) {
  .calc { grid-template-columns: 1fr; gap: 36px; }
  .calc-result { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); padding-top: 28px; }
}

/* ── How it works ──────────────────────────────────────────────── */
.pipeline {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px;
  margin-bottom: clamp(64px, 8vw, 96px);
  counter-reset: none;
}
.pipeline li { position: relative; }
.pipeline li::before {
  content: ''; position: absolute; top: 16px; left: 44px; right: -24px; height: 1px;
  background: var(--rule-2);
}
.pipeline li:last-child::before { display: none; }
.step-n {
  display: inline-grid; place-items: center;
  width: 33px; height: 33px; border-radius: 50%;
  border: 1px solid var(--rule-2);
  font-family: var(--f-tech); font-size: 0.875rem; color: var(--ink-2);
  margin-bottom: 18px;
}
.pipeline li:last-child .step-n { background: var(--signal); border-color: var(--signal); color: var(--on-signal); }
.pipeline h3 { margin-bottom: 6px; font-size: 1.25rem; letter-spacing: -0.012em; }
.pipeline p { color: var(--ink-2); font-size: 1rem; max-width: 24ch; }
@media (max-width: 860px) {
  .pipeline { grid-template-columns: 1fr; gap: 28px; }
  .pipeline li { padding-left: 52px; }
  .pipeline li::before { top: 40px; bottom: -22px; left: 16px; right: auto; width: 1px; height: auto; }
  .step-n { position: absolute; left: 0; top: -4px; margin: 0; }
  .pipeline p { max-width: none; }
}

.formats { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.formats span {
  font-family: var(--f-tech); font-size: 0.8rem; color: var(--ink-2);
  border: 1px solid var(--rule-2); border-radius: 999px; padding: 2px 10px;
}

/* ── Demo console ──────────────────────────────────────────────── */
.console {
  background: var(--ground-3);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: inset 0 1px 0 var(--sheen), var(--shadow);
  overflow: hidden;
}
.console-ask {
  display: flex; gap: 10px; align-items: center;
  padding: 14px 14px 14px 24px;
  border-bottom: 1px solid var(--rule);
}
.console-ask input {
  flex: 1; min-width: 0;
  background: transparent; border: 0; outline: 0;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.1875rem);
  color: var(--ink); padding: 10px 0;
}
.console-ask input::placeholder { color: var(--ink-3); }
.console-ask:focus-within { box-shadow: inset 0 -2px 0 var(--signal-mark); }

.console-suggest { display: flex; flex-wrap: wrap; gap: 8px; padding: 16px 24px; border-bottom: 1px solid var(--rule); }
.chip {
  background: transparent; border: 1px solid var(--control-border); border-radius: 999px;
  padding: 7px 14px; font-size: 0.875rem; color: var(--ink-2);
  transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}
.chip:hover { color: var(--ink); border-color: var(--ink-3); }
.chip[aria-pressed="true"] { color: var(--ink); border-color: var(--signal-mark); }
.chip:disabled { opacity: 0.5; cursor: default; }

.console-body { min-height: 380px; padding: 28px 24px 32px; }
.console-empty { position: relative; height: 320px; display: grid; justify-items: center; align-items: end; padding-bottom: 56px; text-align: center; color: var(--ink-3); }
.console-empty p { position: relative; max-width: 26ch; }

/* A faint outline of the result layout, so the empty console previews what an answer looks like */
.ghost {
  position: absolute; inset: 0;
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-content: start;
  -webkit-mask-image: linear-gradient(to bottom, #000 20%, transparent 92%);
  mask-image: linear-gradient(to bottom, #000 20%, transparent 92%);
}
.ghost-col > i { display: block; position: relative; height: 52px; border-top: 1px solid var(--rule); }
.ghost-col > i::before {
  content: ''; position: absolute; left: 0; top: 17px; height: 7px; width: 62%;
  border-radius: 4px; background: var(--rule);
}
.ghost-col > i:nth-child(2)::before { width: 48%; }
.ghost-col > i:nth-child(3)::before { width: 70%; }
.ghost-answer > i::before { left: 22px; width: 82%; }
.ghost-answer > i:nth-child(2)::before { width: 64%; }
.ghost-answer > i:nth-child(3)::before { width: 74%; }
.ghost-answer > i::after {
  content: ''; position: absolute; left: 2px; top: 16px; width: 8px; height: 8px;
  border-radius: 50%; border: 1.5px solid var(--rule-2);
}
.ghost-answer > i:first-child::after { background: color-mix(in srgb, var(--signal-mark) 55%, transparent); border-color: transparent; }

.console-status {
  font-family: var(--f-tech); font-size: 0.8125rem; color: var(--ink-3);
  margin-bottom: 24px; min-height: 1.4em;
}
.console-status.is-working::after {
  content: ''; display: inline-block; width: 6px; height: 6px; margin-left: 8px;
  border-radius: 50%; background: var(--signal-mark); vertical-align: middle;
  animation: blink 1s steps(2, start) infinite;
}
@keyframes blink { to { visibility: hidden; } }

.console-cols { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; }
.console-cols h3 { font-size: 0.9375rem; font-weight: 520; color: var(--ink-3); margin-bottom: 14px; }

#sourceList li {
  display: grid; grid-template-columns: 1fr auto; column-gap: 12px; row-gap: 6px;
  padding: 12px 0; border-top: 1px solid var(--rule);
  animation: rise 0.4s var(--ease) both;
}
#sourceList li:last-child { border-bottom: 1px solid var(--rule); }
.src-name { font-family: var(--f-tech); font-size: 0.8125rem; color: var(--ink); overflow-wrap: anywhere; }
.src-pct  { font-family: var(--f-tech); font-size: 0.8125rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.src-bar  { grid-column: 1 / -1; height: 2px; background: var(--rule); border-radius: 2px; overflow: hidden; }
.src-bar i { display: block; height: 100%; width: 0; background: var(--ink-3); transition: width 0.8s var(--ease); }
#sourceList li:first-child .src-bar i { background: var(--signal-mark); }

#answerList li {
  position: relative; padding: 10px 0 10px 22px; border-top: 1px solid var(--rule);
  animation: rise 0.35s var(--ease) both;
}
#answerList li::before {
  content: ''; position: absolute; left: 2px; top: 1.15em; width: 8px; height: 8px;
  border-radius: 50%; border: 1.5px solid var(--ink-3);
}
#answerList li.is-key::before { background: var(--signal-mark); border-color: var(--signal-mark); }
#answerList .cite { display: block; margin-top: 4px; font-family: var(--f-tech); font-size: 0.75rem; color: var(--ink-3); overflow-wrap: anywhere; }
.console-files { margin-top: 16px; color: var(--ink-2); font-size: 0.9375rem; }
.console-files summary { cursor: pointer; width: fit-content; }
.console-files summary:hover { color: var(--ink); }
.console-files ul { columns: 3 220px; column-gap: 32px; margin-top: 14px; }
.console-files li { font-family: var(--f-tech); font-size: 0.8125rem; color: var(--ink-2); padding: 3px 0; overflow-wrap: anywhere; break-inside: avoid; }
.console-nudge { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--rule); color: var(--ink-2); font-size: 0.9375rem; }
.console-nudge a { color: var(--ink); text-decoration-color: var(--signal); text-underline-offset: 3px; }

@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

@media (max-width: 760px) {
  .console-ask { padding: 12px 12px 12px 18px; }
  .console-ask .btn { padding: 0 18px; }
  .console-suggest { padding: 14px 18px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .console-suggest::-webkit-scrollbar { display: none; }
  .chip { flex-shrink: 0; }
  .console-body { padding: 22px 18px 26px; }
  .console-cols { grid-template-columns: 1fr; gap: 28px; }
  .ghost { grid-template-columns: 1fr; }
  .ghost-answer { display: none; }
}

/* ── Sectors ───────────────────────────────────────────────────── */
/* Line icons: off-white strokes in a ring (the logo's frame), one orange detail */
.ic {
  display: grid; place-items: center;
  width: 64px; height: 64px; margin-bottom: 20px;
  border: 1px solid var(--rule-2); border-radius: 50%;
  color: var(--ink);
}
.ic svg { width: 46px; height: 46px; }
.ic .ac { fill: var(--signal-mark); stroke: none; }
.ic .ac-line { stroke: var(--signal-mark); }
.security dt .ic { margin-bottom: 20px; }

.sectors .uses { margin-top: 14px; font-size: 0.875rem; color: var(--ink-3); }
.onboarding {
  margin-top: clamp(64px, 8vw, 96px);
  max-width: 44rem;
  font-size: clamp(1.25rem, 1.05rem + 0.8vw, 1.625rem);
  line-height: 1.4; letter-spacing: -0.01em;
  color: var(--ink-2);
}
.onboarding strong { font-weight: 500; }

/* ── Security ──────────────────────────────────────────────────── */
.security { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 48px; }
@media (max-width: 860px) { .security { grid-template-columns: 1fr; gap: 32px; } }
.security dt { font-size: 1.125rem; font-weight: 560; }
.security dd { margin: 0; max-width: 36rem; }

/* ── Team ──────────────────────────────────────────────────────── */
.founders { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 32px; }
.person img {
  width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover;
  border-radius: var(--r-md); background: var(--ground-3);
  margin-bottom: 20px;
  /* One monochrome treatment so mixed backdrops sit quietly on navy; color returns on hover */
  filter: grayscale(1) contrast(1.06) brightness(0.94);
  transition: filter 0.5s var(--ease);
}
.person:hover img { filter: none; }
.person h3 { font-size: 1.25rem; }
.person .role { font-family: var(--f-tech); font-size: 0.8125rem; color: var(--ink-2); margin: 4px 0 12px; }
.person p { color: var(--ink-2); font-size: 0.975rem; }
.person .creds { margin-top: 12px; font-size: 0.875rem; color: var(--ink-3); }
.person-link {
  display: inline-block; margin-top: 12px; font-size: 0.9375rem;
  text-decoration: underline; text-decoration-color: var(--rule-2); text-underline-offset: 4px;
  transition: text-decoration-color 0.2s ease;
}
.person-link:hover { text-decoration-color: var(--signal); }

.advisors-title { margin: clamp(64px, 8vw, 96px) 0 24px; font-size: 1.5rem; font-weight: 500; border-top: 1px solid var(--rule-2); padding-top: 22px; }
.advisors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.person-row { display: grid; grid-template-columns: 132px 1fr; gap: 24px; align-items: start; }
.person-row img { margin-bottom: 0; }

@media (max-width: 960px) {
  .founders { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .advisors { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .founders { grid-template-columns: 1fr; }
  .founders .person img { max-width: 360px; }
  .person-row { grid-template-columns: 96px 1fr; gap: 18px; }
}

/* ── FAQ ───────────────────────────────────────────────────────── */
.faq details { border-top: 1px solid var(--rule-2); }
.faq details:last-child { border-bottom: 1px solid var(--rule-2); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 22px 0; cursor: pointer; list-style: none;
  font-size: 1.125rem; font-weight: 480;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; flex-shrink: 0; width: 12px; height: 12px;
  background:
    linear-gradient(var(--ink-2), var(--ink-2)) center / 12px 1.5px no-repeat,
    linear-gradient(var(--ink-2), var(--ink-2)) center / 1.5px 12px no-repeat;
  transition: transform 0.3s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--ink); }
.faq details p { padding: 0 0 24px; color: var(--ink-2); max-width: 40rem; }
.faq summary:focus-visible { outline-offset: -2px; }

/* ── Access & contact ──────────────────────────────────────────── */
.section-access { background: var(--ground-2); border-top: 1px solid var(--rule); }
.access-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 88px); align-items: start; }
.access-copy h2 { margin-bottom: 20px; }
.access-sub { margin: 40px 0 14px; font-size: 1rem; font-weight: 560; }
.next-steps { counter-reset: step; }
.next-steps li {
  counter-increment: step;
  display: grid; grid-template-columns: 28px 1fr; gap: 8px;
  padding: 10px 0; border-top: 1px solid var(--rule); color: var(--ink-2);
}
.next-steps li::before { content: counter(step); font-family: var(--f-tech); color: var(--ink-3); font-size: 0.875rem; padding-top: 2px; }
.direct p { color: var(--ink-2); }
.direct-links { margin-top: 12px; display: flex; flex-direction: column; gap: 6px; }
.direct-links a {
  font-family: var(--f-tech); font-size: 0.975rem;
  text-decoration: underline; text-decoration-color: var(--rule-2); text-underline-offset: 4px;
}
.direct-links a:hover { text-decoration-color: var(--signal); }

.form-card {
  background: var(--ground);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: inset 0 1px 0 var(--sheen), var(--shadow);
}
#accessForm { display: flex; flex-direction: column; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; }
/* Side-by-side fields share row heights, so a label that wraps to two lines
   ("エンジニアリングチームの人数") doesn't push its input below its neighbour's */
@supports (grid-template-rows: subgrid) {
  .form-row { grid-template-rows: auto auto auto; row-gap: 0; }
  .form-row > .field { display: grid; grid-row: span 3; grid-template-rows: subgrid; row-gap: 0; }
  @media (max-width: 560px) { .form-row > .field + .field { margin-top: 18px; } }
  /* Spacing as margins, so an empty (hidden) error line adds no gap */
  .form-row > .field > label { align-self: end; margin-bottom: 7px; }
  .form-row > .field > .field-error { margin-top: 7px; }
}
.field label { font-size: 0.9375rem; font-weight: 450; color: var(--ink-2); }
.field input, .field select {
  width: 100%; min-height: 48px; padding: 10px 14px;
  background: var(--field); color: var(--ink);
  border: 1px solid var(--field-border); border-radius: 10px;
  font-size: 1rem;
  transition: border-color 0.2s ease;
}
.field input:hover, .field select:hover { border-color: var(--ink-3); }
.field input::-webkit-calendar-picker-indicator { display: none !important; }
.field input:focus, .field select:focus { outline: 2px solid var(--signal-mark); outline-offset: 1px; border-color: transparent; }
.field select {
  -webkit-appearance: none; appearance: none; padding-right: 40px; cursor: pointer;
  background-image: var(--chevron);
  background-repeat: no-repeat; background-position: right 15px center;
}
.field select:invalid { color: var(--ink-3); }
.field select option { color: var(--ink); background: var(--field); }
.field.has-error input, .field.has-error select { border-color: var(--error); }
.field-error, .form-status { display: flex; gap: 7px; align-items: baseline; color: var(--error); }
.field-error::before, .form-status::before {
  content: '!'; flex-shrink: 0; display: inline-grid; place-items: center;
  width: 1.15em; height: 1.15em; border-radius: 50%; background: var(--error); color: var(--ground);
  font-size: 0.8em; font-weight: 700; line-height: 1; transform: translateY(0.1em);
}
.field-error { font-size: 0.875rem; min-height: 0; }
.field-error:empty { display: none; }
.form-foot { font-size: 0.875rem; color: var(--ink-3); text-align: center; }
.form-status { font-size: 0.9375rem; justify-content: center; }
.form-status:empty { display: none; }
.form-done { padding: 24px 0; }
.form-done h3 { font-size: 1.5rem; margin-bottom: 10px; }
.form-done h3::before {
  content: ''; display: block; width: 14px; height: 14px; border-radius: 50%;
  background: var(--signal-mark); margin-bottom: 20px;
}
.form-done p { color: var(--ink-2); }
.form-done:focus { outline: none; }

@media (max-width: 900px) { .access-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }

/* ── Footer ────────────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--rule); padding-block: 40px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 20px 32px; }
.footer .brand { margin-right: 0; }
.footer .brand span { font-size: 1.05rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 22px; flex: 1; }
.footer-links a { font-size: 0.9375rem; color: var(--ink-2); text-decoration: none; }
.footer-links a:hover { color: var(--ink); }
.footer-copy { font-size: 0.875rem; color: var(--ink-3); }

/* ── Touch targets: at least 44px on phones and touch screens ─── */
@media (max-width: 760px), (pointer: coarse) {
  .icon-btn { width: 44px; height: 44px; }
  .lang-switch { height: 44px; }
  .lang-switch a { min-width: 38px; }
  .brand { min-height: 44px; }
  .chip { min-height: 44px; }
  input[type="range"] { height: 44px; }
  .footer-links { gap: 0 22px; }
  .footer-links a, .direct-links a, .person-link { display: inline-flex; align-items: center; min-height: 44px; }
  .direct-links { gap: 0; }
  .person-link { margin-top: 4px; }
}

/* ── Japanese (/ja/) ───────────────────────────────────────────── */
/* Geologica has no Japanese glyphs, so kana and kanji fall through to the system's
   Japanese face while Latin letters and numerals stay in Geologica. Japanese text
   needs open tracking, taller lines and phrase-aware breaks instead of the tight
   Latin display settings. */
:root:lang(ja) {
  --f-sans: 'Geologica', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', Meiryo, 'Yu Gothic UI', system-ui, sans-serif;
  --f-tech: 'B612', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', Meiryo, 'Yu Gothic UI', sans-serif;
  --w-body: 400;
}
:lang(ja) body { line-height: 1.85; line-break: strict; }
:lang(ja) h1, :lang(ja) h2, :lang(ja) h3, :lang(ja) .faq summary, :lang(ja) .onboarding {
  word-break: auto-phrase; letter-spacing: 0.02em;
}
:lang(ja) h2 { font-size: clamp(1.6rem, 1.15rem + 1.9vw, 2.4rem); line-height: 1.4; font-weight: 600; }
:lang(ja) h3 { line-height: 1.5; }
:lang(ja) .hero h1 {
  font-size: clamp(2.25rem, 1.3rem + 3.4vw, 4rem); line-height: 1.25; font-weight: 600;
  letter-spacing: 0.02em; max-width: 10em;
}
:lang(ja) .split > :first-child { max-width: 15em; }
:lang(ja) .lede, :lang(ja) .section-lede { line-height: 1.9; }
:lang(ja) .problems p, :lang(ja) .capabilities p, :lang(ja) .sectors p, :lang(ja) .security dd,
:lang(ja) .pipeline p, :lang(ja) .person p, :lang(ja) .faq details p { line-height: 1.85; }
:lang(ja) .problems h3, :lang(ja) .capabilities h3, :lang(ja) .sectors h3, :lang(ja) .security dt,
:lang(ja) .pipeline h3 { font-size: 1.125rem; letter-spacing: 0.02em; }
:lang(ja) .onboarding { line-height: 1.7; letter-spacing: 0.01em; }
:lang(ja) .calc-figure { font-size: clamp(2.25rem, 1.5rem + 3vw, 3.75rem); }
:lang(ja) .callout-v { line-height: 1.55; }
:lang(ja) .btn { letter-spacing: 0.02em; }
.ja-note { margin-top: 10px; font-size: 0.875rem; color: var(--ink-3); }

/* ── Reduced motion ────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
