/* =================================================================
   TwinCode — "Twin / Duality" dev-premium. Dark-first.
================================================================= */
:root {
  --bg: #0a0b0d;
  --bg-2: #0d0f13;
  --surface: #131217;
  --surface-2: #1a1b22;
  --text: #edf0f5;
  --dim: #99a1b0;
  --faint: #828d9e;

  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.15);

  --lime: #c6f94e;
  --lime-soft: rgba(198, 249, 78, 0.14);
  --azure: #5b9dff;
  --azure-soft: rgba(91, 157, 255, 0.16);
  --ink: #0a0b0d;

  /* text-readable accents (darken on light bg) */
  --lime-tx: #c6f94e;
  --azure-tx: #5b9dff;
  /* theme-aware surfaces */
  --grid-line: rgba(255, 255, 255, 0.028);
  --nav-bg: rgba(13, 15, 19, 0.55);
  --nav-bg-2: rgba(13, 15, 19, 0.85);
  --overlay: rgba(10, 11, 13, 0.86);

  --display: 'Sora', system-ui, sans-serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;

  --maxw: 1240px;
  --gutter: clamp(1.25rem, 4vw, 3rem);

  --ease: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);

  color-scheme: dark;
}

[data-theme="light"] {
  --bg: #f7f8fa;
  --bg-2: #eef1f5;
  --surface: #ffffff;
  --surface-2: #eef1f5;
  --text: #0f1419;
  --dim: #4b5667;
  --faint: #646d7c;
  --line: rgba(10, 14, 21, 0.09);
  --line-2: rgba(10, 14, 21, 0.16);
  --lime-tx: #5c850c;
  --azure-tx: #2767cf;
  --grid-line: rgba(10, 14, 21, 0.05);
  --nav-bg: rgba(255, 255, 255, 0.62);
  --nav-bg-2: rgba(255, 255, 255, 0.86);
  --overlay: rgba(247, 248, 250, 0.86);
  color-scheme: light;
}
[data-theme="light"] .bg__glow { opacity: 0.32; }

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
svg { display: block; }
::selection { background: var(--lime); color: var(--ink); }

.shell {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Background ---------- */
.bg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bg__grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 58px 58px;
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 35%, transparent 80%);
  mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 35%, transparent 80%);
}
.bg__glow { position: absolute; width: 50vw; height: 50vw; max-width: 720px; max-height: 720px; border-radius: 50%; filter: blur(90px); opacity: 0.5; }
.bg__glow--lime { top: -16%; left: -8%; background: radial-gradient(circle, rgba(198, 249, 78, 0.22), transparent 65%); }
.bg__glow--azure { top: -6%; right: -10%; background: radial-gradient(circle, rgba(91, 157, 255, 0.22), transparent 65%); }

