:root {
  --pink: #e0478c;
  --pink-deep: #c73374;
  --pink-soft: #f8d5e6;
  --ink: #1c1c22;
  --muted: #6b6570;
  --line: #e6e0e6;
  --paper: #f7f4f6;
  --card: #fffcfd;
  --silver: #ece8ee;
  --success: #1f7a4d;
  --success-bg: #e8f6ee;
  --used: #8a5a12;
  --used-bg: #f8efd8;
  --invalid: #b4233c;
  --invalid-bg: #fdecef;
  --radius: 16px;
  --shadow: 0 10px 36px rgba(40, 18, 36, 0.08);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "PingFang SC", "Hiragino Sans GB", "Heiti SC", "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

body {
  background-image:
    radial-gradient(circle at 12% 18%, rgba(224, 71, 140, 0.08), transparent 28%),
    radial-gradient(circle at 88% 8%, rgba(180, 170, 190, 0.28), transparent 32%),
    radial-gradient(rgba(28, 28, 34, 0.045) 1px, transparent 1.2px);
  background-size: auto, auto, 18px 18px;
  min-height: 100dvh;
}

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

a { color: var(--pink-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

.page {
  max-width: 520px;
  margin: 0 auto;
  padding: 0 0 calc(28px + env(safe-area-inset-bottom));
}

.topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: calc(12px + env(safe-area-inset-top)) 18px 12px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  color: var(--pink);
  flex: none;
}

.logo-en {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--pink);
  line-height: 1;
}

.logo-cn {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.08em;
}

.hero-frame {
  position: relative;
  margin: 0 14px;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #d8d6db;
  aspect-ratio: 4 / 4.35;
}

.hero-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 42%;
}

.hero-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 12, 18, 0.04) 28%, rgba(18, 12, 18, 0.62) 100%);
  pointer-events: none;
}

.hero-caption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 46px;
  color: #fff;
}

.caption-en {
  margin: 0 0 4px;
  font-size: 11px;
  letter-spacing: 0.22em;
  opacity: 0.86;
}

.hero-caption h1 {
  margin: 0;
  font-size: 26px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.caption-sub {
  margin: 6px 0 0;
  font-size: 13px;
  opacity: 0.9;
}

main { padding: 0 14px; }

.verify-card {
  position: relative;
  margin-top: -22px;
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 18px 18px;
}

.verify-card h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 650;
}

.lead {
  margin: 8px 0 18px;
  color: var(--muted);
  font-size: 13.5px;
}

#verify-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

#code {
  width: 100%;
  height: 52px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 14px;
  font-size: 17px;
  letter-spacing: 0.04em;
  background: #fff;
  color: var(--ink);
  outline: none;
  appearance: none;
}

#code::placeholder { color: #a9a3aa; letter-spacing: 0; }

#code:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 3px rgba(224, 71, 140, 0.16);
}

#verify-btn {
  height: 52px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(180deg, #e85a98 0%, var(--pink-deep) 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 650;
  letter-spacing: 0.12em;
  cursor: pointer;
}

#verify-btn:active { transform: translateY(1px); }
#verify-btn:disabled { opacity: 0.62; cursor: wait; }

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

.result-wrap { margin-top: 14px; min-height: 0; }

.result-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  border-radius: 14px;
  padding: 14px 14px 13px;
}

.result-icon {
  width: 32px;
  flex: none;
  margin-top: 1px;
}

.result-icon svg { width: 32px; height: 32px; display: block; }

.result-card h3 {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 650;
}

.result-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
}

.result-pending {
  display: block;
  text-align: center;
  color: var(--muted);
  background: var(--silver);
}

.result-success { background: var(--success-bg); color: var(--success); }
.result-used, .result-caution { background: var(--used-bg); color: var(--used); }
.result-invalid { background: var(--invalid-bg); color: var(--invalid); }

.steps {
  margin: 26px 2px 0;
}

.steps h2 {
  margin: 0 0 12px;
  font-size: 15px;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 600;
}

.steps ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.steps li {
  display: flex;
  gap: 12px;
  background: rgba(255, 252, 253, 0.78);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 14px;
}

.step-num {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--pink);
  padding-top: 1px;
  flex: none;
}

.steps h3 {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 650;
}

.steps p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.site-footer {
  margin: 28px 18px 0;
  color: var(--muted);
  font-size: 12px;
}

.site-footer p { margin: 0 0 8px; }

.footer-meta { color: #8a838c; }
.footer-meta a { color: #8a838c; }
.dot { margin: 0 6px; }

.page-error {
  padding: 80px 24px;
  text-align: center;
}

.error-code {
  margin: 0;
  color: var(--pink);
  letter-spacing: 0.16em;
  font-weight: 700;
}

@media (min-width: 640px) {
  .page { padding-top: 16px; }
  .hero-frame { aspect-ratio: 16 / 13; }
  .hero-photo { object-position: 50% 45%; }
}

@media (prefers-reduced-motion: reduce) {
  #verify-btn:active { transform: none; }
}
