/* ==============================================
   CSS CUSTOM PROPERTIES (Variables)
   CONSOLIDATED & ORGANIZED
   ============================================== */
:root {
  /* ======================
     CORE COLOR PALETTE
     ====================== */
  --color-primary: #1c1c1c;
  --color-secondary: #fbe86b;
  --color-accent-1: #fd635a;
  --color-accent-2: var(--color-secondary);
  --color-white: #ffffff;

  /* ======================
     BACKGROUND COLORS
     ====================== */
  --color-page-bg: #f9faf2;
  --color-surface: #fafafa;
  --color-card-bg: var(--color-surface);
  --color-dark-bg: var(--color-primary);

  /* ======================
     TEXT COLORS
     ====================== */
  --color-text-primary: var(--color-primary);
  --color-text-secondary: #6b6b6b;
  --color-text-muted: #555;
  --color-text-light: var(--color-white);
  --color-text-dark: var(--color-primary);

  /* ======================
     BORDER COLORS
     ====================== */
  --color-stroke: #ebe9de;
  --color-border-light: var(--color-stroke);
  --color-card-stroke-light: rgba(235, 233, 222, 0.5);
  --color-card-stroke-lighter: rgba(235, 233, 222, 0.3);

  /* ======================
     BUTTON COLORS
     ====================== */
  --color-button: #000000;
  --color-button-light: rgba(28, 28, 28, 0.15);
  --color-button-lighter: rgba(28, 28, 28, 0.08);
  --color-accent-2-light: rgba(237, 62, 41, 0.08);
  --color-accent-2-lighter: rgba(253, 99, 90, 0.08);

  /* ======================
     SHADOWS & OVERLAYS
     ====================== */
  --shadow-light: rgba(0, 0, 0, 0.08);
  --shadow-medium: rgba(0, 0, 0, 0.15);
  --shadow-dark: rgba(28, 28, 28, 0.3);
  --accent-shadow: rgba(253, 99, 90, 0.2);
  --overlay-white: rgba(255, 255, 255, 0.92);

  /* ======================
     TYPOGRAPHY
     ====================== */
  --gh-font-heading: 'Inter', sans-serif;
  --gh-font-body: 'Inter', sans-serif;

  /* ======================
     LAYOUT & SPACING
     ====================== */
  --header-height: 80px;

  /* ======================
     BORDER RADIUS
     ====================== */
  --radius-card: 20px;
  --radius-button: 50px;

  /* ======================
     ANIMATIONS
     ====================== */
  --anim-fast: .3s ease;
  --anim-medium: .5s ease;
  --anim-slow: .6s ease-out;

  /* ======================
     TRANSITION UTILS
     ============================================== */
  --nav-transition-out: all 0.1s ease-out;
  --page-load-cover: rgba(249, 250, 242, 0.98);

  /* ======================
     BLOG & POST THEME MAPPING
     ====================== */
  --blog-primary: var(--color-primary);
  --blog-secondary: var(--color-accent-1);
  --blog-bg-card: var(--color-surface);
  --blog-border-color: var(--color-border-light);
  --blog-shadow-color: var(--shadow-light);
  --blog-bg-placeholder: var(--color-button-lighter);
  --blog-text-dark: var(--color-primary);

  /* Alias for legacy/typo compatibility */
  --color-page-background: var(--color-page-bg);

  /* Dynamic Offsets */
  --announcement-bar-height: 0px;
}

/* ======================================================
   GLOBAL RESET
   ====================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html:not(.js-ready) *,
html:not(.js-ready) *::before,
html:not(.js-ready) *::after {
  transition: none !important;
  animation: none !important;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  scroll-padding-top: 0px;
}

/* ======================================================
   GLOBAL TYPOGRAPHY
   ====================================================== */
html,
body,
button,
input,
textarea,
select,
a,
p,
span,
div,
ul,
li,
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--gh-font-body) !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ======================================================
   CRITICAL: STABLE HEADER ENTRANCE
   Hides header internal components until JS restructuring is complete
   to avoid visible layout shifts and flickering.
   ====================================================== */
.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 100%;
  min-width: 0;
}

/* Remove hard-blocking of individual li as the parent now handles it */
.nebula-nav-horizontal:not(.nav-ready) ul li {
  visibility: hidden;
  opacity: 0;
}

/* Unblock items ONLY when they are safely inside a submenu */
.nebula-nav-horizontal .ghost-submenu li {
  display: block !important;
}

