/* =============== THE GODS — three worlds, three architectures =============== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; color-scheme: light; }
body {
  background: #f7f4ec;
  color: #33302a;
  font-family: 'Palatino Linotype', Palatino, 'Book Antiqua', Georgia, 'Times New Roman', serif;
  line-height: 1.7;
}
a { color: inherit; text-decoration: none; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---------- identity typefaces ---------- */
.p-roman, body.w-roman { --disp: 'Trajan Pro', 'Optima', 'Palatino Linotype', Palatino, serif; }
.p-egyptian, body.w-egyptian, .scene-egyptian { --disp: 'Avenir Next', Futura, 'Century Gothic', 'Trebuchet MS', sans-serif; }
.p-norse, body.w-norse, .scene-norse { --disp: 'Copperplate', 'Copperplate Gothic Light', 'Avenir Next', Futura, 'Trebuchet MS', sans-serif; }

/* ---------- top navigation ---------- */
.topnav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid rgba(43,40,34,.10);
  background: rgba(247,244,236,.92);
}
.topnav .brand { font-variant: small-caps; letter-spacing: .45em; font-size: 15px; color: rgba(51,48,42,.8); }
.topnav .nav-links { display: flex; gap: 26px; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; }
.topnav .nav-links a { opacity: .55; transition: opacity .2s; }
.topnav .nav-links a:hover { opacity: 1; }

