:root {
  color-scheme: dark;
  --bg: #141210;
  --bg-raise: #1c1a17;
  --line: #2c2823;
  --ink: #f4f1ea;
  --muted: #9a9286;
  --soft: #d7d0c4;
  --gold: #d4a351;
  --gold-dim: #e8d3a2;
  --serif: "Fraunces", "Songti SC", "Noto Serif SC", "Noto Serif JP", "Noto Serif KR", serif;
  --sans: "Outfit", "PingFang SC", "Hiragino Sans", "Noto Sans SC", "Noto Sans JP", sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 520px at 50% 115%, rgba(212, 163, 81, 0.16), transparent 58%),
    var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--sans);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.08;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
  z-index: 0;
}

a { color: var(--gold-dim); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--ink); }

img { max-width: 100%; }

.wrap {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header,
.site-footer {
  border-bottom: 1px solid var(--line);
}

.site-footer { border-bottom: 0; border-top: 1px solid var(--line); }

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: inherit;
  text-decoration: none;
}

.brand img,
.brand svg {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: block;
  background: #f4f1ea;
}

.brand-name {
  font-size: 0.82rem;
  letter-spacing: 0.28em;
  font-weight: 500;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.nav a { color: var(--soft); text-decoration: none; font-size: 0.92rem; }
.nav a:hover { color: var(--ink); }

.lang {
  appearance: none;
  background: var(--bg-raise);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.4rem 1.8rem 0.4rem 0.8rem;
  font: inherit;
  font-size: 0.85rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 14px) 55%, calc(100% - 9px) 55%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.hero {
  padding: 5rem 0 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-rule {
  display: block;
  width: 2.4rem;
  height: 2px;
  margin: 0 0 1.3rem;
  background: #f7931a;
}

.hero-stage {
  position: relative;
  min-height: 520px;
  display: grid;
  place-items: center;
  justify-items: center;
}

.hero-glow {
  position: absolute;
  inset: 18% -18% 8%;
  background:
    radial-gradient(ellipse at 50% 78%, rgba(247, 147, 26, 0.32), transparent 58%),
    radial-gradient(ellipse at 50% 100%, rgba(212, 163, 81, 0.12), transparent 50%);
  pointer-events: none;
}

.hero-horizon {
  position: absolute;
  bottom: 1.2rem;
  width: 72%;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0, 0, 0, 0.55), transparent 72%);
  pointer-events: none;
}

.hero-artifact {
  position: relative;
  z-index: 1;
  width: min(340px, 86%);
}

.hero-artifact canvas {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  filter: drop-shadow(0 28px 48px rgba(0, 0, 0, 0.45));
}

.hero-artifact .mini-tray {
  margin-top: 0.55rem;
  gap: 6px;
}

.hero-artifact .mini-tray img {
  width: 20px;
  height: 20px;
}

.hero-qty {
  position: relative;
  z-index: 1;
  margin: 1.1rem 0 0;
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: #f5a33a;
  line-height: 1;
  letter-spacing: -0.03em;
}

.hero-qty span {
  font-size: 0.42em;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.7;
}

.hero-epigraph {
  position: relative;
  z-index: 1;
  margin: 0.55rem 0 0;
  color: var(--muted);
  letter-spacing: 0.22em;
  font-size: 0.68rem;
  text-transform: uppercase;
}

.hero-shard {
  position: absolute;
  z-index: 1;
  width: 22px;
  height: 22px;
  background: linear-gradient(145deg, #f7b14a, #c46a12);
  clip-path: polygon(18% 8%, 88% 22%, 78% 86%, 10% 72%);
  opacity: 0.88;
  filter: drop-shadow(0 8px 12px rgba(0, 0, 0, 0.35));
}

.hero-shard.a { top: 14%; right: 12%; transform: rotate(18deg); opacity: 0.7; }
.hero-shard.b { top: 38%; left: 6%; width: 16px; height: 16px; transform: rotate(-28deg); opacity: 0.38; }
.hero-shard.c { bottom: 26%; right: 8%; width: 14px; height: 14px; transform: rotate(42deg); opacity: 0.28; }

.kicker {
  margin: 0 0 1rem;
  color: var(--gold);
  letter-spacing: 0.32em;
  font-size: 0.72rem;
  font-weight: 500;
}

h1, h2, h3 { font-family: var(--serif); font-weight: 550; letter-spacing: -0.03em; }
h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); line-height: 1.08; margin: 0 0 1rem; }
.hero-copy h1 { margin-bottom: 0.85rem; }
h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); margin: 0 0 0.6rem; }
h3 { font-size: 1.2rem; margin: 0 0 0.45rem; }

.lead {
  margin: 0 0 1.8rem;
  color: var(--soft);
  font-size: 1.12rem;
  max-width: 36rem;
}

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.8rem;
  padding: 0.65rem 1.15rem;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.95rem;
  border: 1px solid transparent;
}

