/* ══════════════════════════════════════════════════════════════
   EMERA · LIGHT PAGES — Editorial premium base
   /pages-light.css
   ──────────────────────────────────────────────────────────────
   Emil Kowalski design philosophy applied:
   - Restraint: typography does the heavy lifting
   - Generous whitespace, hairline rules, no decorative cards
   - Gold accent used like jewelry: once per section, max
   - Custom easing, subtle motion under 400ms
   - Barlow + Barlow Condensed (matching cyborg/sentinel brand)
═══════════════════════════════════════════════════════════════ */

*, ::before, ::after {
  box-sizing: border-box; margin: 0; padding: 0;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
}
html, body { -webkit-user-select: none !important; user-select: none !important; }
::-webkit-scrollbar { display: none; }
* { scrollbar-width: none; -ms-overflow-style: none; }

:root {
  /* Color tokens — restrained palette */
  --ink:      #1a1816;
  --ink-2:    #2E2C2A;
  --ink-3:    #5a5450;
  --ink-4:    #9a9490;
  --paper:    #fbfaf7;
  --paper-2:  #f4f0e8;
  --gold:     #B89A5C;
  --gold-soft:#cfa970;
  --hair:     rgba(26,24,22,.08);
  --hair-2:   rgba(26,24,22,.04);

  /* Typography */
  --serif: 'Barlow Condensed', sans-serif;
  --sans:  'Barlow', sans-serif;

  /* Easing (Emil's strong curves) */
  --ease-out: cubic-bezier(.23,1,.32,1);
  --ease-io:  cubic-bezier(.77,0,.175,1);
  --ease:     cubic-bezier(.65,0,.35,1);
}

html, body { min-height: 100%; }
body {
  background: #fff;
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  cursor: none;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "kern" 1, "liga" 1;
  text-rendering: optimizeLegibility;
}
*, a { cursor: none; }
@media (hover: none) and (pointer: coarse), (max-width: 768px) {
  body, *, a { cursor: auto !important; }
}

main { flex: 1 0 auto; }

/* ── CURSOR (preserved exactly) ── */
#cursor {
  position: fixed; top: 0; left: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: .75px solid rgba(26,24,22,.28);
  background: rgba(26,24,22,.03);
  pointer-events: none; z-index: 9999;
  transform: translate(-50%,-50%);
  transition: width .6s var(--ease-out), height .6s var(--ease-out),
              border-color .4s, background .4s;
}
#cursor::after {
  content: ''; position: absolute;
  top: 50%; left: 50%;
  width: 3px; height: 3px; border-radius: 50%;
  background: rgba(26,24,22,.6);
  transform: translate(-50%,-50%);
  transition: all .5s var(--ease-out);
}
#cursor.hover {
  width: 54px; height: 54px;
  border-color: rgba(184,154,92,.45);
  background: rgba(184,154,92,.07);
}
#cursor.hover::after { width: 0; height: 0; opacity: 0; }
@media (hover: none) and (pointer: coarse), (max-width: 768px) {
  #cursor { display: none !important; }
}

/* ══════════════════════════════════════════════════════════
   HEADER — same as cyborg/sentinel light theme
═══════════════════════════════════════════════════════════ */
header {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 300;
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 13px 40px;
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: 1px solid var(--hair);
}
.logo a { display: block; pointer-events: auto; cursor: none; }
.logo img { height: 28px; width: auto; display: block; }
.nav-medallion {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(26,24,22,.32);
  background: transparent;
  display: flex; align-items: center; justify-content: center;
  position: relative; z-index: 400;
  pointer-events: auto;
  transition: border-color .25s, transform .2s var(--ease-out), background .25s;
  cursor: none;
}
.nav-medallion:hover { border-color: var(--ink); background: rgba(26,24,22,.04); }
.nav-medallion:active { transform: scale(.97); }
.burger { display: flex; flex-direction: column; gap: 5px; width: 18px; }
.burger span {
  display: block; height: 1px; width: 100%;
  background: var(--ink);
  transition: transform .35s var(--ease-out), opacity .25s;
  transform-origin: center;
}
.nav-medallion.nav-open .burger span:nth-child(1),
body.nav-open .nav-medallion .burger span:nth-child(1),
.nav-medallion.open .burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-medallion.nav-open .burger span:nth-child(2),
body.nav-open .nav-medallion .burger span:nth-child(2),
.nav-medallion.open .burger span:nth-child(2) { opacity: 0; }
.nav-medallion.nav-open .burger span:nth-child(3),
body.nav-open .nav-medallion .burger span:nth-child(3),
.nav-medallion.open .burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

