/* First screen: copy left, the burning sheet right (WebGL, DOM callouts follow it), how-it-works and the demo caption
   on the bottom row, a live flap.sh ticker along the floor. */
.hero { position: relative; display: flex; flex-direction: column; min-height: calc(100svh - var(--bar-h) - var(--banners-h, 0px)); overflow: hidden; isolation: isolate; }
.hero .fx { position: absolute; inset: 0; z-index: -1; background:
  radial-gradient(60% 70% at 72% 42%, #1a1513 0%, rgba(14, 12, 11, 0) 70%), var(--room); }
.fx-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity .8s; }
.hero.fx-on .fx-canvas { opacity: 1; }
.hero-in { position: relative; flex: 1; width: 100%; max-width: 1600px; margin: 0 auto; padding: clamp(32px, 7.5vh, 96px) 64px clamp(24px, 4vh, 40px);
  display: grid; grid-template-columns: minmax(0, 640px) minmax(0, 1fr); column-gap: 64px; }
.hero-l { display: flex; flex-direction: column; justify-content: space-between; gap: 36px; position: relative; z-index: 2; }
.hero-r { display: flex; flex-direction: column; min-height: 520px; }
.hero-copy { position: relative; }
.stage { position: relative; flex: 1; min-height: 360px; margin: -8px 0 8px; }
.caption { position: relative; z-index: 2; align-self: center; width: min(470px, 100%); margin: 0; }
.how { position: relative; }

.kicker { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-2); letter-spacing: .02em; }
.kicker i { width: 7px; height: 7px; border-radius: 1px; background: var(--ember); box-shadow: 0 0 12px var(--ember); }
.kicker .sep { color: var(--text-4); }
.h1 { margin-top: 24px; font-size: clamp(60px, 7.4vw, 120px); line-height: 1; letter-spacing: -.008em; }
html[lang="en"] .h1 { font-size: clamp(52px, 6.2vw, 100px); letter-spacing: -.012em; line-height: 1.02; }
.h1 .l { display: block; padding: 0 .06em .02em 0; }
.h1 .l > span { display: inline-block; position: relative; opacity: 0; transform: translateY(26%); clip-path: inset(0 0 100% 0);
  animation: rise 1s var(--ease) .05s forwards; }

