:root {
  --bg: #f7f5f2;
  --surface: #fffdfb;
  --surface-alt: #f1eee9;
  --ink: #1d172b;
  --muted: #6b6478;
  --faint: #98919f;
  --line: #e3ded7;
  --line-soft: #ebe7e1;
  --brand: #4e338f;
  --brand-hover: #3f2875;
  --brand-soft: #efebf9;
  --rose: #c73572;
  --on-brand: #ffffff;
  --cream: #f9efe0;
  --stamp-card: #fffdfb;
  --who-line: rgba(78, 51, 143, 0.28);
  --hairline: rgba(29, 23, 43, 0.12);
  --hairline-soft: rgba(29, 23, 43, 0.08);
  --radius: 12px;
  --radius-lg: 14px;
  --shadow: 0 1px 2px rgba(29, 23, 43, 0.04);
  color-scheme: light;
}

html[data-theme="dark"] {
  --bg: #121019;
  --surface: #1a1724;
  --surface-alt: #171420;
  --ink: #ece8f3;
  --muted: #a49db3;
  --faint: #756e85;
  --line: #2b2738;
  --line-soft: #232030;
  --brand: #b39af2;
  --brand-hover: #c7b4f7;
  --brand-soft: #241e35;
  --rose: #f07aac;
  --on-brand: #121019;
  --cream: #191322;
  --stamp-card: #221c33;
  --who-line: rgba(179, 154, 242, 0.32);
  --hairline: #2b2738;
  --hairline-soft: #232030;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --bg: #121019;
    --surface: #1a1724;
    --surface-alt: #171420;
    --ink: #ece8f3;
    --muted: #a49db3;
    --faint: #756e85;
    --line: #2b2738;
    --line-soft: #232030;
    --brand: #b39af2;
    --brand-hover: #c7b4f7;
    --brand-soft: #241e35;
    --rose: #f07aac;
    --on-brand: #121019;
    --cream: #191322;
    --stamp-card: #221c33;
    --who-line: rgba(179, 154, 242, 0.32);
    --hairline: #2b2738;
    --hairline-soft: #232030;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    color-scheme: dark;
  }
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.2s, color 0.2s;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
ul { list-style: none; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -0.02em; }
img, svg { display: block; max-width: 100%; }

::selection { background: var(--brand-soft); color: var(--brand); }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}

[hidden] { display: none !important; }

.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;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  transition: top 0.2s;
}
.skip-link:focus { top: 12px; }

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand-mark {
  width: 30px;
  height: 30px;
  flex: none;
  object-fit: contain;
}

.brand-name { font-size: 15px; }

.brand-en {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--faint);
  padding-left: 2px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s, background-color 0.15s;
}
.theme-toggle:hover {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-select {
  height: 32px;
  padding: 0 8px;
  font: inherit;
  font-size: 13px;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.lang-select:hover {
  color: var(--ink);
  border-color: var(--faint);
}

.theme-icon { width: 18px; height: 18px; }
.theme-toggle .moon { display: none; }

html[data-theme="dark"] .theme-toggle .sun { display: none; }
html[data-theme="dark"] .theme-toggle .moon { display: block; }

@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .theme-toggle .sun { display: none; }
  html:not([data-theme="light"]) .theme-toggle .moon { display: block; }
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--brand);
  margin-bottom: 16px;
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--rose);
  flex: none;
}

.appeal {
  position: relative;
  overflow: clip;
  background: var(--cream);
  padding: 64px 0 72px;
}

.corner {
  position: absolute;
  z-index: 0;
  color: var(--brand);
  opacity: 0.15;
  pointer-events: none;
}

.corner-tl { top: 12px; left: 16px; width: 200px; }
.corner-tr { top: 0; right: 0; width: 250px; }
.corner-bl { bottom: 10px; left: 12px; width: 210px; }
.corner-br { bottom: 12px; right: 14px; width: 200px; }

.appeal-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 64px;
}

.appeal-copy { min-width: 0; }

.appeal h1 {
  font-family: Georgia, "Times New Roman", "Songti SC", "STSong", "Noto Serif CJK SC", "Source Han Serif SC", SimSun, serif;
  font-size: clamp(2.5rem, 5vw, 3.6rem);
  font-weight: 400;
  line-height: 1.28;
  letter-spacing: 0.01em;
  margin-bottom: 4px;
}

.hero-art {
  width: min(460px, 92%);
  margin: 22px 0 10px;
  color: var(--brand);
}

.hero-art .heart { stroke: var(--rose); }

.letter {
  padding-top: 26px;
  border-top: 1px solid var(--hairline);
}

.letter-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--faint);
  margin-bottom: 18px;
}

.letter-body p {
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
  margin-bottom: 16px;
  max-width: 60ch;
}

.letter-body p:last-child { margin-bottom: 0; }

.letter-body strong { font-weight: 650; }

.signature {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 30px;
  padding-top: 24px;
  border-top: 1px solid var(--hairline-soft);
}

.signature img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  flex: none;
}

.signature p {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

.signature strong {
  color: var(--ink);
  font-weight: 600;
}

.signature span {
  font-size: 13px;
  color: var(--faint);
}

.who-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 28px;
  padding: 14px 16px;
  border: 1px solid var(--who-line);
  border-radius: 8px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 60ch;
}

