:root {
  color-scheme: light dark;
  --bg: #fff3e7;
  --bg-2: #f7e0cf;
  --card: #ffffff;
  --ink: #2f2420;
  --muted: #8b6e5a;
  --accent: #e6503f;
  --accent-2: #f3a34f;
  --ring: rgba(230, 80, 63, 0.22);
  --shadow: 0 20px 60px rgba(145, 86, 52, 0.2);
  --panel-bg: rgba(255, 255, 255, 0.7);
  --panel-border: rgba(230, 80, 63, 0.15);
  --ghost-bg: #ffffff;
  --ghost-border: rgba(230, 80, 63, 0.3);
  --token-bg: #e41b1b;
  --token-border: rgba(255, 255, 255, 0.25);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans SC", "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  min-height: 100vh;
  background: radial-gradient(circle at top, #ffe7d4, transparent 60%),
    linear-gradient(135deg, var(--bg), var(--bg-2));
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 20px;
}

.page {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  width: min(820px, 100%);
}

.card {
  background: var(--card);
  padding: 32px;
  border-radius: 24px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: -60% -10% auto auto;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(243, 163, 79, 0.3), transparent 70%);
  z-index: 0;
}

.card-header {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  margin-bottom: 24px;
}

.eyebrow {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}

h1 {
  font-size: 32px;
  letter-spacing: 0.04em;
}

.subtitle {
  color: var(--muted);
  line-height: 1.5;
}

.token-box {
  border-radius: 18px;
  padding: 8px 0 4px;
  text-align: center;
  background: transparent;
  margin-bottom: 24px;
  position: relative;
  z-index: 1;
  box-shadow: none;
}

.token-value {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 8px;
  color: #ffffff;
  font-size: 20px;
  letter-spacing: 0.05em;
  line-height: 1;
  word-break: break-all;
}

.token-cell {
  display: grid;
  place-items: center;
  height: 44px;
  border-radius: 10px;
  background: var(--token-bg);
  border: 1px solid var(--token-border);
  font-weight: 600;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

button {
  font-family: inherit;
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  font-size: 16px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(230, 80, 63, 0.2);
}

.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: white;
}

.ghost {
  background: var(--ghost-bg);
  border: 1px solid var(--ghost-border);
  color: var(--accent);
}

.hint {
  margin-top: 18px;
  font-size: 14px;
  color: var(--muted);
}

@media (max-width: 600px) {
  body {
    padding: 28px 16px;
  }

  .card {
    padding: 24px;
    border-radius: 20px;
  }

  h1 {
    font-size: 24px;
  }

  .subtitle {
    font-size: 14px;
  }

  .token-value {
    font-size: 16px;
    gap: 6px;
  }

  .token-cell {
    height: 38px;
  }

  .actions {
    flex-direction: column;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a1412;
    --bg-2: #241b17;
    --card: #2a201c;
    --ink: #f6efe9;
    --muted: #c7b3a5;
    --accent: #ff6b5f;
    --accent-2: #ffb056;
    --ring: rgba(255, 107, 95, 0.35);
    --shadow: 0 22px 60px rgba(0, 0, 0, 0.4);
    --panel-bg: rgba(42, 32, 28, 0.8);
    --panel-border: rgba(255, 107, 95, 0.2);
    --ghost-bg: rgba(32, 24, 21, 0.9);
    --ghost-border: rgba(255, 107, 95, 0.3);
    --token-bg: #ff3b30;
    --token-border: rgba(255, 255, 255, 0.25);
  }

  body {
    background: radial-gradient(circle at top, rgba(255, 107, 95, 0.18), transparent 60%),
      linear-gradient(135deg, var(--bg), var(--bg-2));
  }
}