@keyframes rise { to { opacity: 1; transform: none; clip-path: inset(-30% -12% -45% -12%); } }
/* line 1: paper, with one sheen pass after the reveal; line 2: burning from below, the ember band breathing */
.h1 .paper { background: linear-gradient(105deg, rgba(255, 255, 255, 0) 42%, rgba(255, 252, 245, .75) 50%, rgba(255, 255, 255, 0) 58%) no-repeat,
  linear-gradient(180deg, #fbf6ee 10%, #e9dcc6 100%);
  background-size: 260% 100%, 100% 100%; background-position: 140% 0, 0 0;
  -webkit-background-clip: text; background-clip: text; color: transparent; }
@keyframes sheen { to { background-position: -40% 0, 0 0; } }
.h1 .burn { background: linear-gradient(180deg, #f7efe3 0%, #f1e2cc 44%, #ffc27a 58%, #ff6a24 71%, #a3300e 85%, #2b1209 100%);
  background-size: 100% 112%; background-position: 50% 0;
  -webkit-background-clip: text; background-clip: text; color: transparent; }
@keyframes ember { to { background-position: 50% 100%; } }
.h1 .l > span.paper { animation: rise 1s var(--ease) .05s forwards, sheen 1.5s cubic-bezier(.4, 0, .2, 1) 1.15s forwards; }
.h1 .l > span.burn { animation: rise 1s var(--ease) .17s forwards, ember 3.2s ease-in-out 1.2s infinite alternate; }
.h1 .burn::after { content: attr(data-t); position: absolute; left: 0; top: 0; z-index: -1; color: #ff5a1f; opacity: .3; filter: blur(26px); transform: translateY(18px); pointer-events: none; }
.sub { margin-top: 22px; font-size: clamp(24px, 2.2vw, 32px); line-height: 1.25; color: var(--text); }
html[lang="en"] .sub { font-size: clamp(21px, 1.9vw, 28px); }
.lede { margin-top: 16px; max-width: 560px; font-size: 15.5px; line-height: 1.75; color: var(--text-2); text-wrap: pretty; }
.cta { margin-top: 28px; display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.cta .link { color: var(--text-2); text-decoration: none; font-weight: 550; border-bottom: 1px solid var(--line-3); padding-bottom: 2px; }
.cta .link:hover { color: var(--text); border-color: var(--text-2); }
.live { flex: none; display: flex; align-items: center; gap: 0; height: 100%; padding: 0 20px 0 24px; border-right: 1px solid var(--line); font-size: 12px; color: var(--text-2); white-space: nowrap; }
.live p { display: flex; align-items: baseline; gap: 0; }
.live p + p { margin-left: 18px; padding-left: 18px; border-left: 1px solid var(--line); }
.live .kv { margin-left: 12px; }
.live .kv.first { margin-left: 0; }
.live .kv b { color: var(--text); font-weight: 650; }
.live .sk { width: 7em; }

.how { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line-2); }
.how li { padding: 14px 18px 0 0; }
.how li + li { padding-left: 18px; border-left: 1px solid var(--line); }
.how b { display: block; font-size: 17px; line-height: 1.2; color: var(--text); margin-bottom: 7px; }
.how p { font-size: 12.5px; line-height: 1.6; color: var(--text-2); text-wrap: pretty; }

.caption .tls { display: flex; gap: 6px; margin-bottom: 12px; }
.tl { flex: 1; position: relative; text-align: left; padding-top: 9px; font-size: 11.5px; font-weight: 650; letter-spacing: .04em; color: var(--text-3); }
.tl::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--line-2); }
.tl i { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--text); transform-origin: left; transform: scaleX(0); }
.tl[aria-pressed="true"] { color: var(--text); }
.tl:hover { color: var(--text-2); }
.cap-line { font-size: 14.5px; line-height: 1.6; color: var(--text); min-height: 48px; font-variant-numeric: tabular-nums; }
.cap-line .tag { margin-right: 8px; vertical-align: 2px; }
.cap-note { margin-top: 4px; font-size: 12px; color: var(--text-3); line-height: 1.55; }

.callout { position: absolute; left: 0; top: 0; z-index: 3; pointer-events: none; font-size: 12.5px; color: var(--text-2); white-space: nowrap; opacity: 0; transition: opacity .35s; }
.callout > span { position: absolute; right: 48px; top: -10px; }
.callout b { color: var(--text); font-weight: 650; }
.callout em { font-style: normal; }
.callout::before { content: ''; position: absolute; right: 6px; top: 0; width: 36px; height: 1px; background: var(--text-3); }
.callout::after { content: ''; position: absolute; right: -1px; top: -3px; width: 7px; height: 7px; border-radius: 50%; background: var(--paper); box-shadow: 0 0 0 3px rgba(14, 12, 11, .8); }
.callout.hot b { color: var(--ember-hot); }
.callout.hot::after { background: var(--ember); }
.callout.cool b { color: var(--up); }
.callout.cool::after { background: var(--up); }

.ticker { position: relative; z-index: 2; flex: none; height: 44px; display: flex; align-items: center; border-top: 1px solid var(--line); background: rgba(14, 12, 11, .78); }
.ticker .run { flex: 1; overflow: hidden; height: 100%; display: flex; align-items: center; mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent); }
.track { display: flex; gap: 34px; width: max-content; padding-left: 24px; white-space: nowrap; font-size: 12.5px; animation: tick 70s linear infinite; }
.track.idle { animation: none; color: var(--text-3); }
.ticker:hover .track { animation-play-state: paused; }
.tk-i { color: var(--text-2); text-decoration: none; }
.tk-i b { color: var(--text); font-weight: 650; }
.tk-i:hover b { text-decoration: underline; text-underline-offset: 3px; }
@keyframes tick { to { transform: translateX(-50%); } }

