/* ==========================================================================
   TERVIA — product page (Lumine Praxis)
   Palette from the TERVIA brand kit.
   ========================================================================== */

:root {
  --bg: #070d0c;
  --bg-2: #0b1613;
  --panel: #0f1c19;
  --text: #e9f3ef;
  --muted: #8fa39c;
  --dim: #5d706a;
  --line: rgba(233, 243, 239, 0.08);
  --line-2: rgba(233, 243, 239, 0.14);
  --mint: #39f5a6;
  --emerald: #0e9f6e;
  --cyan: #36d6f0;
  --teal: #1c8ea8;
  --grad: linear-gradient(90deg, var(--cyan) 0%, var(--mint) 100%);

  --f-display: "Space Grotesk", system-ui, sans-serif;
  --f-body: "Inter", system-ui, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --maxw: 1280px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--f-body); font-weight: 300; font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.is-loading { overflow: hidden; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
::selection { background: var(--mint); color: var(--bg); }

.tv-container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.tv-grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tv-outline { color: transparent; -webkit-text-stroke: 1px rgba(233, 243, 239, 0.55); }
.tv-muted { color: var(--muted); max-width: 560px; }

.tv-kicker {
  font-family: var(--f-mono); font-size: 12px; font-weight: 400; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--mint); margin: 0 0 22px; display: inline-flex; align-items: center; gap: 12px;
}
.tv-pulse {
  width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 14px var(--mint);
  animation: tvPulse 2s ease-in-out infinite; display: inline-block;
}
@keyframes tvPulse { 50% { opacity: 0.3; transform: scale(0.75); } }

.tv-h2 {
  font-family: var(--f-display); font-weight: 400; font-size: clamp(34px, 5.4vw, 76px);
  line-height: 1.02; letter-spacing: -0.025em; margin: 0;
}
.tv-head { margin-bottom: clamp(48px, 7vw, 88px); }
.tv-head--split { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: end; }
.tv-head--split .tv-h2 { font-size: clamp(34px, 4.8vw, 68px); }