#flash {
  position: fixed; inset: 0;
  background: #fff;
  z-index: 9000;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s var(--ease-out);
}
#flash.on { opacity: 1; }

/* ══════════════════════════════════════════════════════════
   PAGE WRAPPER — generous container
═══════════════════════════════════════════════════════════ */
.ep {
  --gutter: clamp(20px, 5vw, 80px);
}

/* ══════════════════════════════════════════════════════════
   HERO — pure typography, no chrome
═══════════════════════════════════════════════════════════ */
.ep-hero {
  position: relative;
  padding: clamp(180px, 24vh, 280px) var(--gutter) clamp(80px, 12vh, 140px);
  min-height: 92vh;
  display: flex; flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}
.ep-hero-scene {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 1.6s var(--ease-out) .3s;
}
.ep-hero-scene.in { opacity: 1; }

.ep-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1480px;
  margin: 0 auto;
  width: 100%;
}

.ep-eyebrow {
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding-left: .42em;
  margin-bottom: clamp(32px, 5vh, 64px);
  display: inline-flex; align-items: center; gap: 14px;
  opacity: 0;
  animation: epFade .8s var(--ease-out) .1s forwards;
}
.ep-eyebrow b {
  font-weight: 500;
  color: var(--gold);
}
.ep-eyebrow .ep-dot {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--gold);
}

.ep-title {
  font-family: var(--serif);
  font-weight: 200;
  font-size: clamp(72px, 14vw, 220px);
  letter-spacing: -.025em;
  line-height: .88;
  color: var(--ink);
  max-width: 12ch;
}
.ep-title em {
  font-style: italic;
  font-weight: 200;
  color: var(--gold);
}
.ep-title .ep-line {
  display: block;
  overflow: hidden;
  padding: .04em 0;
}
.ep-title .ep-w {
  display: inline-block;
  opacity: 0;
  transform: translateY(.4em);
  animation: epRiseIn 1.1s var(--ease-out) forwards;
}
.ep-title .ep-line:nth-child(2) .ep-w { animation-delay: .12s; }
.ep-title .ep-line:nth-child(3) .ep-w { animation-delay: .24s; }
@keyframes epRiseIn { to { opacity: 1; transform: translateY(0); } }
@keyframes epFade { to { opacity: 1; } }

.ep-tagline {
  margin-top: clamp(40px, 6vh, 72px);
  max-width: 560px;
  font-family: var(--sans);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(17px, 1.4vw, 22px);
  line-height: 1.5;
  color: var(--ink-3);
  opacity: 0;
  animation: epFade 1.2s var(--ease-out) .8s forwards;
}

.ep-hero-row {
  margin-top: clamp(64px, 9vh, 96px);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 40px;
  flex-wrap: wrap;
  opacity: 0;
  animation: epFade 1.2s var(--ease-out) 1.0s forwards;
}
.ep-hero-meta {
  display: flex;
  gap: clamp(32px, 4vw, 80px);
  flex-wrap: wrap;
}
.ep-meta-cell {
  display: flex; flex-direction: column;
  gap: 6px;
}
.ep-meta-l {
  font-family: var(--serif);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .38em;
  text-transform: uppercase;
  color: var(--ink-4);
  padding-left: .38em;
}
.ep-meta-v {
  font-family: var(--serif);
  font-weight: 200;
  font-size: clamp(20px, 1.8vw, 26px);
  letter-spacing: -.005em;
  color: var(--ink);
}
.ep-hero-spacer { display: none; }