/* no-WebGL / lost context: a printed still made of DOM, same language as the page */
.still { position: absolute; inset: 0; display: grid; place-items: center; --burn: .24; }
.st-paper { position: relative; width: min(78%, 380px); aspect-ratio: .74; padding: 7% 8% 0; background: #ece4d6; color: #1d1814;
  transform: perspective(1100px) rotateY(-14deg) rotateX(4deg) rotate(2.5deg); box-shadow: 30px 40px 60px rgba(0, 0, 0, .5);
  -webkit-mask: linear-gradient(#000, #000) top / 100% calc(100% - var(--burn) * 100%) no-repeat, url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 12' preserveAspectRatio='none'%3E%3Cpath d='M0 0h200v4l-6 3-7-4-8 6-6-3-9 5-7-5-8 4-6-2-9 5-8-6-6 3-9-2-7 5-8-4-6 4-9-5-7 3-8-3-6 5-9-4-7 3-8-5-6 4-9-2-7 4-8-5-6 3-9-4z'/%3E%3C/svg%3E") 0 calc((1 - var(--burn)) * 100%) / 100% 14px no-repeat;
  mask: linear-gradient(#000, #000) top / 100% calc(100% - var(--burn) * 100%) no-repeat, url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 12' preserveAspectRatio='none'%3E%3Cpath d='M0 0h200v4l-6 3-7-4-8 6-6-3-9 5-7-5-8 4-6-2-9 5-8-6-6 3-9-2-7 5-8-4-6 4-9-5-7 3-8-3-6 5-9-4-7 3-8-5-6 4-9-2-7 4-8-5-6 3-9-4z'/%3E%3C/svg%3E") 0 calc((1 - var(--burn)) * 100%) / 100% 14px no-repeat; }
.st-top { display: flex; justify-content: space-between; font: 650 10px/1 var(--ui); color: #6f655a; letter-spacing: .02em; padding-bottom: 8px; border-bottom: 1px solid rgba(29, 24, 20, .25); }
.st-sym { font-size: clamp(34px, 4.4vw, 60px); line-height: 1.15; margin-top: 10px; }
.st-name { font-size: 11px; color: #6f655a; padding-bottom: 10px; border-bottom: 1px solid rgba(29, 24, 20, .25); }
.st-dl { display: grid; gap: 4px; margin-top: 12px; font-size: 11.5px; }
.st-dl div { display: flex; justify-content: space-between; }
.st-dl dt { color: #6f655a; } .st-dl dd { font-weight: 650; }
.st-pl { display: flex; justify-content: space-between; margin-top: 14px; padding-top: 10px; border-top: 1px solid rgba(29, 24, 20, .25); font-size: 11px; color: #6f655a; }
.st-pnl { display: block; font: 750 clamp(40px, 4.6vw, 62px)/1.1 var(--ui); letter-spacing: -.02em; }
.st-pnl.down { color: #c43a0c; } .st-pnl.up { color: #1f7a52; }
.still::after { content: ''; position: absolute; left: 50%; top: 50%; width: min(78%, 380px); height: 3px; transform: translate(-50%, 0); opacity: 0; }
.still .st-burn { display: none; }
.st-paper::after { content: ''; position: absolute; left: 0; right: 0; bottom: calc(var(--burn) * 100%); height: 22%; pointer-events: none;
  background: linear-gradient(to top, rgba(255, 98, 32, .75), rgba(214, 96, 34, .28) 30%, rgba(120, 70, 30, .08) 70%, transparent); }
.still.gain .st-paper { box-shadow: 30px 40px 60px rgba(0, 0, 0, .5), 0 0 0 1px rgba(191, 240, 212, .35), 0 0 60px rgba(191, 240, 212, .18); }
.still.gain .st-paper::after { display: none; }
.hero.fx-on .still { display: none; }

/* below the fold */
.home-more { max-width: 1600px; margin: 0 auto; padding: 72px 64px 96px; display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 56px; }
.sec-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 18px; }
.sec-h h2 { font-size: 30px; line-height: 1.1; }
.sec-h p { color: var(--text-3); margin-top: 8px; font-size: 13px; }
.hot-t td.tok-td { padding-top: 7px; padding-bottom: 7px; }
.hot-t td { color: var(--text-2); }
.hot-t td:nth-child(2) { color: var(--text-3); }
.hot-src { margin-top: 10px; font-size: 11.5px; color: var(--text-3); }
.ledger-l { border-top: 1px solid var(--line-2); }
.ledger-l div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.ledger-l dt { color: var(--text-2); }
.ledger-l dd { color: var(--text); font-weight: 650; text-align: right; }
.ledger-l div:nth-child(4) dd { color: var(--down); }
.ledger-l div:nth-child(5) dd { color: var(--up); }
.ledger-l div:nth-child(6) dd { color: var(--text-2); font-weight: 500; }

@media (max-width: 1360px) {
  .hero-in { grid-template-columns: minmax(0, 560px) minmax(0, 1fr); padding-left: 48px; padding-right: 48px; column-gap: 40px; }
  .how li { padding-right: 12px; } .how li + li { padding-left: 12px; }
}
@media (max-width: 1099px) {
  .hero-in { display: flex; flex-direction: column; padding: 36px 32px 0; }
  .hero-l { display: contents; }
  .hero-r { display: contents; }
  .hero-copy { order: 1; }
  .stage { order: 2; flex: none; height: 440px; margin: 10px 0 0; }
  .caption { order: 3; }
  .how { order: 4; margin-top: 28px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .how li:nth-child(3) { border-left: 0; padding-left: 0; }
  .how li:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: 14px; }
  .ticker { margin-top: 32px; height: auto; flex-direction: column; align-items: stretch; }
  .live { height: auto; padding: 10px 18px; border-right: 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; gap: 4px 0; white-space: normal; }
  .ticker .run { height: 42px; }
  .home-more { grid-template-columns: 1fr; padding: 56px 32px 72px; }
}
@media (max-width: 599px) {
  .hero-in { padding: 26px 18px 0; }
  .kicker { font-size: 12px; }
  .h1 { margin-top: 16px; font-size: 56px; }
  html[lang="en"] .h1 { font-size: 44px; }
  .sub { margin-top: 14px; font-size: 22px; }
  html[lang="en"] .sub { font-size: 19px; }
  .lede { font-size: 14px; line-height: 1.7; }
  .cta { margin-top: 20px; gap: 16px; }
  .cta .btn-lg { height: 50px; padding: 0 20px; font-size: 15.5px; }
  .stage { height: 360px; }
  .cap-line { font-size: 13.5px; }
  .how p { font-size: 12.5px; }
  .live { font-size: 11.5px; }
  .live p + p { margin-left: 0; padding-left: 0; border-left: 0; }
  .live p { width: 100%; }
  .ticker .track { font-size: 12px; }
  .home-more { padding: 44px 18px 56px; gap: 44px; }
  .sec-h { flex-direction: column; align-items: flex-start; gap: 12px; }
  .sec-h h2 { font-size: 26px; }
  .hot-t th:nth-child(2), .hot-t td:nth-child(2), .hot-t .hide-s { display: none; }
}
@media (min-width: 1100px) and (max-height: 960px) {
  .hero-in { padding-top: clamp(24px, 5vh, 56px); }
  .h1 { margin-top: 18px; font-size: clamp(56px, min(7.4vw, 11.6vh), 112px); }
  html[lang="en"] .h1 { font-size: clamp(48px, min(6.2vw, 9.6vh), 92px); }
  .sub { margin-top: 16px; }
  .lede { margin-top: 12px; line-height: 1.68; }
  .cta { margin-top: 22px; }
  .hero-l { gap: 28px; }
  .how li { padding-top: 12px; }
  .how b { margin-bottom: 5px; }
}
@media (prefers-reduced-motion: reduce) {
  .h1 .l > span { opacity: 1; transform: none; clip-path: none; animation: none; }
  .h1 .l > span.paper, .h1 .l > span.burn { animation: none; }
  .track { animation: none; }
  .ticker .run { overflow-x: auto; }
}
