/* Alpha-War Stories app (stories/web). Fonts are the device's own: the app loads nothing from other sites.
   Alpha-War Stories: "a theater you trust" (build plan, Design). Deep black, gold titles, purple highlights.
   Quiet screens where the story is the brightest thing; money always shown plainly; no timers, no fake scarcity. */
:root {
  --bg: #07060A; --panel: #121019; --line: #2A2433; --text: #F2EEE6; --muted: #A49DB0;
  --gold: #E6C26E; --gold-2: #F3D894; --purple: #A78BFA; --purple-2: #6D4FD3; --danger: #F2828A;
  --r: 14px; --font: system-ui, -apple-system, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font); line-height: 1.6; -webkit-text-size-adjust: 100%; }
a { color: var(--gold); text-decoration: none; }
a:hover, a:focus-visible { color: var(--gold-2); }
:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
button { font: inherit; color: inherit; cursor: pointer; }
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; padding-top: max(14px, env(safe-area-inset-top)); background: linear-gradient(#07060Aee, #07060Acc); backdrop-filter: blur(8px); }
.brand { display: flex; align-items: baseline; gap: 8px; }
.mark { font-weight: 800; font-size: 24px; letter-spacing: .5px; color: var(--gold); }
.sub { font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--purple); }
.pill { min-width: 44px; min-height: 44px; padding: 0 14px; border-radius: 22px; border: 1px solid var(--line); background: var(--panel); }
main { max-width: 1100px; margin: 0 auto; padding: 8px 18px 40px; }
h1, h2, h3 { line-height: 1.3; margin: 0 0 8px; }
h1 { font-size: 26px; color: var(--gold); }
h2 { font-size: 19px; margin-top: 26px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; border: 1px solid var(--line); color: var(--muted); }
.badge.free { color: #0b0a10; background: var(--gold); border-color: var(--gold); }
.badge.r17 { color: var(--danger); border-color: var(--danger); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 24px;
  border: 1px solid var(--line); background: var(--panel); font-weight: 700; }
.btn.primary { background: var(--gold); color: #0b0a10; border-color: var(--gold); }
.btn.purple { background: var(--purple-2); border-color: var(--purple-2); }
.btn:disabled { opacity: .5; cursor: default; }
.empty { padding: 60px 0; text-align: center; }
/* Catalog */
.hero { position: relative; display: grid; grid-template-columns: minmax(0, 220px) 1fr; gap: 20px; align-items: end; margin: 8px 0 24px;
  padding: 18px; border-radius: var(--r); background: radial-gradient(120% 120% at 100% 0, #2a1c4f 0, var(--panel) 55%); border: 1px solid var(--line); }
.hero p { margin: 6px 0 14px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.poster { display: block; aspect-ratio: 9 / 16; width: 100%; object-fit: cover; border-radius: var(--r); background: linear-gradient(160deg, #1d1630, #0c0a12);
  border: 1px solid var(--line); }
.card { display: flex; flex-direction: column; gap: 6px; color: var(--text); }
.card b { font-size: 15px; line-height: 1.35; }
/* Series page */
.series { display: grid; grid-template-columns: minmax(0, 260px) 1fr; gap: 24px; align-items: start; }
.price { margin: 14px 0; padding: 12px 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.eps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ep { display: grid; grid-template-columns: 72px 1fr auto; gap: 12px; align-items: center; padding: 8px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.ep img, .ep .ph { width: 72px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 8px; background: #1a1424; }
.ep button { min-height: 44px; }
.made { margin-top: 10px; padding: 16px; border-radius: var(--r); border: 1px solid var(--purple-2); background: #120d22; }
.made ul { margin: 6px 0 0; padding-left: 20px; }
/* Player: a vertical stage, one thumb */
.player { position: fixed; inset: 0; z-index: 20; display: grid; grid-template-rows: auto 1fr auto; background: #000; }
.player header, .player footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; }
.player header { padding-top: max(10px, env(safe-area-inset-top)); }
.player footer { padding-bottom: max(12px, env(safe-area-inset-bottom)); flex-wrap: wrap; }
.player video { width: 100%; height: 100%; max-height: calc(100vh - 140px); object-fit: contain; background: #000; }
.player select { min-height: 44px; border-radius: 22px; background: var(--panel); color: var(--text); border: 1px solid var(--line); padding: 0 12px; }
.lock { display: grid; place-items: center; text-align: center; padding: 24px; }
.lock .box { max-width: 360px; padding: 22px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--gold); }
.foot { max-width: 1100px; margin: 0 auto; padding: 20px 18px 40px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--line); }
@media (max-width: 640px) {
  .hero, .series { grid-template-columns: 1fr; }
  .hero .poster, .series .poster { max-width: 220px; }
  h1 { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
/* 17+ check: a sheet from the bottom, one tap (mockup 3) */
.sheet-wrap { position: fixed; inset: 0; z-index: 30; background: #000000b3; display: flex; align-items: flex-end; justify-content: center; }
.sheet { width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 14px; padding: 26px 22px max(30px, env(safe-area-inset-bottom));
  border-radius: 22px 22px 0 0; background: var(--panel); border-top: 1px solid var(--line); }
.sheet h2 { margin: 0; font-size: 21px; }
.sheet .btn { width: 100%; min-height: 52px; }
.sheet .badge.r17 { align-self: flex-start; }
/* Sign-in, birth month, account (sheets) */
.top-actions { display: flex; gap: 8px; }
.sheet label { display: flex; flex-direction: column; gap: 6px; }
.sheet input { min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: #0d0b12; color: var(--text); font: inherit; font-size: 17px; }
.sheet input:focus-visible { outline: 2px solid var(--purple); outline-offset: 1px; }
.sheet [role="alert"]:empty { display: none; }
.sheet [role="alert"] { color: var(--danger); margin: 0; }
/* Privacy notice and other plain pages */
.doc { max-width: 760px; line-height: 1.75; }
.doc h1 { font-size: 24px; margin: 16px 0 4px; }
.doc h2 { font-size: 17px; margin: 28px 0 6px; }
.doc ul { padding-left: 1.2em; }
.doc a { color: inherit; }