/* ---------- Buttons ---------- */
.tv-btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 15px 26px; border-radius: 999px;
  font-family: var(--f-mono); font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  white-space: nowrap; will-change: transform;
  transition: background 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.tv-btn--mint { background: var(--mint); color: #04150e; box-shadow: 0 10px 40px -10px rgba(57, 245, 166, 0.6); }
.tv-btn--mint:hover { box-shadow: 0 0 0 6px rgba(57, 245, 166, 0.14), 0 14px 50px -8px rgba(57, 245, 166, 0.75); }
.tv-btn--ghost { border: 1px solid var(--line-2); background: rgba(233, 243, 239, 0.02); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.tv-btn--ghost:hover { border-color: var(--mint); color: var(--mint); }
.tv-btn--lg { padding: 20px 36px; font-size: 13px; }

.tv-arrow { display: inline-block; width: 18px; height: 1px; background: currentColor; position: relative; transition: width 0.4s var(--ease); }
.tv-arrow::after {
  content: ""; position: absolute; right: 0; top: -3px; width: 7px; height: 7px;
  border-top: 1px solid currentColor; border-right: 1px solid currentColor; transform: rotate(45deg);
}
.tv-arrow--back { transform: scaleX(-1); }
a:hover > .tv-arrow { width: 28px; }

/* ---------- Loader ---------- */
.tv-loader {
  position: fixed; inset: 0; z-index: 100; background: var(--bg);
  display: grid; place-content: center; justify-items: center; gap: 26px;
}
.tv-loader__mark { width: 84px; height: 84px; }
.tv-loader__line {
  display: flex; gap: 22px; font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted);
}
.tv-loader__pct { color: var(--mint); min-width: 3ch; }
.tv-loader__bar { width: 200px; height: 1px; background: var(--line); overflow: hidden; }
.tv-loader__bar span { display: block; height: 100%; background: var(--grad); transform: scaleX(0); transform-origin: left; }
.tv-no-anim .tv-loader, .tv-loader.is-done { display: none; }

/* ---------- Cursor ---------- */
.tv-cursor { position: fixed; inset: 0; pointer-events: none; z-index: 90; display: none; }
.tv-has-cursor .tv-cursor { display: block; }
.tv-has-cursor, .tv-has-cursor a, .tv-has-cursor button { cursor: none; }
.tv-cursor__dot, .tv-cursor__ring { position: fixed; left: 0; top: 0; will-change: transform; }
.tv-cursor__dot { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--mint); border-radius: 50%; }
.tv-cursor__ring {
  width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%;
  border: 1px solid rgba(57, 245, 166, 0.45); display: grid; place-items: center;
  transition: width 0.35s var(--ease), height 0.35s var(--ease), margin 0.35s var(--ease), background 0.35s var(--ease), border-color 0.35s var(--ease);
}
.tv-cursor__label { font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: #04150e; opacity: 0; transition: opacity 0.25s; }
.tv-cursor.is-hover .tv-cursor__ring { width: 74px; height: 74px; margin: -37px 0 0 -37px; background: var(--mint); border-color: transparent; }
.tv-cursor.is-hover .tv-cursor__label { opacity: 1; }
.tv-cursor.is-hover .tv-cursor__dot { opacity: 0; }
.tv-cursor.is-link .tv-cursor__ring { width: 50px; height: 50px; margin: -25px 0 0 -25px; border-color: var(--cyan); }

/* ---------- Nav ---------- */
.tv-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px;
  padding: 18px var(--gutter); border-bottom: 1px solid transparent;
  transition: background 0.5s var(--ease), padding 0.5s var(--ease), transform 0.5s var(--ease), border-color 0.5s;
}
.tv-nav.is-scrolled {
  background: rgba(7, 13, 12, 0.66); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-color: var(--line); padding-top: 12px; padding-bottom: 12px;
}
.tv-nav.is-hidden { transform: translateY(-110%); }
.tv-nav__back {
  justify-self: start; display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); transition: color 0.3s;
}
.tv-nav__back:hover { color: var(--text); }
.tv-nav__brand img { height: 26px; width: auto; }
.tv-nav__links { display: none; }
.tv-nav__cta { justify-self: end; padding: 10px 18px; font-size: 11px; }
@media (min-width: 1180px) {
  .tv-nav { grid-template-columns: auto auto 1fr auto; }
  .tv-nav__links { display: flex; gap: 32px; justify-self: center; }
  .tv-nav__links a {
    font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
    position: relative; padding: 6px 0; transition: color 0.3s;
  }
  .tv-nav__links a::after {
    content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px; background: var(--mint);
    transform: scaleX(0); transform-origin: right; transition: transform 0.5s var(--ease);
  }
  .tv-nav__links a:hover, .tv-nav__links a.is-active { color: var(--text); }
  .tv-nav__links a:hover::after, .tv-nav__links a.is-active::after { transform: scaleX(1); transform-origin: left; }
}