/* ======================================================
   BASE BODY STYLES
   ====================================================== */
body {
  color: var(--color-text-primary);
  line-height: 1.6;
  background: var(--color-page-bg);
  overflow-x: hidden;
  padding: 0;
}

body.menu-open {
  overflow: hidden;
}

/* ======================================================
   TYPOGRAPHY UTILITIES
   ====================================================== */
.subtitle,
.section-title,
.card-title,
.oasis-subtitle,
.oasis-card h3,
.benefit-content strong,
.join-steps.redesigned-steps li::before,
.testimonial-subheading,
strong {
  font-family: var(--gh-font-heading);
  font-weight: 600;
}

/* ======================================================
   BASE ELEMENT STYLES
   ====================================================== */
a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
}

/* ==============================================
   GHOST NATIVE ANNOUNCEMENT BAR SUPPORT
   JS sets --announcement-bar-height and adds
   body.has-announcement-bar. :has() is a fallback.
   ============================================== */
.gh-announcement-bar {
  z-index: 4001 !important;
}

/* Fallback: CSS :has() for browsers that support it (sets a default until JS measures) */
:root:has(.gh-announcement-bar) {
  --announcement-bar-height: 48px;
}

/* Primary: JS-driven class (always correct, uses measured height) */
body.has-announcement-bar {
  --announcement-bar-height: var(--announcement-bar-height-js, 48px);
}


/* ==============================================
   HEADER CONTAINER & LAYOUT
   ============================================== */
.nebula-header {
  position: fixed;
  top: calc(var(--announcement-bar-height) + 1rem);
  left: 50%;
  transform: translateX(-50%);
  width: 95%;
  max-width: 87.5rem;
  height: var(--header-height);
  box-sizing: border-box;
  background: rgba(250, 250, 250, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--color-border-light);
  border-radius: 3.125rem;
  padding: 0.875rem 1.875rem;
  box-shadow: 0 8px 25px var(--shadow-dark);
  z-index: 3000;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  will-change: transform;
  isolation: isolate;
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 100%;
  min-width: 0;
}

.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo img {
  height: 3rem;
  width: auto;
  max-width: 180px;
}

.logo span {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-primary);
  font-family: var(--gh-font-heading);
  white-space: nowrap;
}

/* ==============================================
   NAVIGATION (DESKTOP DEFAULT)
   ============================================== */
.nebula-nav-horizontal {
  flex-grow: 1;
  display: flex;
  justify-content: center;
  min-height: 22px;
  flex: 1 1 auto;
  min-width: 0;
}

/* Desktop only: Hide until JS restructured the menu */
@media (min-width: 1151px) {
  .nebula-nav-horizontal {
    opacity: 1 !important;
    visibility: visible !important;
    flex: 1 1 0%;
    /* Reserve space to stabilize the "bar" */
  }

  /* Items enter seamlessly when ready */
  .nebula-nav-horizontal.nav-ready ul li {
    visibility: visible;
    opacity: 1;
    animation: nebulaItemEntrance 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    will-change: transform, opacity;
  }

  /* Staggered entrance */
  .nebula-nav-horizontal.nav-ready ul li:nth-child(1) {
    animation-delay: 0.05s;
  }

  .nebula-nav-horizontal.nav-ready ul li:nth-child(2) {
    animation-delay: 0.10s;
  }

  .nebula-nav-horizontal.nav-ready ul li:nth-child(3) {
    animation-delay: 0.15s;
  }

  .nebula-nav-horizontal.nav-ready ul li:nth-child(4) {
    animation-delay: 0.20s;
  }

  .nebula-nav-horizontal.nav-ready ul li:nth-child(5) {
    animation-delay: 0.25s;
  }

  .nebula-nav-horizontal.nav-ready ul li:nth-child(6) {
    animation-delay: 0.30s;
  }
}