.ep-scroll-cue {
  position: absolute;
  bottom: 32px; right: var(--gutter);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  opacity: 0;
  animation: epFade 1.2s var(--ease-out) 1.6s forwards;
  z-index: 3;
}
.ep-scroll-line {
  width: 1px; height: 36px;
  background: var(--ink-3);
  transform-origin: top;
  animation: epScrollPulse 2.4s ease-in-out infinite;
}
@keyframes epScrollPulse {
  0%,100% { transform: scaleY(.4); opacity: .4; }
  50%     { transform: scaleY(1);   opacity: 1; }
}
.ep-scroll-t {
  font-family: var(--serif);
  font-size: 9px; font-weight: 500;
  letter-spacing: .42em; text-transform: uppercase;
  color: var(--ink-4);
  writing-mode: vertical-rl;
  text-orientation: mixed;
  padding-bottom: .42em;
}

/* ══════════════════════════════════════════════════════════
   SECTION DIVIDER (subtle hairline only)
═══════════════════════════════════════════════════════════ */
.ep-rule {
  border: none;
  height: 1px;
  background: var(--hair);
  margin: 0;
  max-width: 1480px;
  margin-left: auto; margin-right: auto;
  width: calc(100% - 2 * var(--gutter));
}

/* ══════════════════════════════════════════════════════════
   SECTION — common pattern (numbered, headlined, restrained)
═══════════════════════════════════════════════════════════ */
.ep-section {
  padding: clamp(96px, 18vh, 200px) var(--gutter);
  max-width: 1480px;
  margin: 0 auto;
  width: 100%;
}
.ep-section-num {
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: clamp(24px, 4vh, 40px);
  padding-left: .42em;
  display: block;
}
.ep-section-num em {
  font-style: normal;
  color: var(--gold);
}
.ep-section-title {
  font-family: var(--serif);
  font-weight: 200;
  font-size: clamp(42px, 6.5vw, 96px);
  letter-spacing: -.018em;
  line-height: 1;
  color: var(--ink);
  max-width: 18ch;
}
.ep-section-title em { font-style: italic; color: var(--gold); font-weight: 200; }
.ep-section-lead {
  margin-top: clamp(32px, 5vh, 56px);
  max-width: 640px;
  font-family: var(--sans);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(17px, 1.4vw, 22px);
  line-height: 1.55;
  color: var(--ink-2);
}
.ep-section-lead em { color: var(--gold); }
.ep-body {
  font-family: var(--sans);
  font-weight: 300;
  font-size: clamp(15px, 1.05vw, 17px);
  line-height: 1.75;
  color: var(--ink-2);
  max-width: 65ch;
}
.ep-body em { font-style: italic; color: var(--gold); }
.ep-body + .ep-body { margin-top: 1.2em; }

/* ══════════════════════════════════════════════════════════
   REVEAL HELPER — sober fade-up
═══════════════════════════════════════════════════════════ */
.ep-reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
}
.ep-reveal.in {
  opacity: 1;
  transform: translateY(0);
}
.ep-reveal-stagger > * {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
}
.ep-reveal-stagger.in > * { opacity: 1; transform: translateY(0); }
.ep-reveal-stagger.in > *:nth-child(2) { transition-delay: .06s; }
.ep-reveal-stagger.in > *:nth-child(3) { transition-delay: .12s; }
.ep-reveal-stagger.in > *:nth-child(4) { transition-delay: .18s; }
.ep-reveal-stagger.in > *:nth-child(5) { transition-delay: .24s; }
.ep-reveal-stagger.in > *:nth-child(6) { transition-delay: .30s; }
.ep-reveal-stagger.in > *:nth-child(7) { transition-delay: .36s; }

/* ══════════════════════════════════════════════════════════
   LINK + CTA — restrained
═══════════════════════════════════════════════════════════ */
.ep-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .38em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--ink);
  transition: color .25s, border-color .25s, letter-spacing .35s var(--ease-out);
}
.ep-link:hover { color: var(--gold); border-color: var(--gold); letter-spacing: .44em; }
.ep-link:active { transform: scale(.98); }
.ep-link svg { width: 18px; height: 10px; transition: transform .3s var(--ease-out); }
.ep-link:hover svg { transform: translateX(4px); }