/* ---------- Hero ---------- */
.tv-hero {
  position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden; isolation: isolate;
  display: flex; align-items: center;
  background:
    radial-gradient(60% 70% at 78% 45%, rgba(57, 245, 166, 0.10) 0%, rgba(54, 214, 240, 0.05) 35%, transparent 70%),
    radial-gradient(50% 60% at 10% 80%, rgba(28, 142, 168, 0.10) 0%, transparent 70%),
    var(--bg);
}
.tv-hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.tv-hero__floor {
  position: absolute; left: -20%; right: -20%; bottom: -10%; height: 46%; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(rgba(54, 214, 240, 0.16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(54, 214, 240, 0.16) 1px, transparent 1px);
  background-size: 64px 64px;
  transform: perspective(520px) rotateX(64deg); transform-origin: 50% 0%;
  mask-image: linear-gradient(to bottom, transparent 0%, #000 30%, #000 60%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 30%, #000 60%, transparent 100%);
  animation: tvFloor 6s linear infinite;
}
@keyframes tvFloor { to { background-position: 0 64px, 0 64px; } }
.tv-hero__content { position: relative; width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 140px var(--gutter) 160px; }
.tv-hero__title {
  font-family: var(--f-display); font-weight: 400; font-size: clamp(40px, 8.6vw, 136px);
  line-height: 0.96; letter-spacing: -0.04em; margin: 0 0 30px;
}
.tv-line { display: block; }
.tv-hero__sub { max-width: 540px; margin: 0 0 40px; color: #b9c9c3; font-size: clamp(16px, 1.3vw, 18px); text-shadow: 0 0 20px var(--bg); }
.tv-hero__ctas { display: flex; flex-wrap: wrap; gap: 14px; }
.tv-hud {
  position: absolute; right: var(--gutter); bottom: 40px; display: grid; gap: 6px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--muted);
  padding: 14px 18px; border: 1px solid var(--line); border-radius: 12px;
  background: rgba(7, 13, 12, 0.55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.tv-hud__row { display: grid; grid-template-columns: 150px 70px auto; gap: 12px; align-items: baseline; }
.tv-hud__row span { text-transform: uppercase; }
.tv-hud__row b { color: var(--mint); font-weight: 500; text-align: right; }
.tv-hud__row em { font-style: normal; color: var(--dim); }
.tv-hero__tags {
  position: absolute; left: var(--gutter); bottom: 40px; list-style: none; margin: 0; padding: 0; display: flex; gap: 22px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dim);
}
.tv-hero__tags li::before { content: "■ "; color: var(--teal); }

/* ---------- Promise ---------- */
.tv-promise { padding: clamp(120px, 16vw, 200px) 0 clamp(80px, 10vw, 140px); }
.tv-statement {
  font-family: var(--f-display); font-weight: 400; font-size: clamp(28px, 4.2vw, 60px);
  line-height: 1.14; letter-spacing: -0.02em; margin: 0; max-width: 1150px;
}
.tv-statement .w { opacity: 0.12; }
.tv-no-anim .tv-statement .w { opacity: 1; }

/* ---------- Workflow ---------- */
.tv-flow { padding: clamp(80px, 12vw, 160px) 0; border-top: 1px solid var(--line); }
.tv-flow__wrap { position: relative; }
.tv-flow__line { position: absolute; left: 0; right: 0; top: 0; width: 100%; height: 80px; overflow: visible; }
.tv-flow__line path { fill: none; stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.tv-flow__track { stroke: var(--line-2); stroke-dasharray: 2 6; }
.tv-flow__steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 28px; position: relative; }
.tv-flow__steps li { padding-top: 80px; position: relative; opacity: 0.35; transition: opacity 0.6s var(--ease); }
.tv-flow__steps li.is-on { opacity: 1; }
.tv-flow__node {
  position: absolute; top: 33px; left: 0; width: 14px; height: 14px; border-radius: 50%;
  border: 1px solid var(--line-2); background: var(--bg); transition: all 0.6s var(--ease);
}
.tv-flow__steps li.is-on .tv-flow__node { background: var(--mint); border-color: var(--mint); box-shadow: 0 0 0 6px rgba(57, 245, 166, 0.14), 0 0 24px var(--mint); }
.tv-flow__n { font-family: var(--f-mono); font-size: 12px; color: var(--cyan); letter-spacing: 0.16em; }
.tv-flow__steps h3 { font-family: var(--f-display); font-weight: 500; font-size: 22px; letter-spacing: -0.01em; margin: 8px 0 10px; }
.tv-flow__steps p { margin: 0; color: var(--muted); font-size: 15px; }
.tv-no-anim .tv-flow__steps li { opacity: 1; }

/* ---------- Impact ---------- */
.tv-impact { padding: clamp(80px, 12vw, 160px) 0; background: linear-gradient(180deg, transparent, rgba(14, 159, 110, 0.05) 50%, transparent); }
.tv-stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.tv-stat { padding: 44px 32px 44px 0; }
.tv-stat + .tv-stat { padding-left: 32px; border-left: 1px solid var(--line); }
.tv-stat__v {
  font-family: var(--f-display); font-weight: 400; font-size: clamp(44px, 6.4vw, 96px); line-height: 1; letter-spacing: -0.04em;
  display: flex; align-items: baseline; gap: 12px; font-variant-numeric: tabular-nums;
}
.tv-stat__v span { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tv-stat__v small { font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.1em; color: var(--muted); }
.tv-stat p { margin: 14px 0 0; color: var(--muted); }
.tv-note { margin: 18px 0 0; font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.08em; color: var(--dim); }
.tv-decision {
  margin-top: clamp(64px, 9vw, 120px); padding: clamp(32px, 5vw, 64px); border-radius: 24px; position: relative; overflow: hidden;
  border: 1px solid var(--line); background: linear-gradient(135deg, rgba(54, 214, 240, 0.06), rgba(57, 245, 166, 0.03) 50%, transparent);
}
.tv-decision::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
  background-image: radial-gradient(rgba(57, 245, 166, 0.35) 1px, transparent 1.6px); background-size: 18px 18px;
  mask-image: radial-gradient(60% 80% at 100% 0%, #000, transparent 70%); -webkit-mask-image: radial-gradient(60% 80% at 100% 0%, #000, transparent 70%);
}
.tv-decision blockquote {
  position: relative; margin: 0; font-family: var(--f-display); font-weight: 400; font-size: clamp(24px, 3.2vw, 44px); line-height: 1.18; letter-spacing: -0.02em; max-width: 1000px;
}
.tv-decision__foot { position: relative; margin: 28px 0 0; color: var(--muted); max-width: 620px; }

/* ---------- Modules ---------- */
.tv-modules { padding: clamp(80px, 12vw, 160px) 0; }
.tv-modules__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tv-mod {
  --mx: 50%; --my: 50%;
  position: relative; overflow: hidden; padding: 30px 26px 32px; min-height: 400px; border-radius: 20px;
  background: linear-gradient(180deg, rgba(233, 243, 239, 0.035), rgba(233, 243, 239, 0.01)); border: 1px solid var(--line);
  display: flex; flex-direction: column; transition: border-color 0.5s var(--ease), translate 0.6s var(--ease);
}
.tv-mod::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(380px circle at var(--mx) var(--my), rgba(57, 245, 166, 0.13), rgba(54, 214, 240, 0.05) 40%, transparent 70%);
}
.tv-mod::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(240px circle at var(--mx) var(--my), var(--mint), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
}
.tv-mod:hover::before, .tv-mod:hover::after { opacity: 1; }
.tv-mod:hover { translate: 0 -6px; border-color: rgba(57, 245, 166, 0.25); }
.tv-mod img { width: 76px; height: 76px; margin-bottom: auto; transition: transform 0.8s var(--ease), filter 0.8s; }
.tv-mod:hover img { transform: scale(1.12); filter: drop-shadow(0 0 16px rgba(57, 245, 166, 0.5)); }
.tv-mod__verb { margin-top: 48px; font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--cyan); }
.tv-mod h3 { font-family: var(--f-display); font-weight: 500; font-size: 24px; letter-spacing: -0.01em; margin: 8px 0 12px; }
.tv-mod p { margin: 0; color: var(--muted); font-size: 15px; }
.tv-engines {
  margin-top: 40px; overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 20px 0;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.tv-engines__track { display: inline-flex; gap: 48px; white-space: nowrap; animation: tvMarquee 40s linear infinite; }
.tv-engines span { font-family: var(--f-mono); font-size: 12px; letter-spacing: 0.06em; color: var(--dim); }
.tv-engines b { color: var(--mint); font-weight: 500; margin-right: 10px; text-transform: uppercase; letter-spacing: 0.16em; }
@keyframes tvMarquee { to { transform: translateX(-50%); } }

/* ---------- Dashboard ---------- */
.tv-dash { padding: clamp(80px, 12vw, 160px) 0; border-top: 1px solid var(--line); }
.tv-screen {
  position: relative; overflow: hidden; border-radius: 20px; border: 1px solid var(--line-2);
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  box-shadow: 0 60px 120px -40px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(57, 245, 166, 0.04), 0 0 80px -20px rgba(57, 245, 166, 0.15);
  transform-origin: 50% 100%;
}
.tv-screen__bar {
  display: flex; align-items: center; gap: 8px; padding: 14px 20px; border-bottom: 1px solid var(--line);
  font-family: var(--f-mono); font-size: 11px; color: var(--dim);
}
.tv-screen__bar > i, .tv-term__bar > i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }
.tv-screen__bar > span:first-of-type { margin-left: 12px; }
.tv-screen__live { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; color: var(--mint); text-transform: uppercase; letter-spacing: 0.14em; }
.tv-screen__live .tv-pulse { width: 6px; height: 6px; }
.tv-screen__kpis { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); }
.tv-screen__kpis div { padding: 26px 24px; }
.tv-screen__kpis div + div { border-left: 1px solid var(--line); }
.tv-screen__kpis small { display: block; font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); margin-bottom: 10px; }
.tv-screen__kpis b { font-family: var(--f-display); font-weight: 500; font-size: clamp(22px, 2.4vw, 34px); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.tv-screen__kpis div:first-child b { color: var(--mint); }
.tv-table { padding: 10px 24px 24px; font-size: 15px; }
.tv-table__row {
  display: grid; grid-template-columns: 2.2fr 1fr 1fr 1fr 1.6fr; gap: 16px; align-items: center;
  padding: 16px 0; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums;
  transition: background 0.3s;
}
.tv-table__row:not(.tv-table__head):hover { background: rgba(57, 245, 166, 0.04); }
.tv-table__head { font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim); padding-top: 12px; }
.tv-table__row span:first-child { color: var(--text); }
.tv-table__row:not(.tv-table__head) span:nth-child(3) { color: var(--mint); }
.tv-pay { display: flex; align-items: center; gap: 12px; font-family: var(--f-mono); font-size: 13px; }
.tv-pay i { flex: 1; height: 4px; border-radius: 4px; background: var(--line); position: relative; overflow: hidden; }
.tv-pay i::after { content: ""; position: absolute; inset: 0; background: var(--grad); transform: scaleX(var(--w)); transform-origin: left; transition: transform 1.4s var(--ease); }
.tv-anim .tv-screen:not(.is-live) .tv-pay i::after { transform: scaleX(0); }
.tv-screen__scan {
  position: absolute; left: 0; right: 0; top: 0; height: 120px; pointer-events: none;
  background: linear-gradient(to bottom, transparent, rgba(57, 245, 166, 0.07) 70%, rgba(57, 245, 166, 0.3) 99%, transparent);
  animation: tvScan 5s cubic-bezier(.6, 0, .4, 1) infinite; mix-blend-mode: screen;
}
@keyframes tvScan { 0% { transform: translateY(-120px); } 100% { transform: translateY(640px); } }

