:root {
  --ground: #03110f;
  --ground-2: #051815;
  --panel: #071e1a;
  --panel-2: #0a2721;
  --panel-3: #0d3029;
  --line: rgba(140, 255, 220, 0.14);
  --line-strong: rgba(140, 255, 220, 0.28);
  --mint: #00e6a0;
  --mint-2: #6affd0;
  --mint-ink: #02110c;
  --cyan: #7cebff;
  --amber: #ffc857;
  --text: #effffa;
  --muted: #93b8ae;
  --dim: #6f9a8e;
  --font-display: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  --shell: 1280px;
  --radius: 10px;
  --radius-sm: 4px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  scrollbar-color: rgba(0, 230, 160, 0.28) var(--ground);
  background: var(--ground);
  overflow-x: clip;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

body.dialog-open {
  overflow: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 48% at 88% -8%, rgba(0, 230, 160, 0.07), transparent 62%),
    radial-gradient(ellipse 46% 40% at 0% 28%, rgba(124, 235, 255, 0.035), transparent 62%);
}

img {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

::selection {
  background: var(--mint);
  color: var(--mint-ink);
}

::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--ground);
}

::-webkit-scrollbar-thumb {
  background: rgba(0, 230, 160, 0.24);
  border: 2px solid var(--ground);
  border-radius: 10px;
}

:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 200;
  padding: 10px 16px;
  border: 1px solid var(--mint);
  border-radius: 3px;
  background: var(--ground-2);
  color: var(--mint);
  font-weight: 600;
  text-decoration: none;
  transition: top 0.2s var(--ease);
}

.skip-link:focus {
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.shell {
  width: min(var(--shell), calc(100% - 48px));
  margin-inline: auto;
}

.icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Header */
.site-head {
  position: sticky;
  top: 0;
  z-index: 60;
  border-bottom: 1px solid var(--line);
  background: rgba(3, 17, 15, 0.76);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.site-head.is-scrolled {
  background: rgba(3, 17, 15, 0.94);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.3);
}

.head-inner {
  display: flex;
  align-items: center;
  gap: 30px;
  height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  display: block;
  width: 32px;
  height: 32px;
  color: var(--mint);
}

.brand-mark svg {
  width: 100%;
  height: 100%;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-copy strong {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.015em;
}

.brand-copy small {
  margin-top: 2px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.desktop-nav {
  display: flex;
  gap: 26px;
  margin-left: auto;
}

.desktop-nav a {
  position: relative;
  padding: 8px 0;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
}

.desktop-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 1px;
  background: var(--mint);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease);
}

.desktop-nav a:hover {
  color: var(--text);
}

.desktop-nav a:hover::after {
  transform: scaleX(1);
}

.head-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.head-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  white-space: nowrap;
}

.status-dot {
  width: 6px;
  height: 6px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--mint);
}

.head-lookup {
  color: var(--muted);
  font-size: 12px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.head-lookup:hover {
  color: var(--mint);
}

.menu-btn {
  display: none;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  place-items: center;
}

.menu-btn:hover {
  border-color: var(--mint);
  color: var(--mint);
}

.mobile-menu {
  display: none;
  padding: 8px 24px 20px;
  border-top: 1px solid var(--line);
  background: rgba(3, 17, 15, 0.98);
}

.mobile-menu[hidden] {
  display: none;
}

.mobile-menu nav {
  display: grid;
  margin-bottom: 14px;
}

.mobile-menu nav a {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

.mobile-menu nav a:hover {
  color: var(--mint);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s var(--ease);
}

.btn .icon {
  transition: transform 0.25s var(--ease);
}

.btn:hover .icon {
  transform: translateX(3px);
}

.btn-primary {
  border-color: var(--mint);
  background: var(--mint);
  color: var(--mint-ink);
}

.btn-primary:hover {
  border-color: var(--mint-2);
  background: var(--mint-2);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-ghost {
  border-color: var(--line-strong);
  background: transparent;
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--mint);
  background: rgba(0, 230, 160, 0.05);
  color: var(--mint);
}

.btn-sm {
  min-height: 36px;
  padding: 0 15px;
  font-size: 11.5px;
}

.btn-block {
  width: 100%;
}

/* Hero */
.hero {
  position: relative;
  padding-top: 40px;
  overflow: clip;
}

.hero-glow {
  position: absolute;
  top: -30%;
  left: 36%;
  width: 900px;
  height: 860px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 230, 160, 0.1), transparent 66%);
  pointer-events: none;
  filter: blur(12px);
}

.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  align-items: center;
  gap: 36px;
  min-height: 480px;
  padding-bottom: 8px;
}

.hero-copy {
  position: relative;
  z-index: 3;
  min-width: 0;
  max-width: 660px;
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(36px, 5.1vw, 72px);
  font-stretch: 105%;
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.93;
  text-transform: uppercase;
  text-wrap: balance;
}

.hero h1 .h1-line {
  display: block;
  white-space: nowrap;
}

.hero h1 em {
  display: block;
  color: var(--mint);
  font-style: italic;
  font-stretch: 100%;
}

.hero-sub {
  max-width: 56ch;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.7;
}

.hero-sub a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: rgba(0, 230, 160, 0.5);
  text-underline-offset: 3px;
}

.hero-sub a:hover {
  color: var(--mint);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 12.5px;
}

.hero-trust li {
  display: flex;
  align-items: center;
  gap: 7px;
}

.hero-trust .icon {
  width: 14px;
  height: 14px;
  color: var(--mint);
}

.hero-stage {
  position: relative;
  z-index: 2;
  display: grid;
  min-height: 500px;
  place-items: center;
}

.stage-grid {
  position: absolute;
  inset: 14% 0;
  background-image: radial-gradient(rgba(140, 255, 220, 0.22) 1px, transparent 1px);
  background-size: 20px 20px;
  mask-image: radial-gradient(circle at 50% 50%, #000 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 0%, transparent 70%);
  opacity: 0.38;
  pointer-events: none;
}

.orbit {
  position: absolute;
  border: 1px solid var(--line);
  border-radius: 50%;
  pointer-events: none;
}

.orbit-a {
  top: 0;
  left: 50%;
  width: 560px;
  height: 560px;
  border-color: rgba(0, 230, 160, 0.16);
  transform: translateX(-50%) rotate(-14deg);
}

.orbit-a::after {
  content: "";
  position: absolute;
  top: 50%;
  left: -2px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mint);
}

.orbit-b {
  top: 60px;
  left: 50%;
  width: 440px;
  height: 440px;
  border-color: rgba(124, 235, 255, 0.12);
  border-style: dashed;
  transform: translateX(-50%) rotate(18deg);
}

.phone {
  position: relative;
  z-index: 2;
  width: 270px;
  height: 500px;
  padding: 7px;
  border: 1px solid rgba(180, 255, 230, 0.18);
  border-radius: 42px;
  background: linear-gradient(145deg, #203b34, #061411 30%, #10251f 70%, #1f3a33);
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.55),
    inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  transform: rotate(3deg);
  animation: phoneFloat 7s ease-in-out infinite;
}