.who-box img {
  width: 20px;
  height: 20px;
  flex: none;
  margin-top: 4px;
  object-fit: contain;
}

.who-box p { margin: 0; }

.donate-side { scroll-margin-top: 96px; }

@media (min-width: 901px) {
  .appeal-grid .donate-card {
    position: sticky;
    top: 24px;
  }
}

.donate-card {
  --bite: 9px;
  position: relative;
  padding: 28px 24px;
  background: var(--stamp-card);
  border-radius: 2px;
  box-shadow: none;
}

.donate-card::before,
.donate-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.donate-card::before {
  background:
    radial-gradient(circle var(--bite) at 50% 0, var(--cream) 98%, #0000 100%) 0 0 / 26px 12px repeat-x,
    radial-gradient(circle var(--bite) at 50% 100%, var(--cream) 98%, #0000 100%) 0 100% / 26px 12px repeat-x;
}

.donate-card::after {
  background:
    radial-gradient(circle var(--bite) at 0 50%, var(--cream) 98%, #0000 100%) 0 0 / 12px 26px repeat-y,
    radial-gradient(circle var(--bite) at 100% 50%, var(--cream) 98%, #0000 100%) 100% 0 / 12px 26px repeat-y;
}

.donate-card h2 {
  font-size: 18px;
  font-weight: 650;
  margin-bottom: 4px;
}

.donate-sub {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 20px;
}

.donate-note {
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--faint);
}

.donate-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  font-size: 12px;
  color: var(--faint);
}

.donate-divider::before,
.donate-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.donate-label {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.btn-primary {
  background: var(--brand);
  color: var(--on-brand);
}
.btn-primary:hover { background: var(--brand-hover); }

.btn-outline {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}
.btn-outline:hover { border-color: var(--faint); }

.btn-block { width: 100%; }

.pay-form { margin: 0; }

.amounts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  margin: 0 0 14px;
  border: 0;
}

.amount { position: relative; cursor: pointer; }

.amount input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.amount span {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 8px;
  font-size: 14px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: border-color 0.15s, color 0.15s, background-color 0.15s;
}

.amount:hover span { border-color: var(--faint); }

.amount input:checked + span {
  color: var(--brand);
  background: var(--brand-soft);
  border-color: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand);
}

.amount input:focus-visible + span {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.amount:last-child { grid-column: span 2; }

.custom-field { margin-bottom: 14px; }

.custom-field label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
}

.custom-field input {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.custom-field input:focus {
  border-color: var(--brand);
  outline: none;
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.form-error {
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--rose);
}

.side-extra {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--hairline-soft);
}

.side-extra h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}

.side-extra p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
}

.section {
  padding: 64px 0;
  scroll-margin-top: 84px;
}

.cost-section,
.faq-section {
  border-top: 1px solid var(--line-soft);
}

.section-head {
  max-width: 620px;
  margin-bottom: 36px;
}

.section-head h2 {
  font-size: clamp(1.6rem, 3vw, 2.05rem);
  font-weight: 650;
  letter-spacing: -0.025em;
  margin-bottom: 10px;
}

.section-head > p:last-child {
  font-size: 15px;
  color: var(--muted);
}

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

.cost-item {
  padding: 20px 0 22px;
  border-top: 1px solid var(--line);
}

.cost-item h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
}

.cost-item p {
  font-size: 14px;
  color: var(--muted);
}

.faq-wrap { max-width: 760px; }

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

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

.faq-wrap summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
}

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

.faq-wrap summary::after {
  content: "+";
  flex: none;
  font-size: 18px;
  font-weight: 400;
  line-height: 1;
  color: var(--faint);
}

.faq-wrap details[open] summary::after { content: "–"; }

.faq-wrap details p {
  padding: 0 0 18px;
  font-size: 14px;
  color: var(--muted);
  max-width: 62ch;
}

.site-footer {
  padding: 40px 0 26px;
  background: var(--surface);
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.footer-note {
  margin-top: 2px;
  color: var(--faint);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-nav a { transition: color 0.15s; }
.footer-nav a:hover { color: var(--ink); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--faint);
}

.page-simple {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.simple-main { width: 100%; }

.simple-card {
  max-width: 480px;
  margin: 0 auto;
  padding: 40px 32px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.simple-card h1 {
  font-size: 28px;
  margin-bottom: 14px;
}

.simple-card p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 16px;
}

.simple-card .eyebrow { margin-bottom: 12px; }

.simple-card .btn { margin-top: 8px; }

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

@media (max-width: 900px) {
  .appeal { padding: 44px 0 52px; }

  .appeal-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .corner-bl,
  .corner-br { display: none; }

  .donate-side { max-width: 480px; }

  .cost-list {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .section { padding: 52px 0; }
}

@media (max-width: 720px) {
  .brand-en { display: none; }
}

@media (max-width: 480px) {
  .container { padding: 0 18px; }

  .corner-tl { display: none; }
  .corner-tr { width: 150px; }

  .donate-side { max-width: none; }

  .footer-bottom { flex-direction: column; }
}