/* ---------- Ask ---------- */
.tv-ask { padding: clamp(80px, 12vw, 160px) 0; }
.tv-ask__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(40px, 6vw, 96px); align-items: center; }
.tv-ask .tv-h2 { margin-bottom: 28px; }
.tv-prov { list-style: none; padding: 0; margin: 32px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tv-prov li {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.08em; color: var(--muted);
}
.tv-prov i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); box-shadow: 0 0 10px var(--c); }
.tv-term {
  border-radius: 18px; border: 1px solid var(--line-2); background: rgba(11, 22, 19, 0.85); overflow: hidden;
  box-shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.9), 0 0 60px -20px rgba(54, 214, 240, 0.18);
  font-family: var(--f-mono); font-size: 13px;
}
.tv-term__bar { display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-bottom: 1px solid var(--line); color: var(--dim); font-size: 11px; }
.tv-term__bar span { margin-left: 12px; }
.tv-term__body { padding: 26px 24px 30px; min-height: 340px; }
.tv-term__q { margin: 0 0 20px; color: var(--text); font-size: 15px; line-height: 1.5; }
.tv-term__prompt { color: var(--mint); }
.tv-caret { display: inline-block; width: 8px; height: 1.1em; margin-left: 2px; vertical-align: text-bottom; background: var(--mint); animation: tvBlink 1s steps(1) infinite; }
@keyframes tvBlink { 50% { opacity: 0; } }
.tv-term__calls { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 8px; }
.tv-term__calls li { color: var(--dim); display: flex; gap: 10px; opacity: 0; transform: translateX(-8px); transition: opacity 0.4s, transform 0.4s var(--ease); }
.tv-term__calls li.is-in { opacity: 1; transform: none; }
.tv-term__calls li::before { content: "→"; color: var(--cyan); }
.tv-term__calls li em { font-style: normal; color: var(--cyan); }
.tv-term__calls li b { margin-left: auto; color: var(--mint); font-weight: 400; }
.tv-term__a {
  margin: 0; padding: 16px 18px; border-radius: 12px; border: 1px solid rgba(57, 245, 166, 0.2); background: rgba(57, 245, 166, 0.05);
  color: #cfe1da; font-family: var(--f-body); font-size: 15px; line-height: 1.55; opacity: 0; transform: translateY(8px);
  transition: opacity 0.5s, transform 0.5s var(--ease);
}
.tv-term__a.is-in { opacity: 1; transform: none; }
.tv-term__a strong { color: var(--mint); font-weight: 500; }