.phone::after {
  content: "";
  position: absolute;
  top: 18px;
  left: 50%;
  z-index: 3;
  width: 74px;
  height: 20px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  background: #020a08;
  transform: translateX(-50%);
}

.phone-screen {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.6);
  border-radius: 36px;
  background: #020a08;
}

.phone-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95) contrast(1.05);
}

.phone-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(1, 10, 8, 0.35), transparent 20%, transparent 75%, rgba(1, 10, 8, 0.55));
}

.phone-status {
  position: absolute;
  top: 12px;
  right: 20px;
  left: 20px;
  z-index: 4;
  display: flex;
  justify-content: space-between;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.85);
}

.phone-nav {
  position: absolute;
  bottom: 10px;
  left: 50%;
  z-index: 4;
  display: flex;
  gap: 32px;
  color: rgba(255, 255, 255, 0.75);
  transform: translateX(-50%);
}

.phone-nav svg {
  width: 14px;
  height: 14px;
}

@keyframes phoneFloat {
  0%,
  100% {
    transform: rotate(3deg) translateY(0);
  }
  50% {
    transform: rotate(3deg) translateY(-8px);
  }
}

.live-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border: 1px solid rgba(0, 230, 160, 0.25);
  border-radius: 2px;
  background: rgba(3, 17, 15, 0.7);
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.hero-stage > .live-chip {
  position: absolute;
  top: 18px;
  right: 0;
  z-index: 6;
}

.code-float {
  position: absolute;
  top: 54%;
  left: -18px;
  z-index: 5;
  width: 244px;
  padding: 13px 14px;
  border: 1px solid rgba(0, 230, 160, 0.22);
  border-radius: 8px;
  background: rgba(7, 30, 26, 0.92);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(18px);
  transform: translateY(-50%) rotate(-2deg);
  animation: codeFloat 6s ease-in-out infinite;
}

.code-float::before,
.code-float::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  pointer-events: none;
}

.code-float::before {
  top: -1px;
  left: -1px;
  border-top: 1px solid var(--mint);
  border-left: 1px solid var(--mint);
  border-top-left-radius: 8px;
}

.code-float::after {
  right: -1px;
  bottom: -1px;
  border-right: 1px solid var(--mint);
  border-bottom: 1px solid var(--mint);
  border-bottom-right-radius: 8px;
}

@keyframes codeFloat {
  0%,
  100% {
    transform: translateY(-50%) rotate(-2deg);
  }
  50% {
    transform: translateY(calc(-50% - 6px)) rotate(-2deg);
  }
}

.code-float-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.code-tag {
  padding: 1px 4px;
  border: 1px solid rgba(255, 200, 87, 0.3);
  border-radius: 2px;
  color: var(--amber);
  font-size: 7px;
}

.code-string {
  margin: 8px 0 10px;
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  word-break: break-all;
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: transparent;
  color: var(--muted);
  font-size: 10px;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.copy-btn:hover {
  border-color: var(--mint);
  color: var(--mint);
}

.copy-btn.is-copied {
  border-color: var(--mint);
  color: var(--mint);
}

.copy-btn .icon {
  width: 12px;
  height: 12px;
}

.copy-btn-wide {
  justify-content: center;
  width: 100%;
  min-height: 36px;
  margin-top: 12px;
  font-size: 12px;
}

/* Exchange board */
.board-wrap {
  position: relative;
  z-index: 5;
  margin-top: -56px;
}

.exchange {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(9, 34, 29, 0.94), rgba(4, 20, 17, 0.98));
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(18px);
}

.exchange::before,
.exchange::after {
  content: "";
  position: absolute;
  z-index: 2;
  width: 22px;
  height: 22px;
  pointer-events: none;
}

.exchange::before {
  top: -1px;
  left: -1px;
  border-top: 1px solid var(--mint);
  border-left: 1px solid var(--mint);
  border-top-left-radius: var(--radius);
}

.exchange::after {
  right: -1px;
  bottom: -1px;
  border-right: 1px solid var(--mint);
  border-bottom: 1px solid var(--mint);
  border-bottom-right-radius: var(--radius);
}

.exchange-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--line);
}

.exchange-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.exchange-meta {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
}

.exchange-body {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.9fr);
  min-height: 250px;
}

.plan-list {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 6px 0;
  border-right: 1px solid var(--line);
}

.plan-row {
  display: grid;
  width: 100%;
  grid-template-columns: 34px minmax(0, 1fr) 108px 76px 16px;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 8px 18px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease;
}

.plan-row:last-child {
  border-bottom: 0;
}

.plan-row:hover {
  background: rgba(0, 230, 160, 0.04);
}

.plan-row.is-active {
  background: linear-gradient(90deg, rgba(0, 230, 160, 0.09), rgba(0, 230, 160, 0.02));
}

.plan-index {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
}

.plan-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.plan-name {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.plan-row.is-active .plan-name {
  color: var(--mint);
}

.plan-meta {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.plan-price {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
}

.plan-price small {
  display: block;
  margin-top: 1px;
  color: var(--dim);
  font-size: 7px;
  letter-spacing: 0.06em;
}

.plan-badge {
  padding: 2px 5px;
  border: 1px solid var(--line);
  border-radius: 2px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8.5px;
  text-align: center;
  white-space: nowrap;
}

.plan-badge.is-save {
  border-color: rgba(255, 200, 87, 0.3);
  background: rgba(255, 200, 87, 0.04);
  color: var(--amber);
}

.plan-radio {
  position: relative;
  justify-self: end;
  width: 12px;
  height: 12px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}

.plan-row.is-active .plan-radio {
  border-color: var(--mint);
}

.plan-row.is-active .plan-radio::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--mint);
}

.ticket {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 144px;
  grid-template-rows: auto auto auto auto auto;
  align-content: space-between;
  min-width: 0;
  gap: 5px 16px;
  padding: 10px 16px;
  background: rgba(2, 14, 12, 0.28);
}

.ticket > * {
  min-width: 0;
}

