/* Global header offset */
:root {
  --nav-height: 30px; /* Adjust if needed based on actual header height */
}

/* Ensure the main scroll container accounts for the fixed nav */
html,
body {
  padding-top: var(--nav-height);
  scroll-padding-top: var(--nav-height); /* helpful for in-page anchors */
}

/* Aurora background animation */

.aurora-layer {
  position: absolute;
  inset: -20%;
  pointer-events: none;
  z-index: 0;

  /* Keep base background from the app (bg-black), just add faint streaks */
  background:
    radial-gradient(ellipse at 10% 0%, rgba(120, 220, 255, 0.18) 0, transparent 60%),
    radial-gradient(ellipse at 90% 10%, rgba(255, 180, 230, 0.14) 0, transparent 65%),
    radial-gradient(ellipse at 0% 90%, rgba(255, 220, 160, 0.10) 0, transparent 65%),
    radial-gradient(ellipse at 100% 80%, rgba(160, 200, 255, 0.14) 0, transparent 65%);
  filter: blur(70px);
  opacity: 0.35;
  mix-blend-mode: screen;

  animation: auroraFloat 26s ease-in-out infinite alternate;
}

@keyframes auroraFloat {
  0% {
    transform: translate3d(-5%, -5%, 0) scale(1);
  }
  25% {
    transform: translate3d(3%, -8%, 0) scale(1.05);
  }
  50% {
    transform: translate3d(6%, 4%, 0) scale(1.03);
  }
  75% {
    transform: translate3d(-4%, 6%, 0) scale(1.08);
  }
  100% {
    transform: translate3d(2%, -3%, 0) scale(1.02);
  }
}

@keyframes star-drift {
  0% { background-position: 0% 0%; }
  100% { background-position: 10% 10%; }
}

.animate-star-drift {
  background-size: 110% 110%; /* Zoom in so it has room to move */
  animation: star-drift 90s linear infinite alternate; /* 'alternate' makes it go back and forth smoothly */
}

/* Self-hosted PurposeBased / BasedTalk / nav faces (latin subset, variable weight),
   replacing the two Google Fonts stylesheets that used to block first paint on every
   page. Same families and weights as before; the size-adjusted fallbacks below keep
   the swap from moving anything. */
@font-face {
  font-family: 'Cormorant';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('/fonts/cormorant-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Cormorant';
  font-style: italic;
  font-weight: 300 700;
  font-display: swap;
  src: url('/fonts/cormorant-latin-italic.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 100 1000;
  font-display: swap;
  src: url('/fonts/dm-sans-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Cinzel';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('/fonts/cinzel-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Playfair Display';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('/fonts/playfair-display-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Playfair Display';
  font-style: italic;
  font-weight: 400 900;
  font-display: swap;
  src: url('/fonts/playfair-display-latin-italic.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Metric-matched fallbacks for the PurposeBased fonts. While Cormorant / DM Sans
   load, text is set in a local font scaled to the same width and vertical metrics
   (measured against the Google Fonts files), so the swap does not re-wrap lines
   and cause layout shift. Values: size-adjust = web/local width; overrides =
   web ascent/descent divided by size-adjust. */
@font-face {
  font-family: 'Cormorant Fallback';
  src: local('Times New Roman'), local('TimesNewRomanPSMT');
  font-style: normal;
  size-adjust: 94.8%;
  ascent-override: 97%;
  descent-override: 30.6%;
  line-gap-override: 0%;
}
@font-face {
  font-family: 'Cormorant Fallback';
  src: local('Times New Roman Italic'), local('TimesNewRomanPS-ItalicMT');
  font-style: italic;
  size-adjust: 86%;
  ascent-override: 107%;
  descent-override: 33.7%;
  line-gap-override: 0%;
}
@font-face {
  font-family: 'DM Sans Fallback';
  src: local('Arial'), local('ArialMT');
  size-adjust: 103%;
  ascent-override: 96.1%;
  descent-override: 30.1%;
  line-gap-override: 0%;
}

/* ============================================================
   PurposeBased (/purposebased) — site-within-a-site styles
   ============================================================ */

.pb-font-serif {
  font-family: 'Cormorant', 'Cormorant Fallback', Georgia, 'Times New Roman', serif;
}

.pb-font-sans {
  font-family: 'DM Sans', 'DM Sans Fallback', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

.pb-nav-link:hover {
  color: #ffc864 !important;
}

.pb-foot-link {
  font-size: 13px;
  color: #cadcf0;
  text-decoration: none;
  transition: color 0.2s ease;
}

.pb-foot-link:hover {
  color: #ffc864;
}

/* Glassmorphic buttons */
.pb-btn,
.pb-btn-solid {
  position: relative;
  display: inline-block;
  overflow: hidden;
  padding: 14px 36px;
  border-radius: 8px;
  font-size: 11px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  font-family: 'DM Sans', 'DM Sans Fallback', system-ui, sans-serif;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.pb-btn {
  background: linear-gradient(135deg, rgba(255, 200, 100, 0.18), rgba(255, 200, 100, 0.06));
  border: 1px solid rgba(255, 200, 100, 0.4);
  color: #ffc864;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.pb-btn:hover {
  background: linear-gradient(135deg, rgba(255, 200, 100, 0.26), rgba(255, 200, 100, 0.1));
  border-color: rgba(255, 200, 100, 0.65);
  transform: translateY(-2px);
}

.pb-btn-solid {
  background: linear-gradient(135deg, rgba(255, 200, 100, 0.9), rgba(220, 160, 50, 0.85));
  border: 1px solid rgba(255, 220, 130, 0.6);
  color: #12283f;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.25), 0 0 24px rgba(255, 200, 100, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.pb-btn-solid:hover {
  border-color: rgba(255, 220, 130, 0.85);
  transform: translateY(-2px);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.3), 0 0 34px rgba(255, 200, 100, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.pb-btn::before,
.pb-btn-solid::before {
  content: '';
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  transition: left 0.6s ease;
}

.pb-btn:hover::before,
.pb-btn-solid:hover::before {
  left: 130%;
}
