:root {
  color-scheme: light;
  --bg: #f4f0e7;
  --bg-deep: #e9e2d5;
  --surface: #fffdf8;
  --surface-soft: rgba(255, 253, 248, .78);
  --surface-strong: #f8f3e8;
  --ink: #171816;
  --ink-soft: #595a55;
  --ink-faint: #85867e;
  --line: rgba(40, 36, 26, .14);
  --line-gold: rgba(173, 126, 43, .42);
  --gold: #a87927;
  --gold-bright: #c99b45;
  --gold-pale: #ead3a1;
  --shadow: 0 28px 80px rgba(73, 60, 35, .1);
  --header-bg: rgba(250, 247, 240, .87);
  --serif: "Yu Mincho", "Hiragino Mincho ProN", "Noto Serif JP", Georgia, serif;
  --sans: Inter, "Yu Gothic UI", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #090b0c;
  --bg-deep: #050607;
  --surface: #111416;
  --surface-soft: rgba(17, 20, 22, .8);
  --surface-strong: #171818;
  --ink: #f1ebdf;
  --ink-soft: #b6b1a7;
  --ink-faint: #7f807c;
  --line: rgba(226, 210, 175, .14);
  --line-gold: rgba(204, 161, 84, .45);
  --gold: #c69a4b;
  --gold-bright: #e0bd77;
  --gold-pale: #f0dbab;
  --shadow: 0 34px 90px rgba(0, 0, 0, .38);
  --header-bg: rgba(9, 11, 12, .88);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 104px; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); line-height: 1.8; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(circle at 8% 8%, rgba(191, 150, 77, .12), transparent 28%), radial-gradient(circle at 90% 75%, rgba(191, 150, 77, .06), transparent 30%); }
a { color: inherit; }
button { font: inherit; }
h1, h2, h3, p { margin-top: 0; }
h1, h2 { font-family: var(--serif); font-weight: 400; letter-spacing: .025em; }
.page-shell { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.skip-link { position: fixed; top: -60px; left: 16px; z-index: 100; padding: 9px 15px; background: var(--surface); border: 1px solid var(--gold); }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 4px; }

/* Shared header */
.preview-bar { min-height: 24px; padding: 4px 16px; background: var(--gold); color: #17130b; font-family: var(--mono); font-size: 8px; font-weight: 700; letter-spacing: .12em; text-align: center; }
.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid var(--line); background: var(--header-bg); backdrop-filter: blur(18px); }
.header-inner { width: min(1320px, calc(100% - 48px)); min-height: 76px; margin: auto; display: flex; align-items: center; gap: 25px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; white-space: nowrap; font-size: 14px; font-weight: 600; letter-spacing: -.025em; }
.brand-mark { display: grid; place-items: center; width: 29px; height: 29px; border: 1px solid var(--line-gold); color: var(--gold-bright); font-family: var(--serif); transform: rotate(45deg); }
.brand-mark b { font-size: 13px; font-weight: 400; transform: rotate(-45deg); }
.page-context { padding-left: 24px; border-left: 1px solid var(--line); color: var(--gold); font-family: var(--mono); font-size: 8px; letter-spacing: .14em; }
.desktop-nav { display: flex; gap: 27px; margin-left: auto; }
.desktop-nav a, .site-footer nav a { color: var(--ink-soft); text-decoration: none; font-size: 11px; letter-spacing: .06em; }
.desktop-nav a:hover, .site-footer nav a:hover { color: var(--gold-bright); }
.header-actions { display: flex; align-items: center; gap: 15px; }
.theme-switcher { display: flex; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-soft); }
.theme-switcher button { min-width: 36px; padding: 4px 8px; border: 0; border-radius: 999px; background: transparent; color: var(--ink-faint); cursor: pointer; font-size: 10px; }
.theme-switcher button[aria-pressed="true"] { color: var(--ink); background: var(--surface-strong); box-shadow: 0 1px 5px rgba(0, 0, 0, .1); }
.login-link { min-height: 39px; padding: 7px 15px; border: 1px solid var(--line-gold); color: var(--gold-bright); text-decoration: none; font-size: 11px; }