@keyframes nebulaItemEntrance {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nebula-nav-horizontal ul {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nebula-nav-horizontal li {
  position: relative;
}

.nebula-nav-horizontal a {
  font-family: var(--gh-font-body);
  font-weight: 600;
  font-size: 1rem;
  color: var(--color-text-primary);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-button);
  transition: color var(--anim-fast), background-color var(--anim-fast);
  position: relative;
  display: block;
  white-space: nowrap;
}

/* Hover only */
.nebula-nav-horizontal a:hover {
  color: var(--color-accent-1);
  background: var(--color-accent-2-light);
}


/* =========================================
   UNIVERSAL ACTIVE NAV STATE (Desktop + Mobile)
   ========================================= */

/* Highlight current page link */
.nebula-nav-horizontal li.nav-current>a {
  color: var(--color-accent-1);
  background: var(--color-accent-2-light);
  border-radius: var(--radius-button);
  /* match hover */
  font-weight: 700;
}

/* Submenu active item */
.nebula-nav-horizontal li ul li.nav-current>a {
  color: var(--color-accent-1);
  background: var(--color-accent-2-light);
}


/* Submenu Base Styles */
.nebula-nav-horizontal li ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--color-surface);
  min-width: 220px;
  border-radius: var(--radius-card);
  box-shadow: 0 8px 25px var(--shadow-dark);
  border: 1px solid var(--color-border-light);
  padding: 0.5rem 0;
  flex-direction: column;
  gap: 0;
  z-index: 999;
}

/* ======================================================
   SUBMENU TOGGLE BUTTON (NEW - REPLACES ARROW IN LINK)
   ====================================================== */
.submenu-toggle {
  position: absolute;
  right: 0;
  top: 1.1rem;
  background: none;
  border: none;
  padding: 6px;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background-color var(--anim-fast);
}

.submenu-toggle:hover {
  background: var(--color-button-lighter);
}

.submenu-toggle svg {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease;
}

.menu-item-has-children.open .submenu-toggle svg {
  transform: rotate(180deg);
}

/* Hide the legacy inline SVG arrow on all screens — toggle button replaces it */
.menu-item-has-children>svg {
  display: none !important;
}

/* ======================================================
   ALLOW SUBMENU LINKS TO NAVIGATE
   ====================================================== */
.nebula-nav-horizontal li ul a {
  pointer-events: auto;
}

/* ======================================================
   DESKTOP: Click-to-open submenus (via .open class)
   ====================================================== */
@media (min-width: 1151px) {

  /* Keep li normal */
  .nebula-nav-horizontal .menu-item-has-children {
    position: relative;
  }

  /* Make anchor wrap text cleanly */
  .nebula-nav-horizontal .menu-item-has-children>a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1.75rem 0.5rem 1rem;
    /* extra right space */
  }

  /* Position arrow inside the pill */
  .menu-item-has-children>.submenu-toggle {
    position: absolute !important;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    padding: 0;
    background: transparent !important;
  }

  .menu-item-has-children>.submenu-toggle svg {
    width: 14px;
    height: 14px;
  }


  /* Submenu dropdown is absolutely positioned below the li */
  .nebula-nav-horizontal .menu-item-has-children>ul {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 10px;
    min-width: 220px;
    z-index: 1000;
  }

  /* Click-based open via JS-toggled .open class */
  .nebula-nav-horizontal .menu-item-has-children.open>ul,
  .nebula-nav-horizontal .menu-item-has-children.open:hover>ul {
    display: flex !important;
  }

  .nebula-nav-horizontal li ul a {
    border-radius: var(--radius-button);
    /* make pill */
    padding: 0.65rem 1.25rem;
    font-size: 0.95rem;
    transition: background 0.2s ease, color 0.2s ease;
  }

  /* Add spacing so pill does not touch container edges */
  .nebula-nav-horizontal li ul li {
    padding: 0.25rem 0.5rem;
  }

  /* Add spacing so rounded edges are visible */
  .nebula-nav-horizontal li ul li {
    padding: 0 0.5rem;
  }

  /* Hide the legacy inline SVG arrow (appended by ghost-dropdown.js) */
  .menu-item-has-children>svg {
    display: none !important;
  }
}

/* ==============================================
   HEADER RIGHT ACTIONS
   ============================================== */
.header-right-items {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-left: auto;
  flex-shrink: 1;
  min-width: 0;
}

.mobile-extra-items {
  display: none;
}

.gh-search-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 0;
  font-size: 1.2rem;
  color: inherit;
  background-color: transparent;
  cursor: pointer;
  outline: none;
  border-radius: 50%;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.gh-search-icon:hover {
  background: var(--color-accent-2-light);
  color: var(--color-accent-1);
  transform: scale(1.05);
}

.profile-icon,
.join-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.5rem;
  border-radius: var(--radius-button);
  background: var(--color-button);
  color: var(--color-text-light);
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  max-width: 100%;
  flex-shrink: 0;
}

