/* home page: dark, restrained. White type, hairlines, coral signal, lime only for the undo window */
.btn--ghost-ink { color: var(--text); }

/* ---------- hero */
.hero { padding: calc(var(--hdr) + clamp(56px, 8vw, 104px)) 0 0; position: relative; overflow: hidden; background: radial-gradient(1000px 420px at 50% -10%, rgba(255, 255, 255, .05), transparent 70%), var(--bg); }
.hero-top { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px); align-items: end; margin-bottom: clamp(44px, 6vw, 80px); }
.hero-copy { display: grid; gap: 28px; }
.hero .h-xl { font-size: clamp(44px, 6.6vw, 96px); }
.hero-side { display: grid; gap: 28px; padding-bottom: 10px; }
.hero-side .lead { font-size: clamp(16px, 1.4vw, 18.5px); }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.mon { position: relative; border: 1px solid var(--line-2); border-radius: 20px; background: #0b0b0d; overflow: hidden; box-shadow: 0 60px 120px -60px rgba(0, 0, 0, .9); }
.mon-bar { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 20px; border-bottom: 1px solid var(--line); }
.mon-url, .mon-net { font-size: 12px; color: var(--mute); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mon-url { flex: 1; text-align: center; }
#monRec { display: none; }
#scene { display: block; width: 100%; height: auto; background: #0b0b0d; touch-action: pan-y; }
.mon-ctl { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 24px; align-items: center; padding: 38px 20px 10px; border-top: 1px solid var(--line); }
.mon-btns { display: flex; gap: 8px; }
.mon-state .chip { min-width: 104px; justify-content: center; }
.mon-state .chip.go { color: var(--accent); border-color: rgba(212, 255, 58, .35); }
.mon-state .chip.stop { color: var(--signal); border-color: rgba(255, 90, 54, .4); }
.mon-cap { margin: 0; padding: 6px 20px 22px; color: var(--mute); font-size: 14.5px; min-height: 3em; }
.mon-cap b { color: var(--text); font-weight: 500; }
#btnUndo svg { transition: transform .3s var(--ease); }
#btnUndo:hover svg { transform: translateX(-3px); }
#btnUndo.shake { animation: shake .38s; }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }

.trk { position: relative; height: 40px; cursor: ew-resize; user-select: none; touch-action: none; outline-offset: 6px; }
.trk-seg { position: absolute; top: 8px; height: 26px; border-radius: 6px; display: flex; align-items: center; overflow: hidden; }
.trk-seg i { font-style: normal; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .02em; padding: 0 10px; white-space: nowrap; color: var(--mute); }
.trk-lock { left: 0; width: 14%; background: var(--bg-3); }
.trk-undo { left: 14%; width: 46%; background: rgba(212, 255, 58, .1); box-shadow: inset 0 0 0 1px rgba(212, 255, 58, .45); }
.trk-undo i { color: var(--accent); }
.trk-final { left: 60%; width: 40%; background: repeating-linear-gradient(135deg, rgba(255, 255, 255, .06) 0 4px, transparent 4px 9px); box-shadow: inset 0 0 0 1px var(--line-2); }
.trk-claim { position: absolute; left: 60%; top: -6px; bottom: 0; width: 1px; background: var(--signal); }
.trk-claim i { position: absolute; left: 7px; top: -3px; font-style: normal; font-family: var(--f-mono); font-size: 10px; color: var(--signal); white-space: nowrap; }
.trk::after { content: none; }
.trk-head { position: absolute; top: -10px; bottom: -6px; width: 0; left: 0; z-index: 3; }
.trk-head::before { content: ''; position: absolute; left: -1px; top: 0; bottom: 0; width: 2px; background: var(--text); border-radius: 2px; }
.trk-head::after { content: ''; position: absolute; left: -6px; top: -3px; width: 12px; height: 9px; background: var(--text); clip-path: polygon(0 0, 100% 0, 50% 100%); }
.trk-head em { position: absolute; left: 50%; top: -30px; transform: translateX(-50%); padding: 3px 8px; border-radius: 6px; background: var(--text); color: var(--bg); font-style: normal; font-size: 12px; white-space: nowrap; }
.trk-head.end em { left: auto; right: -8px; transform: none; }
.trk-head.beg em { left: -8px; transform: none; }
.rewinding .trk-head::before, .rewinding .trk-head::after, .rewinding .trk-head em { background: var(--signal); }
.rewinding .trk-head em { color: var(--signal-ink); }

.hero-facts { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: clamp(48px, 6vw, 88px); border-top: 1px solid var(--line); }
.fact { padding: 32px 24px 44px 0; display: grid; gap: 8px; }
.fact + .fact { padding-left: 24px; border-left: 1px solid var(--line); }
.fact b { font-family: var(--f-display); font-weight: 600; font-size: clamp(28px, 3.4vw, 46px); color: var(--text); line-height: 1.05; letter-spacing: -.04em; }
.fact span { color: var(--mute); font-size: 14.5px; }

/* ---------- film */
.filmsec { padding: clamp(64px, 8vw, 112px) 0; }
.film-box { border: 1px solid var(--line-2); border-radius: 20px; overflow: hidden; background: #0b0b0d; }
.film-box video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: #0b0b0d; }
.film-cap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 14px 20px; border-top: 1px solid var(--line); color: var(--mute); font-size: 12.5px; }

/* ---------- 01 compare */
.cmp { display: grid; gap: 18px; padding: 32px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--bg); margin-bottom: 20px; }
.cmp-row { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: center; }
.cmp-name { display: grid; gap: 2px; }
.cmp-name b { font-weight: 500; }
.cmp-name span { color: var(--mute); font-size: 12px; }
.cmp-track { position: relative; height: 44px; border-radius: 8px; background: var(--bg-3); overflow: hidden; display: flex; }
.cmp-final { flex: 1; background: repeating-linear-gradient(135deg, rgba(255, 255, 255, .06) 0 4px, transparent 4px 9px); box-shadow: inset 0 0 0 1px var(--line-2); border-radius: 8px; }
.cmp-undo { width: 70%; background: rgba(212, 255, 58, .12); box-shadow: inset 0 0 0 1px rgba(212, 255, 58, .5); border-radius: 8px 0 0 8px; transition: width .25s var(--ease); }
.cmp-tag { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-size: 12px; background: var(--bg); padding: 3px 9px; border-radius: 6px; color: var(--text-2); border: 1px solid var(--line); }
.cmp-ctl { display: grid; grid-template-columns: 220px minmax(0, 1fr) 70px; gap: 24px; align-items: center; margin-top: 4px; }
.cmp-ctl span { font-size: 12px; color: var(--mute); }
.cmp-ctl output { font-size: 20px; text-align: right; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 30px; background: transparent; cursor: pointer; color: var(--text); }
input[type=range]::-webkit-slider-runnable-track { height: 2px; background: var(--line-2); border-radius: 2px; }
input[type=range]::-moz-range-track { height: 2px; background: var(--line-2); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; margin-top: -7px; background: var(--text); border: 0; border-radius: 50%; }
input[type=range]::-moz-range-thumb { width: 16px; height: 16px; background: var(--text); border: 0; border-radius: 50%; }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.trio .card { display: grid; gap: 14px; align-content: start; background: transparent; }
.trio .num { font-size: 13px; color: var(--mute); line-height: 1; }
.trio p { margin: 0; font-size: 16px; }

/* ---------- 02 mechanism */
.nle { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--bg); padding: 22px 24px 28px; margin-bottom: 56px; }
.nle-tabs { display: flex; gap: 4px; margin-bottom: 22px; flex-wrap: wrap; padding: 4px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; width: fit-content; }
.nle-tab { height: 38px; padding: 0 16px; border: 0; border-radius: 8px; background: transparent; color: var(--mute); font-family: var(--f-display); font-weight: 500; font-size: 14.5px; transition: all .15s; }
.nle-tab:hover { color: var(--text); }
.nle-tab.on { background: var(--bg-3); color: var(--text); }
.nle-grid { display: grid; gap: 0; position: relative; }
.nle-ruler { display: grid; grid-template-columns: 150px minmax(0, 1fr); height: 24px; color: var(--mute); }
.nle-ruler div { position: relative; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(90deg, currentColor 0 1px, transparent 1px 5%) bottom / 100% 5px no-repeat; opacity: .5; }
.nle-lane { display: grid; grid-template-columns: 150px minmax(0, 1fr); height: 64px; border-bottom: 1px solid var(--line); }
.nle-lab { display: flex; flex-direction: column; justify-content: center; padding-right: 12px; font-size: 12px; color: var(--mute); }
.nle-lab b { color: var(--text); font-weight: 500; font-size: 13.5px; }
.nle-road { position: relative; }
.clip { position: absolute; top: 11px; bottom: 11px; display: flex; align-items: center; padding: 0 12px; border-radius: 7px; font-family: var(--f-mono); font-size: 12px; white-space: nowrap; overflow: hidden; transform-origin: left; animation: clipIn .6s var(--ease) both; }
@keyframes clipIn { from { transform: scaleX(0); opacity: 0; } }
.clip--call { background: var(--bg-3); border: 1px solid var(--line-2); color: var(--text); }
.clip--hold { background: rgba(212, 255, 58, .1); border: 1px solid rgba(212, 255, 58, .45); color: var(--accent); }
.clip--hit { background: var(--text); color: var(--bg); font-weight: 500; }
.clip--undo { background: var(--signal); color: var(--signal-ink); font-weight: 500; }
.clip--ghost { border: 1px dashed var(--line-2); color: var(--mute); }
.clip--crank { border: 1px solid rgba(255, 90, 54, .5); color: var(--signal); }
.nle-mark { position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px dashed rgba(255, 90, 54, .7); }
.nle-mark i { position: absolute; top: -20px; left: 7px; font-style: normal; font-family: var(--f-mono); font-size: 10.5px; color: var(--signal); white-space: nowrap; }
.nle-note { margin-top: 24px; display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 12px 44px; align-items: baseline; color: var(--mute); font-size: 14.5px; }
.nle-note p { grid-column: 1 / -1; margin: 0 0 8px; color: var(--text-2); max-width: 70ch; font-size: 16px; }
.nle-note span b { display: block; font-size: 26px; color: var(--text); line-height: 1.15; font-weight: 500; }
.nle-note span.neg b { color: var(--mute); }

