/* ============================================================
   SOUL EROSION — grim Norse/Celtic dark-fantasy promo site
   Palette: warm near-black + pewter/bronze ornaments + sage accent
   Type: Cinzel (engraved Roman caps) + EB Garamond (body)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600;700;800;900&family=EB+Garamond:ital,wght@0,400;0,500;0,600;1,400&family=Cinzel+Decorative:wght@400;700&display=swap');

@font-face {
  font-family: 'Blanka';
  src: url('assets/fonts/Blanka-Regular.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg:        #0b0a09;
  --bg-2:      #131110;
  --bg-3:      #1a1715;
  --ink:       #ece6da;
  --ink-dim:   #b8b1a3;
  --muted:     #8c857a;
  --faint:     #5d574e;

  /* metallic hairline / ornament */
  --line:      rgba(205,193,168,0.22);
  --line-soft: rgba(205,193,168,0.10);
  --metal-1:   #d9cfb8;
  --metal-2:   #9a8f78;
  --bronze:    #b69a5e;
  --bronze-dk: #6e5c34;

  /* accent — muted sage green (user pick) */
  --accent:      oklch(0.72 0.055 150);
  --accent-dim:  oklch(0.60 0.05 150);
  --accent-glow: oklch(0.72 0.10 150 / 0.35);

  --maxw: 1680px;
  --frame-pad: clamp(18px, 2.6vw, 44px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html, body { height: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'EB Garamond', Georgia, serif;
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow: hidden; /* the scroll container handles scrolling */
}

#root { height: 100vh; }

::selection { background: var(--accent-glow); color: #fff; }

h1, h2, h3, .cinzel {
  font-family: 'Cinzel', Georgia, serif;
  font-weight: 600;
  letter-spacing: 0.04em;
}

a { color: inherit; text-decoration: none; }

/* ============================================================
   METALLIC TEXT (logo / big title)
   ============================================================ */
.metal-text {
  background: linear-gradient(180deg, #fbf7ec 0%, #d7ccb4 26%, #8e8470 52%, #cdbf9f 64%, #f3ecdb 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}

/* ============================================================
   APP SHELL
   ============================================================ */
.shell {
  position: fixed;
  inset: 0;
  height: 100vh;
  width: 100vw;
}

/* full-screen scroll snap */
.scroller {
  height: 100vh;
  overflow-y: scroll;
  overflow-x: hidden;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
}
.scroller::-webkit-scrollbar { width: 0; height: 0; display: none; }

.section {
  position: relative;
  min-height: 100vh;
  width: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(70px, 9vh, 120px) var(--frame-pad);
  overflow: hidden;
}

/* ============================================================
   TOP & BOTTOM ORNAMENTAL FRAME (fixed)
   ============================================================ */
.frame-bar {
  position: fixed;
  left: 0; right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 var(--frame-pad);
  pointer-events: none;
  height: 64px;
}
.frame-bar > * { pointer-events: auto; }
.frame-bar.top { top: 0; }
.frame-bar.bottom { bottom: 0; }

/* the ornamental hairline with diamond nodes */
.rule {
  flex: 1;
  height: 1px;
  position: relative;
  background: linear-gradient(90deg, transparent, var(--line) 8%, var(--line) 92%, transparent);
}
.rule::before, .rule::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 6px; height: 6px;
  transform: translateY(-50%) rotate(45deg);
  border: 1px solid var(--line);
  background: var(--bg);
}
.rule::before { left: 14%; }
.rule::after  { right: 14%; }

.rule-mid {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) rotate(45deg);
  width: 7px; height: 7px;
  border: 1px solid var(--line);
  background: var(--bronze-dk);
}

/* brand mark top-left */
.brandmark {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1;
  user-select: none;
}
.brandmark .bm-title {
  font-family: 'Cinzel', serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.34em;
  padding-left: 0.34em;
}
.brandmark .bm-sub {
  font-family: 'Cinzel', serif;
  font-size: 8.5px;
  letter-spacing: 0.5em;
  color: var(--bronze);
  padding-left: 0.5em;
  margin-top: 5px;
  border-top: 1px solid var(--line-soft);
  padding-top: 4px;
}

/* wishlist pill top-right */
.wishlist-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: 'Cinzel', serif;
  font-size: 12px;
  letter-spacing: 0.22em;
  color: var(--ink-dim);
  background: none;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.wishlist-btn:hover { color: var(--ink); }
.wishlist-btn svg { width: 15px; height: 15px; opacity: 0.85; }

/* social bar bottom-left */
.social {
  display: flex;
  align-items: center;
  gap: 16px;
}
.social a {
  color: var(--muted);
  display: grid;
  place-items: center;
  transition: color 0.3s var(--ease), transform 0.3s var(--ease);
}
.social a:hover { color: var(--accent); transform: translateY(-2px); }
.social svg { width: 17px; height: 17px; }

.globe-btn {
  background: none; border: none; cursor: pointer;
  color: var(--muted);
  display: grid; place-items: center;
  transition: color 0.3s var(--ease);
}
.globe-btn:hover { color: var(--ink); }
.globe-btn svg { width: 18px; height: 18px; }

/* language popover (opens upward from the globe) */
.lang { position: relative; display: inline-flex; }
.lang:hover .globe-btn, .lang:focus-within .globe-btn { color: var(--ink); }
.lang-menu {
  position: absolute; bottom: calc(100% + 14px); right: 0;
  min-width: 196px; padding: 6px;
  background: linear-gradient(180deg, var(--bg-3), var(--bg-2));
  border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 18px 44px -16px rgba(0,0,0,0.82), inset 0 1px 0 rgba(217,207,184,0.06);
  opacity: 0; transform: translateY(8px); pointer-events: none;
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease);
  z-index: 90;
}
.lang:hover .lang-menu, .lang:focus-within .lang-menu {
  opacity: 1; transform: translateY(0); pointer-events: auto;
}
.lang-menu::after {
  content: ""; position: absolute; bottom: -5px; right: 16px;
  width: 9px; height: 9px; transform: rotate(45deg);
  background: var(--bg-2); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.lang-head {
  font-family: 'Cinzel', serif; font-size: 9px; letter-spacing: 0.32em;
  text-transform: uppercase; color: var(--bronze);
  padding: 6px 10px 8px; border-bottom: 1px solid var(--line-soft); margin-bottom: 4px;
}
.lang-item {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; width: 100%;
  background: none; border: none; cursor: pointer; text-align: left;
  padding: 9px 10px; border-radius: 4px; color: var(--muted);
  font-family: 'Cinzel', serif; font-size: 13px; letter-spacing: 0.04em;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.lang-item .lang-code { font-size: 10px; letter-spacing: 0.16em; color: var(--faint); transition: color 0.2s var(--ease); }
.lang-item:hover { background: rgba(122,154,109,0.12); color: var(--ink); }
.lang-item:hover .lang-code { color: var(--accent); }
.lang-item.active { background: rgba(122,154,109,0.08); color: var(--ink); }
.lang-item.active .lang-code { color: var(--accent); }

/* floating Patreon button — sits just above the language button */
.patreon-float {
  position: fixed;
  left: var(--frame-pad);
  bottom: 74px;
  z-index: 70;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 16px 10px 14px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--bg-3), var(--bg-2));
  border: 1px solid var(--line);
  color: var(--ink-dim);
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.22em;
  box-shadow: 0 6px 22px rgba(0,0,0,0.5), inset 0 1px 0 rgba(217,207,184,0.06);
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.patreon-float svg { width: 16px; height: 16px; color: var(--bronze); transition: color 0.3s var(--ease); }
.patreon-float:hover {
  color: var(--ink);
  border-color: rgba(205,193,168,0.42);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.6), inset 0 1px 0 rgba(217,207,184,0.10);
}
.patreon-float:hover svg { color: var(--metal-1); }
@media (max-width: 640px) {
  .patreon-float { bottom: 64px; padding: 9px; }
  .patreon-float span { display: none; }
}

/* ============================================================
   LEFT VERTICAL NAV
   ============================================================ */
.sidenav {
  position: fixed;
  left: var(--frame-pad);
  top: 50%;
  transform: translateY(-50%) translateX(-30px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.5s var(--ease), opacity 0.5s var(--ease);
  z-index: 55;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.sidenav.visible {
  transform: translateY(-50%);
  opacity: 1;
  pointer-events: auto;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 16px;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 2px 0;
  transition: color 0.35s var(--ease);
  position: relative;
}
.nav-item .nav-arrow {
  width: 12px;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
  color: var(--accent);
}
.nav-item:hover { color: var(--ink-dim); }
.nav-item.active { color: #fff; }
.nav-item.active .nav-arrow { opacity: 1; transform: translateX(0); }
.nav-item .ext { width: 11px; height: 11px; opacity: 0.5; margin-left: 2px; }

/* scroll progress dots fallback (hidden but accessible) */

/* ============================================================
   ORNATE FRAME (media / trailer container)
   ============================================================ */
.ornate {
  position: relative;
  padding: 14px;
  background:
    linear-gradient(var(--bg-2), var(--bg-2)) padding-box,
    linear-gradient(145deg, var(--metal-2), #3a352d 40%, var(--metal-2) 75%, #2a2620) border-box;
  border: 1px solid transparent;
  border-radius: 3px;
  box-shadow: 0 30px 80px -30px rgba(0,0,0,0.85), inset 0 0 0 1px rgba(0,0,0,0.4);
}
.ornate::before {
  /* inner hairline */
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid var(--line);
  border-radius: 1px;
  pointer-events: none;
}
.ornate .corner {
  position: absolute;
  width: 22px; height: 22px;
  color: var(--bronze);
  opacity: 0.85;
  z-index: 2;
}
.ornate .corner.tl { top: -2px; left: -2px; }
.ornate .corner.tr { top: -2px; right: -2px; transform: scaleX(-1); }
.ornate .corner.bl { bottom: -2px; left: -2px; transform: scaleY(-1); }
.ornate .corner.br { bottom: -2px; right: -2px; transform: scale(-1); }

/* ============================================================
   BUTTONS / CTAS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 0.14em;
  color: var(--ink);
  cursor: pointer;
  padding: 16px 34px;
  border-radius: 3px;
  position: relative;
  transition: all 0.35s var(--ease);
}
.btn-primary {
  background: linear-gradient(180deg, #2a2723, #17150f);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 14px 30px -16px #000;
  min-width: 280px;
}
.btn-primary:hover {
  border-color: var(--accent);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 0 28px -6px var(--accent-glow);
  color: #fff;
}
.btn-primary svg { width: 19px; height: 19px; }

.btn-ghost {
  background: none;
  border: none;
  font-size: 15px;
  letter-spacing: 0.3em;
  color: var(--ink-dim);
  padding: 10px 6px;
}
.btn-ghost:hover { color: #fff; }
.btn-ghost .lead, .btn-ghost .trail { color: var(--bronze); opacity: 0.8; }
.btn-ghost .arrow { transition: transform 0.35s var(--ease); }
.btn-ghost:hover .arrow { transform: translateX(6px); }

/* ============================================================
   SHARED HEADINGS / DECOR
   ============================================================ */
.section-title {
  font-family: 'Blanka', 'Cinzel', serif;
  font-weight: 400;
  font-size: clamp(38px, 5.6vw, 80px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1;
}
.eyebrow {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  letter-spacing: 0.42em;
  color: var(--accent);
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before, .eyebrow::after {
  content: "";
  width: 34px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-dim));
}
.eyebrow::after { transform: scaleX(-1); }

/* small celtic divider glyph */
.divider-glyph {
  color: var(--metal-2);
  opacity: 0.7;
  width: 64px;
}

/* striped image placeholder */
.ph {
  position: relative;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.018) 0 14px, transparent 14px 28px),
    radial-gradient(120% 120% at 50% 0%, var(--bg-3), var(--bg) 75%);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.ph-label {
  font-family: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
  text-align: center;
  padding: 8px 14px;
  border: 1px dashed rgba(205,193,168,0.16);
  border-radius: 2px;
  background: rgba(0,0,0,0.25);
}

/* ============================================================
   ATMOSPHERE — embers / fog / rain (decorative, perf-cheap)
   ============================================================ */
.atmos { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.fog {
  position: absolute; inset: -10% 0;
  background:
    radial-gradient(60% 50% at 30% 20%, rgba(122,154,109,0.05), transparent 70%),
    radial-gradient(70% 60% at 75% 80%, rgba(0,0,0,0.6), transparent 60%);
  mix-blend-mode: screen;
  opacity: 0.7;
}
.vignette {
  position: absolute; inset: 0;
  background: radial-gradient(120% 100% at 50% 38%, transparent 40%, rgba(0,0,0,0.55) 100%);
  z-index: 2;
}

@keyframes ember-rise {
  0%   { transform: translateY(0) translateX(0); opacity: 0; }
  10%  { opacity: 0.8; }
  90%  { opacity: 0.5; }
  100% { transform: translateY(-100vh) translateX(20px); opacity: 0; }
}
.ember {
  position: absolute;
  bottom: -10px;
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px 1px var(--accent-glow);
  animation: ember-rise linear infinite;
}

@media (prefers-reduced-motion: reduce) {
  .ember { display: none; }
  .scroller { scroll-behavior: auto; }
}

/* ============================================================
   AGE GATE
   ============================================================ */
.gate {
  position: fixed; inset: 0; z-index: 200;
  background: radial-gradient(120% 100% at 50% 30%, #14110e, #060504 80%);
  display: grid; place-items: center;
  text-align: center;
  padding: 40px;
  animation: gate-in 0.6s var(--ease);
}
@keyframes gate-in { from { opacity: 0; } to { opacity: 1; } }
.gate.out { animation: gate-out 0.7s var(--ease) forwards; }
@keyframes gate-out { to { opacity: 0; visibility: hidden; } }
.gate-inner { max-width: 540px; }
.gate .mark {
  font-family: 'Cinzel', serif; font-weight: 700;
  font-size: clamp(34px, 6vw, 60px);
  letter-spacing: 0.18em;
  margin-bottom: 6px;
}
.gate .sub { font-family: 'Cinzel', serif; letter-spacing: 0.5em; font-size: 11px; color: var(--bronze); margin-bottom: 38px; }
.gate p { color: var(--ink-dim); font-size: 16px; max-width: 420px; margin: 0 auto 8px; }
.gate .age { color: var(--accent); font-family:'Cinzel',serif; letter-spacing: 0.3em; font-size: 13px; margin: 30px 0 18px; }
.gate-actions { display: flex; gap: 16px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
.gate .leave {
  font-family: 'Cinzel', serif; letter-spacing: 0.14em; font-size: 14px;
  color: var(--muted); background: none; border: 1px solid var(--line-soft);
  padding: 16px 30px; border-radius: 3px; cursor: pointer; transition: all .3s var(--ease);
}
.gate .leave:hover { color: var(--ink); border-color: var(--line); }
.gate .fine { font-size: 12px; color: var(--faint); margin-top: 30px; letter-spacing: 0.04em; }

/* ============================================================
   HERO
   ============================================================ */
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg video, .hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.hero-scrim {
  position: absolute; inset: 0; z-index: 2;
  background:
    radial-gradient(70% 60% at 50% 46%, rgba(0,0,0,0.46), transparent 70%),
    linear-gradient(180deg, rgba(0,0,0,0.35) 0%, transparent 30%, transparent 62%, rgba(8,7,6,0.78) 100%);
  pointer-events: none;
}
.hero-bg .ph { position: absolute; inset: 0; }
.hero-content {
  position: relative; z-index: 3;
  display: flex; flex-direction: column; align-items: center;
  text-align: center;
  gap: 26px;
  margin-top: 4vh;
}
.hero-logo {
  display: flex; flex-direction: column; align-items: center; gap: 14px;
}
.hero-logo-img {
  width: min(94vw, 1040px);
  height: auto;
  margin: -4vh 0 -7vh;
  filter: drop-shadow(0 10px 50px rgba(0,0,0,0.5));
  pointer-events: none;
}
.hero-logo .glyph { width: clamp(46px, 5vw, 70px); color: var(--metal-1); filter: drop-shadow(0 2px 8px rgba(0,0,0,.7)); }
.hero-title {
  font-family: 'Cinzel', serif;
  font-weight: 800;
  font-size: clamp(52px, 9vw, 132px);
  letter-spacing: 0.08em;
  line-height: 0.92;
}
.hero-sub {
  font-family: 'Cinzel', serif;
  font-weight: 500;
  font-size: clamp(15px, 2vw, 26px);
  letter-spacing: 0.46em;
  color: var(--ink-dim);
  display: inline-flex; align-items: center; gap: 18px;
  padding-left: 0.46em;
}
.hero-sub::before, .hero-sub::after { content:""; width: clamp(30px,6vw,90px); height:1px; background: linear-gradient(90deg, transparent, var(--line)); }
.hero-sub::after { transform: scaleX(-1); }
.hero-cta { display: flex; flex-direction: column; align-items: center; gap: 18px; margin-top: 12px; }
.scroll-hint {
  position: absolute; bottom: 86px; left: 50%; transform: translateX(-50%);
  z-index: 3; color: var(--muted);
  font-family: 'Cinzel', serif; font-size: 11px; letter-spacing: 0.3em;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  animation: bob 2.4s ease-in-out infinite;
}
@keyframes bob { 0%,100%{ transform: translate(-50%,0);} 50%{ transform: translate(-50%,7px);} }
/* avoid the hint colliding with CTAs on short viewports */
@media (max-height: 940px) {
  .scroll-hint { display: none; }
}

/* ============================================================
   LORE
   ============================================================ */
.lore-wrap {
  max-width: 880px; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 30px;
  z-index: 3;
}
.lore-body {
  font-size: clamp(19px, 2.1vw, 27px);
  line-height: 1.85;
  color: var(--ink-dim);
  text-wrap: pretty;
}
.lore-body .drop {
  float: left;
  font-family: 'Cinzel Decorative', 'Cinzel', serif;
  font-size: 4.4em;
  line-height: 0.74;
  padding: 6px 14px 0 0;
  color: var(--metal-1);
}
.lore-body em { color: var(--accent); font-style: italic; }

/* ============================================================
   CHARACTERS
   ============================================================ */
.char-stage {
  position: relative; z-index: 3;
  width: 100%; max-width: var(--maxw);
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  min-height: 70vh;
}
.char-info { padding-left: clamp(40px, 7vw, 130px); }
.char-info .crest { width: 40px; color: var(--metal-2); opacity: 0.7; margin-bottom: 26px; }
.char-name {
  font-family: 'Blanka', 'Cinzel', serif; font-weight: 400;
  font-size: clamp(40px, 5vw, 70px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.char-role {
  font-family: 'Cinzel', serif; font-size: 13px; letter-spacing: 0.34em;
  color: var(--accent); margin-top: 6px;
}
.char-desc {
  font-size: clamp(17px, 1.5vw, 21px); line-height: 1.7; color: var(--ink-dim);
  max-width: 420px; margin: 26px 0 0; text-wrap: pretty;
}
.char-selector {
  display: flex; gap: 14px; margin-top: 40px;
}
.char-chip {
  background: none; border: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  width: 84px; padding: 8px 4px;
  transition: transform 0.35s var(--ease);
}
.char-chip:hover { transform: translateY(-3px); }
.char-portrait-mini {
  width: 60px; height: 60px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid var(--line-soft);
  position: relative;
  background: radial-gradient(circle at 50% 35%, var(--bg-3), var(--bg));
  overflow: hidden;
  transition: border-color 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.char-portrait-mini img { width:100%; height:100%; object-fit: cover; object-position: top center; filter: grayscale(0.4) brightness(0.85); transition: filter .35s var(--ease); }
.char-chip.active .char-portrait-mini {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 0 20px -4px var(--accent-glow);
}
.char-chip.active .char-portrait-mini img { filter: none; }
.char-chip .cn {
  font-family: 'Cinzel', serif; font-size: 12px; letter-spacing: 0.1em; color: var(--muted);
  transition: color 0.35s var(--ease);
}
.char-chip.active .cn { color: #fff; }
.char-chip .glyph-mini { width: 26px; height: 26px; color: var(--metal-2); opacity: 0.8; }

.char-render {
  position: relative; height: 100%;
  display: flex; align-items: flex-end; justify-content: center;
}
.char-render .figure {
  position: relative;
  width: min(46vw, 640px);
  height: 86vh;
  max-height: 920px;
}
.char-render .ph { position: absolute; inset: 0; border-radius: 4px 4px 0 0;
  -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent);
          mask-image: linear-gradient(180deg, #000 70%, transparent); }
.char-figimg { position: absolute; inset: 0; }
.char-figimg img {
  width: 100%; height: 100%;
  object-fit: contain;
  object-position: bottom center;
  filter: drop-shadow(0 20px 50px rgba(0,0,0,0.6));
}
.char-render .halftone {
  position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1.4px);
  background-size: 5px 5px;
  -webkit-mask-image: radial-gradient(60% 70% at 50% 40%, #000, transparent 75%);
          mask-image: radial-gradient(60% 70% at 50% 40%, #000, transparent 75%);
}
.char-fade {
  animation: char-in 0.55s var(--ease);
}
@keyframes char-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* framed character portrait — matches the media frame */
.char-render { align-items: center; }
.char-frame { position: relative; }
.char-frame .figure { aspect-ratio: 9 / 16; height: min(72vh, 800px); width: auto; max-height: none; }
.char-frame .char-figimg img { object-fit: cover; filter: drop-shadow(0 16px 36px rgba(0,0,0,0.55)); }

/* ============================================================
   MEDIA GALLERY
   ============================================================ */
/* media section backdrop */
#media { background-color: var(--bg); }
#media::before {
  content: "";
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: url('assets/media/background.jpg') center / cover no-repeat;
}
#media::after {
  content: "";
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(120% 100% at 50% 45%, transparent 45%, rgba(6,5,4,0.72) 100%);
}

.media-wrap { z-index: 3; width: 100%; max-width: 1200px; display: flex; flex-direction: column; align-items: center; gap: 34px; }
.media-stage { width: 100%; }
.media-main { aspect-ratio: 16 / 9; width: 100%; }
.media-main .ph, .media-main img { width: 100%; height: 100%; object-fit: cover; border-radius: 2px; }
.media-main img { display: block; }
.media-controls { display: flex; align-items: center; gap: 22px; width: 100%; justify-content: center; }
.media-arrow {
  background: none; border: none; cursor: pointer; color: var(--metal-2);
  width: 44px; transition: color 0.3s var(--ease), transform 0.3s var(--ease);
  flex-shrink: 0;
}
.media-arrow:hover { color: var(--ink); }
.media-arrow.left:hover { transform: translateX(-3px); }
.media-arrow.right:hover { transform: translateX(3px); }
.thumbs { display: flex; gap: 12px; justify-content: center; }

/* windowed thumbnail strip with paging arrows (max 7 visible) */
.thumb-rail { display: flex; align-items: center; gap: 18px; }
.thumb-nav {
  background: none; border: none; cursor: pointer; color: var(--metal-2);
  width: 44px; flex-shrink: 0;
  transition: color 0.3s var(--ease), transform 0.3s var(--ease), opacity 0.3s var(--ease);
}
.thumb-nav:hover { color: var(--ink); }
.thumb-nav.left:hover { transform: translateX(-3px); }
.thumb-nav.right:hover { transform: translateX(3px); }
.thumb-nav:disabled { opacity: 0.22; cursor: default; color: var(--metal-2); transform: none; }
.media-main.is-photo { cursor: zoom-in; }
.thumb {
  width: 108px; aspect-ratio: 16/9; border: 1px solid transparent; cursor: pointer;
  padding: 0; background: none; overflow: hidden; border-radius: 2px;
  opacity: 0.5; transition: all 0.3s var(--ease); position: relative;
}
.thumb:hover { opacity: 0.85; }
.thumb.active { opacity: 1; border-color: var(--accent); box-shadow: 0 0 14px -4px var(--accent-glow); }
.thumb .ph, .thumb img { width: 100%; height: 100%; object-fit: cover; }

/* video tile on the main stage */
.media-main.is-video { cursor: pointer; }
.media-thumb { width: 100%; height: 100%; object-fit: cover; display: block; }
.media-main .play { position: absolute; inset: 0; display: grid; place-items: center; z-index: 2; pointer-events: none; }
.media-main.is-video::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(62% 62% at 50% 46%, rgba(0,0,0,0.08), rgba(0,0,0,0.5));
  transition: background 0.35s var(--ease);
}
.media-main.is-video:hover::after { background: radial-gradient(62% 62% at 50% 46%, rgba(0,0,0,0.02), rgba(0,0,0,0.34)); }
.media-main.is-video:hover .play-btn { border-color: var(--accent); color: #fff; box-shadow: 0 0 40px -8px var(--accent-glow); transform: scale(1.05); }

/* caption ribbon at the foot of the stage */
.media-cap {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; pointer-events: none;
  padding: 36px 22px 16px;
  background: linear-gradient(180deg, transparent, rgba(6,5,4,0.82));
  display: flex; justify-content: center;
}
.media-cap span {
  font-family: 'Cinzel', serif; font-weight: 600; font-size: 13px;
  letter-spacing: 0.18em; color: var(--ink-dim); text-transform: uppercase;
}

/* play badge on video thumbnails */
.thumb { position: relative; }
.thumb-play {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none;
  color: var(--ink);
}
.thumb-play svg { width: 18px; height: 18px; margin-left: 2px; filter: drop-shadow(0 1px 4px rgba(0,0,0,0.8)); }

/* ============================================================
   LIGHTBOX VIDEO PLAYER
   ============================================================ */
.lightbox {
  position: fixed; inset: 0; z-index: 400;
  background: radial-gradient(120% 100% at 50% 30%, rgba(12,11,9,0.96), rgba(4,4,3,0.98));
  backdrop-filter: blur(6px);
  display: grid; place-items: center;
  padding: clamp(20px, 5vh, 64px) clamp(20px, 6vw, 80px);
  animation: lb-in 0.32s var(--ease);
}
@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }
.lightbox-close {
  position: absolute; top: 22px; left: 50%; transform: translateX(-50%);
  width: 48px; height: 48px; border-radius: 50%;
  background: none; border: 1px solid var(--line); cursor: pointer;
  color: var(--metal-2); display: grid; place-items: center; z-index: 2;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.lightbox-close:hover { color: var(--ink); border-color: var(--accent); transform: translateX(-50%) rotate(90deg); }
.lightbox-close svg { width: 22px; height: 22px; }
.lightbox-stage {
  width: min(86vw, 1500px); display: flex; flex-direction: column;
  align-items: center; gap: 18px;
  animation: lb-rise 0.4s var(--ease);
}
@keyframes lb-rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.lightbox-frame {
  width: 100%; aspect-ratio: 16/9; max-height: 78vh;
  border-radius: 3px; overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 40px 120px -30px rgba(0,0,0,0.9);
  background: #000;
}
.lightbox-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
/* image lightbox — show the full picture, uncropped, at large size */
.lightbox.is-image .lightbox-stage { width: auto; }
.lightbox-frame.is-image {
  aspect-ratio: auto; width: auto; height: auto;
  max-width: min(92vw, 1600px); max-height: 82vh;
  background: #0b0a09;
}
.lightbox-frame.is-image img {
  width: auto; height: auto;
  max-width: min(92vw, 1600px); max-height: 82vh;
  object-fit: contain; display: block;
}
.lightbox-cap {
  font-family: 'Cinzel', serif; font-weight: 600; font-size: 13px;
  letter-spacing: 0.2em; color: var(--muted); text-transform: uppercase;
}

/* ============================================================
   TRAILER
   ============================================================ */
.trailer-wrap { z-index: 3; width: 100%; max-width: 1180px; }
.trailer-frame { aspect-ratio: 16/9; width: 100%; }
.trailer-frame iframe { width: 100%; height: 100%; border: 0; border-radius: 2px; display: block; }
.trailer-frame .ph { width: 100%; height: 100%; }
.trailer-ph { position: relative; cursor: pointer; }
.trailer-thumb { width: 100%; height: 100%; object-fit: cover; display: block; }
.trailer-ph::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(60% 60% at 50% 50%, rgba(0,0,0,0.15), rgba(0,0,0,0.55));
  transition: background 0.35s var(--ease);
}
.trailer-ph:hover::after { background: radial-gradient(60% 60% at 50% 50%, rgba(0,0,0,0.05), rgba(0,0,0,0.4)); }
.trailer-ph .play {
  position: absolute; inset: 0; display: grid; place-items: center; z-index: 2;
}
.play-btn {
  width: 96px; height: 96px; border-radius: 50%;
  border: 1px solid var(--line); background: rgba(10,9,8,0.55);
  display: grid; place-items: center; color: var(--ink);
  transition: all 0.35s var(--ease); backdrop-filter: blur(2px);
}
.trailer-ph:hover .play-btn { border-color: var(--accent); color: #fff; box-shadow: 0 0 40px -8px var(--accent-glow); transform: scale(1.05); }
.play-btn svg { width: 30px; height: 30px; margin-left: 5px; }

/* ============================================================
   CTA FINALE
   ============================================================ */
/* wishlist / finale section backdrop */
#wishlist { background-color: var(--bg); }
#wishlist::before {
  content: "";
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: url('assets/media/background2.jpg') center / cover no-repeat;
}
#wishlist::after {
  content: "";
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(120% 100% at 50% 45%, transparent 42%, rgba(6,5,4,0.74) 100%);
}

.cta-wrap { z-index: 3; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 30px; max-width: 760px; }
.cta-platforms { display: flex; gap: 28px; align-items: center; color: var(--muted); margin-top: 8px; }
.cta-platforms svg { height: 26px; width: auto; opacity: 0.7; transition: opacity .3s var(--ease); }
.cta-platforms a:hover svg { opacity: 1; }
.form-row { display: flex; gap: 12px; width: 100%; max-width: 520px; }
.form-row input {
  flex: 1; background: rgba(0,0,0,0.4); border: 1px solid var(--line);
  color: var(--ink); font-family: 'EB Garamond', serif; font-size: 16px;
  padding: 15px 18px; border-radius: 3px; outline: none; transition: border-color .3s var(--ease);
}
.form-row input::placeholder { color: var(--faint); }
.form-row input:focus { border-color: var(--accent); }
.form-note { font-size: 13px; color: var(--faint); }
.form-ok { color: var(--accent); font-family: 'Cinzel', serif; letter-spacing: 0.1em; }

.studio { font-family:'Cinzel',serif; font-size: 11px; letter-spacing: 0.3em; color: var(--faint); margin-top: 10px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1040px) {
  .sidenav { display: none; }
  .char-stage { grid-template-columns: 1fr; min-height: auto; gap: 30px; }
  .char-info { padding-left: 0; text-align: center; display: flex; flex-direction: column; align-items: center; order: 2; }
  .char-desc { margin-left: auto; margin-right: auto; }
  .char-render { order: 1; }
  .char-render .figure { width: min(80vw, 380px); height: 46vh; }
  .char-selector { justify-content: center; flex-wrap: wrap; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .frame-bar { height: 54px; gap: 10px; }
  .brandmark .bm-title { font-size: 14px; letter-spacing: 0.24em; }
  .wishlist-btn span, .brandmark .bm-sub { display: none; }
  .hero-title { font-size: clamp(42px, 13vw, 76px); }
  .thumbs { display: none; }
  .form-row { flex-direction: column; }
  .btn-primary { min-width: 0; width: 100%; }
}