.profile-icon:hover,
.join-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(28, 28, 28, 0.25);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 1.75rem;
  height: 1.25rem;
  background: none;
  cursor: pointer;
  padding: 0;
  z-index: 3100;
  margin-left: 0.5rem;
  flex-shrink: 0;
}

.hamburger span {
  width: 100%;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
  transform-origin: center;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* ==========================================
   CLEAN SLIDE-IN MOBILE NAV
   ========================================== */
@media (max-width: 1150px) {

  .nebula-nav-horizontal {
    position: fixed;
    top: calc(var(--announcement-bar-height) + 5rem) !important;
    right: 2.5%;
    height: auto;
    max-height: calc(100dvh - var(--announcement-bar-height) - 6rem);
    width: 90%;
    max-width: 360px;

    background: var(--color-page-bg);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border-radius: 1.5rem;
    border: 1px solid var(--color-border-light);

    transform: translateX(120%);
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.4s;

    display: flex;
    flex-direction: column;
    justify-content: flex-start;

    padding: 1.5rem;
    overflow-y: auto;
    z-index: 2000;
  }

  .nebula-nav-horizontal.active {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
  }

  body.menu-open::before {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(6px);
    z-index: 1500;
  }

  body.menu-open {
    overflow: hidden;
  }

  /* Hide desktop header actions on mobile */
  .header-right-items {
    display: none;
  }

  /* Show hamburger on mobile */
  .hamburger {
    display: flex;
  }
}

/* ======================================================
   DESKTOP RESPONSIVE VISIBILITY (1151px and above)
   ====================================================== */
@media (min-width: 1151px) {

  /* Show desktop header actions */
  .header-right-items {
    display: flex;
  }

  /* Hide hamburger on desktop */
  .hamburger {
    display: none;
  }
}

/* ======================================================
   MOBILE MENU CONTENT STYLES
   ====================================================== */
@media (max-width: 1150px) {
  .nebula-nav-horizontal ul {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0 !important;
    width: 100%;
  }

  .nebula-nav-horizontal ul li {
    width: 100%;
    border-bottom: 1px solid var(--color-border-light);
    margin: 0;
    position: relative;
  }

  .nebula-nav-horizontal ul li:last-child {
    border-bottom: none;
  }

  .nebula-nav-horizontal ul li a {
    width: 100%;
    padding: 0.9rem 1.2rem;
    font-size: 1.1rem;
    text-align: left;
    border-radius: var(--radius-button);
    /* make pill */
    background-color: transparent;
    display: flex;
    align-items: center;
  }


  /* Submenus */
  .nebula-nav-horizontal li ul,
  .nebula-nav-horizontal ul.ghost-submenu {
    position: relative;
    top: 0;
    box-shadow: none;
    border: none;
    background: transparent;
    padding: 0;
    display: none;
    overflow: hidden;
    width: 100%;
  }

  .nebula-nav-horizontal .menu-item-has-children.open>ul {
    display: block !important;
    animation: nebulaSubmenuFadeIn 0.3s ease-out forwards;
  }

  /* Remove the rule that made "open" look like "active" */
  /* .menu-item-has-children.open > a { ... }  [REMOVED] */

  .submenu-toggle {
    display: flex !important;
    /* Force visible on mobile */
    top: 0.85rem;
    right: 0.5rem;
    color: var(--color-text-secondary);
    z-index: 5;
    background: var(--color-accent-2-light) !important;
    border-radius: 50% !important;
  }

  .menu-item-has-children.open .submenu-toggle {
    color: var(--color-accent-1);
    transform: rotate(180deg);
  }

  @keyframes nebulaSubmenuFadeIn {
    from {
      opacity: 0;
      transform: translateY(-5px);
    }

    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .nebula-nav-horizontal li ul li {
    border-bottom: none;
  }

  /* Cleaner mobile submenu links */
  .nebula-nav-horizontal li ul a {
    padding: 0.85rem 0 0.85rem 2rem;
    font-size: 0.98rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    background: transparent;
    border-radius: 10px;
    transition: background 0.2s ease, color 0.2s ease;
  }

  .nebula-nav-horizontal li ul a:hover,
  .nebula-nav-horizontal li ul a:focus-visible {
    background: var(--color-accent-2-light);
    color: var(--color-accent-1);
  }

  /* Clean mobile submenu container */
  .nebula-nav-horizontal .menu-item-has-children>ul {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding-top: 0.4rem;
  }

  /* Subtle divider between parent and children */
  .menu-item-has-children.open>ul {
    margin-top: 0.3rem;
  }

  /* Mobile Extra Items (Search & Join) */
  .nebula-nav-horizontal .mobile-extra-items {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding-top: 1.5rem;
    margin-top: 0.5rem;
    border-top: 1px solid var(--color-border-light);
    width: 100%;
  }

  .nebula-nav-horizontal .mobile-extra-items .gh-search-icon {
    width: 100%;
    height: 54px;
    padding: 0 1.5rem;
    border-radius: var(--radius-button);
    border: 1px solid var(--color-border-light);
    font-size: 1.1rem;
    justify-content: flex-start;
    gap: 12px;
    color: var(--color-text-primary);
    background: var(--color-surface);
    transition: transform 0.2s ease, border-color 0.2s ease;
  }

  .nebula-nav-horizontal .mobile-extra-items .gh-search-icon:active {
    transform: scale(0.98);
    border-color: var(--color-accent-1);
  }

  .nebula-nav-horizontal .mobile-extra-items .profile-icon,
  .nebula-nav-horizontal .mobile-extra-items .join-cta {
    width: 100%;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    padding: 0;
    color: var(--color-white) !important;
    background: var(--color-button) !important;
    border-radius: var(--radius-button);

    /* Reset desktop block/static overrides */
    position: relative;
    transform: none;
    transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.2s ease;
  }

  /* Premium Hover/Active state for Mobile */
  .nebula-nav-horizontal .mobile-extra-items .join-cta:active {
    transform: scale(0.97);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  }

  /* Remove dropdown arrow on mobile */
  .submenu-toggle {
    display: none !important;
  }

}

/* ======================================================
   DESKTOP: Submenu item hover highlight
   ====================================================== */
@media (min-width: 1151px) {
  .nebula-nav-horizontal li ul a:hover {
    background: var(--color-accent-2-light);
    color: var(--color-accent-1);
  }
}

/* ======================================================
   MOBILE (768px and below) - Additional tweaks
   ====================================================== */
@media (max-width: 768px) {
  .nebula-header {
    border-radius: 1rem;
    padding: 0.75rem 1rem;
    min-height: 60px;
    top: calc(var(--announcement-bar-height) + 0.5rem);
  }

  .logo img {
    height: 2.2rem;
  }

  .nebula-nav-horizontal {
    top: calc(var(--announcement-bar-height) + 5rem);
    max-height: calc(100vh - var(--announcement-bar-height) - 6rem);
    padding-bottom: 2rem;
  }

  .nebula-nav-horizontal.active {
    padding-bottom: 2rem;
  }

  .submenu-toggle {
    top: 1rem;
  }
}

@media (max-width: 400px) {
  .logo span {
    font-size: 1.2rem;
  }

  .nebula-header {
    padding: 0.75rem;
  }
}

.gs-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.165, 0.84, 0.44, 1),
    background-color 0.4s ease,
    backdrop-filter 0.4s ease;
}

