/* Crowns & Jewels — CLEAR GLASS over candlelit art (owner's glass rule):
   strongly see-through, palette-tinted (burgundy / gold / parchment),
   backdrop blur, light and luminous — never frosted or opaque. */
:root {
  --burgundy: #4a0e20;
  --burgundy-deep: #2a0a14;
  --gold: #d8b25a;
  --gold-bright: #f0d089;
  --parchment: #f4e8cd;
  --ink: #2b1a12;
  --glass-bright: rgba(246, 232, 203, 0.14);
  --glass-tint: rgba(122, 26, 48, 0.18);
  --glass-border: rgba(216, 178, 90, 0.55);
  --text: #f7ecd4;
  --muted: #d9c49a;
  --danger: #e88;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 19px;
  color: var(--text);
  background: var(--burgundy-deep);
  min-height: 100vh;
}
.bg {
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(42,10,20,0.25), rgba(42,10,20,0.88)),
    url('/assets/chamber.jpg') center / cover no-repeat fixed,
    var(--burgundy-deep);
}
h1, h2, h3, .cinzel { font-family: "Cinzel", serif; letter-spacing: 0.04em; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

/* ---------- clear glass ---------- */
.glass {
  background: linear-gradient(155deg, var(--glass-bright), var(--glass-tint));
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  backdrop-filter: blur(16px) saturate(1.5);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 244, 214, 0.35), inset 0 -1px 0 rgba(0,0,0,0.15), 0 12px 32px rgba(0,0,0,0.35);
}
.glass-soft {
  background: linear-gradient(155deg, rgba(246,232,203,0.10), rgba(122,26,48,0.12));
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
  backdrop-filter: blur(12px) saturate(1.4);
  border: 1px solid rgba(216,178,90,0.38);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255,244,214,0.25), 0 8px 22px rgba(0,0,0,0.28);
}