/* ---------- Loop ---------- */
.tv-loop { padding: clamp(80px, 12vw, 160px) 0; border-top: 1px solid var(--line); overflow: hidden; }
.tv-loop__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 96px); align-items: center; }
.tv-loop .tv-h2 { margin-bottom: 24px; }
.tv-orbit { --s: min(500px, 86vw); --r: calc(var(--s) * 0.375); position: relative; width: var(--s); height: var(--s); justify-self: center; }
.tv-orbit svg { width: 100%; height: 100%; overflow: visible; }
.tv-orbit__ring { fill: none; stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 2 6; }
.tv-orbit__glow { fill: none; stroke-width: 1.5; stroke-dasharray: 120 822; stroke-dashoffset: 120; stroke-linecap: round; transform-origin: 200px 200px; animation: tvSpin 9s linear infinite; filter: drop-shadow(0 0 6px rgba(57, 245, 166, 0.8)); }
@keyframes tvSpin { from { transform: rotate(-90deg); } to { transform: rotate(270deg); } }
.tv-orbit__inner { fill: rgba(57, 245, 166, 0.03); stroke: var(--line); }
.tv-orbit__comet { fill: var(--mint); filter: drop-shadow(0 0 10px var(--mint)); }
.tv-orbit__nodes { list-style: none; margin: 0; padding: 0; }
.tv-orbit__nodes li {
  --a: calc(var(--i) * 60deg);
  position: absolute; left: 50%; top: 50%; width: 140px; text-align: center;
  transform: translate(-50%, -50%) rotate(var(--a)) translateY(calc(var(--r) * -1)) rotate(calc(var(--a) * -1));
}
.tv-orbit__nodes b {
  display: inline-block; font-family: var(--f-mono); font-weight: 500; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--bg); color: var(--muted);
  animation: tvNode 9s linear infinite; animation-delay: calc(var(--i) * 1.5s - 0.4s);
}
.tv-orbit__nodes span { display: block; margin-top: 6px; font-size: 12px; color: var(--dim); line-height: 1.3; }
@keyframes tvNode {
  0%, 14%, 100% { color: var(--muted); border-color: var(--line-2); box-shadow: none; }
  3%, 9% { color: #04150e; background: var(--mint); border-color: var(--mint); box-shadow: 0 0 28px rgba(57, 245, 166, 0.6); }
}
.tv-orbit__core {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); text-align: center;
  font-family: var(--f-display); font-size: clamp(18px, 2vw, 24px); line-height: 1.15; letter-spacing: -0.01em;
}
.tv-orbit__core small { display: block; font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mint); margin-bottom: 8px; }
.tv-compare { margin-top: 40px; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: rgba(233, 243, 239, 0.02); }
.tv-compare__title { margin: 0 0 18px; font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--cyan); }
.tv-compare__row { display: grid; grid-template-columns: 70px 1fr auto; gap: 16px; align-items: center; padding: 8px 0; }
.tv-compare__row span { font-size: 14px; color: var(--muted); }
.tv-compare__row b { font-family: var(--f-mono); font-weight: 400; font-size: 12px; color: var(--text); }
.tv-bars { display: grid; gap: 4px; }
.tv-bars i { display: block; height: 5px; border-radius: 5px; transform: scaleX(var(--w)); transform-origin: left; transition: transform 1.6s var(--ease); }
.tv-bars i:first-child { background: rgba(54, 214, 240, 0.45); }
.tv-bars i:last-child { background: var(--mint); transition-delay: 0.3s; }
.tv-anim .tv-compare:not(.is-live) .tv-bars i { transform: scaleX(0); }
.tv-compare__legend { margin: 14px 0 0; display: flex; gap: 18px; align-items: center; font-family: var(--f-mono); font-size: 11px; color: var(--dim); }
.tv-compare__legend i { display: inline-block; width: 14px; height: 5px; border-radius: 5px; margin-right: -10px; }
.tv-compare__legend .p { background: rgba(54, 214, 240, 0.45); }
.tv-compare__legend .a { background: var(--mint); }