.anat { display: grid; gap: 20px; }
.anat-url { display: flex; flex-wrap: wrap; padding: 22px 24px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-lg); font-size: clamp(13px, 1.8vw, 18px); word-break: break-all; }
.anat .seg { padding: 6px 3px; cursor: pointer; border-radius: 6px; transition: background .15s; }
.seg-host { color: var(--mute); }
.seg-path { color: var(--text); }
.seg-frag { color: var(--signal); }
.anat .seg:hover, .anat .seg.on { background: var(--bg-3); }
.anat-tip { min-height: 4.6em; color: var(--mute); max-width: 70ch; }
.anat-tip b { color: var(--text); font-weight: 500; }

/* ---------- 03 cheat */
.cheat { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--bg); overflow: hidden; }
.cheat-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 22px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--mute); }
.cheat-list { list-style: none; margin: 0; padding: 0; counter-reset: c; }
.cheat-list li { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 16px 22px; border-bottom: 1px solid var(--line); counter-increment: c; transition: background .2s; }
.cheat-list li:last-child { border-bottom: 0; }
.cheat-list li::before { content: counter(c, decimal-leading-zero); font-family: var(--f-mono); font-size: 12px; color: var(--mute); }
.cheat-list .t { display: grid; gap: 3px; min-width: 0; }
.cheat-list .t b { font-family: var(--f-display); font-weight: 500; font-size: 16.5px; }
.cheat-list .t code { background: none; padding: 0; color: var(--mute); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cheat-list .r { font-family: var(--f-mono); font-size: 12px; text-align: right; color: var(--mute); min-width: 190px; }
.cheat-list li.run { background: var(--bg-2); }
.cheat-list li.run .r::after { content: 'running...'; }
.cheat-list li.ref .r { color: var(--mute); }
.cheat-list li.ref .r b { display: block; font-family: var(--f-display); font-weight: 500; font-size: 14.5px; color: var(--text); }
.cheat-list li.ref::before { color: var(--signal); content: '×'; font-size: 15px; }
.cheat-list li.good .r { color: var(--mute); }
.cheat-list li.good .r b { display: block; font-family: var(--f-display); font-weight: 500; font-size: 14.5px; color: var(--accent); }
.cheat-list li.good::before { color: var(--accent); content: '✓'; font-size: 15px; }
.cheat-list .sel { color: var(--mute); font-size: 11px; }

/* ---------- 04 fees */
.fees { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.flow { display: grid; grid-template-columns: 1fr 20px 1fr 20px 1fr 20px 1fr; align-items: stretch; margin-top: 24px; }
.flow i { align-self: center; height: 1px; background: var(--line-2); position: relative; }
.flow i::after { content: ''; position: absolute; right: -1px; top: -3px; border: 3.5px solid transparent; border-left: 5px solid var(--line-2); }
.flow-node { display: grid; gap: 4px; align-content: center; padding: 16px 12px; min-height: 88px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg); text-align: center; }
.flow-node b { font-family: var(--f-display); font-weight: 500; font-size: 15px; }
.flow-node span { font-size: 11px; color: var(--mute); }
.flow-burn { border-color: rgba(255, 90, 54, .4); }
.flow-burn b { color: var(--signal); }
.fees-r { display: grid; gap: 16px; }
.calc, .burn { padding: 28px; background: var(--bg); }
.calc label { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--mute); margin-bottom: 20px; flex-wrap: wrap; }
.calc input { width: 120px; height: 44px; padding: 0 14px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--r); color: var(--text); font-family: var(--f-mono); font-size: 16px; }
.calc input:focus { outline: 0; border-color: var(--text); }
.calc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.calc-grid > div { display: grid; gap: 2px; padding: 18px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); }
.calc-grid span { font-size: 12px; color: var(--mute); }
.calc-grid b { font-family: var(--f-display); font-weight: 600; font-size: 32px; color: var(--text); line-height: 1.15; letter-spacing: -.03em; }
.calc-grid em { font-style: normal; font-family: var(--f-mono); font-size: 17px; color: var(--signal); margin-top: 10px; }
.calc-grid small { color: var(--mute); font-size: 12px; }
.calc-undo b { color: var(--text); } .calc-undo em { color: var(--text-2); }
.burn { display: grid; gap: 10px; }
.burn-h { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; color: var(--mute); font-size: 12.5px; }
.burn-n { font-family: var(--f-display); font-weight: 600; font-size: clamp(38px, 5vw, 60px); color: var(--text); line-height: 1; letter-spacing: -.04em; }