.btn-gold { background: var(--gold); color: #1a140a; }
.btn-gold:hover { background: #e0b56a; color: #1a140a; }
.btn-ghost { border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-dim); }

.qty {
  font-family: var(--serif);
  font-size: 2.4rem;
  color: var(--gold);
  line-height: 1;
}

.qty span { font-size: 1rem; color: var(--soft); margin-inline-start: 0.25rem; }

.chart-label { color: var(--muted); font-size: 0.75rem; margin-bottom: 0.4rem; }

.btc-well {
  background: #202022;
  border-radius: 22px;
  padding: 0.7rem 0.75rem 0.85rem;
}
.btc-well canvas {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  height: auto;
}
.btc-well .qty {
  margin-top: 0.55rem;
  font-size: 1.7rem;
  color: #f5a33a;
}
.btc-well .qty span { color: #f5a33a; opacity: 0.72; }
.mini-tray {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: 0.2rem;
}
.mini-tray img {
  width: 18px;
  height: 18px;
  display: block;
}

.puzzle {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
  border-top: 1px solid var(--line);
}
.puzzle-copy .lead { margin-bottom: 1.5rem; }
.puzzle-points { display: grid; gap: 1.1rem; }
.puzzle-points h3 { font-size: 1.05rem; margin: 0 0 0.3rem; }
.puzzle-points p { margin: 0; color: var(--soft); }
.puzzle-stage { justify-self: center; width: min(360px, 100%); }
.btc-seat { display: grid; justify-items: center; }
.btc-seat .btc-well {
  width: 100%;
  padding: 1rem 1rem 1.1rem;
  border-radius: 28px;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.38);
}
.seat-plinth {
  width: 62%;
  height: 16px;
  margin-top: 2px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0, 0, 0, 0.5), transparent 72%);
}
.puzzle-stage .chart-label { margin: 0 0 0.35rem; }

.ribbon {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0 2.5rem;
  color: var(--muted);
  letter-spacing: 0.18em;
  font-size: 0.68rem;
  text-transform: uppercase;
  border-bottom: 1px solid var(--line);
}

section { padding: 4rem 0; }
.eyebrow {
  color: var(--gold);
  letter-spacing: 0.22em;
  font-size: 0.72rem;
  margin: 0 0 0.7rem;
}

.principles, .features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.6rem;
}

.card {
  background: var(--bg-raise);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.25rem 1.2rem 1.35rem;
}

.card h2 { font-size: 1.2rem; margin: 0 0 0.45rem; }
.card p, .step p { margin: 0; color: var(--soft); }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  margin-top: 1.8rem;
}

.num {
  font-family: var(--serif);
  color: var(--gold);
  font-size: 1.4rem;
  margin-bottom: 0.4rem;
}

.preview-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
}
.preview-head h2 { margin-bottom: 0; }
.preview-controls { display: flex; gap: 0.5rem; }
.preview-btn {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-raise);
  color: var(--ink);
  font: inherit;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
.preview-btn:hover {
  border-color: var(--gold);
  color: var(--gold-dim);
}
.preview-frame { margin-top: 1.6rem; }
.preview-viewport {
  overflow: hidden;
  touch-action: pan-y;
}
.preview-track {
  --preview-gap: 1rem;
  display: flex;
  gap: var(--preview-gap);
  width: 100%;
  transition: transform 0.45s ease;
  user-select: none;
}
.preview-track figure {
  flex: 0 0 calc((100% - 2 * var(--preview-gap)) / 3);
  margin: 0;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #0c0b0a;
}
.preview-track img {
  display: block;
  width: 100%;
  height: auto;
}
.preview-dots {
  display: flex;
  justify-content: center;
  gap: 0.45rem;
  margin-top: 1rem;
}
.preview-dots button {
  width: 0.48rem;
  height: 0.48rem;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: var(--line);
  cursor: pointer;
}
.preview-dots button[aria-current="true"] {
  background: var(--gold);
  width: 1.1rem;
}

.legal { padding: 3.5rem 0 5rem; max-width: 40rem; }
.legal p, .legal li { color: var(--soft); }
.legal h2 { font-size: 1.15rem; margin-top: 2rem; }
.meta { color: var(--muted); font-size: 0.9rem; }

.foot {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem 0 2rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.foot nav { display: flex; gap: 1rem; }

[dir="rtl"] .brand-name,
[dir="rtl"] .kicker,
[dir="rtl"] .ribbon,
[dir="rtl"] .eyebrow { letter-spacing: 0.06em; }

@media (max-width: 860px) {
  .hero, .principles, .features, .steps, .foot, .ribbon, .puzzle { grid-template-columns: 1fr; display: grid; }
  .nav .hide-sm { display: none; }
  .hero-stage { min-height: 420px; }
  .ribbon { display: grid; }
}

@media (max-width: 720px) {
  .preview-head { align-items: center; }
  .preview-track { --preview-gap: 0.65rem; }
  .preview-track figure { border-radius: 12px; }
}