.ticket-head {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.ticket-eyebrow {
  display: block;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.ticket-head strong {
  display: block;
  margin-top: 1px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.15;
  text-transform: uppercase;
}

.ticket-badge {
  padding: 3px 6px;
  border: 1px solid rgba(255, 200, 87, 0.3);
  border-radius: 2px;
  background: rgba(255, 200, 87, 0.04);
  color: var(--amber);
  font-family: var(--font-mono);
  font-size: 9px;
}

.ticket-badge[hidden] {
  display: none;
}

.qty-row {
  grid-column: 1;
  grid-row: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.qty-label {
  color: var(--muted);
  font-size: 11px;
}

.stepper {
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 3px;
}

.stepper button {
  display: grid;
  width: 28px;
  height: 26px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  place-items: center;
  transition: background 0.2s ease, color 0.2s ease;
}

.stepper button:hover {
  background: rgba(0, 230, 160, 0.08);
  color: var(--mint);
}

.stepper .icon {
  width: 12px;
  height: 12px;
}

.stepper input {
  width: 38px;
  height: 26px;
  padding: 0;
  border: 0;
  border-right: 1px solid var(--line);
  border-left: 1px solid var(--line);
  outline: none;
  background: transparent;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  text-align: center;
}

.ticket-prices {
  grid-column: 1;
  grid-row: 3;
  display: grid;
  gap: 2px;
  padding-top: 6px;
  border-top: 1px solid var(--line);
}

.ticket-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 10px;
}

.ticket-line strong {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
}

.ticket-line.is-total {
  margin-top: 2px;
  padding-top: 5px;
  border-top: 1px dashed var(--line);
}

.ticket-line.is-total span {
  color: var(--text);
  font-weight: 600;
}

.ticket-line.is-total strong {
  color: var(--mint);
  font-size: 15px;
  font-weight: 600;
}

.ticket-line[hidden] {
  display: none;
}

.qr-row {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-top: 0;
}

.qr-frame {
  position: relative;
  width: 68px;
  height: 68px;
  flex-shrink: 0;
  overflow: hidden;
  padding: 4px;
  border: 1px solid rgba(0, 230, 160, 0.28);
  border-radius: 4px;
  background: #eafff7;
}

.qr {
  display: block;
  width: 100%;
  height: 100%;
}

.scan-line {
  position: absolute;
  top: 4px;
  right: 4px;
  left: 4px;
  height: 1px;
  background: var(--mint);
  opacity: 0;
  animation: scan 3.2s ease-in-out infinite;
}

@keyframes scan {
  0%,
  100% {
    opacity: 0;
    transform: translateY(0);
  }
  20% {
    opacity: 1;
  }
  50% {
    opacity: 1;
    transform: translateY(58px);
  }
  80% {
    opacity: 0;
  }
}

.qr-demo {
  position: absolute;
  right: 2px;
  bottom: 2px;
  padding: 1px 3px;
  border-radius: 1px;
  background: rgba(255, 200, 87, 0.9);
  color: #03110f;
  font-family: var(--font-mono);
  font-size: 6px;
  letter-spacing: 0.08em;
}

.qr-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.qr-meta strong {
  font-size: 10px;
  font-weight: 600;
}

.ticket .qr-meta span {
  display: none;
}

.qr-meta span {
  color: var(--muted);
  font-size: 9.5px;
  line-height: 1.45;
}

.ticket .btn {
  grid-column: 1 / -1;
  grid-row: 4;
  min-height: 36px;
  margin-top: 0;
  padding: 0 12px;
  font-size: 12px;
}

.ticket-note {
  grid-column: 1 / -1;
  grid-row: 5;
  margin: 0;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.4;
}

.ticket-note a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Ticker */
.ticker {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(6, 26, 22, 0.5);
}

.ticker-track {
  display: flex;
  width: max-content;
  animation: marquee 42s linear infinite;
}

.ticker:hover .ticker-track {
  animation-play-state: paused;
}

.ticker-group {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  padding: 12px 0;
}

.ticker-item {
  padding: 0 18px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.ticker-item b {
  color: var(--text);
  font-weight: 500;
}

.ticker-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--mint);
  opacity: 0.5;
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

/* Sections */
.section {
  position: relative;
  padding: clamp(64px, 8vw, 110px) 0;
  border-top: 1px solid var(--line);
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: end;
  gap: 40px;
  margin-bottom: clamp(32px, 4vw, 52px);
}

h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(30px, 4.2vw, 56px);
  font-stretch: 105%;
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.96;
  text-transform: uppercase;
  text-wrap: balance;
}

.section-lede {
  justify-self: end;
  max-width: 52ch;
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

/* Steps */
.steps {
  background: linear-gradient(180deg, var(--ground) 0%, var(--ground-2) 100%);
}

.steps-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.75fr);
  align-items: start;
  gap: clamp(32px, 5vw, 72px);
}

.step-list {
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.step {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 18px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}

.step-num {
  padding-top: 5px;
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.step h3 {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
  text-transform: uppercase;
}

.step p {
  max-width: 54ch;
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.65;
}

.code-demo {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-3), var(--panel));
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

.code-demo::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  width: 18px;
  height: 18px;
  border-top: 1px solid var(--mint);
  border-left: 1px solid var(--mint);
  border-top-left-radius: var(--radius);
}

.code-demo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.code-demo-label {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.code-demo-string {
  margin: 14px 0 0;
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: clamp(15px, 1.6vw, 19px);
  font-weight: 600;
  letter-spacing: 0.04em;
  word-break: break-all;
}

.code-demo-divider {
  margin: 14px 0 10px;
  border-top: 1px dashed rgba(140, 255, 220, 0.2);
}

.code-demo-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  margin: 0;
}

.code-demo-meta div {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.code-demo-meta dt {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.code-demo-meta dd {
  margin: 0;
  font-size: 12px;
  font-weight: 500;
}

.code-demo-meta dd.is-ok {
  color: var(--mint);
}

.code-demo-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 11px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.code-demo-link:hover {
  color: var(--mint);
}

.code-demo-link .icon {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease;
}

.code-demo-link:hover .icon {
  transform: translateX(3px);
}

/* Proof */
.proof {
  background: var(--ground);
}

.proof-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(32px, 5vw, 72px);
}

.proof-copy h2 {
  margin-bottom: 20px;
}

.proof-copy > p {
  max-width: 58ch;
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.spec-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 24px;
  margin: 0 0 28px;
  border-top: 1px solid var(--line);
}

.spec-list div {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.spec-list dt {
  margin-bottom: 2px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.spec-list dd {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--mint);
  font-size: 12px;
  text-decoration: none;
}

.text-link .icon {
  width: 15px;
  height: 15px;
  transition: transform 0.2s ease;
}

.text-link:hover .icon {
  transform: translateX(3px);
}

.proof-media {
  position: relative;
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel);
}

.proof-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1.18;
  object-fit: cover;
  filter: saturate(0.7) contrast(1.06) brightness(0.86);
}

.proof-media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(3, 17, 15, 0.3) 0%, rgba(3, 17, 15, 0.04) 38%, rgba(3, 17, 15, 0.9) 100%);
}

.proof-media figcaption {
  position: absolute;
  right: 16px;
  bottom: 14px;
  left: 16px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: rgba(239, 255, 250, 0.7);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Rates */
.rates {
  background: var(--ground-2);
}

.rate-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(7, 30, 26, 0.4);
}

.rate-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 13px;
}