/* Shared type and controls */
.eyebrow { display: flex; align-items: center; gap: 12px; margin: 0 0 22px; color: var(--gold); font-size: 10px; font-weight: 700; letter-spacing: .18em; }
.eyebrow span { width: 34px; height: 1px; background: currentColor; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 28px; min-height: 56px; padding: 13px 24px; border: 1px solid transparent; text-decoration: none; font-size: 13px; font-weight: 700; transition: transform .2s; }
.button:hover { transform: translateY(-2px); }
.button-primary { color: #17130b; background: linear-gradient(135deg, var(--gold-pale), var(--gold-bright)); box-shadow: 0 14px 34px rgba(165, 120, 40, .2); }
.section { padding: 56px 0; border-bottom: 1px solid var(--line); }
.section-heading { max-width: 710px; }
.section-heading h2 { margin-bottom: 16px; font-size: clamp(35px, 4.2vw, 54px); line-height: 1.45; }
.section-heading > p:not(.eyebrow) { color: var(--ink-soft); }

/* Hero: introductory copy and plan summary */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); background: linear-gradient(135deg, var(--bg), var(--bg-deep)); }
.hero::before { content: ""; position: absolute; inset: 0; opacity: .2; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 72px 72px; mask-image: linear-gradient(90deg, transparent, black 65%, transparent); }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.12fr .88fr; align-items: center; gap: 90px; min-height: auto; padding-block: 48px; }
h1 { margin-bottom: 25px; font-size: clamp(50px, 6.5vw, 82px); line-height: 1.38; }
.lead { max-width: 660px; margin-bottom: 34px; color: var(--ink-soft); font-size: 15px; }
.hero-actions { display: flex; align-items: center; gap: 28px; }
.text-link, .back-link { color: var(--ink); text-decoration-color: var(--gold); text-underline-offset: 5px; font-size: 12px; font-weight: 600; }
.microcopy { margin: 18px 0 0; color: var(--ink-faint); font-size: 9px; }
.price-panel { position: relative; padding: 42px; border: 1px solid var(--line-gold); background: var(--surface-soft); box-shadow: var(--shadow); }
.price-panel::after { content: "A"; position: absolute; right: 24px; top: 5px; color: var(--line-gold); font-family: var(--serif); font-size: 110px; line-height: 1; }
.panel-code { position: relative; z-index: 1; color: var(--gold); font-family: var(--mono); font-size: 8px; letter-spacing: .13em; }
.price { position: relative; z-index: 1; display: flex; align-items: baseline; margin: 37px 0 0; color: var(--gold-bright); }
.price span { margin-right: 6px; font-family: var(--serif); font-size: 22px; }
.price strong { font-family: var(--serif); font-size: clamp(53px, 6vw, 72px); font-weight: 400; line-height: 1; }
.price-note { color: var(--ink-faint); font-size: 10px; }
.price-panel dl { margin: 31px 0 0; border-top: 1px solid var(--line); }
.price-panel dl div { display: flex; justify-content: space-between; gap: 24px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 10px; }
.price-panel dt { color: var(--ink-soft); }
.price-panel dd { margin: 0; color: var(--gold-bright); }

/* Benefit cards: duplicate cards freely as content grows */
.benefits-section { background: var(--surface); }
.benefits-section .section-heading { margin-bottom: 55px; }
.benefit-grid { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); }
.benefit-card { display: flex; flex-direction: column; min-height: 350px; padding: 35px; border-right: 1px solid var(--line); background: var(--bg); }
.benefit-card:last-child { border-right: 0; }
.card-number { color: var(--gold); font-family: var(--mono); font-size: 8px; letter-spacing: .12em; }
.benefit-card h3 { margin: 54px 0 15px; font-family: var(--serif); font-size: clamp(26px, 3vw, 36px); font-weight: 400; line-height: 1.35; }
.benefit-card > p:not(.card-number) { color: var(--ink-soft); font-size: 11px; }
.benefit-card a { margin-top: auto; padding-top: 17px; border-top: 1px solid var(--line-gold); color: var(--gold-bright); text-decoration: none; font-size: 11px; font-weight: 700; }
.account-card { background: linear-gradient(145deg, var(--bg), var(--surface-strong)); }

