/* ─── PANTHEXVS 4K V3 Travertine Cover & Minimalist Folio Architecture ─── */
.home-sanctuary {
  position: relative;
  min-height: 100vh;
  width: 100%;
  background: #0C0B0A;
  color: #F4EFE6;
  overflow-x: hidden;
  overflow-y: auto;
}

.home-hero {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.home-bg-layer {
  position: absolute;
  inset: -2.5%;
  background-image: url('/assets/athens-sanctuary-v3.jpg');
  background-size: cover;
  background-position: center 45%;
  transform: translate3d(var(--px, 0px), var(--py, 0px), 0) scale(1.03);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
  pointer-events: none;
}

@keyframes sanctuaryBreathe {
  0%, 100% {
    opacity: 0.36;
    transform: scale(1);
  }
  50% {
    opacity: 0.72;
    transform: scale(1.045);
  }
}

.home-breath-light {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 38% 34% at 50% 48%, rgba(232, 198, 130, 0.28) 0%, rgba(212, 175, 106, 0.08) 46%, transparent 74%),
    linear-gradient(125deg, transparent 22%, rgba(242, 214, 152, 0.09) 48%, transparent 72%);
  mix-blend-mode: screen;
  animation: sanctuaryBreathe 7.5s ease-in-out infinite;
  pointer-events: none;
}

.home-scrim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 72% 45% at 50% 18%, rgba(10, 9, 8, 0.62) 0%, rgba(10, 9, 8, 0.14) 68%),
    linear-gradient(180deg, rgba(10, 9, 8, 0.86) 0%, rgba(10, 9, 8, 0.16) 36%, rgba(10, 9, 8, 0.18) 68%, rgba(10, 9, 8, 0.96) 100%);
  pointer-events: none;
}

.home-topbar {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2.6rem;
}

.home-brand {
  display: flex;
  align-items: center;
  gap: 0.72rem;
}

/* Shared geometric seal: fine incised line, square box, optically centred, never filtered */
.brand-seal-mark, .home-crest-mark {
  display: grid; place-items: center; flex: none; aspect-ratio: 1 / 1; line-height: 0; color: #E6C88A;
  stroke-width: 1.1; stroke-linecap: round; stroke-linejoin: round; shape-rendering: geometricPrecision; filter: none;
}
.brand-seal-mark { width: 1.95rem; }
.home-crest-mark { width: clamp(3.2rem, 4.6vw, 4.2rem); margin: 0 auto 0.9rem; }
.brand-seal-mark svg, .home-crest-mark svg { display: block; width: 100%; height: 100%; overflow: visible; }

.home-wordmark {
  font-family: "Cinzel", Georgia, serif;
  font-size: 1.06rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: #EBD4A4;
}

.home-nav { display: flex; align-items: center; gap: 1.45rem; }