.gs-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.gs-modal-content {
  background: var(--color-white);
  width: 90%;
  max-width: 440px;
  padding: 2.5rem;
  border-radius: 1.5rem;
  text-align: center;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gs-modal.active .gs-modal-content {
  transform: scale(1) translateY(0);
}

.gs-modal-content h2 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

.gs-option {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  margin: 0.75rem 0;
  border-radius: 0.875rem;
  background: #f8f8f8;
  color: var(--color-primary);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 1px solid #eeeeee;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.gs-option:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  border-color: var(--color-primary);
}

.gs-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  line-height: 1;
  padding: 0;
  border: none;
  color: var(--color-text-secondary);
  background: #f0f0f0 !important;
  border-radius: 50% !important;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
}

.gs-close:hover {
  background: #e0e0e0 !important;
  color: var(--color-primary);
  transform: rotate(90deg);
}

/* Modal Open Body Lock */
body.modal-open {
  overflow: hidden;
}

/* ==============================================
   BUTTON STYLES
   ============================================== */
.hero-cta,
.event-btn {
  background: var(--color-button);
  color: var(--color-text-light);
  padding: 1rem 2.5rem;
  border-radius: var(--radius-button);
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-cta:hover,
.event-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(28, 28, 28, 0.25);
}

.view-all {
  display: inline-block;
  margin-top: 30px;
  font-weight: 600;
  color: var(--color-text-primary);
  text-decoration: none;
}