/* ---------- site hero ---------- */
.site-hero {
  padding: 90px 0 70px; text-align: center;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(201,162,39,.10), transparent 60%),
    #f7f4ec;
}
.site-hero .kicker { letter-spacing: .5em; text-transform: uppercase; font-size: 13px; color: #9a7b3f; margin-bottom: 18px; }
.site-hero h1 { font-size: clamp(46px, 8vw, 88px); font-variant: small-caps; letter-spacing: .14em; line-height: 1.1; color: #2b2822; }
.tri-band {
  width: 230px; height: 8px; margin: 34px auto 0;
  background: linear-gradient(90deg, #f3f0e9 0 33.3%, #e2cf9f 33.3% 66.6%, #c8d4dc 66.6% 100%);
  border-top: 1px solid rgba(43,40,34,.18);
  border-bottom: 1px solid rgba(43,40,34,.18);
}

/* ---------- edge fade: the paper of every image flows into its surface ---------- */
.art {
  display: block; width: 100%; aspect-ratio: 832 / 1024; object-fit: cover;
  -webkit-mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 6%, #000 94%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 6%, #000 94%, transparent 100%);
  mask-composite: intersect;
}

/* ---------- shared bits ---------- */
.rune-row { text-align: center; letter-spacing: .9em; font-size: 15px; padding: 18px 0; }
.fog { position: absolute; pointer-events: none; width: 70%; height: 240px; background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(222,235,240,.13), transparent 70%); }
.fog.f1 { top: 12%; left: -8%; animation: fog1 32s ease-in-out infinite alternate; }
.fog.f2 { top: 46%; right: -10%; animation: fog2 24s ease-in-out infinite alternate; }
@keyframes fog1 { from { transform: translateX(-4%); } to { transform: translateX(8%); } }
@keyframes fog2 { from { transform: translateX(5%); } to { transform: translateX(-7%); } }

/* ================= PORTALS — tall doors, text only on hover ================= */
.site-hero .gate-hint { margin-top: 26px; font-size: 13px; letter-spacing: .34em; text-transform: uppercase; color: rgba(51,48,42,.45); }
.portals { padding: 10px 0 70px; }
.portals.gates-only {
  min-height: 100svh; display: flex; align-items: center; justify-content: center;
  padding: 24px; position: relative; z-index: 1;
}
.gates .portal-grid { max-width: none; gap: clamp(18px, 3vw, 34px); grid-template-columns: repeat(3, minmax(0, min(340px, 42svh))); }
.portal-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---------- the sky behind the gates ---------- */
body.gates { background: linear-gradient(180deg, #c2d3e0 0%, #d5e0e8 40%, #e6ebee 75%, #eef0e9 100%); }
.sky { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.cloud {
  position: absolute; left: -45vw; width: 38vw; height: 130px;
  background:
    radial-gradient(ellipse 30% 62% at 28% 58%, rgba(255,255,255,.92), transparent 70%),
    radial-gradient(ellipse 34% 55% at 52% 42%, rgba(255,255,255,.88), transparent 72%),
    radial-gradient(ellipse 28% 58% at 74% 62%, rgba(255,255,255,.82), transparent 70%);
  filter: blur(7px);
  animation: drift linear infinite;
}
@keyframes drift {
  from { transform: translateX(0); }
  to   { transform: translateX(195vw); }
}
.cloud.c1 { top: 12%; opacity: .75; animation-duration: 130s; }
.cloud.c2 { top: 34%; width: 46vw; height: 150px; opacity: .6; filter: blur(10px); animation-duration: 170s; animation-delay: -60s; }
.cloud.c3 { top: 55%; width: 30vw; height: 110px; opacity: .55; filter: blur(5px); animation-duration: 95s; animation-delay: -30s; }
.cloud.c4 { top: 74%; width: 52vw; height: 170px; opacity: .5; filter: blur(12px); animation-duration: 200s; animation-delay: -120s; }
.cloud.c5 { top: 22%; width: 26vw; height: 96px; opacity: .45; filter: blur(4px); animation-duration: 80s; animation-delay: -15s; }
@media (prefers-reduced-motion: reduce) {
  .cloud { animation: none; }
  .cloud.c1 { left: 8vw; } .cloud.c2 { left: 38vw; } .cloud.c3 { left: 62vw; } .cloud.c4 { left: 18vw; } .cloud.c5 { left: 76vw; }
}
.portal {
  position: relative; display: block; aspect-ratio: 9 / 17; overflow: hidden;
  border: 1px solid rgba(43,40,34,.16);
  box-shadow: 0 26px 50px -28px rgba(20,25,30,.6);
}
.portal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s ease; }
.portal:hover img { transform: scale(1.05); }
.portal-info {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  padding: 34px 26px 26px;
  background: linear-gradient(180deg, transparent, rgba(18,22,26,.82) 58%);
  opacity: 0; transform: translateY(14px);
  transition: opacity .5s ease, transform .5s ease;
}
.portal:hover .portal-info { opacity: 1; transform: none; }
.portal .p-world { display: block; font-size: 11px; letter-spacing: .42em; text-transform: uppercase; margin-bottom: 8px; }
.portal h2 { font-size: 25px; color: #fff; letter-spacing: .08em; }
.portal p { font-size: 13.5px; color: rgba(255,255,255,.78); max-width: 92%; margin-top: 7px; line-height: 1.55; }
.portal .enter { display: block; margin-top: 12px; font-size: 11.5px; letter-spacing: .28em; text-transform: uppercase; }
.p-roman .p-world { color: #cfe0ee; }
.p-roman h2 { font-family: var(--disp); text-transform: uppercase; letter-spacing: .2em; }
.p-roman .enter { color: #cfe0ee; }
.p-egyptian .p-world { color: #ecd9a8; }
.p-egyptian h2 { font-family: var(--disp); }
.p-egyptian .enter { color: #e8c95a; }
.p-norse .p-world { color: #b9d4e4; }
.p-norse h2 { font-family: var(--disp); text-transform: uppercase; letter-spacing: .22em; }
.p-norse .enter { color: #9fc0d8; }

/* ================= WORLD SCENES ================= */
.scene { position: relative; overflow: hidden; }
.scene-fill { min-height: calc(100vh - 57px); display: flex; flex-direction: column; }
.scene-fill .temple, .scene-fill .monoliths, .scene-fill .carpets { margin-top: auto; margin-bottom: auto; }
.scene-head { position: relative; z-index: 3; text-align: center; padding: 52px 24px 6px; }
.scene-head .numeral { font-size: 14px; letter-spacing: .45em; text-transform: uppercase; margin-bottom: 10px; }
.scene-head h2 { font-size: clamp(32px, 5vw, 52px); line-height: 1.15; }
.scene-head .lede { margin-top: 14px; font-size: 15px; font-style: italic; }
.topnav .nav-links a.cur { opacity: 1; border-bottom: 1px solid currentColor; padding-bottom: 2px; }

/* ================= ROMAN: TEMPLE INTERIOR ================= */
.scene-roman {
  background-color: #241c12;
  background-image:
    linear-gradient(180deg, rgba(26,19,11,.66) 0, rgba(26,19,11,.22) 24%, rgba(26,19,11,0) 46%),
    radial-gradient(38% 32% at 5% 95%, rgba(255,146,54,.30), transparent 72%),
    radial-gradient(38% 32% at 95% 95%, rgba(255,146,54,.30), transparent 72%),
    url("../images/roman_wall_a.webp");
  background-size: 100% 100%;
  background-position: center;
  padding-bottom: 0;
}
.scene-roman h2::after { content: ""; display: block; width: 220px; height: 2px; margin: 16px auto 0; background: linear-gradient(90deg, transparent, #c89a4a, transparent); }

.scene-fill .carpets { margin-top: auto; margin-bottom: auto; }
.carpets {
  position: relative; z-index: 3;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 3.5vw;
  max-width: 1560px; width: 100%; margin: 0 auto; padding: 0 4vw;
}
.carpet {
  position: relative; display: block; color: inherit;
  filter: brightness(.97);
  transition: filter .4s ease;
}
.carpet-skin { display: block; width: 100%; height: auto; }
.god-art {
  position: absolute; left: 50%; bottom: 29%;
  width: 84%; transform: translateX(-50%);
  filter: saturate(1.08) contrast(1.02);
  pointer-events: none;
}
.carpet::after {
  content: ""; position: absolute; inset: -16% -14%;
  background: radial-gradient(50% 46% at 50% 44%, rgba(255,186,105,.30), transparent 72%);
  opacity: 0; transition: opacity .45s ease;
  pointer-events: none; z-index: -1;
}
.carpet:hover { filter: brightness(1.14); }
.carpet:hover::after { opacity: 1; }
.carpet-name {
  position: absolute; left: 0; right: 0; bottom: 8%;
  text-align: center;
  font-family: var(--disp); text-transform: uppercase; letter-spacing: .26em;
  font-size: 19px; font-weight: 700; color: #e8c87e;
}

/* fire bowls at either end of the hall: CSS fire after the codepen (blur + contrast, rising holes) */
.bowl { position: absolute; bottom: 0; width: clamp(170px, 15vw, 250px); height: 44%; z-index: 4; pointer-events: none; }
.bowl-left { left: 1.5%; }
.bowl-right { right: 1.5%; }
.bowl-glow {
  position: absolute; left: 50%; bottom: 0; z-index: 1;
  width: 360%; aspect-ratio: 1; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(255,150,54,.38), rgba(255,120,40,.14) 42%, transparent 70%);
  animation: ember-glow 3.4s ease-in-out infinite alternate;
}
@keyframes ember-glow { from { opacity: .72; } to { opacity: 1; } }
.bowl-part { position: absolute; bottom: 0; left: 0; width: 100%; }
.bowl-back { z-index: 2; }
.bowl-tint {
  position: absolute; bottom: 0; left: 0;
  width: 100%; aspect-ratio: 1 / 1;
  z-index: 2;
  background: url("../images/roman_bowl_back_orange.webp") center / 100% 100% no-repeat;
  animation: bowl-flicker 1.1s linear infinite;
}
@keyframes bowl-flicker {
  0%   { opacity: 1;   }
  12%  { opacity: .5;  }
  25%  { opacity: .95; }
  38%  { opacity: .4;  }
  50%  { opacity: 1;   }
  63%  { opacity: .55; }
  75%  { opacity: .9;  }
  88%  { opacity: .5;  }
  100% { opacity: 1;   }
}
.bowl-front { z-index: 4; }
.fire-slot { position: absolute; left: 50%; bottom: 28%; width: 110px; height: 220px; z-index: 3; transform: translateX(-50%) scale(var(--fs, 1)); transform-origin: 50% 100%; }
.fire {
  position: absolute; left: 50%; bottom: 0;
  width: 110px; height: 220px;
  transform: translateX(-50%);
  filter: blur(1px);
}
.particle {
  position: absolute; bottom: 0;
  width: 55px; height: 55px;
  border-radius: 50%;
  background-image: radial-gradient(#ff5000 20%, rgba(255, 80, 0, 0) 70%);
  mix-blend-mode: screen;
  opacity: 0;
  animation: rise 2s ease-in infinite;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(0) scale(1); }
  25%  { opacity: 1; }
  to   { opacity: 0; transform: translateY(-183px) scale(0); }
}

/* ================= EGYPTIAN: MONOLITHS IN THE DESERT ================= */
.scene-egyptian {
  background-color: #efe3c6;
  background-image:
    linear-gradient(180deg, rgba(250,243,226,.5) 0, rgba(250,243,226,0) 30%),
    url("../images/egypt_scene.webp");
  background-size: cover;
  background-position: center bottom;
  padding-bottom: 64px;
}
.scene-egyptian .dunes {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
  width: 100%; height: auto;
  display: block;
}
/* wind: short gust streaks travelling along wavy paths, right to left */
.wind {
  position: absolute; left: 0; right: 0; bottom: 0;
  width: 100%; height: 46%;
  z-index: 4; pointer-events: none;
}
.wind path {
  fill: none; stroke-width: 3; stroke-linecap: round;
  stroke-dasharray: 100 1200;
  animation: wind-dash 4.8s linear infinite;
}
.wind .w1 { stroke: rgba(255,250,238,.85); animation-duration: 3.4s; }
.wind .w2 { stroke: rgba(255,250,238,.6); animation-duration: 4.8s; animation-delay: -1.9s; }
.wind .w3 { stroke: rgba(255,250,238,.45); animation-duration: 6.2s; animation-delay: -3.2s; }
@keyframes wind-dash { from { stroke-dashoffset: 1300; } to { stroke-dashoffset: 0; } }
/* palm bush tucked behind the front dune, swaying in the wind */
.palm-bush {
  position: absolute; right: 4%; bottom: 10%;
  width: clamp(150px, 15vw, 320px);
  z-index: 2;
  transform-origin: 50% 96%;
  animation: palm-sway 6.5s ease-in-out infinite alternate;
}
@keyframes palm-sway {
  from { transform: rotate(-1.2deg); }
  to   { transform: rotate(1.5deg); }
}
.scene-egyptian .scene-head .numeral { color: #a07d24; font-family: var(--disp); }
.scene-egyptian .lede { color: rgba(58,47,29,.75); }
.scene-egyptian h2 { font-family: var(--disp); letter-spacing: .1em; color: #3a2f1d; text-shadow: 0 1px 0 rgba(255,250,235,.6); }
.scene-egyptian h2::after { content: ""; display: block; width: 170px; height: 2px; margin: 14px auto 0; background: repeating-linear-gradient(90deg, #b8912f 0 14px, transparent 14px 22px); }

.monoliths {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px;
  width: 100%; max-width: 1150px; margin: 46px auto 0; padding: 0 24px; align-items: end;
}
.scene-egyptian .monoliths { margin-top: auto; margin-bottom: 8px; }
.monolith {
  position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  width: 100%; height: 620px;
  padding: 0;
  transition: transform .25s ease;
}
.obelisk {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain;
  filter: saturate(1.12) contrast(1.06) drop-shadow(0 14px 20px rgba(70,45,15,.45));
}
.monolith { transform: translateY(var(--lift, 0px)) rotate(var(--tilt, 0deg)); transform-origin: 50% 92%; }
.monolith:hover { transform: translateY(calc(var(--lift, 0px) - 6px)) rotate(var(--tilt, 0deg)); }
.monolith:nth-child(even) { margin-top: 16px; }
.monolith:nth-child(1) { --tilt: -1.8deg; --lift: 42px; }
.monolith:nth-child(2) { --tilt: 1.4deg; --lift: 42px; }
.monolith:nth-child(3) { --tilt: -0.7deg; --lift: -5px; }
.monolith:nth-child(4) { --tilt: 2.1deg; --lift: 30px; }
.monolith:nth-child(5) { --tilt: -1.3deg; --lift: 30px; }
.mon-anims { display: none; }

/* ================= NORSE: RUNESTONES IN THE FOREST ================= */
.scene-norse {
  background-color: #1a242b;
  background-image:
    linear-gradient(180deg, rgba(18,28,34,.3) 0, rgba(10,18,22,.35) 55%, rgba(6,12,14,.6) 100%),
    url("../images/norse_scene.webp");
  background-size: cover;
  background-position: center 40%;
  padding-bottom: 0;
}
.scene-norse .scene-head .numeral { color: #9fc0d8; font-family: var(--disp); letter-spacing: .5em; }
.scene-norse .scene-head h2 {
  font-family: var(--disp); text-transform: uppercase; letter-spacing: .26em; color: #eaf2f6;
  text-shadow: 0 1px 0 rgba(0,0,0,.55), 0 2px 18px rgba(120,170,200,.3);
  font-size: clamp(24px, 3.6vw, 38px);
}
.scene-norse .lede { color: rgba(207,224,234,.7); }
.scene-norse .rune-row { color: rgba(159,192,216,.5); text-shadow: 0 1px 0 rgba(0,0,0,.5); padding-bottom: 6px; }

/* Norse gallery: the whole painting lives in a stage with the canvas's own
   aspect ratio, centered and bottom-anchored. On wide screens the stage is
   narrower than the viewport (forest shows around it, trunks frame the sides);
   on narrow screens it is shorter (forest shows above). Every same-canvas
   layer fills the stage, so the layers stay aligned at any screen ratio */
.stage {
  position: absolute; left: 50%; bottom: 0;
  transform: translateX(-50%);
  height: 100%;
  aspect-ratio: 16 / 10;
  max-width: 100%;
  z-index: 2;
}
.cave-fore, .cave-gods {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.cave-fore { z-index: 3; }
.cave-gods { z-index: 2; }
/* the dark cavern interiors act as a cover over the baked caverns;
   hovering an arch fades out that half of it */
.covers {
  position: absolute; inset: 0;
  z-index: 4; pointer-events: none;
}
.cover {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  transition: opacity .8s ease;
  -webkit-mask-image: linear-gradient(90deg, black 50%, transparent 50.5%);
  mask-image: linear-gradient(90deg, black 50%, transparent 50.5%);
}
.cover-odin {
  -webkit-mask-image: linear-gradient(90deg, transparent 49.5%, black 50%);
  mask-image: linear-gradient(90deg, transparent 49.5%, black 50%);
}
.arch-freya:hover ~ .covers .cover-freya,
.arch-odin:hover ~ .covers .cover-odin { opacity: .12; }
.stage:has(.arch-freya:hover) .cave-gods,
.stage:has(.arch-odin:hover) .cave-gods { animation: flicker 2.4s linear infinite; }
@keyframes flicker {
  0%   { opacity: 1; }
  8%   { opacity: .93; }
  14%  { opacity: .99; }
  22%  { opacity: .9; }
  30%  { opacity: .97; }
  41%  { opacity: .94; }
  52%  { opacity: 1; }
  61%  { opacity: .92; }
  72%  { opacity: .98; }
  84%  { opacity: .95; }
  100% { opacity: 1; }
}
.scene-norse .scene-head { position: relative; z-index: 6; }

.arch {
  position: absolute;
  top: 38%; height: 52%;
  z-index: 5;
  display: block; text-decoration: none;
}
/* centered on the baked caverns (30% / 71% across the painting) */
.arch-freya { left: 19%; width: 22%; }
.arch-odin  { left: 60%; width: 22%; }
.arch .glow {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 62% 48% at 50% 62%, rgba(255,176,84,.5), rgba(255,150,60,.22) 55%, transparent 78%),
    radial-gradient(ellipse 100% 92% at 50% 55%, rgba(255,190,110,.18), transparent 70%);
  mix-blend-mode: screen;
  opacity: 0;
  transition: opacity .7s ease;
}
.arch:hover .veil { opacity: .22; }
.arch:hover .glow { opacity: 1; animation: candle 3.2s ease-in-out .35s infinite; }
@keyframes candle {
  0%, 100% { filter: brightness(1); }
  50%      { filter: brightness(1.18); }
}
.arch-title {
  position: absolute; left: 0; right: 0; top: 29%;
  text-align: center;
  font-family: var(--disp); text-transform: uppercase;
  letter-spacing: .34em; font-size: 26px;
  color: rgba(234,240,244,.5);
  text-shadow: 0 1px 0 rgba(0,0,0,.5), 0 2px 8px rgba(0,0,0,.55);
  transition: color .5s ease;
  pointer-events: none;
}
.arch:hover .arch-title { color: rgba(240,245,248,.92); }

/* framing tree trunks on the left and right edges */
.trunk {
  position: absolute; top: 0; bottom: 0;
  width: 18%;
  z-index: 5; pointer-events: none;
  background: url("../images/trunk.webp") center / cover no-repeat;
}
.trunk-left  { left: 0; }
.trunk-right { right: 0; transform: scaleX(-1); }

.leaves { position: absolute; inset: 0; z-index: 7; pointer-events: none; }
.leaf {
  position: absolute; top: -5%;
  width: 46px; height: auto;
  opacity: 0;
  animation: leaf-fall var(--dur, 18s) linear var(--delay, 0s) infinite;
}
@keyframes leaf-fall {
  0%   { transform: translate3d(0, -5vh, 0) rotate(0deg); opacity: 0; }
  7%   { opacity: .85; }
  25%  { transform: translate3d(5vw, 25vh, 0) rotate(130deg); }
  50%  { transform: translate3d(-4vw, 52vh, 0) rotate(250deg); }
  75%  { transform: translate3d(4vw, 80vh, 0) rotate(390deg); }
  93%  { opacity: .75; }
  100% { transform: translate3d(-3vw, 108vh, 0) rotate(540deg); opacity: 0; }
}

/* ================= GOD PAGES ================= */
.god-hero {
  position: relative; text-align: center; padding: 90px 0 70px;
  background:
    radial-gradient(ellipse 90% 100% at 50% 0%, var(--glow), transparent 65%),
    radial-gradient(ellipse 130% 90% at 50% 135%, var(--world-wash, transparent), transparent 65%),
    var(--hero-base, #f7f4ec);
  border-bottom: 1px solid var(--accent);
  overflow: hidden;
}
.god-hero .watermark {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 300px; opacity: .07; color: var(--accent); pointer-events: none; user-select: none;
}
.god-hero .section-tag {
  display: inline-block; margin-bottom: 20px; padding: 6px 18px;
  border: 1px solid var(--accent); color: var(--accent);
  font-size: 12px; letter-spacing: .3em; text-transform: uppercase;
}
.god-hero h1 {
  font-size: clamp(48px, 9vw, 92px); font-variant: small-caps; letter-spacing: .1em; line-height: 1.05;
  color: #2b2822; text-shadow: 0 2px 34px var(--glow);
}
.god-hero .epithet { margin-top: 18px; color: var(--accent); letter-spacing: .22em; text-transform: uppercase; font-size: 14px; }

.god-main {
  display: grid; grid-template-columns: 330px minmax(0,1fr) 300px;
  gap: 44px; padding: 60px 0 80px;
}
.portrait { position: sticky; top: 26px; align-self: start; }
.portrait-frame { aspect-ratio: 4 / 5; display: flex; align-items: center; justify-content: center; background: transparent; }
.portrait-frame img {
  width: 100%; height: 100%; object-fit: cover;
  -webkit-mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 6%, #000 94%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 6%, #000 94%, transparent 100%);
  mask-composite: intersect;
}

.god-article h2 {
  font-size: 30px; font-variant: small-caps; letter-spacing: .08em; color: #2b2822;
  margin-bottom: 18px; padding-bottom: 10px; border-bottom: 1px solid rgba(43,40,34,.10);
}
.god-article h2::before { content: ""; display: inline-block; width: 34px; height: 2px; background: var(--accent); margin-right: 14px; vertical-align: middle; }
.god-article h3 { font-size: 19px; color: var(--accent); margin: 30px 0 10px; letter-spacing: .04em; }
.god-article p { margin-bottom: 16px; color: rgba(51,48,42,.92); }
.god-article p.note { font-size: 14px; color: rgba(51,48,42,.55); font-style: italic; }

.chips { display: flex; flex-wrap: wrap; gap: 9px; margin: 4px 0 26px; }
.chip {
  padding: 7px 15px; font-size: 12.5px; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid var(--accent); color: var(--accent);
  background: var(--glow); border-radius: 2px;
}

.facts {
  border: 1px solid rgba(43,40,34,.10);
  background: #fff;
  box-shadow: 0 12px 32px -20px rgba(43,40,34,.22);
  padding: 26px 24px; position: sticky; top: 26px;
}
.facts h4 { font-size: 13px; letter-spacing: .3em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
.fact { display: flex; gap: 12px; padding: 11px 0; border-top: 1px solid rgba(43,40,34,.08); font-size: 14px; }
.fact:first-of-type { border-top: none; }
.fact .k { flex: 0 0 92px; letter-spacing: .08em; text-transform: uppercase; font-size: 11.5px; color: rgba(51,48,42,.45); padding-top: 2px; }
.fact .v { color: rgba(51,48,42,.9); }

.page-footer { border-top: 1px solid rgba(43,40,34,.10); padding: 30px 0 44px; font-size: 13px; color: rgba(51,48,42,.5); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-footer a { color: var(--accent, #9a7b3f); }

/* ---------- per-god accent washes ---------- */
body.g-juno     { --accent:#3f8fc4; --accent-bright:#7cc4ea; --glow:rgba(63,143,196,.16); }
body.g-jupiter  { --accent:#b8912f; --accent-bright:#e8c95a; --glow:rgba(201,162,39,.16); }
body.g-mars     { --accent:#b3382c; --accent-bright:#e06a52; --glow:rgba(179,56,44,.14); }
body.g-maia     { --accent:#6d9a49; --accent-bright:#a8d182; --glow:rgba(121,168,84,.16); }
body.g-vulcanus { --accent:#c0561a; --accent-bright:#ff8c42; --glow:rgba(211,84,0,.14); }
body.g-ptah     { --accent:#3f6bb5; --accent-bright:#7fa3e0; --glow:rgba(63,107,181,.16); }
body.g-isis     { --accent:#2a9d8f; --accent-bright:#5fd0c0; --glow:rgba(42,157,143,.15); }
body.g-osiris   { --accent:#4f7942; --accent-bright:#8cb57c; --glow:rgba(79,121,66,.16); }
body.g-horus    { --accent:#a8842a; --accent-bright:#ecc267; --glow:rgba(201,155,47,.15); }
body.g-sekhmet  { --accent:#c0392b; --accent-bright:#e8786a; --glow:rgba(192,57,43,.14); }
body.g-freya    { --accent:#8a68b5; --accent-bright:#c5a9e8; --glow:rgba(155,123,191,.16); }
body.g-odin     { --accent:#55647a; --accent-bright:#93a3ba; --glow:rgba(85,100,122,.16); }

/* ================= ROMAN GOD PAGE ================= */
body.w-roman {
  --world-wash: rgba(122,158,192,.12); --hero-base: #ffffff;
  background:
    repeating-linear-gradient(90deg, rgba(125,105,75,.03) 0 2px, transparent 2px 140px),
    linear-gradient(180deg, #ffffff 0%, #f3f0e9 100%);
}
body.w-roman .topnav { background: rgba(255,255,255,.90); }
body.w-roman .god-hero {
  background:
    radial-gradient(ellipse 85% 95% at 50% -25%, rgba(141,178,210,.18), transparent 65%),
    #ffffff;
  border-bottom: 1px solid rgba(90,80,60,.18);
}
body.w-roman .god-hero h1 { font-family: var(--disp); font-variant: normal; text-transform: uppercase; letter-spacing: .3em; font-size: clamp(38px, 7vw, 72px); }
body.w-roman .god-hero .epithet { letter-spacing: .34em; }
body.w-roman .god-hero .section-tag { background: rgba(255,255,255,.6); }
body.w-roman .god-article h2 { font-family: var(--disp); font-variant: normal; text-transform: uppercase; letter-spacing: .24em; font-size: 26px; }
body.w-roman .god-article h3 { font-family: var(--disp); text-transform: uppercase; letter-spacing: .14em; font-size: 15px; }
body.w-roman .chip { border-radius: 0; background: transparent; box-shadow: inset 0 0 0 1px var(--accent); text-shadow: 0 1px 0 #fff; letter-spacing: .2em; }
body.w-roman .god-main { grid-template-columns: 280px 34px minmax(0,1fr) 34px 270px; }
body.w-roman .facts {
  background: #fff; border: 1px solid rgba(90,80,60,.18);
  box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 4px rgba(90,80,60,.10), 0 14px 30px -22px rgba(60,50,30,.25);
}
body.w-roman .facts h4 { font-family: var(--disp); letter-spacing: .3em; }
body.w-roman .facts .fact .v { font-variant: small-caps; letter-spacing: .04em; }

/* ================= EGYPTIAN GOD PAGE ================= */
body.w-egyptian {
  --world-wash: rgba(184,145,47,.12); --hero-base: #f8efdc; color: #3a2f1d;
  background:
    radial-gradient(circle at 15% 18%, rgba(31,120,140,.05) 0 240px, transparent 250px),
    radial-gradient(circle at 85% 72%, rgba(184,145,47,.07) 0 260px, transparent 270px),
    linear-gradient(180deg, #f8efdc 0%, #f0e2c4 100%);
}
body.w-egyptian .topnav { background: rgba(248,239,220,.92); }
body.w-egyptian .god-hero {
  background:
    radial-gradient(ellipse 90% 100% at 50% 0%, var(--glow), transparent 60%),
    linear-gradient(180deg, #f9f0da, #f2e4c6);
  border-bottom: 3px solid rgba(58,47,29,.5);
}
body.w-egyptian .god-hero h1 { font-family: var(--disp); font-variant: normal; letter-spacing: .14em; text-transform: none; }
body.w-egyptian .god-article h2 {
  font-family: var(--disp); font-variant: normal; letter-spacing: .1em; text-transform: none;
  border-bottom: 3px solid rgba(58,47,29,.7); position: relative;
}
body.w-egyptian .god-article h2::before { width: 0; margin: 0; }
body.w-egyptian .god-article h2::after { content: ""; position: absolute; left: 0; bottom: -7px; width: 60px; height: 3px; background: #b8912f; }
body.w-egyptian .god-article h3 { font-family: var(--disp); text-transform: uppercase; letter-spacing: .12em; font-size: 15px; }
body.w-egyptian .chip { border-radius: 999px; border: 2px solid #8a6b2f; background: rgba(253,247,231,.75); color: #6d5518; font-family: var(--disp); letter-spacing: .06em; text-transform: none; font-size: 13px; }
body.w-egyptian .facts {
  background: #fdf7e7; border: 2px solid rgba(58,47,29,.7);
  box-shadow: 5px 5px 0 rgba(58,47,29,.15);
}
body.w-egyptian .facts::before {
  content: ""; display: block; height: 16px; margin: -26px -24px 16px;
  background: url("../images/egyptian_border.webp") center / auto 100% repeat-x; opacity: .8;
}
body.w-egyptian .facts h4 { border-bottom: 2px solid rgba(58,47,29,.55); padding-bottom: 8px; font-family: var(--disp); letter-spacing: .14em; }
body.w-egyptian .facts .fact { border-top-color: rgba(58,47,29,.15); }

/* ================= NORSE GOD PAGE ================= */
body.w-norse {
  --world-wash: rgba(80,105,122,.16); --hero-base: #2b3941; color: #d5e1e8;
  background:
    radial-gradient(ellipse 100% 34% at 50% 0%, rgba(210,226,236,.28), transparent 70%),
    linear-gradient(180deg, #2b3941 0%, #22303a 45%, #1c272f 100%);
}
body.w-norse .topnav { background: rgba(28,39,47,.88); border-bottom-color: rgba(150,185,205,.14); }
body.w-norse .topnav .brand, body.w-norse .topnav .nav-links a { color: #cfe0ea; }
body.w-norse .god-hero {
  background:
    radial-gradient(ellipse 90% 110% at 50% 0%, var(--glow), transparent 65%),
    linear-gradient(180deg, #31424c, #26343d);
  border-bottom: 1px solid rgba(150,185,205,.22);
}
body.w-norse .god-hero .watermark { color: #9fc0d8; opacity: .10; }
body.w-norse .god-hero h1 {
  font-family: var(--disp); font-variant: normal; text-transform: uppercase; letter-spacing: .3em;
  color: #eef5f8; text-shadow: 0 2px 26px rgba(140,180,210,.3), 0 1px 0 rgba(0,0,0,.6);
}
body.w-norse .god-hero .epithet { color: #9fc0d8; letter-spacing: .3em; text-shadow: 0 1px 0 rgba(0,0,0,.5); }
body.w-norse .god-hero .section-tag { border-color: rgba(159,192,216,.4); color: #9fc0d8; }
body.w-norse .god-article {
  position: relative;
  background: linear-gradient(170deg, rgba(54,70,80,.5), rgba(38,51,59,.55));
  border: 1px solid rgba(150,185,205,.16);
  border-radius: 200px 200px 6px 6px / 120px 120px 6px 6px;
  padding: 54px 42px 44px;
  box-shadow: inset 0 2px 10px rgba(0,0,0,.3);
}
body.w-norse .god-article h2 {
  font-family: var(--disp); font-variant: normal; text-transform: uppercase; letter-spacing: .22em; font-size: 24px;
  color: #e8f0f4; text-shadow: 0 1px 0 rgba(0,0,0,.55);
  border-bottom-color: rgba(150,185,205,.22);
}
body.w-norse .god-article h2::before { background: #9fc0d8; }
body.w-norse .god-article h3 {
  font-family: var(--disp); text-transform: uppercase; letter-spacing: .14em; font-size: 14px; color: #9fc0d8;
  text-shadow: 0 1px 0 rgba(0,0,0,.5);
}
body.w-norse .god-article p { color: rgba(213,225,232,.85); }
body.w-norse .chip {
  border-radius: 0; border: 1px solid rgba(159,192,216,.45); color: #cfe0ea;
  background: rgba(255,255,255,.05); letter-spacing: .14em;
  box-shadow: inset 0 1px 0 rgba(0,0,0,.35);
}
body.w-norse .facts {
  background: linear-gradient(165deg, #2e3d46, #26333c);
  border: 1px solid rgba(150,185,205,.25);
  box-shadow: inset 0 2px 8px rgba(0,0,0,.4), inset 0 -1px 0 rgba(255,255,255,.05), 0 16px 34px -20px rgba(0,0,0,.5);
}
body.w-norse .facts h4 { color: #9fc0d8; text-shadow: 0 1px 0 rgba(0,0,0,.5); font-family: var(--disp); }
body.w-norse .facts .fact { border-top-color: rgba(150,185,205,.14); }
body.w-norse .facts .fact .k { color: rgba(207,224,234,.45); }
body.w-norse .facts .fact .v { color: rgba(213,225,232,.9); text-shadow: 0 1px 0 rgba(0,0,0,.4); }
body.w-norse .rune-row { color: rgba(159,192,216,.45); text-shadow: 0 1px 0 rgba(0,0,0,.5); }
body.w-norse .rr-bot { padding: 8px 0 26px; }
body.w-norse .portrait-frame img { filter: drop-shadow(0 16px 28px rgba(0,0,0,.45)); }
body.w-norse .page-footer { border-top-color: rgba(150,185,205,.18); }
body.w-norse .page-footer span { color: rgba(207,224,234,.5); }
body.w-norse .page-footer a { color: #9fc0d8; }

/* ---------- decorative elements used on god pages ---------- */
.meander {
  height: 14px; margin: 0 24px; opacity: .5;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='12'%3E%3Cpath d='M0 11 H16 V1 H4 V7 H10' fill='none' stroke='%239a7b3f' stroke-width='1.5'/%3E%3C/svg%3E") repeat-x center / 20px 12px;
}
.band-x {
  height: 80px; opacity: .8;
  background: url("../images/egyptian_border.webp") center / auto 100% repeat-x;
  border-top: 1px solid rgba(58,47,29,.25);
  border-bottom: 1px solid rgba(58,47,29,.25);
}
.pediment { position: relative; width: min(340px, 72vw); height: 118px; margin: 6px auto 26px; }
.pediment::before { content: ""; position: absolute; inset: 0; background: #ffffff; clip-path: polygon(50% 0, 100% 100%, 0 100%); filter: drop-shadow(0 2px 3px rgba(90,80,60,.20)); }
.pediment::after { content: ""; position: absolute; left: -26px; right: -26px; bottom: -12px; height: 12px; background: #fff; border: 1px solid rgba(90,80,60,.22); }
.pediment span { position: absolute; bottom: 16px; width: 100%; text-align: center; font-size: 40px; opacity: .75; }
.pyramid-horizon { position: absolute; left: 0; right: 0; bottom: 0; height: 110px; overflow: hidden; pointer-events: none; }
.pyramid-horizon::before, .pyramid-horizon::after { content: ""; position: absolute; bottom: 0; border-style: solid; border-color: transparent; }
.pyramid-horizon::before { left: 50%; transform: translateX(-50%); border-width: 0 170px 105px 170px; border-bottom-color: rgba(160,125,36,.20); }
.pyramid-horizon::after { left: 16%; border-width: 0 95px 62px 95px; border-bottom-color: rgba(160,125,36,.14); }
.pyramid-horizon .sun { position: absolute; right: 14%; bottom: 62px; width: 42px; height: 42px; border: 2px solid rgba(184,145,47,.55); border-radius: 50%; background: radial-gradient(circle, rgba(232,201,90,.25), transparent 70%); }
.col { display: none; position: relative; }
.col::before { content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 36px; height: 10px; background: #fff; border: 1px solid rgba(90,80,60,.22); }
.col::after {
  content: ""; position: absolute; top: 10px; bottom: 12px; left: 50%; transform: translateX(-50%); width: 13px;
  background: repeating-linear-gradient(90deg, #e9e3d6 0 2px, #fdfcf9 2px 4px, #e2dbcc 4px 5px);
  border-left: 1px solid rgba(90,80,60,.12); border-right: 1px solid rgba(90,80,60,.12);
}
body.w-roman .col { display: block; background: linear-gradient(#fff, #fff) center bottom / 36px 10px no-repeat; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .columns { grid-template-columns: repeat(3, 1fr); }
  .columns .temple-column:nth-child(4), .columns .temple-column:nth-child(5) { margin-top: 26px; }
  .monoliths { grid-template-columns: repeat(3, 1fr); }
  .god-main { grid-template-columns: 280px minmax(0,1fr); }
  body.w-roman .god-main { grid-template-columns: 250px 30px minmax(0,1fr); }
  body.w-roman .col.c2 { display: none; }
  .facts { position: static; grid-column: 1 / -1; max-width: 640px; }
  body.w-norse .god-article { padding: 40px 28px 36px; }
}
@media (max-width: 1560px) {
  .scene-roman .fire-slot { --fs: 0.85; }
}
@media (max-width: 1280px) {
  .scene-roman .fire-slot { --fs: 0.7; }
}
@media (max-width: 760px) {
  .columns { grid-template-columns: repeat(2, 1fr);   .carpets { grid-template-columns: repeat(2, 1fr); gap: 22px; max-width: 620px; padding: 0 6vw; }
  .carpet-name { font-size: 16px; }
  .bowl { width: 120px; height: 36%; }
  .fire-slot { bottom: 32%; --fs: 0.55; }
}
  .columns .temple-column:nth-child(4) { margin-top: 0; }
  .monoliths { grid-template-columns: repeat(2, 1fr); }
  .leaf { width: 32px; }
  .arch-title { font-size: 20px; letter-spacing: .24em; }
  .trunk { display: none; }
  .palm-bush { width: 120px; right: 2%; }
  .god-main { grid-template-columns: 1fr; }
  body.w-roman .god-main { grid-template-columns: 1fr; }
  body.w-roman .col { display: none; }
  .portrait { position: static; max-width: 380px; margin: 0 auto; }
  .topnav .nav-links { display: none; }
  body.w-norse .god-article { border-radius: 90px 90px 6px 6px / 60px 60px 6px 6px; padding: 30px 20px 30px; }
}
@media (max-width: 620px) {
  .portal-grid, body.gates .portal-grid { grid-template-columns: 1fr; max-width: 460px; }
  .portal { aspect-ratio: 4 / 5; }
}
@media (max-width: 480px) {
  .columns { grid-template-columns: 1fr; }
  .monoliths { grid-template-columns: 1fr; }
}