/* ---------- 06 faq */
.faq { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq .sec-head { margin: 0; position: sticky; top: calc(var(--hdr) + 32px); }
.faq-list details { border-top: 1px solid var(--line); }
.faq-list details:last-child { border-bottom: 1px solid var(--line); }
.faq-list summary { list-style: none; cursor: pointer; padding: 24px 48px 24px 0; position: relative; font-family: var(--f-display); font-weight: 500; font-size: 19px; letter-spacing: -.02em; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: ''; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; border-right: 1.5px solid var(--mute); border-bottom: 1.5px solid var(--mute); transform: translateY(-70%) rotate(45deg); transition: transform .25s var(--ease); }
.faq-list details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq-list details p { margin: 0 0 26px; max-width: 62ch; color: var(--mute); }

/* ---------- closing */
.cta { background: var(--bg); color: var(--text); padding: clamp(88px, 12vw, 160px) 0; border-top: 1px solid var(--line); text-align: left; }
.cta-in { display: flex; justify-content: space-between; align-items: end; gap: 32px; flex-wrap: wrap; }
.cta .h-lg { font-size: clamp(40px, 6vw, 88px); letter-spacing: -.045em; }

@media (max-width: 960px) {
  .hero-top, .fees, .faq { grid-template-columns: 1fr; }
  .faq .sec-head { position: static; }
  .hero-facts { grid-template-columns: 1fr 1fr; }
  .fact:nth-child(3) { padding-left: 0; border-left: 0; }
  .fact { padding-bottom: 24px; }
  .trio { grid-template-columns: 1fr; }
  .cmp-row, .cmp-ctl { grid-template-columns: 1fr; gap: 8px; }
  .cmp { padding: 22px; }
  .mon-ctl { grid-template-columns: 1fr auto; padding-top: 42px; }
  .mon-btns { grid-column: 1; grid-row: 2; }
  .mon-state { grid-column: 2; grid-row: 2; }
  .trk { grid-column: 1 / -1; grid-row: 1; }
  .mon-net { display: none; }
  .nle { padding: 16px; }
  .nle-grid { overflow-x: auto; padding-bottom: 6px; }
  .nle-ruler, .nle-lane { grid-template-columns: 90px minmax(0, 1fr); min-width: 640px; }
  .nle-lab { font-size: 10.5px; }
  .clip { font-size: 10.5px; padding: 0 7px; }
  .flow { grid-template-columns: 1fr; gap: 8px; }
  .flow i { width: 1px; height: 14px; justify-self: center; }
  .flow i::after { display: none; }
  .cheat-list li { grid-template-columns: 28px minmax(0, 1fr); }
  .cheat-list .r { grid-column: 2; text-align: left; min-width: 0; }
  .nle-note { grid-template-columns: 1fr 1fr; }
}
