:root {
  color-scheme: dark;
  --page: #10101d;
  --surface: #181829;
  --text: #f8f4fa;
  --muted: #c0b8d0;
  --accent: #f2abba;
  --lavender: #c8adff;
  --border: #38334d;
  --success: #a7e0c3;
  --mono: "Cascadia Mono", Consolas, monospace;
  font-family: "Segoe UI", "Microsoft JhengHei", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--page); color: var(--text); font-size: 1rem; line-height: 1.55; }
img { max-width: 100%; display: block; }
a { color: var(--lavender); text-underline-offset: .2em; }
a:not([href]) { color: var(--muted); }
button, input { font: inherit; }
:focus-visible { outline: 2px solid var(--lavender); outline-offset: 4px; }
.shell { width: min(1180px, calc(100% - 64px)); margin-inline: auto; }
.masthead { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 70px; }
.brand { font-size: 1.7rem; font-weight: 900; letter-spacing: -.08em; color: var(--text); text-decoration: none; }
.brand span { color: var(--accent); }
.masthead nav { display: flex; align-items: center; gap: 24px; }
.masthead nav a { color: var(--muted); font-size: .9rem; text-decoration: none; }
.masthead nav a:hover { color: var(--text); }
.language { border: 1px solid var(--border); border-radius: 7px; padding: 4px 9px; }
.facts {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px 16px;
  background: #1b1729; border: 1px solid var(--border); border-radius: 8px; padding: 8px 14px;
  color: var(--muted); font-size: .875rem; margin-bottom: 14px;
}
.facts p { margin: 0; }
.facts code { overflow-wrap: anywhere; }
.fact-dot { margin: 0 .3em; }
.hero {
  min-height: 478px; position: relative; display: grid; grid-template-columns: 52% 48%; overflow: hidden;
  border: 1px solid #59446b; border-radius: 20px; isolation: isolate;
  background: linear-gradient(113deg, #21172f 0%, #191729 48%, #2c2340 100%);
}
.hero-text { position: relative; z-index: 1; align-self: center; padding: 48px 0 48px 56px; }
.network { margin: 0; font: bold .875rem var(--mono); letter-spacing: .08em; color: #e1b8ea; }
.network span { padding: 0 .3em; color: var(--accent); }
h1 { margin: 14px 0 8px; letter-spacing: -.075em; font-size: clamp(4.5rem, 9vw, 8rem); line-height: .94; font-weight: 900; }
[lang="zh-Hant-TW"] h1 { letter-spacing: -.06em; font-size: clamp(3.9rem, 7vw, 6.6rem); }
[lang="zh-Hant-TW"] h1 span { display: inline-block; font-size: .52em; color: #e0c5f2; letter-spacing: -.045em; }
.intro { color: #e0d6e9; margin: 20px 0; font-size: 1.125rem; }
.hero-art { position: absolute; z-index: -1; inset: 0 0 0 auto; width: 66%; height: 100%; object-fit: cover; object-position: center; mask-image: linear-gradient(90deg, transparent, #000 29%); }
.sale-state { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin: 0 0 22px; color: var(--accent); }
.sale-state time { color: var(--text); font: bold .9rem var(--mono); }
.sale-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
body[data-state="open"] .sale-state { color: var(--success); }
.button { display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; padding: 10px 16px; border: 1px solid transparent; min-height: 44px; font-weight: 720; text-decoration: none; cursor: pointer; }
.button.primary, .hero-action { background: var(--accent); color: #251428; }
.button.secondary { border-color: #76618e; background: #272038; color: var(--text); }
.button:hover:not(:disabled) { filter: brightness(1.11); }
button:disabled { opacity: .5; cursor: default; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); margin: 17px 0 24px; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--surface); }
.stats > div { min-width: 0; display: grid; align-content: start; padding: 16px 20px; border-inline-end: 1px solid var(--border); }
.stats > div:last-child { border-inline-end: 0; }
.stats span, .stats small { color: var(--muted); font-size: .875rem; }
.stats strong { font-size: clamp(1rem, 1.7vw, 1.35rem); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.overview { display: grid; grid-template-columns: 1.05fr 1fr; gap: 18px; }
.panel { min-width: 0; margin-bottom: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 25px; scroll-margin-top: 12px; }
.panel h2 { margin: 0 0 8px; font-size: 1.5rem; line-height: 1.25; }
.panel p { margin: 7px 0 15px; color: var(--muted); }
.panel h3 { margin: 18px 0 8px; font-size: 1rem; }
.fields { display: grid; grid-template-columns: minmax(60px, 1fr) minmax(0, 3fr); gap: 11px; }
.fields label { display: grid; gap: 5px; font-size: .875rem; color: var(--muted); }
.fields input { min-width: 0; width: 100%; padding: 9px; border-radius: 7px; border: 1px solid #655a76; background: #121121; color: var(--text); }
.actions, .utility { display: flex; align-items: center; flex-wrap: wrap; gap: 9px 12px; margin-top: 13px; }
.text-button { background: none; padding: 4px 0; border: 0; color: var(--lavender); text-decoration: underline; text-underline-offset: .24em; cursor: pointer; }
#message { min-height: 1.55em; margin: 8px 0 4px; }
#quote-result { color: var(--text); padding: 10px 12px; background: #221b32; border-radius: 8px; }
.wallet-address { overflow-wrap: anywhere; font: .875rem var(--mono); }
.pool-values { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0; }
.pool-values div { border-bottom: 1px solid var(--border); padding-bottom: 10px; }
.pool-values dt { color: var(--muted); font-size: .875rem; }
.pool-values dd { margin: 4px 0 0; font-weight: 700; overflow-wrap: anywhere; }
.allocation { display: grid; grid-template-columns: 8fr 1fr 1fr; gap: 3px; height: 7px; margin-bottom: 8px; }
.allocation span { border-radius: 2px; background: #b792ea; }
.allocation span:nth-child(2) { background: #f2abba; }
.allocation span:nth-child(3) { background: #dfc8a0; }
.splits { display: flex; flex-wrap: wrap; gap: 5px 16px; padding: 0; margin: 0; list-style: none; }
.ladder-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.tier { border: 1px solid var(--border); border-radius: 8px; padding: 9px 12px; min-width: 0; display: grid; }
.tier strong { font-size: .96rem; overflow-wrap: anywhere; }
.tier span { color: var(--muted); font-size: .875rem; }
.tier[aria-current="step"] { border-color: var(--accent); background: #302036; }
.tier[aria-current="step"] span { color: var(--accent); }
.table-hint { display: none; }
.table-scroll { overflow: auto; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; white-space: nowrap; }
th, td { text-align: right; padding: 8px 11px; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-weight: 600; }
th:first-child, td:first-child { text-align: left; }
tbody tr:nth-child(4n+1) td { border-top: 2px solid #625471; }
.footer { padding: 8px 0 28px; color: var(--muted); font-size: .875rem; }
.risk { color: #a9a0ba; }
@media (max-width: 900px) {
  .hero-text { padding-inline-start: 35px; }
  .stats > div { padding-inline: 12px; }
  .ladder-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .shell { width: calc(100% - 32px); }
  .masthead { min-height: 58px; }
  .masthead nav { gap: 12px; }
  .facts { padding: 7px 10px; margin-bottom: 12px; }
  .hero { min-height: 455px; display: grid; grid-template-columns: 1fr; align-items: end; }
  .hero-art { inset: 0; width: 100%; height: 81%; object-position: 60% 38%; mask-image: linear-gradient(180deg, #000 38%, transparent 100%); }
  .hero-text { align-self: end; padding: 126px 18px 22px; }
  h1 { font-size: 4.55rem; }
  [lang="zh-Hant-TW"] h1 { font-size: 4rem; }
  .intro { font-size: 1rem; margin: 12px 0; }
  .sale-state { margin-bottom: 16px; }
  .stats { grid-template-columns: repeat(2, 1fr); margin: 12px 0; }
  .stats > div { padding: 10px 12px; }
  .stats > div:nth-child(2) { border-inline-end: 0; }
  .stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
  .overview { grid-template-columns: 1fr; gap: 0; }
  .panel { padding: 16px; margin-bottom: 12px; }
  .ladder-grid { grid-template-columns: repeat(2, 1fr); }
  .table-hint { display: block; font-size: .875rem; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