.view-all-btn {
  display: block;
  width: fit-content;
  margin: 2rem auto 0;
  padding: 0.8rem 1.8rem;
  font-size: 0.95rem;
  background: var(--color-button);
  color: var(--color-text-light);
  border-radius: var(--radius-button);
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.view-all-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(28, 28, 28, 0.25);
}

/* ==============================================
   MAIN CONTENT & UTILITIES
   ============================================== */
.cosmic-flow {
  padding-top: calc(7.5rem + var(--announcement-bar-height));
  min-height: 100vh;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  max-width: 75rem;
  margin: 0 auto;
  padding: 0 1rem;
}

.loading-state {
  display: none;
}

.form-loading .loading-state,
.form-success .success-state,
.form-error .error-state {
  display: block;
}

.benefits-stack {
  display: flex;
  flex-direction: column;
  gap: 3.75rem;
  max-width: 53.125rem;
  margin: 3.75rem auto;
}

.benefits-stack .oasis-card {
  padding: 2.5rem 2.2rem;
  border-radius: var(--radius-card);
  background: var(--color-card-bg);
}

@media (max-width: 600px) {
  .benefits-stack {
    gap: 1.5rem;
    padding: 0 1rem;
  }
}

.kg-width-wide {
  max-width: 75rem;
  margin: 0 auto;
}

.kg-width-full {
  width: 100%;
  margin: 0;
}

/* ==============================================
   FOOTER STYLES – FULLY RESPONSIVE
   ============================================== */
.stack-footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border-light);
  padding: 2rem 2rem;
  margin-top: auto;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1.5rem;
}

/* Secondary Navigation (text links from Ghost Admin) */
.footer-nav-secondary {
  display: flex;
  justify-content: flex-start;
}

.footer-nav-secondary ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-nav-secondary li a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-nav-secondary li a:hover {
  color: var(--color-accent-1);
}

/* Social media SVG icons in footer */
.footer-nav-secondary li a svg.icon {
  width: 22px;
  height: 22px;
  display: block;
  fill: currentColor;
  transition: transform 0.2s ease;
}

.footer-nav-secondary li a:hover svg.icon {
  transform: translateY(-2px);
}

.footer-brand-social {
  display: flex;
  justify-content: flex-start;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
}

.footer-social a {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--color-text-secondary);
  transition: all 0.25s ease;
}

.footer-social a svg {
  width: 22px;
  /* Slightly larger for better visibility */
  height: 22px;
  display: block;
}

.footer-social a:hover {
  color: var(--color-accent-1);
  background: var(--color-accent-2-light);
  transform: translateY(-2px);
}

.footer-copy {
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  font-weight: 600;
  white-space: nowrap;
}

.footer-mail {
  justify-self: end;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-text-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-mail:hover {
  color: var(--color-accent-1);
}

@media (max-width: 1024px) {
  .footer-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-nav-secondary,
  .footer-copy,
  .footer-mail {
    justify-self: center;
  }

  .footer-nav-secondary {
    justify-content: center;
  }

  .footer-nav-secondary ul {
    justify-content: center;
  }

  .footer-copy {
    white-space: normal;
  }
}

@media (max-width: 600px) {
  .stack-footer {
    padding: 2.5rem 1.25rem;
  }

  .footer-inner {
    gap: 1.2rem;
  }

  .footer-social {
    gap: 1rem;
  }

  .footer-mail {
    font-size: 1rem;
  }

  .footer-copy {
    font-size: 0.85rem;
    opacity: 0.85;
    font-weight: 500;
  }
}

/* ==============================================
   PAGE UTILS & TRANSITIONS
   ============================================== */
body * .nebula-header,
body:not(.loaded) .nebula-header {
  visibility: visible !important;
}

/* PAGE LOAD COVER */
body {
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--page-load-cover);
  z-index: 9999;
  opacity: 1;
  transition: opacity 0.08s cubic-bezier(0.4, 0, 1, 1);
}

/* ==============================================
   FINAL FIX 2: LOWER Z-INDEX OF PAGE OVERLAY
   ============================================== */
body.loaded::before {
  display: none !important;
}

body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: calc(var(--header-height) + var(--announcement-bar-height) + 1.5rem);
  background: var(--color-page-bg);
  z-index: 998;
  pointer-events: none;
}