.rate-table th,
.rate-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.rate-table thead th {
  background: rgba(2, 14, 12, 0.35);
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.rate-table tbody th {
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.rate-table tbody td {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 12px;
}

.rate-table tbody td.is-mint {
  color: var(--mint);
}

.rate-table tbody td.is-dim {
  color: var(--dim);
}

.rate-table tbody tr:last-child th,
.rate-table tbody tr:last-child td {
  border-bottom: 0;
}

.rate-table tbody tr:hover {
  background: rgba(0, 230, 160, 0.035);
}

.rate-table tbody tr.is-featured {
  background: rgba(0, 230, 160, 0.04);
}

.rate-tag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 5px;
  border: 1px solid rgba(255, 200, 87, 0.3);
  border-radius: 2px;
  color: var(--amber);
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  vertical-align: middle;
}

.rate-table s {
  color: var(--dim);
}

.rate-buy {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--mint);
  font-size: 11px;
  text-decoration: none;
  white-space: nowrap;
}

.rate-buy .icon {
  width: 13px;
  height: 13px;
  transition: transform 0.2s ease;
}

.rate-buy:hover .icon {
  transform: translateX(2px);
}

.rate-note {
  max-width: 62ch;
  margin: 12px 0 0;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.6;
}

/* Use cases */
.case-list {
  border-top: 1px solid var(--line);
}

.case-row {
  display: grid;
  grid-template-columns: 34px 128px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  transition: background 0.2s ease;
}

.case-row:hover {
  background: rgba(0, 230, 160, 0.03);
}

.case-num {
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
}

.case-thumb {
  width: 128px;
  height: 76px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--panel);
}

.case-thumb-app {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 9px;
  background: linear-gradient(145deg, var(--panel-3), var(--panel));
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
}

.app-grid i {
  display: block;
  aspect-ratio: 1;
  border: 1px solid rgba(0, 230, 160, 0.2);
  border-radius: 2px;
  background: rgba(0, 230, 160, 0.16);
}

.app-grid i:nth-child(2) {
  border-color: rgba(124, 235, 255, 0.22);
  background: rgba(124, 235, 255, 0.14);
}

.app-grid i:nth-child(3) {
  border-color: rgba(255, 200, 87, 0.22);
  background: rgba(255, 200, 87, 0.15);
}

.app-grid i:nth-child(5) {
  background: rgba(0, 230, 160, 0.08);
}

.app-grid i:nth-child(6) {
  border-color: rgba(239, 255, 250, 0.12);
  background: rgba(239, 255, 250, 0.07);
}

.app-build {
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  text-align: center;
}

.case-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1) contrast(1.02) brightness(1.06);
  transition: transform 0.5s var(--ease);
}

.case-row:hover .case-thumb img {
  transform: scale(1.04);
}

.case-copy {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.case-copy strong {
  font-family: var(--font-display);
  font-size: clamp(16px, 1.7vw, 20px);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.case-copy span {
  max-width: 62ch;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.case-arrow {
  justify-self: end;
  width: 18px;
  height: 18px;
  color: var(--mint);
  transition: transform 0.2s ease;
}

.case-row:hover .case-arrow {
  transform: translateX(3px);
}

/* FAQ */
.faq {
  background: var(--ground);
}

.faq-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr);
  align-items: start;
  gap: clamp(32px, 5vw, 72px);
}

.faq-intro h2 {
  margin-bottom: 18px;
}

.faq-intro p {
  max-width: 44ch;
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
}

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-list details {
  border-bottom: 1px solid var(--line);
}

.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 0;
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
  transition: color 0.2s ease;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "";
  width: 10px;
  height: 10px;
  flex-shrink: 0;
  background:
    linear-gradient(currentColor, currentColor) center / 10px 1px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1px 10px no-repeat;
  color: var(--mint);
  transition: transform 0.2s ease;
}

.faq-list details[open] summary {
  color: var(--mint);
}

.faq-list details[open] summary::after {
  transform: rotate(45deg);
}

.faq-list details p {
  max-width: 66ch;
  margin: 0;
  padding: 0 24px 18px 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
}

/* Final CTA */
.final {
  position: relative;
  overflow: hidden;
  padding: clamp(72px, 9vw, 120px) 0;
  border-top: 1px solid var(--line);
  background:
    radial-gradient(ellipse 60% 90% at 20% 50%, rgba(0, 230, 160, 0.12), transparent 65%),
    var(--ground-2);
}

.final-code::before {
  content: "XCP-720H-1M-8F2K";
}

.final-code {
  position: absolute;
  top: 50%;
  right: -2%;
  color: rgba(239, 255, 250, 0.035);
  font-family: var(--font-mono);
  font-size: clamp(48px, 8vw, 120px);
  font-weight: 600;
  letter-spacing: -0.04em;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  transform: translateY(-50%) rotate(-8deg);
}

.final-inner {
  position: relative;
  z-index: 2;
  max-width: 640px;
}

.final h2 {
  margin-bottom: 18px;
  font-size: clamp(38px, 5.5vw, 72px);
}

.final p {
  max-width: 52ch;
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.7;
}

.final-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* Footer */
.footer {
  padding: 48px 0 22px;
  border-top: 1px solid var(--line);
  background: var(--ground);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 0.8fr 0.8fr;
  gap: 32px;
}

.footer-brand p {
  max-width: 40ch;
  margin: 14px 0 16px;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.65;
}

.footer-social {
  display: flex;
  gap: 14px;
}