.home-nav-link {
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(244, 239, 230, 0.82);
  transition: color 0.14s ease;
}
.home-nav-link:hover { color: #E6C88A; }

.home-lang-pill {
  padding: 0.28rem 0.62rem;
  border: 1px solid rgba(212, 175, 106, 0.34);
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #E6C88A;
  background: rgba(12, 11, 10, 0.52);
}

.home-lang-pill:hover {
  background: rgba(212, 175, 106, 0.16);
}

/* Shifted cleanly upward into the dark coffered upper spandrel */
.home-centerpiece {
  position: relative;
  z-index: 4;
  max-width: 48rem;
  margin: 0 auto auto;
  padding: 2.2vh 1.5rem 0;
  text-align: center;
}

.home-title {
  margin: 0;
  font-family: "Cinzel", "Times New Roman", Georgia, serif;
  font-size: clamp(3.15rem, 5vw, 4.75rem);
  font-weight: 700;
  letter-spacing: 0.24em;
  background: linear-gradient(180deg, #FFF7E4 0%, #E7C88B 48%, #B28844 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 8px 26px rgba(0, 0, 0, 0.85)) drop-shadow(0 1px 1px rgba(0, 0, 0, 0.9));
}

.home-aphorism {
  margin: 0.68rem auto 0;
  font-family: "Cormorant Garamond", "Noto Serif SC", Georgia, serif;
  font-size: 1.28rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: rgba(244, 232, 206, 0.92);
  text-shadow: 0 3px 16px rgba(0, 0, 0, 0.88);
}

.home-doors {
  margin-top: 1.45rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}
:where(.home-doors a) { color: inherit; text-decoration: none; }

.home-door-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  min-height: 2.5rem; padding: 0.6rem 1.35rem;
  border: 1px solid rgba(212, 175, 106, 0.46); border-radius: 0.6rem;
  background: linear-gradient(180deg, rgba(40, 36, 31, 0.66) 0%, rgba(18, 16, 14, 0.76) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 236, 196, 0.1), 0 10px 26px rgba(0, 0, 0, 0.5);
  -webkit-backdrop-filter: blur(10px) saturate(1.15); backdrop-filter: blur(10px) saturate(1.15);
  font-family: inherit; font-size: 0.86rem; font-weight: 600; letter-spacing: 0.06em; line-height: 1.2;
  color: #EBD3A0; text-decoration: none; cursor: pointer;
  transition: background 0.22s ease, border-color 0.22s ease, color 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease;
}
.home-door-secondary:hover, .home-door-secondary:focus-visible {
  color: #FBEFD2; text-decoration: none; border-color: rgba(230, 200, 138, 0.82); transform: translateY(-1px);
  background: linear-gradient(180deg, rgba(58, 51, 42, 0.74) 0%, rgba(28, 24, 20, 0.8) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 236, 196, 0.2), 0 14px 30px rgba(0, 0, 0, 0.56), 0 0 0 1px rgba(212, 175, 106, 0.2);
}
.home-door-secondary:focus-visible { outline: 2px solid rgba(230, 200, 138, 0.9); outline-offset: 2px; }
[data-theme="light"] .home-door-secondary { color: #5A3D17; border-color: rgba(138, 104, 52, 0.5); background: linear-gradient(180deg, rgba(255, 251, 242, 0.84) 0%, rgba(240, 230, 210, 0.8) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 8px 20px rgba(138, 104, 52, 0.16); }
[data-theme="light"] .home-door-secondary:hover, [data-theme="light"] .home-door-secondary:focus-visible { color: #3D2910; border-color: rgba(107, 75, 31, 0.78); background: linear-gradient(180deg, #FFFDF7 0%, rgba(246, 237, 219, 0.94) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), 0 12px 26px rgba(138, 104, 52, 0.24); }
@media (prefers-reduced-motion: reduce) { .home-door-secondary { transition: none; } .home-door-secondary:hover { transform: none; } }

.home-footstrip {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.55rem;
  padding: 1.05rem 2rem 1.35rem;
  font-size: 0.74rem;
  color: rgba(244, 232, 206, 0.88);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.92);
  flex-wrap: wrap;
}
[data-theme="light"] .home-footstrip { text-shadow: 0 1px 0 rgba(255, 250, 238, 0.85); }

.home-foot-dot { color: #D4AF6A; }

.home-codex {
  position: relative;
  background: #0C0B0A;
  border-top: 1px solid rgba(212, 175, 106, 0.24);
  padding: 4.2rem 2.4rem 4.8rem;
}

.codex-grid {
  max-width: 68rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.2rem;
}

.codex-folio { border-top: 2px solid rgba(212, 175, 106, 0.45); padding-top: 1.25rem; display: flex; flex-direction: column; gap: 0.72rem; }
.folio-numeral { font-family: "Cinzel", Georgia, serif; font-size: 0.74rem; letter-spacing: 0.22em; color: #D4AF6A; }
.folio-title { margin: 0; font-family: "Cormorant Garamond", "Noto Serif SC", Georgia, serif; font-size: 1.36rem; font-weight: 700; color: #FAF5EC; }
.folio-copy { margin: 0; font-size: 0.85rem; line-height: 1.72; color: #B0A494; }
.folio-action { margin-top: auto; padding: 0.45rem 0 0.14rem; align-self: flex-start; font-size: 0.8rem; font-weight: 600; color: #E6C88A; border-bottom: 1px solid rgba(230, 200, 138, 0.38); }

.home-uaf-whisper {
  max-width: 68rem; margin: 3.2rem auto 0; padding-top: 1.35rem; border-top: 1px dashed rgba(212, 175, 106, 0.2);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: 0.77rem; color: #7E7365;
}

@media (max-width: 960px) {
  .codex-grid { grid-template-columns: 1fr; }
  .home-topbar { padding: 1.1rem 1.4rem; }
}

/* ─── Light: sunlit travertine sanctuary — ivory stele frame, bronze incision, sepia ink ─── */
[data-theme="light"] .home-sanctuary { background: #F5EEDF; color: #3B2A1B; }
[data-theme="light"] .home-bg-layer { opacity: 0.26; }
[data-theme="light"] .home-breath-light {
  background: radial-gradient(ellipse 42% 36% at 50% 44%, rgba(255, 233, 184, 0.62) 0%, rgba(255, 240, 208, 0.2) 48%, transparent 76%);
  mix-blend-mode: normal;
}
[data-theme="light"] .home-scrim {
  background: linear-gradient(180deg, rgba(248, 243, 231, 0.9) 0%, rgba(248, 243, 231, 0.42) 38%, rgba(245, 238, 223, 0.5) 68%, rgba(245, 238, 223, 0.96) 100%);
  box-shadow: inset 0 0 0 0.7rem #F8F3E7, inset 0 0 0 calc(0.7rem + 1px) rgba(138, 104, 52, 0.5), inset 0 0 5rem rgba(168, 124, 58, 0.14);
}
[data-theme="light"] .home-wordmark, [data-theme="light"] .folio-title { color: #2F2115; }
[data-theme="light"] .brand-seal-mark, [data-theme="light"] .home-crest-mark, [data-theme="light"] .folio-numeral, [data-theme="light"] .home-foot-dot { color: #8A6834; }
[data-theme="light"] .home-nav-link { color: rgba(59, 42, 27, 0.84); }
[data-theme="light"] .home-nav-link:hover { color: #6B4B1F; }
[data-theme="light"] .home-lang-pill { color: #6B4B1F; background: rgba(248, 243, 231, 0.78); border-color: rgba(138, 104, 52, 0.42); }
[data-theme="light"] .home-lang-pill:hover { background: rgba(138, 104, 52, 0.12); }
[data-theme="light"] .home-title {
  background-image: linear-gradient(180deg, #8A6430 0%, #5F4019 52%, #3D2910 100%);
  filter: drop-shadow(0 1px 0 rgba(255, 250, 238, 0.9)) drop-shadow(0 10px 22px rgba(168, 124, 58, 0.24));
}
[data-theme="light"] .home-aphorism { color: #4A3522; text-shadow: 0 1px 0 rgba(255, 250, 238, 0.85); }
[data-theme="light"] .home-footstrip { color: rgba(74, 53, 34, 0.8); }
[data-theme="light"] .home-codex { background: #F8F3E7; border-top-color: rgba(138, 104, 52, 0.34); box-shadow: inset 0 14px 28px -20px rgba(168, 124, 58, 0.3); }
[data-theme="light"] .codex-folio { border-top-color: rgba(138, 104, 52, 0.55); }
[data-theme="light"] .folio-copy { color: #5E4B38; }
[data-theme="light"] .folio-action { color: #6B4B1F; border-bottom-color: rgba(107, 75, 31, 0.4); }
[data-theme="light"] .home-uaf-whisper { color: #7A6650; border-top-color: rgba(138, 104, 52, 0.28); }

@media (prefers-reduced-motion: reduce) {
  .home-breath-light { animation: none; opacity: 0.5; }
  .home-bg-layer { transition: none; will-change: auto; transform: scale(1.03); }
  .home-nav-link, .home-lang-pill { transition: none; }
}