/* ---------- Eyebrow / dots ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--mono); font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim);
}
.dot { width: 7px; height: 7px; border-radius: 50%; }
.dot--lime { background: var(--lime); }
.dot--azure { background: var(--azure); }
.cross { color: var(--faint); margin: 0 0.15rem; font-weight: 600; }

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 0.6rem;
  font-weight: 600; font-size: 0.94rem; padding: 0.7rem 1.25rem; border-radius: 999px;
  white-space: nowrap; will-change: transform;
  transition: transform 0.18s var(--ease), background 0.3s var(--ease), box-shadow 0.3s var(--ease), color 0.3s var(--ease);
}
.btn:active { transform: scale(0.97); }
.btn--lg { font-size: 1rem; padding: 0.85rem 1.5rem; }
.btn--primary {
  background: var(--lime); color: var(--ink);
  box-shadow: 0 8px 22px -14px rgba(0, 0, 0, 0.45);
}
.btn--primary:hover { box-shadow: 0 12px 28px -16px rgba(0, 0, 0, 0.5); }
.btn--ghost { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn--ghost:hover { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--faint); }
.btn__arrow { transition: transform 0.35s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }
.btn__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ink); opacity: 0.55; }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 0.6rem; font-family: var(--display); font-weight: 700; font-size: 1.1rem; letter-spacing: -0.04em; }
.brand__mark { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.brand__mark svg { width: 19px; height: 19px; }
.brand__code { color: var(--dim); font-weight: 600; }

/* ---------- Nav ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; display: flex; justify-content: center; padding: 1rem var(--gutter); }
.nav__inner {
  width: 100%; max-width: var(--maxw); display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.55rem 0.6rem 0.55rem 1.2rem; border-radius: 999px;
  background: var(--nav-bg); -webkit-backdrop-filter: blur(16px) saturate(150%); backdrop-filter: blur(16px) saturate(150%);
  box-shadow: inset 0 0 0 1px var(--line); transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.nav.is-scrolled .nav__inner { background: var(--nav-bg-2); box-shadow: inset 0 0 0 1px var(--line-2), 0 16px 44px -24px rgba(0, 0, 0, 0.25); }
.nav__links { display: flex; gap: 0.3rem; }
.nav__links a { font-size: 0.9rem; font-weight: 500; color: var(--dim); padding: 0.45rem 0.85rem; border-radius: 999px; transition: color 0.25s var(--ease), background 0.25s var(--ease); }
.nav__links a:hover { color: var(--text); background: var(--surface-2); }
.nav__actions { display: flex; align-items: center; gap: 0.55rem; }

/* language toggle */
.lang { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.lang button { font-family: var(--mono); font-size: 0.72rem; font-weight: 500; color: var(--faint); padding: 0.32rem 0.55rem; border-radius: 999px; transition: color 0.25s var(--ease), background 0.25s var(--ease), transform 0.18s var(--ease); }
.lang button:hover { color: var(--text); }
.lang button:active { transform: scale(0.94); }
.lang button.is-active { color: var(--ink); background: var(--lime); }

/* theme toggle */
.tt { width: 38px; height: 38px; border-radius: 999px; display: grid; place-items: center; color: var(--dim); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); transition: color 0.25s var(--ease), box-shadow 0.25s var(--ease), transform 0.18s var(--ease); }
.tt:hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.tt:active { transform: scale(0.92); }
.tt svg { width: 17px; height: 17px; }
.tt__sun, .tt__moon { display: none; }
[data-theme="dark"] .tt__sun { display: block; color: var(--lime); }
[data-theme="light"] .tt__moon { display: block; }

.burger { display: none; width: 40px; height: 40px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); position: relative; }
.burger span { position: absolute; left: 11px; width: 18px; height: 1.6px; border-radius: 2px; background: var(--text); transition: transform 0.4s var(--ease-io); }
.burger span:nth-child(1) { top: 16px; }
.burger span:nth-child(2) { top: 22px; }
.burger.is-open span:nth-child(1) { transform: translateY(3px) rotate(45deg); }
.burger.is-open span:nth-child(2) { transform: translateY(-3px) rotate(-45deg); }

/* ---------- Mobile menu ---------- */
.mobile {
  position: fixed; inset: 0; z-index: 90; display: grid; place-items: center;
  background: var(--overlay); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px);
  opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease), visibility 0.4s;
}
.mobile.is-open { opacity: 1; visibility: visible; }
.mobile__links { display: flex; flex-direction: column; align-items: center; gap: 0.3rem; text-align: center; }
.mobile__links a {
  font-family: var(--display); font-size: clamp(1.9rem, 8vw, 2.6rem); font-weight: 700; letter-spacing: -0.04em;
  opacity: 0; transform: translateY(24px); transition: opacity 0.5s var(--ease), transform 0.6s var(--ease-io);
}
.mobile.is-open .mobile__links a { opacity: 1; transform: translateY(0); transition-delay: calc(var(--d, 0) * 1ms); }
.mobile__cta { color: var(--lime) !important; margin-top: 0.8rem; font-size: clamp(1.1rem, 5vw, 1.4rem) !important; }