.footer-social a {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.footer-social a:hover {
  color: var(--mint);
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-col h3 {
  margin: 0 0 2px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-col a {
  color: var(--muted);
  font-size: 12px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: var(--mint);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 40px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.footer-bottom p {
  max-width: 60ch;
  margin: 0;
  color: var(--dim);
  font-size: 9.5px;
  line-height: 1.5;
}

/* Dialog */
.purchase-dialog {
  width: min(440px, calc(100% - 32px));
  max-height: calc(100vh - 40px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-3), var(--panel));
  color: var(--text);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.65);
}

.purchase-dialog::backdrop {
  background: rgba(1, 8, 6, 0.78);
  backdrop-filter: blur(6px);
}

.purchase-dialog[open] {
  animation: dialogIn 0.24s var(--ease);
}

@keyframes dialogIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.dialog-head h2 {
  margin: 2px 0 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.icon-btn {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  place-items: center;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.icon-btn:hover {
  border-color: var(--mint);
  color: var(--mint);
}

.dialog-body {
  display: grid;
  gap: 14px;
  padding: 18px 20px;
}

.dialog-summary {
  display: grid;
  gap: 6px;
}

.dialog-summary div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 12px;
}

.dialog-summary strong {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
}

.dialog-summary strong.is-mint {
  color: var(--mint);
  font-size: 14px;
}

.dialog-qr {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(2, 14, 12, 0.3);
}

.qr-frame-lg {
  width: 180px;
  height: 180px;
  padding: 10px;
}

.qr-frame-lg .scan-line {
  top: 10px;
  right: 10px;
  left: 10px;
  animation: scanLg 3.2s ease-in-out infinite;
}

@keyframes scanLg {
  0%,
  100% {
    opacity: 0;
    transform: translateY(0);
  }
  20% {
    opacity: 1;
  }
  50% {
    opacity: 1;
    transform: translateY(158px);
  }
  80% {
    opacity: 0;
  }
}

.dialog-qr p {
  max-width: 34ch;
  margin: 0;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

.dialog-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px dashed rgba(0, 230, 160, 0.3);
  border-radius: 4px;
  background: rgba(0, 230, 160, 0.03);
}

.dialog-code span {
  color: var(--muted);
  font-size: 10px;
}

.dialog-code strong {
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.dialog-note {
  margin: 0;
  color: var(--dim);
  font-size: 12px;
  text-align: center;
}

.dialog-foot {
  padding: 14px 20px 20px;
  border-top: 1px solid var(--line);
}

/* Reveal */
html.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

html.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* Responsive */
@media (max-width: 1180px) {
  .head-status {
    display: none;
  }

  .desktop-nav {
    gap: 20px;
  }

  .exchange-body {
    grid-template-columns: 1.25fr 0.9fr;
  }

  .plan-row {
    grid-template-columns: 30px minmax(0, 1fr) 100px 68px 16px;
    gap: 8px;
  }

  .code-float {
    left: -8px;
  }
}

@media (max-width: 1024px) {
  .desktop-nav {
    display: none;
  }

  .menu-btn {
    display: grid;
  }

  .mobile-menu:not([hidden]) {
    display: block;
  }

  .head-actions {
    margin-left: auto;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    min-height: 0;
    padding-bottom: 0;
  }

  .hero-copy {
    max-width: 760px;
  }

  .hero h1 {
    font-size: clamp(40px, 6.4vw, 64px);
  }

  .hero-stage {
    min-height: 500px;
    margin-top: 8px;
  }

  .phone {
    width: 238px;
    height: 494px;
  }

  .orbit-a {
    width: 500px;
    height: 500px;
  }

  .orbit-b {
    top: 50px;
    width: 390px;
    height: 390px;
  }

  .code-float {
    top: 58%;
    left: calc(50% - 270px);
    width: 232px;
  }

  .board-wrap {
    margin-top: 0;
  }

  .exchange-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .plan-list {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 860px) {
  .shell {
    width: calc(100% - 32px);
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .section-lede {
    justify-self: start;
  }

  .steps-layout,
  .proof-grid,
  .faq-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .proof-media {
    order: -1;
  }

  .proof-media img {
    aspect-ratio: 1.7;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
  }
}

@media (max-width: 680px) {
  html {
    scroll-padding-top: 76px;
  }

  .site-head .head-inner {
    height: 64px;
    gap: 14px;
  }

  .head-lookup {
    display: none;
  }

  .brand-copy small {
    display: none;
  }

  .hero {
    padding-top: 28px;
  }

  .hero h1 {
    font-size: clamp(26px, 8.5vw, 44px);
  }

  .hero-sub {
    margin-top: 18px;
    font-size: 14.5px;
  }

  .hero-actions {
    margin-top: 22px;
  }

  .hero-trust {
    flex-direction: column;
    gap: 8px;
    margin-top: 20px;
  }

  .hero-stage {
    min-height: 440px;
    margin-top: 0;
  }

  .phone {
    width: 212px;
    height: 440px;
  }

  .orbit-a {
    width: 430px;
    height: 430px;
  }

  .orbit-b {
    top: 34px;
    width: 330px;
    height: 330px;
  }

  .hero-stage > .live-chip {
    top: 8px;
    right: 4px;
  }

  .code-float {
    top: auto;
    bottom: 2px;
    left: 0;
    width: 210px;
    padding: 11px 12px;
    transform: rotate(-2deg);
    animation: none;
  }

  .code-string {
    font-size: 12.5px;
  }

  .exchange-head {
    padding: 10px 13px;
  }

  .exchange-meta {
    display: none;
  }

  .plan-row {
    grid-template-columns: 26px minmax(0, 1fr) 88px 16px;
    gap: 8px;
    min-height: 48px;
    padding: 8px 12px;
  }

  .plan-badge {
    display: none;
  }

  .plan-price {
    font-size: 12px;
  }

  .ticket {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
  }

  .qr-row {
    flex-direction: row;
    align-items: center;
    align-self: stretch;
    gap: 12px;
  }

  .qr-meta span {
    font-size: 9.5px;
  }

  .ticker-item {
    padding: 0 13px;
    font-size: 8px;
  }

  .step {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 12px;
    padding: 20px 0;
  }

  .spec-list {
    grid-template-columns: 1fr;
  }

  .proof-media img {
    aspect-ratio: 1.35;
  }

  .rate-table {
    min-width: 0;
  }

  .rate-table th,
  .rate-table td {
    padding: 12px 8px;
  }

  .rate-table thead th {
    font-size: 7.5px;
    letter-spacing: 0.06em;
  }

  .rate-table tbody th {
    font-size: 12px;
  }

  .rate-table tbody td {
    font-size: 11px;
  }

  .rate-table th:nth-child(2),
  .rate-table td:nth-child(2) {
    display: none;
  }

  .rate-tag {
    display: none;
  }

  .rate-buy {
    font-size: 10px;
  }

  .case-row {
    grid-template-columns: 26px 92px minmax(0, 1fr);
    gap: 12px;
    padding: 14px 0;
  }

  .case-thumb {
    width: 92px;
    height: 58px;
  }

  .case-arrow {
    display: none;
  }

  .case-copy strong {
    font-size: 16px;
  }

  .case-copy span {
    font-size: 12px;
  }

  .faq-list summary {
    padding: 15px 0;
    font-size: 13.5px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  .final-code {
    right: -20%;
    font-size: 64px;
    opacity: 0.8;
  }
}

@media (max-width: 460px) {
  .head-actions .btn-sm {
    display: none;
  }

  .hero h1 {
    font-size: clamp(26px, 8.5vw, 40px);
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-stage {
    min-height: 410px;
  }

  .phone {
    width: 196px;
    height: 408px;
  }

  .orbit-a {
    width: 360px;
    height: 360px;
  }

  .orbit-b {
    top: 32px;
    width: 280px;
    height: 280px;
  }

  .code-float {
    width: 196px;
  }

  .plan-row {
    grid-template-columns: 22px minmax(0, 1fr) 80px 14px;
    gap: 6px;
  }

  .plan-badge {
    display: none;
  }

  .plan-index {
    font-size: 8px;
  }

  .plan-name {
    font-size: 13px;
  }

  .plan-meta {
    font-size: 7px;
  }

  .plan-price {
    font-size: 11px;
  }

  .ticket-line.is-total strong {
    font-size: 14px;
  }

  .qr-frame {
    width: 62px;
    height: 62px;
  }

  .scan-line {
    animation-name: scanSm;
  }

  @keyframes scanSm {
    0%,
    100% {
      opacity: 0;
      transform: translateY(0);
    }
    20% {
      opacity: 1;
    }
    50% {
      opacity: 1;
      transform: translateY(52px);
    }
    80% {
      opacity: 0;
    }
  }

  .qr-frame-lg {
    width: 160px;
    height: 160px;
  }

  .qr-frame-lg .scan-line {
    animation: scanLgSm 3.2s ease-in-out infinite;
  }

  @keyframes scanLgSm {
    0%,
    100% {
      opacity: 0;
      transform: translateY(0);
    }
    20% {
      opacity: 1;
    }
    50% {
      opacity: 1;
      transform: translateY(138px);
    }
    80% {
      opacity: 0;
    }
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-brand {
    grid-column: auto;
  }

  .final-code {
    display: none;
  }
}

/* Readability floor: functional microcopy stays legible at every width. */
.brand-copy small,
.head-status,
.live-chip,
.code-float-head,
.exchange-title,
.exchange-meta,
.plan-index,
.plan-meta,
.plan-badge,
.ticket-eyebrow,
.ticket-badge,
.ticket-line,
.qr-meta strong,
.qr-meta span,
.ticker-item,
.step-num,
.code-demo-label,
.code-demo-meta dt,
.spec-list dt,
.proof-media figcaption,
.rate-table thead th,
.rate-tag,
.case-num,
.footer-social a,
.footer-col h3,
.dialog-code span,
.rate-buy {
  font-size: 11px;
}

.ticket-note,
.rate-note,
.footer-bottom p,
.dialog-qr p,
.dialog-note {
  font-size: 12px;
}

.plan-price small,
.ticker-item b {
  font-size: 11px;
}

.plan-index,
.plan-name,
.plan-meta,
.plan-price,
.plan-price small,
.plan-badge,
.ticket-eyebrow,
.ticket-line,
.qr-meta strong,
.ticker-item {
  line-height: 1.25;
}

.ticket-line.is-total strong {
  line-height: 1.2;
}

.code-tag,
.qr-demo,
.app-build {
  font-size: 9px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html.js [data-reveal] {
    opacity: 1;
    transform: none;
  }

  .phone,
  .code-float,
  .ticker-track,
  .status-dot,
  .scan-line {
    animation: none !important;
  }
}
/* ==========================================================================
   PRODUCTION LAYER — ported from the previous store build onto the
   Cloud Phone Exchange design tokens. Everything below is component code
   that app.js generates or that the live purchase/lookup flow needs.
   ========================================================================== */

/* Token aliases: the old store JS, legal.css and modal markup reference
   these names, so map them onto the new palette instead of duplicating hex. */
:root {
  --bg-page: var(--ground);
  --bg-panel: var(--panel);
  --bg-elevated: var(--panel-2);
  --bg-hover: var(--panel-3);
  --ink: var(--text);
  --ink-muted: var(--muted);
  --ink-subtle: var(--dim);
  --signal: var(--mint);
  --signal-hover: var(--mint-2);
  --signal-text: var(--mint-2);
  --signal-ink: var(--mint-ink);
  --signal-tint: rgba(0, 230, 160, 0.12);
  --amber-text: var(--amber);
  --amber-tint: rgba(255, 200, 87, 0.12);
  --font-sans: var(--font-body);
  --radius-md: 8px;
  --radius-lg: 12px;
}

.hidden {
  display: none !important;
}

.mono-val {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.accent-amber {
  color: var(--amber);
}

/* Header: wallet, account and saved-code counter ------------------------- */
.header-auth {
  display: flex;
  align-items: center;
  gap: 8px;
}

.wallet-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(0, 230, 160, 0.05);
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.wallet-chip strong {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
}

.wallet-chip:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.user-badge {
  display: inline-flex;
  align-items: center;
  max-width: 120px;
  height: 34px;
  padding: 0 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.link-btn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--dim);
  font-size: 12px;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.link-btn:hover {
  color: var(--mint);
}

.nav-count {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 99px;
  background: var(--mint);
  color: var(--mint-ink);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
}

/* Buttons: the exchange sheet only ships primary + ghost. */
.btn-secondary {
  border-color: var(--line-strong);
  background: var(--panel-2);
  color: var(--text);
}

.btn-secondary:hover:not(:disabled) {
  border-color: var(--mint);
  background: rgba(0, 230, 160, 0.06);
  color: var(--mint);
}

.btn-full {
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Exchange ticket: add wallet line, buyer phone and a real QR stub -------- */
.ticket {
  grid-template-rows: auto auto auto auto auto auto;
}

.ticket-prices {
  grid-column: 1 / -1;
}

.ticket-line.is-wallet strong {
  color: var(--muted);
  font-size: 11px;
}

.ticket-line.is-wallet.is-funded strong {
  color: var(--mint);
}

.ticket-buyer {
  grid-column: 1 / -1;
  grid-row: 4;
  min-width: 0;
  padding-top: 5px;
  border-top: 1px dashed var(--line);
}

.ticket-buyer summary {
  color: var(--dim);
  font-size: 11px;
  line-height: 1.4;
  cursor: pointer;
  list-style: none;
}

.ticket-buyer summary::-webkit-details-marker {
  display: none;
}

.ticket-buyer summary::before {
  content: "+";
  display: inline-block;
  width: 12px;
  color: var(--mint);
  font-family: var(--font-mono);
}

.ticket-buyer[open] summary::before {
  content: "−";
}

.ticket-buyer summary span {
  color: var(--dim);
}

.ticket-buyer .form-input {
  height: 32px;
  margin-top: 6px;
  font-size: 11.5px;
}

.ticket > .btn {
  grid-row: 5;
}

.ticket-note {
  grid-row: 6;
}

.qr-stub {
  display: grid;
  width: 68px;
  height: 68px;
  flex-shrink: 0;
  border: 1px dashed rgba(0, 230, 160, 0.32);
  border-radius: 4px;
  background:
    repeating-linear-gradient(135deg, rgba(0, 230, 160, 0.06) 0 6px, transparent 6px 12px),
    rgba(2, 14, 12, 0.35);
  color: var(--mint);
  text-align: center;
  place-content: center;
  gap: 3px;
}

.qr-stub .icon {
  width: 18px;
  height: 18px;
  margin-inline: auto;
}

.qr-stub span {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.08em;
}

.ticket .qr-row {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.ticket .qr-stub {
  width: 56px;
  height: 56px;
}

.ticket .qr-meta strong {
  font-size: 11px;
}

/* Proof section: live issuance counters */
.proof-stats {
  margin: 18px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
}

.proof-stats strong {
  color: var(--mint);
  font-weight: 600;
}

/* Forms ---------------------------------------------------------------- */
.field-label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
}

.form-input {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  outline: none;
  background: rgba(2, 14, 12, 0.42);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13px;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.form-input::placeholder {
  color: var(--dim);
}

.form-input:hover {
  border-color: var(--line-strong);
}

.form-input:focus {
  border-color: var(--mint);
  background: rgba(2, 14, 12, 0.6);
}

/* Vault / lookup / wallet ------------------------------------------------ */
.vault {
  border-top: 1px solid var(--line);
}

.vault-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.vault-panel {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(10, 39, 33, 0.5), rgba(5, 24, 21, 0.6));
}

.vault-panel-wide {
  margin-top: 18px;
}

.vault-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.vault-panel h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.vault-panel-head h3 {
  margin: 0;
}

.vault-tag {
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 2px;
  color: var(--dim);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  white-space: nowrap;
  text-transform: uppercase;
}

.muted-copy {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
  text-wrap: pretty;
}

.muted-copy code {
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 12px;
}

.vault-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.vault-form .form-input {
  height: 42px;
}

.lookup-results {
  margin-top: 14px;
}

.records-list {
  display: flex;
  flex-direction: column;
}

.record-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}

.record-main {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.record-main strong {
  font-size: 14px;
  overflow-wrap: anywhere;
}

.record-main span {
  color: var(--muted);
  font-size: 12.5px;
}

.record-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.balance-banner {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.balance-banner span {
  color: var(--muted);
  font-size: 13px;
}

.balance-banner strong {
  color: var(--amber);
  font-size: 26px;
  font-weight: 700;
}

.preset-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.preset-chip {
  min-height: 30px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: transparent;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}

.preset-chip:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.preset-chip.active {
  border-color: var(--mint);
  background: rgba(0, 230, 160, 0.08);
  color: var(--mint);
}

.topup-presets {
  margin-bottom: 10px;
}

.admin-metrics-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 16px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.admin-metrics-strip dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12.5px;
}

.admin-metrics-strip dd {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* Modal ---------------------------------------------------------------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(1, 8, 6, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.modal-dialog {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  padding: 24px;
  overflow-y: auto;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-3), var(--panel));
  color: var(--text);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.65);
  animation: dialogIn 0.24s var(--ease);
}

.modal-dialog .btn {
  min-height: 42px;
  height: auto;
  padding: 9px 12px;
  line-height: 1.35;
  white-space: normal;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--panel-2);
  color: var(--muted);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.modal-close:hover {
  border-color: var(--mint);
  color: var(--mint);
}

#common-modal-title {
  padding-right: 42px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
  border-bottom: 1px solid var(--line);
}

.auth-tabs .delivery-btn {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 3px 3px 0 0;
  background: transparent;
  color: var(--muted);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.auth-tabs .delivery-btn strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}

.auth-tabs .delivery-btn span {
  color: var(--dim);
  font-size: 11px;
}

.auth-tabs .delivery-btn:hover {
  border-color: var(--line-strong);
}

.auth-tabs .delivery-btn.active {
  border-color: var(--mint);
  background: rgba(0, 230, 160, 0.07);
}

.auth-tabs .delivery-btn.active strong {
  color: var(--mint);
}

.form-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.qr-checkout-grid {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  margin-top: 18px;
}

.qr-checkout-grid > * {
  min-width: 0;
}

.qr-img-wrap {
  padding: 10px;
  border-radius: var(--radius-sm);
  background: #ffffff;
  text-align: center;
}

.qr-img-wrap img {
  display: block;
  width: 100%;
  height: auto;
}

.qr-img-wrap span {
  display: block;
  margin-top: 6px;
  color: #090a0d;
  font-size: 12px;
  font-weight: 600;
}

.pay-dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 12px;
  margin: 0 0 14px;
  font-size: 13.5px;
}

.pay-dl dt {
  color: var(--muted);
}

.pay-dl dd {
  margin: 0;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.issued-codes-list {
  margin: 16px 0 18px;
  border-bottom: 1px solid var(--line);
}

.issued-code-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}

.issued-code-item strong {
  color: var(--mint);
  font-size: 15.5px;
  letter-spacing: 0.02em;
}

.issued-code-item span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.order-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 99px;
  background: var(--panel-2);
  color: var(--muted);
  font-size: 12.5px;
}

.order-status-pill .dot-spin {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber);
  animation: pulse-dot 1.2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 0.35; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.1); }
}

/* Purchase confirmation + mandatory terms ------------------------------ */
.purchase-confirm-box {
  margin: 14px 0 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(0, 230, 160, 0.03);
}

.purchase-confirm-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.purchase-confirm-row span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.purchase-confirm-row strong {
  color: var(--mint);
  font-size: 20px;
  white-space: nowrap;
}

.purchase-confirm-spec {
  margin-top: 6px;
  color: var(--dim);
  font-size: 12px;
}

.purchase-confirm-pay {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed var(--line);
  color: var(--muted);
  font-size: 12px;
}

.terms-block {
  margin-top: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.18);
}

.terms-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(0, 230, 160, 0.03);
}

.terms-block-head strong {
  color: var(--text);
  font-size: 12.5px;
  font-weight: 600;
}

.terms-block-head a {
  flex: 0 0 auto;
  color: var(--mint);
  font-size: 11.5px;
  text-decoration: none;
}

.terms-block-head a:hover {
  text-decoration: underline;
}

.terms-scroll {
  max-height: 300px;
  padding: 0 14px;
  overflow-y: auto;
  scrollbar-color: var(--line-strong) transparent;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.terms-scroll:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: -2px;
}

.terms-scroll::-webkit-scrollbar {
  width: 8px;
}

.terms-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.terms-scroll::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: var(--line-strong);
}

.terms-scroll .legal-body section {
  padding: 16px 0;
}

.terms-scroll .legal-body section:first-child {
  padding-top: 12px;
  border-top: 0;
}

.terms-scroll .legal-body section:last-child {
  padding-bottom: 14px;
}

.terms-scroll .legal-body h2 {
  margin-bottom: 8px;
  font-size: 16px;
  line-height: 1.35;
}

.terms-scroll .legal-body h3 {
  margin: 12px 0 4px;
  font-size: 13.5px;
}

.terms-scroll .legal-body p,
.terms-scroll .legal-body li {
  max-width: none;
  font-size: 13.5px;
  line-height: 1.62;
}

.terms-scroll .legal-body a {
  color: var(--mint);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.terms-scroll .legal-body ul,
.terms-scroll .legal-body ol {
  padding-left: 20px;
}

.terms-loading {
  margin: 12px 0;
  color: var(--dim);
  font-size: 13px;
  line-height: 1.55;
}

.terms-loading a {
  color: var(--mint);
  text-decoration: underline;
}

.terms-scroll-hint {
  margin: 7px 0 0;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.5;
}

.terms-scroll-hint.is-done {
  color: var(--mint);
}

.terms-consent {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.terms-consent-text {
  flex: 1 1 auto;
  padding-top: 1px;
}

.terms-consent input[type="checkbox"] {
  display: inline-grid;
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  border: 1.5px solid var(--line-strong);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
  appearance: none;
  -webkit-appearance: none;
  place-content: center;
}

.terms-consent input[type="checkbox"]::before {
  width: 10px;
  height: 10px;
  background: var(--mint-ink);
  content: "";
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
  transform: scale(0);
  transition: transform 0.12s ease-in;
}

.terms-consent input[type="checkbox"]:checked {
  border-color: var(--mint);
  background: var(--mint);
}

.terms-consent input[type="checkbox"]:checked::before {
  transform: scale(1);
}

.terms-consent input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 2px;
}

.terms-consent input[type="checkbox"]:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.terms-consent label {
  cursor: pointer;
}

.terms-consent a {
  color: var(--mint);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.terms-consent a:hover {
  color: var(--mint-2);
}

#purchase-confirm-btn:disabled {
  border-color: var(--line);
  background: var(--panel-2);
  color: var(--dim);
  opacity: 1;
}

/* Support dock + toast ------------------------------------------------ */
.support-dock {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 35;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 99px;
  background: rgba(7, 30, 26, 0.92);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.support-dock.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.dock-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text);
  font-weight: 500;
  text-decoration: none;
}

.dock-link:hover {
  color: var(--mint);
}

.dock-divider {
  width: 1px;
  height: 14px;
  background: var(--line-strong);
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  z-index: 110;
  padding: 10px 18px;
  border: 1px solid var(--mint);
  border-radius: 99px;
  background: var(--panel-2);
  color: var(--text);
  font-size: 13.5px;
  font-weight: 500;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 16px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Responsive ---------------------------------------------------------- */
@media (max-width: 1024px) {
  .vault-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-metrics-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .qr-checkout-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .qr-img-wrap {
    max-width: 240px;
    margin: 0 auto;
  }
}

@media (max-width: 680px) {
  .vault-panel {
    padding: 18px;
  }

  .vault-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .vault-form .btn {
    width: 100%;
  }

  .user-badge {
    display: none;
  }

  .wallet-chip span:first-child {
    display: none;
  }

  .modal-dialog {
    max-height: 92vh;
    padding: 20px;
  }

  .support-dock {
    right: 10px;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    height: 36px;
    padding: 0 12px;
    gap: 8px;
    font-size: 12.5px;
  }

  .support-dock .dock-divider,
  .support-dock .dock-link[data-contact="telegram"] {
    display: none;
  }
}

@media (max-width: 460px) {
  /* The header keeps the wallet/login action even when the buy shortcut
     is hidden — that button is the only way into the account from mobile. */
  .head-actions .header-auth .btn-sm {
    display: inline-flex;
  }

  .head-actions .head-buy {
    display: none;
  }

  .vault-panel {
    padding: 16px;
  }

  .purchase-confirm-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .terms-scroll {
    max-height: min(38vh, 320px);
  }

  .terms-scroll .legal-body p,
  .terms-scroll .legal-body li {
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .toast,
  .modal-dialog {
    transition: none;
    animation: none;
  }
}

/* Layout QA: keep the purchase board reachable without shrinking the desktop art. */
@media (min-width: 1025px) and (max-height: 850px) {
  .hero {
    padding-top: 24px;
  }

  .hero-grid {
    min-height: 0;
  }

  .hero-stage {
    min-height: 390px;
  }

  .phone {
    width: 195px;
    height: 390px;
  }

  .orbit-a {
    width: 430px;
    height: 430px;
  }

  .orbit-b {
    top: 40px;
    width: 330px;
    height: 330px;
  }

  .code-float {
    top: 58%;
    left: calc(50% - 235px);
    width: 220px;
  }

  .hero-sub {
    margin-top: 16px;
  }

  .hero-actions {
    margin-top: 20px;
  }

  .hero-trust {
    margin-top: 16px;
  }

  .board-wrap {
    margin-top: -42px;
  }
}

/* Stacked hero: keep the phone as a compact visual so the price board is
   visible in the first screen instead of sitting below a 500px illustration. */
@media (max-width: 1024px) {
  .hero-stage {
    min-height: 300px;
    margin-top: 0;
  }

  .phone {
    width: 150px;
    height: 300px;
  }

  .orbit-a {
    width: 330px;
    height: 330px;
  }

  .orbit-b {
    top: 20px;
    width: 250px;
    height: 250px;
  }

  .code-float {
    top: auto;
    bottom: 0;
    left: calc(50% - 230px);
    width: 190px;
    padding: 10px 12px;
    transform: rotate(-2deg);
    animation: none;
  }

  .code-string {
    font-size: 12px;
  }
}

@media (max-width: 680px) {
  .hero-stage > .live-chip,
  .hero-stage .code-float {
    display: none;
  }
}

/* Tablet portrait: the full table's 760px minimum no longer fits, so use the
   same compact four-column layout as phones instead of a scrollbar. */
@media (min-width: 681px) and (max-width: 820px) {
  .rate-table {
    min-width: 0;
  }

  .rate-table th,
  .rate-table td {
    padding: 12px 8px;
  }

  .rate-table thead th {
    font-size: 9px;
    letter-spacing: 0.06em;
  }

  .rate-table tbody th {
    font-size: 12px;
  }

  .rate-table tbody td {
    font-size: 11px;
  }

  .rate-table th:nth-child(2),
  .rate-table td:nth-child(2) {
    display: none;
  }

  .rate-tag {
    display: none;
  }

  .rate-buy {
    font-size: 10px;
  }
}

/* Very small phones: fit the rate table and header instead of hiding data
   behind a horizontal scrollbar or wrapping the login label. */
@media (max-width: 380px) {
  .header-auth .btn,
  .head-actions .btn {
    white-space: nowrap;
  }

  .rate-table th,
  .rate-table td {
    padding: 10px 5px;
  }

  .rate-table tbody th {
    font-size: 11px;
    line-height: 1.25;
    white-space: normal;
  }

  .rate-table tbody td {
    font-size: 10px;
  }

  .rate-buy {
    gap: 2px;
    font-size: 9px;
  }

  .rate-buy .icon {
    width: 10px;
    height: 10px;
  }

  .vault-panel-head {
    flex-wrap: wrap;
  }

  .vault-panel-head .btn {
    margin-left: auto;
    white-space: nowrap;
  }

  .case-row {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .case-num {
    display: none;
  }

  .case-thumb {
    width: 76px;
    height: 48px;
  }
}

@media (max-width: 360px) {
  .site-head .head-inner {
    gap: 8px;
  }

  .head-actions {
    gap: 8px;
  }

  .brand {
    gap: 8px;
  }

  .brand-copy strong {
    font-size: 14px;
  }

  .header-auth .btn {
    padding-inline: 8px;
  }

  .menu-btn {
    width: 38px;
    height: 38px;
  }
}
