:root {
  --ink: #172b35;
  --blue: #244d66;
  --cream: #f4ecdf;
  --wine: #81384a;
  --paper: #fffdf9;
  --line: #d8cdbd;
  --focus: #ffb000;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: "Yu Mincho", "Hiragino Mincho ProN", "Meiryo", serif; color: var(--ink); background: var(--cream); line-height: 1.8; }
a { color: #17669b; }
a:focus-visible, button:focus-visible, video:focus-visible, iframe:focus-visible, summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.skip-link { position: fixed; z-index: 20; left: 12px; top: 8px; padding: 8px 12px; color: #fff; background: #000; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }
.site-header { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 12px max(20px, calc((100vw - 1080px) / 2)); color: #fff; background: #08121d; font-family: sans-serif; }
.site-header a { color: #fff; text-decoration: none; }
.site-header nav { display: flex; flex-wrap: wrap; gap: 10px 20px; }
.site-header nav a:hover { text-decoration: underline; }
.site-name { font-weight: 800; letter-spacing: .1em; white-space: nowrap; }
.hero { min-height: 72vh; display: grid; place-items: center; text-align: center; color: #fff; padding: 64px 20px; background: linear-gradient(90deg, rgba(4, 11, 19, .94), rgba(13, 30, 45, .66)), url("assets/first_step_outside.png") center/cover; }
.hero-inner { max-width: 900px; text-shadow: 0 2px 18px rgba(0, 0, 0, .55); }
.kicker, .eyebrow { letter-spacing: .18em; font: 700 13px sans-serif; }
h1 { font-size: clamp(45px, 9vw, 90px); margin: .12em 0; letter-spacing: .08em; }
main > h1 { font-size: clamp(36px, 7vw, 64px); }
.lead { font-size: clamp(18px, 2.4vw, 28px); }
.preview { display: inline-block; background: #ffe7a8; color: #5b4100; padding: 5px 12px; border-radius: 999px; font: 700 14px sans-serif; text-shadow: none; }
main { max-width: 1080px; margin: auto; padding: 36px 20px 80px; }
section { margin: 64px 0; }
h2 { color: var(--blue); font-size: clamp(24px, 4vw, 32px); border-bottom: 1px solid var(--line); padding-bottom: .3em; }
.intro { display: grid; grid-template-columns: 1.1fr 1fr; gap: 36px; align-items: center; }
.intro img { width: 100%; height: auto; border-radius: 18px; box-shadow: 0 18px 50px rgba(23, 43, 53, .2); }
.eyebrow { color: var(--wine); }
.eras, .downloads { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.button { display: inline-block; background: var(--blue); color: #fff; text-decoration: none; padding: 11px 16px; border: 0; border-radius: 8px; margin: 4px; font: inherit; font-family: sans-serif; cursor: pointer; }
.button.secondary { background: var(--wine); }
.button.light { background: var(--paper); color: var(--ink); text-shadow: none; }
.button.ghost { border: 1px solid rgba(255, 255, 255, .7); background: rgba(0, 0, 0, .2); }
.button[disabled] { cursor: not-allowed; opacity: .58; }
.hero-actions { margin-top: 24px; }
.media-shell { overflow: hidden; border-radius: 14px; background: #050b12; box-shadow: 0 18px 50px rgba(23, 43, 53, .22); aspect-ratio: 16 / 9; }
.media-placeholder { display: grid; align-content: center; min-height: 100%; padding: 32px; color: #dce7ef; text-align: center; background: radial-gradient(circle at 50% 42%, #26394b, #050b12 66%); }
.media-placeholder p { margin: .25em; }
.teaser-video { width: 100%; height: 100%; background: #000; }
.teaser-frame { width: 100%; height: 100%; border: 0; background: #000; }
.media-download { text-align: center; }
.download-callout { border: 1px solid var(--line); padding: 24px; border-radius: 14px; background: rgba(255, 253, 249, .68); }
.download-panel { max-width: 760px; margin: 48px auto; padding: 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.download-meta { display: grid; grid-template-columns: max-content 1fr; gap: 4px 18px; }
.download-meta dt { font-weight: 700; }
.download-meta dd { margin: 0; overflow-wrap: anywhere; }
.hash { font-family: ui-monospace, Consolas, monospace; overflow-wrap: anywhere; font-size: 13px; }
.content-notice { padding: 20px 24px; background: #fff7e4; border: 1px solid #e5c983; border-radius: 14px; }
.regional-notice { padding: 24px; background: #eef2f4; border-radius: 14px; font-size: 14px; }
.regional-notice details { margin-top: 18px; }
.regional-notice summary { cursor: pointer; font-weight: 700; color: var(--blue); }
.status-box { padding: 14px 18px; border-left: 5px solid var(--wine); background: #fff7e4; }
.visitor-counter { min-height: 20px; margin: 8px auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 18px; font: 12px/1.5 sans-serif; opacity: .86; }
.visitor-counter a { display: inline-flex; align-items: center; gap: 5px; }
.visitor-counter img { display: inline-block; max-width: 100%; height: auto; margin: 0; }
.counter-backup-label { color: #fff; }
.counter-help { margin-top: 6px; }
.translation-notice { margin: 28px 0; padding: 20px 24px; border: 1px solid #9eb8c8; border-radius: 14px; background: #edf5f8; }
.translation-notice h2 { margin-top: 0; font-size: 22px; }
.terms-page { max-width: 900px; }
.terms-lead { padding: 28px; border-radius: 18px; color: #fff; background: linear-gradient(135deg, #08121d, #244d66); box-shadow: 0 18px 50px rgba(23, 43, 53, .18); }
.terms-lead h1 { margin-top: 0; font-size: clamp(34px, 7vw, 58px); }
.terms-lead a { color: #bde3ff; }
.terms-meta { display: grid; grid-template-columns: max-content 1fr; gap: 4px 18px; margin: 20px 0 0; }
.terms-meta dt { font-weight: 700; }
.terms-meta dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.terms-meta a { overflow-wrap: anywhere; }
.terms-toc { margin: 28px 0 48px; padding: 22px 28px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 253, 249, .76); }
.terms-toc ol { columns: 2; margin-bottom: 0; }
.terms-content > section { scroll-margin-top: 24px; }
.terms-content a { overflow-wrap: anywhere; }
.terms-content blockquote { margin: 24px 0; padding: 16px 22px; border-left: 5px solid var(--wine); background: var(--paper); }
.terms-content li + li { margin-top: 8px; }
footer { padding: 28px 20px; color: #fff; background: #162d40; text-align: center; }
footer a { color: #bde3ff; }
.small { font-size: 12px; opacity: .78; }
body[data-public-approval="true"] .prepublication-only { display: none; }
[hidden] { display: none !important; }

@media (max-width: 720px) {
  html { scroll-behavior: auto; }
  .site-header { align-items: flex-start; }
  .site-header nav { justify-content: flex-end; }
  .intro { grid-template-columns: 1fr; }
  .hero { min-height: 64vh; }
  .hero-actions .button { display: block; margin: 10px auto; max-width: 260px; }
  .download-meta { grid-template-columns: 1fr; }
  .download-meta dd { margin-bottom: 8px; }
  .terms-meta { grid-template-columns: 1fr; }
  .terms-meta dd { margin-bottom: 8px; }
  .terms-toc ol { columns: 1; }
}

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