/* ---------- Hero ---------- */
.hero { padding: clamp(8rem, 16vh, 11rem) 0 clamp(3rem, 7vh, 5rem); }
.hero__inner { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero__title { font-size: clamp(2.5rem, 5.6vw, 4.6rem); font-weight: 800; margin-top: 1.4rem; }
.hl { position: relative; white-space: nowrap; }
.hl--lime { color: var(--lime-tx); }
.hl--azure { color: var(--azure-tx); }
.hero__lead { margin-top: 1.6rem; max-width: 46ch; font-size: clamp(1.02rem, 1.4vw, 1.18rem); color: var(--dim); }
.hero__lead strong { color: var(--text); font-weight: 600; }
.hero__actions { margin-top: 2.2rem; display: flex; flex-wrap: wrap; gap: 0.85rem; }
.hero__stats { margin-top: 3rem; display: flex; flex-wrap: wrap; gap: clamp(1.5rem, 4vw, 3rem); }
.hero__stats dt { font-family: var(--display); font-size: clamp(1.4rem, 2.4vw, 1.9rem); font-weight: 700; letter-spacing: -0.04em; }
.hero__stats dd { font-size: 0.8rem; color: var(--faint); margin-top: 0.15rem; }

/* ---------- Code window ---------- */
.hero__visual { perspective: 1400px; }
.win {
  /* code editor — always dark, independent of page theme */
  border-radius: 16px; background: #131217; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 50px 110px -50px rgba(0, 0, 0, 0.85);
  overflow: hidden; transform: rotateY(-7deg) rotateX(3deg); transition: transform 0.7s var(--ease);
}
.win:hover { transform: rotateY(0) rotateX(0); }
.win__bar { display: flex; align-items: center; gap: 0.4rem; padding: 0.8rem 1rem; background: #1a1b22; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.win__dot { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, 0.15); }
.win__file { margin-left: 0.6rem; font-family: var(--mono); font-size: 0.72rem; color: #5d6675; }
.win__code { padding: 1.2rem 1.3rem; font-family: var(--mono); font-size: 0.82rem; line-height: 1.85; overflow-x: auto; color: #edf0f5; }
.win__code code { white-space: pre; }
.c-kw { color: #c4a3ff; }
.c-var { color: var(--azure); }
.c-prop { color: var(--lime); }
.c-str { color: #ffd479; }
.c-pn { color: var(--faint); }
.c-cm { color: var(--faint); font-style: italic; }
.c-fn { color: #7ee0c0; }
.typed-cursor { display: inline-block; width: 8px; height: 1.05em; vertical-align: text-bottom; background: var(--lime); margin-left: 2px; animation: blink 1.05s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.win__status { display: flex; align-items: center; gap: 0.5rem; padding: 0.75rem 1.3rem; border-top: 1px solid rgba(255, 255, 255, 0.08); background: #0d0f13; font-family: var(--mono); font-size: 0.72rem; color: #99a1b0; }
.win__ok { color: var(--lime); font-size: 0.7rem; }

/* ---------- Marquee ---------- */
.marquee { border-block: 1px solid var(--line); padding: 1.1rem 0; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.marquee__track { display: inline-flex; align-items: center; gap: 1.4rem; white-space: nowrap; font-family: var(--mono); font-size: 0.88rem; color: var(--dim); animation: scroll 32s linear infinite; }
.marquee__track .sep { color: var(--lime); opacity: 0.5; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding: clamp(5rem, 12vh, 8.5rem) 0; }
.section--alt { background: var(--bg-2); border-block: 1px solid var(--line); }
.head { max-width: 60ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.head__title { font-size: clamp(2rem, 4.4vw, 3.3rem); font-weight: 700; margin-top: 1rem; }
.head__intro { margin-top: 1.1rem; font-size: clamp(1rem, 1.4vw, 1.15rem); color: var(--dim); }

/* ---------- Twin ---------- */
.twin { display: grid; grid-template-columns: 1fr auto 1fr; gap: clamp(1rem, 2vw, 1.5rem); align-items: stretch; }
.twin__x { align-self: center; font-family: var(--display); font-size: clamp(1.5rem, 3vw, 2.4rem); font-weight: 300; color: var(--faint); }
.twin__card {
  position: relative; padding: clamp(1.8rem, 3vw, 2.6rem); border-radius: 22px; background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.twin__card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; }
.twin__card--lime::before { background: var(--lime); }
.twin__card--azure::before { background: var(--azure); }
.twin__card:hover { transform: translateY(-5px); }
.twin__card--lime:hover { box-shadow: inset 0 0 0 1px rgba(198, 249, 78, 0.4), 0 40px 80px -55px rgba(0, 0, 0, 0.5); }
.twin__card--azure:hover { box-shadow: inset 0 0 0 1px rgba(91, 157, 255, 0.4), 0 40px 80px -55px rgba(0, 0, 0, 0.5); }
.twin__tag { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.twin__card--lime .twin__tag { color: var(--lime-tx); }
.twin__card--azure .twin__tag { color: var(--azure-tx); }
.twin__h { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; margin-top: 1rem; }
.twin__p { margin-top: 1rem; color: var(--dim); }
.twin__p strong { color: var(--text); }
.twin__list { list-style: none; margin-top: 1.4rem; display: flex; flex-direction: column; gap: 0.6rem; }
.twin__list li { position: relative; padding-left: 1.4rem; font-size: 0.92rem; color: var(--dim); }
.twin__list li::before { content: ''; position: absolute; left: 0; top: 0.55em; width: 7px; height: 7px; border-radius: 2px; }
.twin__card--lime .twin__list li::before { background: var(--lime-tx); }
.twin__card--azure .twin__list li::before { background: var(--azure-tx); }
.twin__link { display: inline-flex; align-items: center; gap: 0.4rem; margin-top: 1.6rem; font-weight: 600; font-size: 0.92rem; }
.twin__link span { transition: transform 0.35s var(--ease); }
.twin__link:hover span { transform: translateX(4px); }
.twin__card--lime .twin__link { color: var(--lime-tx); }
.twin__card--azure .twin__link { color: var(--azure-tx); }

/* ---------- Balansee ---------- */
.balansee { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.pill { display: inline-block; font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; padding: 0.35rem 0.8rem; border-radius: 999px; }
.pill--lime { color: var(--lime-tx); background: var(--lime-soft); box-shadow: inset 0 0 0 1px var(--line-2); }
.balansee__title { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; margin-top: 1.2rem; }
.balansee__text { margin-top: 1.1rem; color: var(--dim); font-size: 1.05rem; max-width: 42ch; }
.balansee__feats { list-style: none; margin-top: 1.6rem; display: flex; flex-direction: column; gap: 0.8rem; }
.balansee__feats li { display: flex; align-items: center; gap: 0.8rem; color: var(--text); font-size: 0.98rem; }
.balansee__feats span:first-child { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; color: var(--lime-tx); background: var(--lime-soft); font-size: 0.85rem; flex: none; }
.balansee__feats + .btn { margin-top: 1.8rem; }

/* balansee app mock (self-contained light chrome) */
.balansee__visual { perspective: 1400px; }
.app {
  --c-bg: #ffffff; --c-panel: #f6f8fb; --c-line: #edf0f5; --c-ink: #1f2533; --c-dim: #8b94a3;
  display: grid; grid-template-columns: 116px 1fr; background: var(--c-bg); color: var(--c-ink);
  border-radius: 16px; overflow: hidden; line-height: 1.4;
  box-shadow: 0 50px 120px -55px rgba(0, 0, 0, 0.9); transform: rotateY(6deg) rotateX(3deg); transition: transform 0.7s var(--ease);
}
.app:hover { transform: rotateY(0) rotateX(0); }
.app__side { padding: 12px 10px; box-shadow: inset -1px 0 0 var(--c-line); }
.app__nav { display: flex; flex-direction: column; gap: 2px; }
.app__item { display: flex; align-items: center; gap: 7px; padding: 7px 8px; border-radius: 8px; font-size: 10.5px; font-weight: 500; color: var(--c-dim); }
.app__item svg { width: 14px; height: 14px; flex: none; }
.app__item.is-active { background: #eaf0fe; color: #3b6ef5; font-weight: 600; }
.app__main { padding: 12px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.app__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.stat { min-width: 0; overflow: hidden; padding: 8px 9px 6px; border-radius: 10px; background: var(--c-panel); box-shadow: inset 0 0 0 1px var(--c-line); display: flex; flex-direction: column; gap: 1px; }
.stat__k { font-size: 9px; color: var(--c-dim); }
.stat__v { font-family: var(--display); font-weight: 700; font-size: 13px; letter-spacing: -0.02em; }
.stat__v--in { color: #2f9e54; } .stat__v--out { color: #d64b48; } .stat__v--save { color: #3b6ef5; }
.spark { width: 100%; height: 22px; margin-top: 4px; }
.spark__l { fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.spark__a { stroke: none; }
.l-in { stroke: #2f9e54; } .a-in { fill: rgba(47, 158, 84, 0.14); }
.l-out { stroke: #d64b48; } .a-out { fill: rgba(214, 75, 72, 0.13); }
.l-save { stroke: #3b6ef5; } .a-save { fill: rgba(59, 110, 245, 0.14); }
.app__plan { padding: 11px 13px 13px; border-radius: 10px; background: var(--c-panel); box-shadow: inset 0 0 0 1px var(--c-line); display: flex; flex-direction: column; gap: 10px; }
.app__planhead { display: flex; justify-content: space-between; align-items: baseline; }
.app__planhead span:first-child { font-family: var(--display); font-weight: 700; font-size: 12px; color: var(--c-ink); }
.app__month { font-size: 9.5px; color: var(--c-dim); }
.prow { display: grid; grid-template-columns: 22px 1fr auto; column-gap: 9px; row-gap: 5px; align-items: center; }
.prow__ic { grid-row: 1 / 3; width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; }
.prow__ic svg { width: 13px; height: 13px; }
.ic-blue { background: #e8f0fe; color: #3b6ef5; } .ic-orange { background: #fdeee1; color: #e8842b; } .ic-green { background: #e7f6ec; color: #2f9e54; } .ic-red { background: #fdeaea; color: #d64b48; }
.prow__n { font-weight: 600; font-size: 11px; color: var(--c-ink); }
.prow__a { font-size: 10.5px; color: var(--c-dim); white-space: nowrap; }
.prow__bar { grid-column: 2 / 4; height: 5px; border-radius: 3px; background: #e6eaf0; overflow: hidden; }
.prow__bar i { display: block; height: 100%; border-radius: 3px; }
.f-blue { background: #5b8cff; } .f-orange { background: #f0883e; } .f-green { background: #56b870; } .f-red { background: #e5484d; }

/* ---------- Capabilities ---------- */
.caps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 1.6vw, 1.4rem); }
.cap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.9rem; padding: clamp(1.5rem, 2.4vw, 2rem); border-radius: 18px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease); }
.cap:hover { transform: translateY(-4px); box-shadow: inset 0 0 0 1px var(--line-2); }
.cap__ic { flex: none; display: inline-flex; color: var(--azure-tx); transition: transform 0.4s var(--ease); }
.cap:hover .cap__ic { transform: translateX(2px); }
.cap__ic svg { width: 26px; height: 26px; }
.cap h3 { flex: 1 1 auto; min-width: 0; font-size: 1.2rem; font-weight: 700; }
.cap p { flex-basis: 100%; margin: 0; color: var(--dim); font-size: 0.94rem; }
.cap__tags { flex-basis: 100%; font-family: var(--mono); font-size: 0.74rem; color: var(--faint); }

/* ---------- Process ---------- */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(1rem, 1.6vw, 1.6rem); }
.step { padding: 1.6rem 0 0; border-top: 1px solid var(--line-2); position: relative; }
.step::after { content: ''; position: absolute; top: -1px; left: 0; width: 36px; height: 2px; background: var(--lime-tx); }
.step__k { font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.08em; color: var(--lime-tx); }
.step h3 { font-size: 1.15rem; font-weight: 700; margin-top: 0.9rem; }
.step p { margin-top: 0.6rem; font-size: 0.92rem; color: var(--dim); }

/* ---------- CTA ---------- */
.cta { position: relative; padding: clamp(5rem, 13vh, 9rem) 0; text-align: center; overflow: hidden; }
.cta::before { content: ''; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 80% at 30% 120%, rgba(198, 249, 78, 0.16), transparent 70%), radial-gradient(55% 75% at 80% -10%, rgba(91, 157, 255, 0.18), transparent 70%); filter: blur(20px); }
.cta__inner { display: flex; flex-direction: column; align-items: center; }
.cta__title { font-size: clamp(2.1rem, 5vw, 3.6rem); font-weight: 700; margin-top: 1.2rem; }
.cta__lead { margin-top: 1.3rem; max-width: 50ch; color: var(--dim); font-size: clamp(1.02rem, 1.5vw, 1.18rem); }
.cta__inner .btn { margin-top: 2.3rem; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); padding-top: clamp(3rem, 6vw, 4.5rem); background: var(--bg-2); }
.footer__inner { display: grid; grid-template-columns: 1.4fr 2fr; gap: 2.5rem; padding-bottom: 3rem; }
.footer__tag { margin-top: 1.1rem; color: var(--dim); font-size: 0.95rem; max-width: 30ch; }
.footer__cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.footer__cols > div { display: flex; flex-direction: column; gap: 0.7rem; }
.footer__cols a { color: var(--dim); font-size: 0.92rem; transition: color 0.2s var(--ease); }
.footer__cols a:hover { color: var(--lime); }
.footer__h { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin-bottom: 0.3rem; }
.footer__bottom { display: flex; justify-content: space-between; gap: 1rem; padding: 1.6rem 0; border-top: 1px solid var(--line); font-size: 0.82rem; color: var(--faint); }
.footer__sign { font-family: var(--mono); }
.footer__legal { display: flex; flex-direction: column; gap: 0.3rem; padding: 1.4rem 0; border-top: 1px solid var(--line); font-size: 0.82rem; color: var(--faint); line-height: 1.6; text-align: center; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(30px); filter: blur(6px); transition: opacity 0.8s var(--ease), transform 0.9s var(--ease), filter 0.8s var(--ease), clip-path 0.9s var(--ease); transition-delay: var(--rd, 0ms); will-change: transform, opacity; }
.reveal--left { transform: translateX(-48px); filter: blur(4px); }
.reveal--right { transform: translateX(48px); filter: blur(4px); }
.reveal--scale { transform: scale(0.9); filter: blur(4px); }
.reveal--clip { transform: translateY(16px); filter: blur(0); clip-path: inset(0 0 100% 0); }
.reveal.is-visible { opacity: 1; transform: none; filter: blur(0); clip-path: inset(0 0 0 0); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .nav__links { display: none; }
  .nav__cta { display: none; }
  .burger { display: block; }
  .hero__inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero__visual { order: -1; }
  .twin { grid-template-columns: 1fr; }
  .twin__x { display: none; }
  .balansee { grid-template-columns: 1fr; }
  .caps { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .footer__inner { grid-template-columns: 1fr; }
  .win, .app { transform: none; }
}
@media (max-width: 560px) {
  .caps, .steps { grid-template-columns: 1fr; }
  .footer__cols { grid-template-columns: 1fr 1fr; }
  .footer__bottom { flex-direction: column; }
}
@media (hover: none) { .win, .app, .twin__card:hover, .cap:hover { transform: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .reveal--left, .reveal--right, .reveal--scale, .reveal--clip { opacity: 1; transform: none; filter: none; clip-path: none; transition: none; }
  .marquee__track, .typed-cursor { animation: none; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* =================================================================
   Theme-aware code window + Balansee dashboard
================================================================= */

/* build-log "done" colour per theme (status bar follows window theme) */
#buildlog.done { color: #c6f94e; }

/* ---- Code window: LIGHT variant ---- */
[data-theme="light"] .win { background: #ffffff; box-shadow: inset 0 0 0 1px rgba(10, 14, 21, 0.10), 0 40px 90px -50px rgba(13, 30, 45, 0.32); }
[data-theme="light"] .win__bar { background: #f3f5f8; border-bottom-color: rgba(10, 14, 21, 0.08); }
[data-theme="light"] .win__dot { background: #cfd6df; }
[data-theme="light"] .win__file { color: #8a94a3; }
[data-theme="light"] .win__code { color: #1f2533; }
[data-theme="light"] .win__status { background: #f8fafc; border-top-color: rgba(10, 14, 21, 0.08); color: #6c7585; }
[data-theme="light"] .c-kw { color: #7c3aed; }
[data-theme="light"] .c-var { color: #2563eb; }
[data-theme="light"] .c-prop { color: #4d7c0f; }
[data-theme="light"] .c-str { color: #b45309; }
[data-theme="light"] .c-pn { color: #94a0b0; }
[data-theme="light"] .c-cm { color: #94a0b0; }
[data-theme="light"] .c-fn { color: #0e7490; }
[data-theme="light"] .win__ok { color: #4d7c0f; }
[data-theme="light"] .typed-cursor { background: #5c850c; }
[data-theme="light"] #buildlog.done { color: #4d7c0f; }

/* ---- Balansee dashboard: DARK variant ---- */
[data-theme="dark"] .app {
  --c-bg: #0f1722;
  --c-panel: #161f2c;
  --c-line: rgba(255, 255, 255, 0.07);
  --c-ink: #e6eaf1;
  --c-dim: #8893a5;
}
[data-theme="dark"] .app__item.is-active { background: rgba(59, 110, 245, 0.18); color: #6ea0ff; }
[data-theme="dark"] .stat__v--in { color: #3fcf78; }
[data-theme="dark"] .stat__v--out { color: #f06a67; }
[data-theme="dark"] .stat__v--save { color: #6ea0ff; }
[data-theme="dark"] .l-in { stroke: #3fcf78; } [data-theme="dark"] .a-in { fill: rgba(63, 207, 120, 0.16); }
[data-theme="dark"] .l-out { stroke: #f06a67; } [data-theme="dark"] .a-out { fill: rgba(240, 106, 103, 0.15); }
[data-theme="dark"] .l-save { stroke: #6ea0ff; } [data-theme="dark"] .a-save { fill: rgba(110, 160, 255, 0.16); }
[data-theme="dark"] .ic-blue { background: rgba(59, 110, 245, 0.16); color: #6ea0ff; }
[data-theme="dark"] .ic-orange { background: rgba(232, 132, 43, 0.16); color: #f0a35a; }
[data-theme="dark"] .ic-green { background: rgba(47, 158, 84, 0.18); color: #4cc278; }
[data-theme="dark"] .ic-red { background: rgba(214, 75, 72, 0.18); color: #ec6a67; }
[data-theme="dark"] .prow__bar { background: rgba(255, 255, 255, 0.09); }

/* ---------- Contact form ---------- */
.cf { display: flex; flex-direction: column; gap: 1.1rem; width: 100%; max-width: 560px; margin-inline: auto; text-align: left; margin-top: 2rem; }
.cf__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.cf__field { display: flex; flex-direction: column; gap: 0.45rem; }
.cf__label { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--dim); }
.cf__input {
  font-family: var(--body); font-size: 0.95rem; color: var(--text);
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px;
  padding: 0.8rem 1rem; width: 100%;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.cf__input::placeholder { color: var(--faint); }
.cf__input:focus { outline: none; border-color: var(--lime); box-shadow: 0 0 0 3px var(--lime-soft); }
.cf__input--err { border-color: #e0556b !important; box-shadow: none !important; }
.cf__textarea { resize: vertical; min-height: 120px; line-height: 1.6; }
.cf__err { color: #e0556b; font-size: 0.8rem; }
.cf__consent { display: flex; align-items: flex-start; gap: 0.7rem; font-size: 0.88rem; color: var(--dim); line-height: 1.5; cursor: pointer; }
.cf__consent input[type="checkbox"] { margin-top: 0.18rem; width: 16px; height: 16px; flex: none; accent-color: var(--lime); cursor: pointer; }
.cf__consent a { color: var(--azure-tx); text-decoration: underline; text-underline-offset: 2px; }
.cf__consent--err span { color: #e0556b; }
.cf__submit {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 0.65rem;
  font-family: var(--body); font-weight: 600; font-size: 1rem;
  padding: 0.85rem 1rem 0.85rem 1.55rem; border-radius: 999px;
  background: var(--lime); color: var(--ink); border: none; cursor: pointer;
  box-shadow: 0 10px 30px -14px rgba(0,0,0,0.4);
  transition: transform 0.18s var(--ease), box-shadow 0.3s var(--ease);
}
.cf__submit:hover { box-shadow: 0 16px 44px -12px rgba(0,0,0,0.4); }
.cf__submit:hover .cf__icon { transform: translateX(3px); }
.cf__submit:active { transform: scale(0.97); }
.cf__icon { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 999px; background: rgba(10,11,13,0.12); transition: transform 0.4s var(--ease); }
.cf__icon svg { width: 17px; height: 17px; }
.cf__note { font-size: 0.8rem; color: var(--faint); }
.cf__success { font-size: 1.05rem; color: var(--text); background: var(--surface); border: 1px solid var(--line-2); border-radius: 16px; padding: 1.5rem 1.75rem; max-width: 540px; margin: 2rem auto 0; text-align: center; }
@media (max-width: 560px) { .cf__row { grid-template-columns: 1fr; } }

/* ---------- Cookie banner ---------- */
.cookie {
  position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  z-index: 200; width: calc(100% - 3rem); max-width: 860px;
  background: var(--surface); border-radius: 18px;
  box-shadow: inset 0 0 0 1px var(--line-2), 0 24px 60px -20px rgba(0, 0, 0, 0.45);
  padding: 1.3rem 1.6rem;
  animation: cookie-in 0.45s var(--ease) both;
}
@keyframes cookie-in { from { opacity: 0; transform: translateX(-50%) translateY(16px); } }
.cookie__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.cookie__copy { flex: 1 1 auto; min-width: 0; }
.cookie__title { font-family: var(--display); font-size: 0.97rem; font-weight: 700; letter-spacing: -0.02em; }
.cookie__text { margin-top: 0.35rem; font-size: 0.85rem; color: var(--dim); line-height: 1.55; }
.cookie__text a { color: var(--azure-tx); text-decoration: underline; text-underline-offset: 2px; }
.cookie__actions { display: flex; align-items: center; gap: 0.6rem; flex: none; }
.cookie__btn { font-family: inherit; font-size: 0.88rem; font-weight: 600; padding: 0.6rem 1.2rem; border-radius: 999px; white-space: nowrap; border: none; cursor: pointer; transition: background 0.2s var(--ease), box-shadow 0.2s var(--ease), color 0.2s var(--ease); }
.cookie__btn--primary { background: var(--lime); color: var(--ink); }
.cookie__btn--primary:hover { box-shadow: 0 6px 18px -10px rgba(0, 0, 0, 0.4); }
.cookie__btn--ghost { background: none; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--dim); }
.cookie__btn--ghost:hover { background: var(--surface-2); color: var(--text); }
@media (max-width: 560px) {
  .cookie { bottom: 1rem; width: calc(100% - 2rem); padding: 1.1rem 1.2rem; }
  .cookie__inner { flex-direction: column; align-items: stretch; }
  .cookie__actions { justify-content: flex-end; }
}

/* ---------- Privacy / Legal page ---------- */
.phead { padding: 0.9rem var(--gutter); position: sticky; top: 0; z-index: 100; background: var(--nav-bg); -webkit-backdrop-filter: blur(16px) saturate(150%); backdrop-filter: blur(16px) saturate(150%); border-bottom: 1px solid var(--line); }
.phead__inner { width: 100%; max-width: var(--maxw); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; }
.phead__actions { display: flex; align-items: center; gap: 0.6rem; }
.legal { padding: clamp(3rem, 8vh, 5rem) 0 clamp(4rem, 10vh, 7rem); }
.legal__inner { max-width: 72ch; }
.legal__back { display: inline-flex; align-items: center; gap: 0.4rem; color: var(--dim); font-size: 0.9rem; margin-bottom: 2.5rem; transition: color 0.2s var(--ease); }
.legal__back:hover { color: var(--lime-tx); }
.legal__title { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 700; margin-top: 0.6rem; }
.legal__eff { margin-top: 0.5rem; color: var(--faint); font-size: 0.85rem; font-family: var(--mono); }
.legal__p { margin-top: 1.1rem; color: var(--dim); line-height: 1.7; font-size: 0.97rem; }
.legal__p a { color: var(--azure-tx); text-decoration: underline; text-underline-offset: 2px; }
.legal__block { margin-top: 2.6rem; }
.legal__h { font-size: 1.05rem; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 0.8rem; }
.legal__list { margin-top: 0.8rem; padding-left: 1.4rem; display: flex; flex-direction: column; gap: 0.45rem; }
.legal__list li { color: var(--dim); line-height: 1.6; font-size: 0.95rem; }
.legal__data { display: flex; flex-direction: column; gap: 0.55rem; margin-top: 0.9rem; }
.legal__data > div { display: flex; gap: 0.8rem; font-size: 0.92rem; }
.legal__data dt { color: var(--faint); min-width: 9ch; flex: none; }
.legal__data dd { color: var(--text); }
.legal__data a { color: var(--azure-tx); text-decoration: underline; text-underline-offset: 2px; }
.legal__controller { background: var(--surface); border-radius: 16px; padding: 1.4rem 1.6rem; box-shadow: inset 0 0 0 1px var(--line); }
.legal__draft { margin-top: 3rem; padding: 1rem 1.2rem; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px rgba(198, 249, 78, 0.25); color: var(--faint); font-size: 0.82rem; line-height: 1.6; font-style: italic; }
.legal__cookies-reset { margin-top: 1.4rem; }
.legal__cookies-reset button { background: none; border: none; cursor: pointer; color: var(--azure-tx); font-size: 0.88rem; font-family: inherit; text-decoration: underline; text-underline-offset: 2px; padding: 0; }