.ep-cta {
  display: inline-flex; align-items: center; gap: 18px;
  padding: 16px 28px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  white-space: nowrap;
  border-radius: 1px;
  border: 1px solid var(--ink);
  transition: background .25s, color .25s, transform .15s var(--ease-out);
}
.ep-cta:hover { background: #000; }
.ep-cta:active { transform: scale(.97); }
.ep-cta svg {
  width: 14px; height: 8px;
  transition: transform .3s var(--ease-out);
  flex-shrink: 0;
}
.ep-cta:hover svg { transform: translateX(4px); }
.ep-cta--ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
}
.ep-cta--ghost:hover { background: var(--ink); color: #fff; }

/* ══════════════════════════════════════════════════════════
   FOOTER — editorial, multi column
   Background adapts to the last section of each page via
   .ep-footer--<tone> modifiers. Default = page paper.
═══════════════════════════════════════════════════════════ */
.ep-footer {
  flex-shrink: 0;
  position: relative;
  background: #ffffff;
  color: var(--ink);
  font-family: var(--sans);
  padding: clamp(60px, 9vh, 96px) var(--gutter) 0;
  border-top: 1px solid var(--hair);
}

/* Per page tones */
.ep-footer--paper,
.ep-footer--cream,
.ep-footer--ivory,
.ep-footer--mist { background: #ffffff; }

/* Top accent that picks up section mood */
.ep-footer::before {
  content: '';
  position: absolute;
  top: -1px; left: 50%;
  width: 56px; height: 1px;
  background: var(--gold);
  transform: translateX(-50%);
  opacity: .55;
}

.ep-footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: clamp(36px, 5vw, 80px);
  padding-bottom: clamp(50px, 7vh, 80px);
  align-items: start;
}

.ep-footer-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ep-footer-mark {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(28px, 3vw, 40px);
  letter-spacing: .14em;
  line-height: 1;
  color: var(--ink);
}
.ep-footer-tag {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 14px;
  color: var(--gold);
  letter-spacing: .04em;
  margin-top: 14px;
}
.ep-footer-line {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 13px;
  color: var(--ink-3);
  line-height: 1.65;
  max-width: 32ch;
  margin-top: 4px;
}

.ep-footer-label {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 10px;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 4px;
}

.ep-footer a {
  color: var(--ink);
  text-decoration: none;
  font-family: var(--sans);
  font-weight: 300;
  font-size: 13.5px;
  letter-spacing: .01em;
  line-height: 1.5;
  transition: color .25s var(--ease-out);
}
.ep-footer a:hover { color: var(--gold); }

.ep-footer-address {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 13.5px;
  color: var(--ink);
  line-height: 1.65;
  font-style: normal;
}
.ep-footer-address a { display: block; }

.ep-footer-bar {
  border-top: 1px solid var(--hair);
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 10px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.ep-footer-bar a { font-size: 10px; letter-spacing: .28em; color: var(--ink-4); }
.ep-footer-bar a:hover { color: var(--gold); }
.ep-footer-bar-r { display: flex; gap: 22px; align-items: center; }

@media (max-width: 900px) {
  .ep-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
  .ep-footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .ep-footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .ep-footer-bar { flex-direction: column; gap: 12px; text-align: center; }
  .ep-footer-bar-r { flex-direction: column; gap: 8px; }
}

/* Legacy compat (old ep-foot stays valid if referenced) */
.ep-foot {
  flex-shrink: 0;
  border-top: 1px solid var(--hair);
  padding: 32px var(--gutter);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--serif);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: var(--paper);
}
.ep-foot a { color: var(--ink); text-decoration: none; transition: color .25s; }
.ep-foot a:hover { color: var(--gold); }
.ep-foot .ep-foot-r { display: flex; gap: 24px; align-items: center; }

/* (Removed last-section tinting — pages stay pure white throughout.) */

/* ══════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .ep-hero-row { flex-direction: column; align-items: flex-start; }
  .ep-scroll-cue { display: none; }
  .ep-foot { flex-direction: column; gap: 14px; text-align: center; }
}
@media (max-width: 600px) {
  header { padding: 10px 18px; }
  .ep-hero { padding-top: 140px; padding-bottom: 60px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .ep-title .ep-w,
  .ep-eyebrow, .ep-tagline, .ep-hero-row,
  .ep-scroll-cue, .ep-hero-scene {
    animation: none;
    opacity: 1;
    transform: none;
  }
  .ep-reveal, .ep-reveal-stagger > * {
    transition: opacity .3s;
  }
}