/* ---------- Principle ---------- */
.tv-principle { padding: clamp(100px, 14vw, 180px) 0; text-align: center; }
.tv-principle .tv-container { display: flex; flex-direction: column; align-items: center; }
.tv-principle__title { font-family: var(--f-display); font-weight: 400; font-size: clamp(36px, 6.4vw, 96px); line-height: 1.02; letter-spacing: -0.035em; margin: 0 0 32px; }
.tv-stack { margin-top: 56px; width: 100%; max-width: 760px; display: grid; gap: 8px; perspective: 900px; }
.tv-stack div {
  display: flex; justify-content: space-between; gap: 20px; padding: 16px 22px; border-radius: 12px; text-align: left;
  border: 1px solid var(--line); background: linear-gradient(90deg, rgba(54, 214, 240, 0.05), rgba(57, 245, 166, 0.03));
  font-size: 15px; color: var(--text); transition: translate 0.5s var(--ease), border-color 0.5s;
}
.tv-stack div:hover { translate: 10px 0; border-color: rgba(57, 245, 166, 0.4); }
.tv-stack small { font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--cyan); padding-top: 3px; }

/* ---------- Pilot ---------- */
.tv-pilot { padding: clamp(80px, 12vw, 160px) 0; border-top: 1px solid var(--line); }
.tv-timeline { position: relative; }
.tv-timeline__rail { position: absolute; left: 0; right: 0; top: 7px; height: 1px; background: var(--line-2); }
.tv-timeline__rail span { position: absolute; inset: 0; background: var(--grad); transform: scaleX(0); transform-origin: left; box-shadow: 0 0 12px var(--mint); }
.tv-no-anim .tv-timeline__rail span { transform: none; }
.tv-timeline ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.tv-timeline li { position: relative; padding-top: 44px; opacity: 0.35; transition: opacity 0.6s var(--ease); }
.tv-timeline li::before {
  content: ""; position: absolute; top: 0; left: 0; width: 15px; height: 15px; border-radius: 4px; border: 1px solid var(--line-2); background: var(--bg);
  transition: all 0.6s var(--ease);
}
.tv-timeline li.is-on { opacity: 1; }
.tv-timeline li.is-on::before { background: var(--mint); border-color: var(--mint); box-shadow: 0 0 20px var(--mint); transform: rotate(45deg); }
.tv-no-anim .tv-timeline li { opacity: 1; }
.tv-timeline small { font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--cyan); }
.tv-timeline h3 { font-family: var(--f-display); font-weight: 500; font-size: 24px; letter-spacing: -0.01em; margin: 6px 0 10px; }
.tv-timeline p { margin: 0; color: var(--muted); font-size: 15px; }
.tv-pilot__cols { margin-top: clamp(64px, 9vw, 110px); display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(32px, 6vw, 80px); }
.tv-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.tv-list li { padding: 14px 0 14px 28px; border-bottom: 1px solid var(--line); position: relative; color: #cfe1da; }
.tv-list li::before { content: ""; position: absolute; left: 4px; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--teal); }
.tv-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tv-chips li {
  padding: 12px 18px; border-radius: 999px; border: 1px solid rgba(57, 245, 166, 0.22); background: rgba(57, 245, 166, 0.04);
  font-size: 14px; transition: background 0.4s, border-color 0.4s, color 0.4s;
}
.tv-chips li:hover { background: var(--mint); border-color: var(--mint); color: #04150e; }

/* ---------- CTA ---------- */
.tv-cta { position: relative; overflow: hidden; isolation: isolate; padding: clamp(140px, 20vw, 240px) 0; text-align: center; border-top: 1px solid var(--line); }
.tv-cta__canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.tv-cta::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(50% 50% at 50% 50%, rgba(7, 13, 12, 0.85), transparent 100%); }
.tv-cta__inner { display: flex; flex-direction: column; align-items: center; }
.tv-cta__title { font-family: var(--f-display); font-weight: 400; font-size: clamp(32px, 5.4vw, 80px); line-height: 1.06; letter-spacing: -0.03em; margin: 0 0 28px; max-width: 1100px; }
.tv-cta .tv-muted { margin: 0 0 48px; }