/* ---------- chrome ---------- */
.topbar {
  position: sticky; top: 10px; z-index: 40;
  margin: 10px auto 0; max-width: 1080px; width: calc(100% - 20px);
  display: flex; align-items: center; gap: 14px; padding: 10px 16px;
}
.brand { background: none; border: 0; color: var(--text); text-align: left; line-height: 1; padding: 0; }
.brand-crown { color: var(--gold); font-size: 26px; margin-right: 6px; text-shadow: 0 0 14px rgba(216,178,90,.8); }
.brand-text { font-family: "Cinzel", serif; font-weight: 900; font-size: 21px; }
.brand-text .amp { color: var(--gold); }
.brand-sub { display: block; font-family: "Cinzel", serif; font-size: 10.5px; letter-spacing: .34em; color: var(--muted); margin-top: 3px; text-transform: uppercase; }
.topnav { display: flex; gap: 4px; margin-left: auto; }
.topnav button, .ghost-btn {
  background: rgba(246,232,203,0.08); color: var(--text);
  border: 1px solid rgba(216,178,90,0.35); border-radius: 999px;
  padding: 7px 14px; font-size: 15.5px;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.topnav button:hover, .ghost-btn:hover { border-color: var(--gold); color: var(--gold-bright); }
.topmeta { display: flex; align-items: center; gap: 8px; }
.coin-chip { padding: 6px 12px; border-radius: 999px; font-size: 16px; }
.coin-chip b { color: var(--gold-bright); }
.adult-badge { border: 1.5px solid #c0392b; color: #ff9d8f; border-radius: 6px; padding: 2px 7px; font-family: "Cinzel", serif; font-weight: 700; font-size: 13px; }
.app { max-width: 1080px; margin: 0 auto; padding: 18px 14px 40px; }
.footer { max-width: 1080px; margin: 0 auto 16px; width: calc(100% - 20px); padding: 16px 20px; text-align: center; }
.footer p { margin: 4px 0; }
.fine { font-size: 15px; color: var(--muted); }
.link-btn { background: none; border: 0; color: var(--gold-bright); font-size: 15px; text-decoration: underline; padding: 0; }

/* ---------- hero & library ---------- */
.hero { position: relative; border-radius: 20px; overflow: hidden; border: 1px solid var(--glass-border); box-shadow: 0 18px 44px rgba(0,0,0,.5); }
.hero img { width: 100%; height: min(46vh, 420px); object-fit: cover; }
.hero-veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(42,10,20,.18) 30%, rgba(42,10,20,.82)); display: flex; flex-direction: column; justify-content: flex-end; padding: 26px; }
.hero h1 { margin: 0; font-size: clamp(30px, 5.4vw, 52px); font-weight: 900; text-shadow: 0 3px 18px rgba(0,0,0,.7); }
.hero h1 .amp { color: var(--gold); }
.hero .kicker { font-family: "Cinzel", serif; letter-spacing: .3em; font-size: 12px; color: var(--gold-bright); text-transform: uppercase; margin-bottom: 8px; }
.tagline { font-size: clamp(19px, 2.6vw, 24px); font-style: italic; color: #ffeec4; max-width: 760px; margin: 10px 0 0; text-shadow: 0 2px 10px rgba(0,0,0,.8); }
.twist { margin-top: 8px; color: var(--muted); font-size: 17.5px; }
.section-head { display: flex; align-items: baseline; gap: 12px; margin: 30px 4px 14px; }
.section-head h2 { margin: 0; font-size: 24px; color: var(--gold-bright); }
.section-head .rule { flex: 1; height: 1px; background: linear-gradient(90deg, var(--glass-border), transparent); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.ep-card { overflow: hidden; padding: 0; text-align: left; color: var(--text); width: 100%; }
.ep-card .thumb { height: 250px; overflow: hidden; position: relative; }
.ep-card .thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .6s ease; }
.ep-card:hover .thumb img { transform: scale(1.045); }
.ep-card .thumb .ep-no { position: absolute; top: 10px; left: 10px; background: rgba(42,10,20,.55); border: 1px solid var(--glass-border); color: var(--gold-bright); border-radius: 999px; padding: 3px 11px; font-family: "Cinzel", serif; font-size: 12px; letter-spacing: .14em; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.ep-card .body { padding: 14px 16px 16px; }
.ep-card h3 { margin: 0 0 2px; font-size: 21px; }
.ep-card .sub { color: var(--gold-bright); font-style: italic; font-size: 17px; }
.ep-card .era { color: var(--muted); font-size: 14.5px; letter-spacing: .12em; text-transform: uppercase; font-family: "Cinzel", serif; margin: 6px 0; }
.ep-card p { margin: 6px 0 10px; font-size: 16.5px; line-height: 1.45; color: #efe3c8; }
.ep-card .foot { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pill { border: 1px solid rgba(216,178,90,.45); border-radius: 999px; padding: 3px 11px; font-size: 14px; color: var(--gold-bright); background: rgba(246,232,203,.07); }
.pill.done { color: #b9e7b0; border-color: rgba(140,220,130,.5); }
.pill.lock { color: #ffb3a0; border-color: rgba(230,140,110,.5); }
.pill.soon { color: var(--muted); }
.medallion { height: 100%; display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 38%, rgba(216,178,90,.30), rgba(74,14,32,.55) 70%); font-family: "Cinzel", serif; font-size: 92px; color: var(--gold-bright); text-shadow: 0 0 26px rgba(216,178,90,.6); }
.interlude { margin: 26px 0 4px; padding: 14px 18px; text-align: center; color: var(--muted); font-style: italic; }

/* ---------- play view ---------- */
.play-head { padding: 18px; display: grid; grid-template-columns: 168px 1fr; gap: 18px; align-items: center; }
.frame { position: relative; border-radius: 12px; padding: 7px; background: linear-gradient(150deg, #f4d98c, #9a742f 40%, #e9cd82 60%, #7c5c22); box-shadow: 0 10px 26px rgba(0,0,0,.5), inset 0 0 0 2px rgba(60,40,8,.55); }
.frame::after { content: '❦'; position: absolute; bottom: -11px; left: 50%; transform: translateX(-50%); background: var(--burgundy-deep); color: var(--gold); border: 1px solid var(--glass-border); border-radius: 999px; width: 24px; height: 24px; line-height: 22px; text-align: center; font-size: 13px; }
.frame img { border-radius: 7px; width: 100%; height: 218px; object-fit: cover; object-position: top; }
.play-head .kicker { font-family: "Cinzel", serif; letter-spacing: .26em; font-size: 11.5px; color: var(--gold-bright); text-transform: uppercase; }
.play-head h2 { margin: 4px 0 2px; font-size: clamp(24px, 4vw, 34px); }
.play-head .sub { font-style: italic; color: var(--gold-bright); font-size: 19px; }
.play-head .era { color: var(--muted); letter-spacing: .16em; font-size: 13.5px; text-transform: uppercase; font-family: "Cinzel", serif; margin-top: 5px; }
.playas { margin-top: 8px; font-size: 17.5px; color: #ffeec4; }
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.btn {
  background: linear-gradient(155deg, rgba(246,232,203,.16), rgba(122,26,48,.20));
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  color: var(--text); border: 1px solid var(--glass-border); border-radius: 999px;
  padding: 9px 18px; font-size: 16.5px; font-family: "Cinzel", serif; letter-spacing: .03em;
}
.btn:hover { border-color: var(--gold-bright); color: var(--gold-bright); }
.btn.gold { background: linear-gradient(155deg, #e9cd82, #b98f3e); color: #33160a; font-weight: 700; border-color: #f4d98c; }
.btn.gold:hover { color: #1d0c04; filter: brightness(1.06); }
.btn.small { padding: 6px 13px; font-size: 14.5px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.stats-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 0; }
.stat-chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 13px; border-radius: 999px; font-size: 16px; }
.stat-chip .ic { color: var(--gold); }
.stat-chip b { color: var(--gold-bright); font-family: "Cinzel", serif; }
.stat-chip .bar { width: 54px; height: 6px; border-radius: 3px; background: rgba(246,232,203,.18); overflow: hidden; }
.stat-chip .bar i { display: block; height: 100%; background: linear-gradient(90deg, #b98f3e, var(--gold-bright)); }
.secret-line { margin-top: 10px; font-size: 16px; color: var(--muted); }
.secret-line b { color: var(--gold-bright); }
.section-card { margin-top: 16px; padding: 26px clamp(18px, 4vw, 38px); }
.section-enter { animation: rise .55s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.section-card h3 { margin: 0 0 12px; font-size: 24px; color: var(--gold-bright); text-align: center; }
.section-card h3::before, .section-card h3::after { content: ' ✦ '; color: var(--gold); font-size: 15px; vertical-align: 3px; }
.section-text p { font-size: 20.5px; line-height: 1.62; margin: 0 0 14px; color: #f9f0da; }
.section-text p:first-of-type::first-letter { font-family: "Cinzel", serif; font-size: 44px; color: var(--gold-bright); line-height: 1; padding-right: 4px; }
.tidbit { margin: 18px 0 4px; padding: 13px 16px; display: flex; gap: 12px; align-items: flex-start; }
.tidbit .t-ic { font-size: 21px; }
.tidbit .t-head { font-family: "Cinzel", serif; font-size: 12.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-bright); }
.tidbit p { margin: 3px 0 0; font-size: 16.5px; font-style: italic; color: #efe3c8; line-height: 1.45; }
.notes { margin: 12px 0 0; display: flex; gap: 8px; flex-wrap: wrap; }
.note { background: rgba(216,178,90,.16); border: 1px solid rgba(216,178,90,.5); color: #ffe9b0; border-radius: 999px; padding: 4px 12px; font-size: 15px; }
.choices { margin-top: 20px; display: grid; gap: 11px; }
.choice {
  display: flex; gap: 13px; align-items: flex-start; text-align: left; width: 100%;
  padding: 14px 16px; border-radius: 14px; color: var(--text); font-size: 18.5px; line-height: 1.4;
  background: linear-gradient(155deg, rgba(246,232,203,.13), rgba(122,26,48,.16));
  -webkit-backdrop-filter: blur(12px) saturate(1.4); backdrop-filter: blur(12px) saturate(1.4);
  border: 1px solid rgba(216,178,90,.42);
  box-shadow: inset 0 1px 0 rgba(255,244,214,.28);
  transition: transform .15s ease, border-color .15s ease;
}
.choice:hover:not(:disabled) { transform: translateY(-1px); border-color: var(--gold-bright); }
.choice .letter { flex: none; width: 32px; height: 32px; border-radius: 999px; border: 1.5px solid var(--gold); color: var(--gold-bright); font-family: "Cinzel", serif; font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 16px; margin-top: 1px; }
.choice.premium { border-color: rgba(240,208,137,.85); box-shadow: inset 0 1px 0 rgba(255,244,214,.35), 0 0 16px rgba(216,178,90,.22); }
.choice:disabled { opacity: .55; cursor: not-allowed; }
.choice .hint { display: block; font-size: 14.5px; color: var(--muted); margin-top: 3px; font-style: italic; }
.choice .prem-tag { color: var(--gold-bright); font-family: "Cinzel", serif; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; }

/* ---------- endings & epilogue ---------- */
.ending-banner { text-align: center; padding: 10px 0 2px; }
.ending-banner .crown { font-size: 40px; color: var(--gold); text-shadow: 0 0 22px rgba(216,178,90,.75); }
.ending-banner h3 { margin: 6px 0 2px; font-size: 27px; }
.ending-banner .best { color: var(--gold-bright); font-family: "Cinzel", serif; letter-spacing: .2em; font-size: 12.5px; text-transform: uppercase; }
.epilogue { margin-top: 20px; border-radius: 14px; overflow: hidden; border: 1px solid rgba(120,84,30,.6); color: var(--ink); background: #f1e3c2 url('/assets/letter.jpg') center / cover; box-shadow: 0 14px 30px rgba(0,0,0,.45); }
.epilogue .inner { background: rgba(247,238,216,.88); padding: 22px clamp(18px, 4vw, 32px); }
.epilogue h4 { font-family: "Italianno", cursive; font-size: 37px; margin: 0 0 6px; color: #5a3418; font-weight: 500; }
.epilogue h5 { font-family: "Cinzel", serif; margin: 14px 0 5px; font-size: 14.5px; letter-spacing: .14em; text-transform: uppercase; color: #7a4d16; }
.epilogue p { margin: 0 0 7px; font-size: 17.5px; line-height: 1.5; }

/* ---------- panels, forms, modals ---------- */
.panel { padding: 22px clamp(16px, 3.5vw, 30px); margin-top: 16px; }
.panel h2 { margin-top: 0; color: var(--gold-bright); }
.field { margin-bottom: 13px; }
.field label { display: block; font-size: 15.5px; color: var(--muted); margin-bottom: 5px; font-family: "Cinzel", serif; letter-spacing: .05em; }
.field input[type="text"], .field input[type="email"], .field input[type="password"] {
  width: 100%; padding: 11px 14px; border-radius: 11px; font-size: 17px; font-family: inherit;
  background: rgba(246,232,203,.10); border: 1px solid rgba(216,178,90,.4); color: var(--text);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.field input::placeholder { color: rgba(217,196,154,.6); }
.checkline { display: flex; gap: 10px; align-items: flex-start; font-size: 16.5px; margin: 12px 0; }
.checkline input { margin-top: 5px; transform: scale(1.25); }
.form-err { color: #ffb3a0; font-size: 16px; min-height: 20px; }
.modal-veil { position: fixed; inset: 0; z-index: 90; background: rgba(20,4,10,.55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 22px 12px; }
.modal { max-width: 560px; width: 100%; padding: 24px; margin: auto 0; }
.modal.wide { max-width: 860px; }
.modal h2 { margin: 0 0 6px; color: var(--gold-bright); }
.modal .x { float: right; }
.grid-looks { display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 12px; margin: 10px 0 4px; }
.look { padding: 0; overflow: hidden; text-align: left; color: var(--text); width: 100%; }
.look img { height: 158px; width: 100%; object-fit: cover; object-position: top; }
.look .cap { padding: 8px 10px 10px; }
.look .cap b { display: block; font-size: 16px; font-family: "Cinzel", serif; font-weight: 700; }
.look .cap span { font-size: 13.5px; color: var(--muted); line-height: 1.3; display: block; }
.look.sel { outline: 2px solid var(--gold-bright); }
.look .price { color: var(--gold-bright); font-family: "Cinzel", serif; font-size: 14px; }
.acc-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.acc-chip { border-radius: 999px; padding: 7px 13px; font-size: 15px; color: var(--text); background: rgba(246,232,203,.08); border: 1px solid rgba(216,178,90,.4); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.acc-chip.on { background: rgba(216,178,90,.30); border-color: var(--gold-bright); color: #ffeec4; }
.acc-chip .p { color: var(--gold-bright); font-size: 13.5px; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.pack { padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.pack h3 { margin: 0; font-size: 19px; }
.pack .price { font-family: "Cinzel", serif; font-size: 26px; color: var(--gold-bright); }
.pack p { margin: 0; font-size: 16.5px; color: #efe3c8; line-height: 1.45; flex: 1; }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 120; padding: 11px 20px; border-radius: 999px; font-size: 16.5px; max-width: min(92vw, 560px); text-align: center; }
.kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.kv .cell { padding: 12px 14px; }
.kv .cell b { display: block; font-size: 22px; color: var(--gold-bright); font-family: "Cinzel", serif; }
table.simple { width: 100%; border-collapse: collapse; font-size: 15.5px; }
table.simple td, table.simple th { padding: 6px 8px; border-bottom: 1px solid rgba(216,178,90,.25); text-align: left; }
.legal p, .legal li { font-size: 17px; line-height: 1.55; color: #efe3c8; }
@media (max-width: 640px) {
  .play-head { grid-template-columns: 108px 1fr; }
  .frame img { height: 148px; }
  .topnav { display: none; }
  .brand-sub { display: none; }
  .section-text p { font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .section-enter { animation: none; }
  .ep-card .thumb img { transition: none; }
}
