/* /instiv2/terminal/ page.css: the product tour. One idea per screen, big type, real recordings in device frames. */

.tc { background: var(--page); color: var(--page-text); }

/* ---------- hero ---------- */
.tc-hero { position: relative; overflow: hidden; padding: calc(var(--hdr) + clamp(48px, 9vh, 110px)) var(--pad) clamp(70px, 11vh, 130px); color: var(--text); text-align: center;
  background: radial-gradient(70% 55% at 50% 72%, rgba(127, 178, 255, .20), rgba(127, 178, 255, 0) 70%), radial-gradient(60% 40% at 50% 0%, #10213F 0%, rgba(16, 33, 63, 0) 70%), #05080F; }
.tc-hero-copy { max-width: 1280px; margin: 0 auto; }
.tc-kicker { justify-content: center; }
.tc-h1 { margin: 0; font-weight: 700; font-size: clamp(40px, 5.4vw, 84px); line-height: 1; letter-spacing: -0.045em;
  background: linear-gradient(180deg, #FFFFFF 30%, rgba(226, 233, 246, .72)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tc-sub { margin: 22px auto 0; max-width: 58ch; font-size: clamp(16px, 1.35vw, 20px); color: var(--muted); }
.tc-play svg { width: 20px; height: 20px; }
.tc-hero-stage { position: relative; max-width: 1160px; margin: clamp(48px, 8vh, 90px) auto 0; perspective: 2200px; padding-bottom: 4%; }
.tc-hero-stage .laptop { width: 86%; margin: 0 auto 0 2%; }
.tc-hero-stage .handset-x { width: 20%; right: 1%; bottom: 0; }
.tc-hero-stage::before { content: ""; position: absolute; left: 10%; right: 10%; bottom: -6%; height: 30%; border-radius: 50%; background: radial-gradient(closest-side, rgba(127, 178, 255, .28), rgba(127, 178, 255, 0)); filter: blur(20px); pointer-events: none; }
.tc-rec { margin: 34px 0 0; font: 500 11.5px/1.5 "JetBrains Mono", monospace; letter-spacing: .06em; color: var(--faint); }

/* ---------- chapter index (fixed, appears past the hero) ---------- */
.tc-index { position: fixed; z-index: 45; top: calc(var(--hdr) + 10px); left: 50%; transform: translate(-50%, -10px); max-width: calc(100% - 2 * var(--pad)); opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .35s var(--ease), transform .45s var(--ease), visibility 0s linear .35s; }
.tc-index.is-on { opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0); transition: opacity .35s var(--ease), transform .45s var(--ease), visibility 0s; }
.tc-index-in { display: flex; gap: 2px; padding: 4px; overflow-x: auto; scrollbar-width: none; border-radius: 999px; border: 1px solid var(--page-line); background: var(--page-glass); backdrop-filter: blur(18px) saturate(150%); -webkit-backdrop-filter: blur(18px) saturate(150%); box-shadow: 0 18px 40px -24px rgba(5, 8, 15, .45); }
.tc-index-in::-webkit-scrollbar { display: none; }
.tc-index a { flex: none; display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 0 13px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--page-muted); transition: background .3s var(--ease), color .3s; }
.tc-index a b { font: 500 11px/1 "JetBrains Mono", monospace; opacity: .7; }
.tc-index a:hover { color: var(--page-text); }
.tc-index a[aria-current] { background: var(--page-text); color: var(--page); }

/* ---------- facts ---------- */
.tc-facts { padding: clamp(40px, 7vh, 70px) var(--pad); background: var(--page); border-bottom: 1px solid var(--page-line); }
.tc-facts ul { list-style: none; margin: 0 auto; padding: 0; max-width: 1200px; display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(16px, 3vw, 40px); }
.tc-facts b { display: block; font-size: clamp(28px, 3.2vw, 46px); font-weight: 700; letter-spacing: -0.04em; line-height: 1.05; }
.tc-facts span { display: block; margin-top: 6px; font-size: 14px; color: var(--page-muted); max-width: 26ch; }

/* ---------- chapters ---------- */
.tc-ch { position: relative; overflow: hidden; overflow: clip; padding: clamp(80px, 14vh, 160px) var(--pad); background: var(--page); color: var(--page-text); scroll-margin-top: 40px; }
.tc-alt { background: var(--frame-glow); }
.tc-dark { color: var(--text); background: radial-gradient(80% 60% at 50% 100%, rgba(127, 178, 255, .14), rgba(127, 178, 255, 0) 70%), radial-gradient(90% 70% at 50% 0%, #0E1C36 0%, #05080F 70%); }
.tc-ch-head { max-width: 920px; margin: 0 auto; text-align: center; }
.tc-num { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 20px; font: 500 12px/1 "JetBrains Mono", monospace; letter-spacing: .14em; text-transform: uppercase; color: var(--page-muted); }
.tc-num::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--gain); box-shadow: 0 0 0 4px rgba(61, 220, 151, .16); }
.tc-dark .tc-num { color: var(--muted); }
.tc-h2 { margin: 0; font-weight: 700; font-size: clamp(36px, 5.6vw, 84px); line-height: 1; letter-spacing: -0.045em; }
.tc-lede { margin: 22px auto 0; max-width: 56ch; font-size: clamp(16px, 1.3vw, 19.5px); color: var(--page-muted); }
.tc-dark .tc-lede { color: var(--muted); }

/* devices */
.tc-dev { position: relative; max-width: 1120px; margin: clamp(44px, 8vh, 80px) auto 0; perspective: 2000px; }
.tc-dev .laptop.tc-lap { width: 100%; margin: 0; }
.tc-duo { padding-bottom: 6%; }
.tc-duo .laptop.tc-lap { width: 86%; }
.tc-duo .handset-x { width: 21%; right: 0; bottom: 0; }
.tc-tilt [data-scroll] > .laptop, .tc-tilt [data-scroll] > .handset-x { transform-origin: 50% 100%; transition: none;
  transform: rotateX(calc((1 - var(--s, 1)) * 16deg)) scale(calc(.9 + var(--s, 1) * .1)); opacity: calc(.35 + var(--s, 1) * .65); }
.tc-tilt .tc-duo[data-scroll] > .handset-x { transform: translate3d(0, calc((1 - var(--s, 1)) * 60px), 0); }
.tc-tilt .tc-ph[data-scroll] > .handset-x { transform: translate3d(0, calc((1 - var(--s, 1)) * 50px), 0) scale(calc(.94 + var(--s, 1) * .06)); }
.tc-badge { position: absolute; z-index: 3; left: 4%; top: 5%; padding: 7px 12px; border-radius: 999px; font: 500 11.5px/1 "JetBrains Mono", monospace; letter-spacing: .04em; color: #F2F5FB; background: rgba(5, 8, 15, .7); border: 1px solid rgba(214, 226, 255, .2); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }

/* take switcher */
.tc-tabs { display: flex; width: fit-content; max-width: 100%; margin: 30px auto 0; gap: 4px; padding: 4px; overflow-x: auto; scrollbar-width: none; border: 1px solid var(--page-line); border-radius: 999px; background: var(--page-glass); }
.tc-tabs::-webkit-scrollbar { display: none; }
.tc-tabs button { position: relative; flex: none; min-height: 44px; padding: 0 20px; border: 0; border-radius: 999px; background: none; color: var(--page-muted); font-size: 14.5px; font-weight: 600; cursor: pointer; overflow: hidden; transition: background .3s var(--ease), color .3s; }
.tc-tabs button[aria-pressed="true"] { background: var(--page-text); color: var(--page); }
.tc-prog { position: absolute; left: 18px; right: 18px; bottom: 6px; height: 2px; border-radius: 2px; background: var(--gain); transform: scaleX(0); transform-origin: 0 50%; transition: transform .3s linear; opacity: 0; }
.tc-tabs button[aria-pressed="true"] .tc-prog { opacity: 1; }
.tc-tabs-v { flex-direction: column; width: 100%; margin: 0; border-radius: 22px; }
.tc-tabs-v button { display: block; width: 100%; text-align: left; padding: 14px 16px 16px; border-radius: 18px; }
.tc-tabs-v button span { display: grid; grid-template-columns: 28px 1fr; column-gap: 8px; font-size: 16px; }
.tc-tabs-v button span b { grid-row: span 2; font: 500 12px/1.9 "JetBrains Mono", monospace; }
.tc-tabs-v button small { display: block; margin-top: 3px; font-size: 13.5px; font-weight: 400; opacity: .78; }
.tc-tabs-v .tc-prog { left: 16px; right: 16px; bottom: 7px; }

/* split: laptop beside the steps and the fee */
.tc-split { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(280px, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; max-width: 1320px; margin: clamp(44px, 8vh, 80px) auto 0; }
.tc-split .tc-dev { margin: 0; max-width: none; }
.tc-side { display: grid; gap: 16px; }
.tc-fee { padding: 22px 24px; border-radius: 24px; background: var(--page-2); border: 1px solid var(--page-line); box-shadow: 0 30px 60px -40px rgba(5, 8, 15, .35); }
.tc-fee-k { margin: 0; font: 500 11.5px/1 "JetBrains Mono", monospace; letter-spacing: .12em; text-transform: uppercase; color: var(--page-muted); }
.tc-fee-big { margin: 10px 0 0; line-height: .9; }
.tc-fee-big b { font-size: clamp(56px, 5.4vw, 80px); font-weight: 700; letter-spacing: -0.05em; }
.tc-fee-big span { font-size: 30px; font-weight: 600; margin-left: 2px; }
.tc-fee-of { margin: 8px 0 0; color: var(--page-muted); font-size: 15px; }
.tc-fee-ex { display: flex; justify-content: space-between; gap: 12px; margin: 14px 0 0; padding-top: 12px; border-top: 1px solid var(--page-line); font-size: 14px; color: var(--page-muted); }
.tc-fee-ex b { color: var(--page-text); font-family: "JetBrains Mono", monospace; }
.tc-link { position: relative; display: inline-flex; margin-top: 14px; font-size: 14.5px; font-weight: 600; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.tc-link::after { content: ""; position: absolute; inset: -10px -4px; }

/* validate: live curve beside the checks */
.tc-proof { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 16px; max-width: 1120px; margin: clamp(28px, 5vh, 48px) auto 0; align-items: stretch; }
.tc-curve > .iv2 { height: 100%; }
.tc-card { padding: 22px; border-radius: 24px; background: var(--page-2); border: 1px solid var(--page-line); }
.tc-card-k { margin: 0 0 12px; font: 500 11.5px/1.3 "JetBrains Mono", monospace; letter-spacing: .1em; text-transform: uppercase; color: var(--page-muted); }
.tc-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; }
.tc-checks li { display: grid; grid-template-columns: 20px 1fr; gap: 8px; }
.tc-checks li::before { content: ""; width: 14px; height: 14px; margin-top: 4px; border-radius: 50%; background: radial-gradient(circle, var(--gain) 0 3px, transparent 3.5px); box-shadow: inset 0 0 0 1.5px var(--gain); }
.tc-shot { position: relative; margin: 16px 0 0; border-radius: 14px; overflow: hidden; background: #05080F; box-shadow: 0 0 0 1px var(--page-line); cursor: zoom-in; }
.tc-shot img { width: 100%; height: auto; }
.tc-shot figcaption { position: absolute; left: 10px; bottom: 10px; padding: 6px 10px; border-radius: 999px; font: 500 11px/1 "JetBrains Mono", monospace; color: #0B1220; background: rgba(255, 255, 255, .84); }
.tc-fine { margin: 12px 0 0; font-size: 12.5px; color: var(--page-faint); }

/* ledger: order log beside the points */
.tc-pair { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; max-width: 1120px; margin: clamp(32px, 6vh, 56px) auto 0; }
.tc-shot-lg { margin: 0; box-shadow: 0 0 0 1px var(--line), 0 40px 80px -40px rgba(0, 0, 0, .7); }
.tc-list { list-style: none; margin: 0; padding: 0; }
.tc-list li { padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 15.5px; }
.tc-list li:first-child { padding-top: 0; }
.tc-list b { color: var(--text); }

/* pledge flow: a diagram, not a screen */
.tc-flow { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 56px; max-width: 1120px; margin: clamp(48px, 9vh, 90px) auto 0; padding: 0; }
.tc-node { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 26px 16px 22px; border-radius: 24px; background: rgba(13, 22, 40, .72); border: 1px solid rgba(214, 226, 255, .14); box-shadow: 0 30px 60px -36px rgba(0, 0, 0, .8); }
.tc-node i { display: grid; place-items: center; width: 54px; height: 54px; margin-bottom: 10px; border-radius: 16px; color: #7FB2FF; background: rgba(127, 178, 255, .1); border: 1px solid rgba(127, 178, 255, .3); }
.tc-node i svg { width: 26px; height: 26px; }
.tc-node.ok i { color: #3DDC97; background: rgba(61, 220, 151, .1); border-color: rgba(61, 220, 151, .35); }
.tc-node.hi { border-color: rgba(127, 178, 255, .55); background: rgba(20, 38, 72, .85); }
.tc-node b { font-size: 18px; letter-spacing: -0.02em; }
.tc-node span { font-size: 13.5px; color: var(--muted); }
.tc-node:not(:last-child)::after { content: ""; position: absolute; top: 50%; left: 100%; width: 56px; height: 2px; margin-top: -1px;
  background: repeating-linear-gradient(90deg, rgba(127, 178, 255, .85) 0 4px, transparent 4px 11px); background-size: 22px 2px; animation: tcDash 1.1s linear infinite; }
.tc-node:not(:last-child)::before { content: ""; position: absolute; z-index: 1; top: 50%; left: 100%; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; background: #3DDC97; box-shadow: 0 0 10px rgba(61, 220, 151, .9); animation: tcPulse 1.8s cubic-bezier(.5, 0, .5, 1) infinite; }
.tc-node:nth-child(2)::before { animation-delay: .6s; } .tc-node:nth-child(3)::before { animation-delay: 1.2s; }
@keyframes tcDash { to { background-position: 22px 0; } }
@keyframes tcPulse { 0% { transform: translateX(0); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translateX(56px); opacity: 0; } }
.tc-note { max-width: 62ch; margin: 30px auto 0; text-align: center; font-size: 13.5px; color: var(--faint); }

/* coming next */
.tc-soon { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 1120px; margin: clamp(44px, 8vh, 72px) auto 0; }
.tc-soon-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: clamp(22px, 3vw, 36px); border-radius: 28px; background: var(--page-2); border: 1px solid var(--page-line); box-shadow: 0 40px 80px -60px rgba(5, 8, 15, .5); transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.tc-soon-card:hover { transform: translateY(-4px); box-shadow: 0 50px 90px -50px rgba(5, 8, 15, .55); }
.tc-soon-tag { align-self: flex-start; padding: 6px 11px; border-radius: 999px; font: 500 11px/1 "JetBrains Mono", monospace; letter-spacing: .1em; text-transform: uppercase; color: var(--page-text); border: 1px dashed var(--page-line); background: var(--page); }
.tc-soon-art { width: 100%; height: auto; margin: 8px 0 6px; }
.tc-soon-art .sa-floor { fill: none; stroke: var(--gain); stroke-width: 1.5; stroke-dasharray: 4 6; }
.tc-soon-art .sa-line { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.tc-soon-art .sa-cut { fill: none; stroke: var(--gain); stroke-width: 2.4; stroke-linecap: round; }
.tc-soon-art .sa-grid rect { fill: none; stroke: var(--page-line); stroke-width: 1.5; }
html[data-theme="light"] .tc-soon-art .sa-line { stroke: #2F6FD6; }
html[data-theme="light"] .tc-soon-art .sa-floor, html[data-theme="light"] .tc-soon-art .sa-cut { stroke: #14A36B; }
html[data-theme="light"] .tc-soon-art .sa-grid rect { stroke: rgba(11, 18, 32, .2); }
.tc-soon-card b { font-size: clamp(22px, 2.1vw, 30px); letter-spacing: -0.03em; line-height: 1.1; }
.tc-soon-card > span:not(.tc-soon-tag) { color: var(--page-muted); font-size: 15.5px; max-width: 46ch; }
.tc-soon-card em { margin-top: auto; padding-top: 8px; font-style: normal; font-weight: 600; font-size: 14.5px; }
.tc-soon-card em::after { content: " \2192"; }

/* phones */
.tc-phones { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 3vw, 40px); max-width: 1120px; margin: clamp(44px, 8vh, 80px) auto 0; }
.tc-ph { margin: 0; }
.tc-ph .handset-x { position: relative; right: auto; bottom: auto; width: 100%; padding: 4%; transform: none; }
.tc-ph figcaption { margin-top: 16px; text-align: center; font-size: 14px; color: var(--page-muted); }
.tc-ph figcaption b { display: block; font-size: 17px; color: var(--page-text); }
.tc-dots { display: none; }

/* close */
.tc-close .tc-sub { margin-left: auto; margin-right: auto; }
.tc-close .kicker { color: var(--muted); }
.tc-fine-wrap { padding: 28px var(--pad) 8px; background: var(--page); }
.tc-fine-wrap p { max-width: 980px; margin: 0; font-size: 13px; color: var(--page-faint); }

/* ---------- phone ---------- */
@media (max-width: 860px) {
  .tc-hero { padding-top: calc(var(--hdr) + 36px); padding-bottom: 44px; }
  .tc-rec { margin-top: 22px; font-size: 12px; }
  .tc-card-k { font-size: 12px; }
  .tc-facts { padding-top: 34px; padding-bottom: 34px; }
  .tc-hero-stage { margin-top: 40px; padding-bottom: 16%; }
  .tc-hero-stage .laptop { width: 100%; margin: 0; }
  .tc-hero-stage .handset-x { width: 30%; right: -1%; bottom: 0; }
  .tc-index { top: calc(var(--hdr) + 8px); }
  .tc-index a { padding: 0 11px; }
  .tc-facts ul { grid-template-columns: 1fr 1fr; row-gap: 26px; }
  .tc-ch { padding-top: 58px; padding-bottom: 58px; }
  .tc-dev, .tc-split, .tc-flow, .tc-soon, .tc-phones { margin-top: 32px; }
  .tc-lede { margin-top: 16px; font-size: 15.5px; }
  .tc-num { margin-bottom: 14px; }
  .tc-soon-art { max-height: 74px; }
  .tc-soon-card { gap: 8px; }
  .tc-close { min-height: 0; }
  .tc-split, .tc-proof, .tc-pair, .tc-soon { grid-template-columns: 1fr; }
  .tc-tabs { margin-top: 22px; }
  .tc-tabs button { padding: 0 15px; font-size: 13.5px; }
  .tc-tabs-v { flex-direction: row; border-radius: 999px; width: fit-content; max-width: 100%; margin: 0 auto; }
  .tc-tabs-v button { width: auto; padding: 0 15px; border-radius: 999px; }
  .tc-tabs-v button span { display: inline; font-size: 13.5px; }
  .tc-tabs-v button span b, .tc-tabs-v button small { display: none; }
  .tc-tabs-v .tc-prog { left: 15px; right: 15px; bottom: 6px; }
  .tc-duo { padding-bottom: 14%; }
  .tc-duo .laptop.tc-lap { width: 100%; }
  .tc-duo .handset-x { width: 30%; right: -1%; }
  .tc-badge { font-size: 11px; padding: 6px 9px; }
  .tc-flow { grid-template-columns: 1fr; gap: 34px; max-width: 420px; }
  .tc-node { flex-direction: row; text-align: left; gap: 0 14px; display: grid; grid-template-columns: 54px 1fr; padding: 16px 18px; }
  .tc-node i { grid-row: span 2; margin: 0; }
  .tc-node:not(:last-child)::after { top: 100%; left: 50%; width: 2px; height: 34px; margin: 0 0 0 -1px; background: repeating-linear-gradient(180deg, rgba(127, 178, 255, .85) 0 4px, transparent 4px 11px); background-size: 2px 22px; animation-name: tcDashV; }
  .tc-node:not(:last-child)::before { top: 100%; left: 50%; margin: -4px 0 0 -4px; animation-name: tcPulseV; }
  .tc-phones { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 47vw; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin-left: calc(var(--pad) * -1); margin-right: calc(var(--pad) * -1); padding: 0 var(--pad) 6px; scroll-padding: 0 var(--pad); }
  .tc-phones::-webkit-scrollbar { display: none; }
  .tc-ph { scroll-snap-align: center; }
  .tc-dots { display: flex; justify-content: center; gap: 8px; margin-top: 18px; }
  .tc-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--page-line); transition: background .3s, width .3s var(--ease); }
  .tc-dots i.is-on { width: 22px; border-radius: 4px; background: var(--page-text); }
}
@keyframes tcDashV { to { background-position: 0 22px; } }
@keyframes tcPulseV { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translateY(34px); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .tc-node::after, .tc-node::before { animation: none !important; }
  .tc-node:not(:last-child)::before { display: none; }
  .tc-index, .tc-index.is-on, .tc-soon-card { transition: none; }
  .tc-prog { transition: none; }
}

/* the closing recording sits well behind the words */
.tc-close { min-height: 78vh; }
.tc-close > .tc-close-vid { filter: brightness(.5) saturate(.85); }
.tc-close::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(60% 70% at 50% 50%, rgba(5, 8, 15, .78), rgba(5, 8, 15, .5) 70%, rgba(5, 8, 15, .7)); }
.tc-close .pg-close-in { z-index: 2; }