/* ---------- Footer ---------- */
.tv-footer { border-top: 1px solid var(--line); padding: 48px 0; }
.tv-footer__inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 24px 40px; }
.tv-footer img { height: 54px; width: auto; }
.tv-footer p { margin: 0; color: var(--muted); font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; line-height: 1.8; }
.tv-footer p a { color: var(--mint); }
.tv-footer__links { display: flex; gap: 28px; font-size: 14px; color: var(--muted); }
.tv-footer__links a:hover { color: var(--mint); }
.tv-footer .tv-footer__copy { grid-column: 1 / -1; text-transform: none; letter-spacing: 0.02em; font-family: var(--f-body); font-size: 13px; color: var(--dim); }

/* ---------- Reveal defaults (JS enhances) ---------- */
.tv-anim [data-reveal] { opacity: 0; transform: translateY(36px); }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .tv-modules__grid { grid-template-columns: repeat(2, 1fr); }
  .tv-flow__steps { grid-template-columns: repeat(3, 1fr); row-gap: 48px; }
  .tv-flow__line { display: none; }
  .tv-flow__steps li { padding-top: 36px; }
  .tv-flow__node { top: 0; }
  .tv-hud { display: none; }
}
@media (max-width: 860px) {
  .tv-nav { grid-template-columns: auto 1fr auto; }
  .tv-nav__brand { justify-self: center; }
  .tv-nav__back { font-size: 0; gap: 0; }
  .tv-nav__back .tv-arrow { width: 22px; }
  .tv-head--split, .tv-ask__grid, .tv-loop__grid, .tv-pilot__cols { grid-template-columns: 1fr; }
  .tv-loop__grid > .tv-orbit { order: 2; }
  .tv-stats { grid-template-columns: 1fr; }
  .tv-stat, .tv-stat + .tv-stat { padding: 32px 0; border-left: 0; }
  .tv-stat + .tv-stat { border-top: 1px solid var(--line); }
  .tv-screen__kpis { grid-template-columns: repeat(2, 1fr); }
  .tv-screen__kpis div:nth-child(3) { border-left: 0; }
  .tv-screen__kpis div:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .tv-table__row { grid-template-columns: 1.8fr 1fr 1.4fr; }
  .tv-table__row span:nth-child(2), .tv-table__row span:nth-child(4) { display: none; }
  .tv-timeline ol { grid-template-columns: 1fr 1fr; row-gap: 48px; }
  .tv-timeline__rail { display: none; }
  .tv-hero__tags { display: none; }
  .tv-hero { align-items: flex-end; }
  .tv-hero__content { padding-bottom: 72px; }
  .tv-footer__inner { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .tv-modules__grid, .tv-flow__steps, .tv-timeline ol { grid-template-columns: 1fr; }
  .tv-mod { min-height: 320px; }
  .tv-orbit__nodes li { width: 100px; }
  .tv-orbit__nodes span { display: none; }
  .tv-nav__cta { padding: 9px 14px; font-size: 10px; }
  .tv-stack div { flex-direction: column; gap: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .tv-engines__track, .tv-hero__floor, .tv-screen__scan { animation: none; }
}
