:root {
  --bg: #fbf6ec;
  --paper: #fffdf8;
  --ink: #1f1b16;
  --muted: #7a7365;
  --line: #e9e0cf;
  --accent: #ff6b2c;
  --accent-ink: #fff;
  --accent-soft: #ffe3d4;
  --teal: #11a39a;
  --desk: #e8dcc6;
  --win: #ffffff;
  --shadow: 0 18px 50px -20px rgba(60, 40, 10, .35);
  --display: "Bricolage Grotesque", -apple-system, "PingFang SC", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17140f; --paper: #211d17; --ink: #f3ece0; --muted: #a49a88; --line: #3a3328;
    --accent-soft: #4a2716; --desk: #2a251d; --win: #1c1914;
    --shadow: 0 18px 50px -20px rgba(0, 0, 0, .7);
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.65 -apple-system, "PingFang SC", "Hiragino Sans GB", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
main { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; letter-spacing: -.01em; }

.nav { display: flex; align-items: center; justify-content: space-between; max-width: 1040px; margin: 0 auto; padding: 18px 16px; }
.brand { display: flex; align-items: center; gap: 8px; font: 800 20px var(--display); text-decoration: none; }
.dot { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.nav nav { display: flex; gap: 18px; font-size: 15px; }
.nav nav a { text-decoration: none; color: var(--muted); }
.nav nav a:hover, .nav-account { color: var(--ink) !important; }

.hero { padding: 48px 0 28px; max-width: 760px; }
.eyebrow { color: var(--accent); font-weight: 600; margin: 0 0 10px; }
.hero h1 { font-size: clamp(40px, 7vw, 76px); margin: 0 0 18px; font-weight: 800; }
.hl { background: linear-gradient(transparent 62%, var(--accent-soft) 62%); }
.lede { font-size: 18px; color: var(--muted); max-width: 620px; }
.cta-row { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 0; border-radius: 999px; padding: 12px 22px; font: 600 15px inherit; font-family: inherit; cursor: pointer; text-decoration: none; transition: transform .12s, box-shadow .12s, opacity .12s; }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 6px 18px -6px var(--accent); }
.btn.primary:hover { box-shadow: 0 10px 24px -8px var(--accent); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn.sm { padding: 7px 16px; font-size: 14px; }
.btn.big { padding: 16px 30px; font-size: 18px; width: 100%; }
.btn[disabled] { opacity: .55; cursor: default; }

/* ---------- Demo ---------- */
.demo-wrap { padding: 28px 0 40px; }
.scenes { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.scene { border: 0; background: var(--paper); color: var(--muted); padding: 8px 14px; border-radius: 999px; font: inherit; font-size: 14px; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line); }
.scene.on { background: var(--ink); color: var(--bg); box-shadow: none; }

.desk {
  position: relative; height: 520px; border-radius: 22px; overflow: hidden; background: var(--desk);
  background-image: radial-gradient(rgba(0,0,0,.06) 1px, transparent 1px); background-size: 18px 18px;
  box-shadow: var(--shadow);
}
.win { position: absolute; left: 6%; right: 6%; top: 34px; bottom: 90px; background: var(--win); border-radius: 12px; box-shadow: 0 10px 30px -12px rgba(0,0,0,.3); overflow: hidden; transition: filter .3s; }
.desk.capturing .win { filter: saturate(.6) brightness(.96); }
.win-bar { height: 34px; display: flex; align-items: center; gap: 7px; padding: 0 12px; border-bottom: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.win-bar i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.win-bar i:nth-child(2) { background: #febc2e; } .win-bar i:nth-child(3) { background: #28c840; }
.win-bar span { margin-left: 10px; font-family: var(--mono); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.win-body { padding: 18px 22px; font-size: 14px; height: calc(100% - 34px); overflow: hidden; }
.win-body .mono { font-family: var(--mono); font-size: 12.5px; }
.win-body .err-line { background: #ffe9e7; color: #b42318; border-radius: 6px; padding: 6px 10px; margin: 6px 0; }
@media (prefers-color-scheme: dark) { .win-body .err-line { background: #3d1d1a; color: #ff9b8f; } }
.win-body mark { background: #fff1a8; color: #1f1b16; padding: 0 2px; border-radius: 3px; }
.win-body .bubble { max-width: 78%; padding: 9px 13px; border-radius: 14px; margin: 8px 0; background: var(--bg); }
.win-body .bubble.me { margin-left: auto; background: var(--accent-soft); }
.gh-label { display: inline-block; font-size: 11px; padding: 1px 8px; border-radius: 999px; background: #fde2e1; color: #b42318; margin-right: 6px; }

.hint { position: absolute; left: 66px; bottom: 26px; font-size: 14px; background: var(--ink); color: var(--bg); padding: 6px 12px; border-radius: 999px; animation: nudge 1.6s ease-in-out infinite; pointer-events: none; transition: opacity .2s; }
.hint.gone { opacity: 0; }
@keyframes nudge { 50% { transform: translateX(-6px); } }

.dock { position: absolute; left: 14px; bottom: 14px; }
.dock-btn { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--accent); cursor: pointer; display: grid; place-items: center; box-shadow: 0 0 0 5px var(--accent-soft), 0 8px 18px -6px var(--accent); position: relative; z-index: 2; }
.dock-btn span { width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: transform .2s; }
.dock.open .dock-btn span { transform: scale(.6); }
.dock-btn::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--accent); animation: ping 2s ease-out infinite; }
.dock.open .dock-btn::after, .dock.used .dock-btn::after { animation: none; opacity: 0; }
@keyframes ping { 0% { transform: scale(1); opacity: .7 } 100% { transform: scale(1.9); opacity: 0 } }
.fan { position: absolute; left: 0; bottom: 52px; display: flex; flex-direction: column-reverse; gap: 6px; pointer-events: none; }
.fan button {
  display: flex; align-items: center; gap: 8px; white-space: nowrap; border: 0; cursor: pointer;
  background: var(--paper); color: var(--ink); font: inherit; font-size: 14px; padding: 7px 14px 7px 9px; border-radius: 999px;
  box-shadow: 0 6px 16px -8px rgba(0,0,0,.35); opacity: 0; transform: translateY(14px) scale(.9);
  transition: opacity .18s, transform .22s cubic-bezier(.3,1.4,.5,1), background .12s;
}
.fan button .em { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 14px; }
.fan button:hover { background: var(--accent); color: #fff; }
.dock.open .fan { pointer-events: auto; }
.dock.open .fan button { opacity: 1; transform: none; }

.panel {
  position: absolute; left: 50%; top: 50%; width: min(440px, calc(100% - 32px)); transform: translate(-50%, -44%) scale(.94);
  background: var(--paper); border-radius: 16px; padding: 14px; box-shadow: 0 30px 70px -20px rgba(0,0,0,.45);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .28s cubic-bezier(.3,1.3,.5,1);
}
.panel.show { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%); }
.panel.fly { transition: transform .5s cubic-bezier(.6,-.2,.7,.4), opacity .45s; transform: translate(calc(50% + 20vw), 120%) scale(.1) rotate(10deg); opacity: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.chip { font-size: 13px; background: var(--accent-soft); padding: 3px 10px; border-radius: 999px; }
.timer { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.panel textarea { width: 100%; border: 0; background: transparent; color: var(--ink); resize: none; font: 15px/1.55 inherit; font-family: inherit; outline: none; }
.ctx-title { font-size: 12px; color: var(--muted); margin: 6px 0 4px; display: flex; justify-content: space-between; }
.ctx { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; max-height: 190px; overflow: auto; }
.ctx li {
  display: grid; grid-template-columns: 18px 64px 1fr; align-items: center; gap: 8px; font-size: 13px; padding: 5px 7px; border-radius: 8px; cursor: pointer;
  opacity: 0; transform: translateX(-8px); transition: opacity .25s, transform .25s, background .12s;
}
.ctx li.in { opacity: 1; transform: none; }
.ctx li:hover { background: var(--bg); }
.ctx li .ck { width: 16px; height: 16px; border-radius: 5px; background: var(--teal); color: #fff; font-size: 11px; display: grid; place-items: center; }
.ctx li.off .ck { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line); color: transparent; }
.ctx li.off .v { text-decoration: line-through; color: var(--muted); }
.ctx li .k { color: var(--muted); font-size: 12px; }
.ctx li .v { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-family: var(--mono); font-size: 12px; }
.panel-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }
.keys { font-size: 12px; color: var(--muted); }
kbd { font-family: var(--mono); font-size: 11px; background: var(--bg); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 0 5px; }

.library { position: absolute; right: 14px; bottom: 18px; background: var(--paper); border-radius: 999px; padding: 6px 14px; font-size: 13px; box-shadow: 0 6px 16px -8px rgba(0,0,0,.3); transition: transform .2s; }
.library.bump { transform: scale(1.18); }
.library b { color: var(--accent); }
.toast { position: absolute; left: 50%; top: 14px; transform: translate(-50%, -60px); background: var(--ink); color: var(--bg); padding: 8px 16px; border-radius: 999px; font-size: 14px; transition: transform .3s cubic-bezier(.3,1.4,.5,1); white-space: nowrap; }
.toast.show { transform: translate(-50%, 0); }

.versus { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; }
.vs-col { background: var(--paper); border-radius: 16px; padding: 16px 20px; box-shadow: inset 0 0 0 1px var(--line); }
.vs-col h3 { margin: 0 0 6px; font-size: 18px; }
.vs-col ol { margin: 0; padding-left: 20px; font-size: 14px; color: var(--muted); }
.vs-col.old li.struck { text-decoration: line-through; opacity: .5; }
.vs-col.new { box-shadow: inset 0 0 0 2px var(--accent); }
.vs-col.new ol { color: var(--ink); }
.vs-time { margin: 8px 0 0; font: 600 14px var(--mono); }
.vs-col.new .vs-time { color: var(--accent); }

.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; padding: 20px 0 56px; }
.feat b { display: block; margin-bottom: 4px; }
.feat p { margin: 0; color: var(--muted); font-size: 14px; }
code { font-family: var(--mono); font-size: .88em; background: var(--paper); border: 1px solid var(--line); border-radius: 5px; padding: 0 4px; }

/* ---------- Pricing ---------- */
.pricing { padding: 30px 0 40px; text-align: center; }
.pricing h2 { font-size: clamp(34px, 5vw, 52px); margin: 0 0 10px; }
.sub { color: var(--muted); margin: 0 0 28px; }
.stairs-card { background: var(--paper); border-radius: 22px; padding: 26px 22px 18px; box-shadow: var(--shadow); }
.stairs { display: flex; align-items: flex-end; gap: 8px; height: 210px; }
.step { flex: 1; position: relative; border-radius: 10px 10px 4px 4px; background: var(--bg); box-shadow: inset 0 0 0 1px var(--line); transition: background .2s; cursor: pointer; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 6px; }
.step .p { font: 800 15px var(--display); }
.step .r { font-size: 11px; color: var(--muted); }
.step .fill { position: absolute; left: 0; right: 0; bottom: 0; border-radius: inherit; background: var(--teal); opacity: .22; transition: height .5s; }
.step.now { background: var(--accent-soft); box-shadow: inset 0 0 0 2px var(--accent); }
.step.sel .p { color: var(--accent); }
.step .flag { position: absolute; left: 50%; top: -30px; transform: translateX(-50%); font-size: 12px; white-space: nowrap; background: var(--accent); color: #fff; padding: 2px 9px; border-radius: 999px; animation: bob 1.4s ease-in-out infinite; }
@keyframes bob { 50% { transform: translate(-50%, -4px); } }
.slider-row { display: flex; align-items: center; gap: 14px; margin-top: 22px; flex-wrap: wrap; justify-content: center; }
.slider-row input { flex: 1; min-width: 180px; accent-color: var(--accent); }
.seat-price { font: 800 26px var(--display); min-width: 90px; color: var(--accent); }
.live { margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.live b { color: var(--ink); }

.buy-card { max-width: 520px; margin: 26px auto 0; background: var(--paper); border-radius: 22px; padding: 26px; box-shadow: inset 0 0 0 1px var(--line); }
.buy-card h3 { margin: 0 0 6px; font-size: 24px; }
.muted { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.row { display: flex; gap: 8px; }
.row input { flex: 1; min-width: 0; border: 1.5px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 999px; padding: 11px 16px; font: inherit; outline: none; }
.row input:focus { border-color: var(--accent); }
#code { letter-spacing: 6px; text-align: center; font-family: var(--mono); }
.err { color: #d4380d; font-size: 14px; margin: 10px 0 0; min-height: 1em; }
.ticket { margin: 0 auto 14px; width: 260px; padding: 18px; border-radius: 16px; background: linear-gradient(135deg, var(--accent), #ffb347); color: #fff; display: grid; gap: 2px; position: relative; animation: pop .5s cubic-bezier(.3,1.6,.5,1); }
.ticket b { font: 800 54px var(--display); line-height: 1; }
.ticket::before, .ticket::after { content: ""; position: absolute; top: 50%; width: 18px; height: 18px; border-radius: 50%; background: var(--paper); transform: translateY(-50%); }
.ticket::before { left: -9px; } .ticket::after { right: -9px; }
@keyframes pop { from { transform: scale(.6) rotate(-6deg); opacity: 0; } }

.faq { max-width: 680px; margin: 0 auto; padding: 20px 0 60px; }
details { border-bottom: 1px solid var(--line); padding: 14px 4px; }
summary { cursor: pointer; font-weight: 600; }
details p { color: var(--muted); margin: 8px 0 0; }
footer { text-align: center; color: var(--muted); font-size: 13px; padding: 26px 16px 40px; }

.confetti { position: fixed; top: -10px; width: 9px; height: 14px; z-index: 50; pointer-events: none; animation: fall linear forwards; }
@keyframes fall { to { transform: translateY(105vh) rotate(720deg); } }

@media (max-width: 720px) {
  .desk { height: 560px; }
  .win { left: 12px; right: 12px; top: 16px; bottom: 80px; }
  .versus, .features { grid-template-columns: 1fr 1fr; }
  .stairs { height: 170px; gap: 4px; }
  .step .r { display: none; }
  .step .p { font-size: 12px; }
  .hint { font-size: 13px; }
}
@media (max-width: 460px) {
  .versus, .features { grid-template-columns: 1fr; }
  .row { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