/* Management steps */
.management-section { background: var(--bg); }
.management-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 90px; }
.steps { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.steps li { display: grid; grid-template-columns: 76px 1fr; gap: 24px; padding: 27px 0; border-bottom: 1px solid var(--line); }
.steps > li > span { color: var(--gold); font-family: var(--serif); font-size: 27px; }
.steps h3 { margin-bottom: 5px; font-family: var(--serif); font-size: 21px; font-weight: 400; }
.steps p { margin-bottom: 0; color: var(--ink-soft); font-size: 11px; }

/* Closing CTA */
.cta-section { padding: 48px 0; border-bottom: 1px solid var(--line); background: var(--bg-deep); }
.cta-card { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 70px; padding: 48px; border: 1px solid var(--line-gold); background: var(--surface); box-shadow: var(--shadow); }
.cta-card h2 { margin-bottom: 11px; font-size: clamp(34px, 4vw, 50px); line-height: 1.4; }
.cta-card > div > p:not(.eyebrow) { margin-bottom: 0; color: var(--ink-soft); font-size: 12px; }
.cta-actions { display: flex; align-items: center; flex-direction: column; gap: 14px; }

/* Footer */
.site-footer { padding: 55px 0 45px; background: var(--bg-deep); }
.footer-main { display: flex; align-items: center; justify-content: space-between; gap: 40px; padding-bottom: 36px; border-bottom: 1px solid var(--line); }
.site-footer nav { display: flex; gap: 25px; }
.footer-legal { padding-top: 25px; color: var(--ink-faint); font-size: 9px; }
.footer-legal > p { max-width: 880px; }
.footer-legal > div { display: flex; justify-content: space-between; gap: 30px; }

.reveal { opacity: 1; transform: none; }
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (max-width: 1000px) {
  .desktop-nav { display: none; }
  .header-actions { margin-left: auto; }
  .hero-grid, .management-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-grid { padding-block: 44px; }
  .benefit-grid { grid-template-columns: 1fr; }
  .benefit-card { min-height: 270px; border-right: 0; border-bottom: 1px solid var(--line); }
  .benefit-card:last-child { border-bottom: 0; }
  .cta-card { grid-template-columns: 1fr; gap: 35px; }
  .cta-actions { align-items: flex-start; }
}

@media (max-width: 680px) {
  html { scroll-padding-top: 90px; }
  .page-shell, .header-inner { width: min(100% - 32px, 1180px); }
  .header-inner { min-height: 64px; gap: 11px; }
  .brand { font-size: 11px; }
  .brand-mark { width: 25px; height: 25px; }
  .page-context, .login-link { display: none; }
  .theme-switcher button { min-width: 32px; padding-inline: 6px; }
  .hero-grid { min-height: auto; padding-block: 36px; }
  h1 { font-size: 45px; }
  .lead { font-size: 13px; }
  .hero-actions { align-items: stretch; flex-direction: column; gap: 19px; }
  .button { width: 100%; }
  .price-panel { padding: 30px 23px; }
  .price-panel::after { font-size: 85px; }
  .section { padding: 40px 0; }
  .section-heading h2 { font-size: 33px; }
  .benefit-card { padding: 28px 23px; }
  .benefit-card h3 { margin-top: 35px; }
  .management-grid { gap: 38px; }
  .steps li { grid-template-columns: 54px 1fr; gap: 13px; }
  .cta-section { padding: 36px 0; }
  .cta-card { padding: 31px 23px; }
  .cta-actions { align-items: stretch; }
  .back-link { text-align: center; }
  .footer-main { align-items: flex-start; flex-direction: column; }
  .site-footer nav { flex-wrap: wrap; }
  .footer-legal > div { flex-direction: column; gap: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
