:root {
  --bg: #0c1018;
  --surface: #101725;
  --card: #131c2e;
  --text: #e9eef6;
  --muted: #9fb0c6;
  --accent: #23ffd4;
  --accent-2: #21c9ff;
  --header-h: 80px;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0,0,0,.25);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: radial-gradient(1200px 700px at 20% -10%, rgba(33,201,255,.08), transparent 60%),
              radial-gradient(1000px 600px at 120% 20%, rgba(35,255,212,.08), transparent 60%),
              var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
}

a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: min(1100px, 92vw);
  margin: 0 auto;
}

header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(16, 23, 37, .65);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  letter-spacing: 1.5px;
  font-size: 1.45rem;
  color: var(--accent);
  text-shadow: 0 4px 20px rgba(35,255,212,.25);
}

nav { display: flex; gap: 1.2rem; align-items: center; }
nav a {
  color: var(--text);
  padding: .4rem .2rem;
  border-bottom: 2px solid transparent;
  transition: color .15s ease, border-color .2s ease;
  font-weight: 600;
  opacity: .9;
}
nav a:hover { color: white; }
nav a.active { color: var(--accent); border-color: var(--accent); }

header { position: sticky; top: 0; z-index: 100; } /* ensure menu overlays content */

.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; border: 0; background: transparent; }
.hamburger span { width: 28px; height: 3px; background: #fff; border-radius: 2px; }

@media (max-width: 900px) {
  /* Mobile panel */
  nav {
    display: none;
    position: absolute;
    right: 4vw;
    top: calc(var(--header-h) + 8px);
    background: rgba(16, 23, 37, .98);
    border: 1px solid rgba(255,255,255,.08);
    padding: 0.6rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    flex-direction: column;
    gap: .2rem;
    z-index: 200; /* above everything */
    max-height: 0;
    overflow: hidden;
    transition: max-height .25s ease;
  }
  nav.open {
    display: flex;
    max-height: 70vh; /* enables the slide-down feel */
  }

  nav a { padding: .6rem .8rem; border-radius: 8px; }
  nav a:hover { background: rgba(255,255,255,.06); text-decoration: none; }

  .hamburger { display: flex; z-index: 210; }
}


/* Hero */
.hero {
  position: relative; overflow: hidden;
  min-height: 62vh;
  display: grid; place-items: center; text-align: center;
  background: url('../images/hero.jpg') center/cover no-repeat;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(16,23,37,.68) 0%, rgba(16,23,37,.85) 60%, rgba(16,23,37,.95) 100%);
}
.hero-inner { position: relative; z-index: 2; padding: 8vh 0; width: min(900px, 92vw); }
.hero h1 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: clamp(2.2rem, 6vw, 4rem);
  margin: 0 0 .6rem 0;
  color: var(--accent);
}
.hero p { margin: 0 auto 1.2rem; font-size: clamp(1rem, 2.6vw, 1.25rem); color: var(--muted); }

.button, .btn {
  display: inline-block;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #0c1018; font-weight: 800; letter-spacing: .4px;
  padding: .9rem 1.3rem; border-radius: 999px; border: none;
  box-shadow: 0 10px 30px rgba(35,255,212,.18), 0 8px 24px rgba(33,201,255,.12);
  transition: transform .12s ease, box-shadow .12s ease;
}
.button:hover, .btn:hover { transform: translateY(-1px); text-decoration:none; box-shadow: 0 14px 36px rgba(35,255,212,.22), 0 12px 30px rgba(33,201,255,.16); }

main { padding: 2.4rem 0 3rem; }

.card {
  background: linear-gradient(180deg, rgba(19,28,46,.9), rgba(19,28,46,.8));
  border: 1px solid rgba(255,255,255,.06);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
  margin: 1rem 0 1.2rem;
}
.card h2 {
  margin: 0 0 .6rem 0;
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(1.4rem, 3.2vw, 2rem);
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.1rem;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.feature {
  background: rgba(255,255,255,.02);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px; padding: 1rem;
}
.feature h3 { margin: .2rem 0 .4rem; font-size: 1.1rem; }
.muted { color: var(--muted); }

.gallery-grid {
  display: grid; gap: .9rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.gallery-grid img {
  width: 100%; height: 220px; object-fit: cover;
  border-radius: 12px; display: block;
  filter: saturate(1.08) contrast(1.02);
  transition: transform .15s ease;
}
.gallery-grid img:hover { transform: scale(1.02); }

footer {
  margin-top: 2.5rem;
  border-top: 1px solid rgba(255,255,255,.06);
  background: rgba(16,23,37,.65);
  backdrop-filter: blur(10px);
}
.footer-inner {
  padding: 1.4rem 0;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}
.socials a img {
  filter: grayscale(30%); opacity: .85; vertical-align: middle;
  transition: filter .15s ease, opacity .15s ease, transform .15s ease;
}
.socials a:hover img { filter: none; opacity: 1; transform: translateY(-1px) scale(1.06); }

/* Forms */
input, textarea {
  background: #0e1524; color: var(--text);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px; padding: .85rem .9rem;
  outline: none;
}
input:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(35,255,212,.15); }

/* Map container */
.map-wrap { background:#0e1524; border:1px solid rgba(255,255,255,.06); border-radius: 12px; overflow: hidden; }
iframe { display:block; border:0; }

/* Default Dark Mode (already defined) */
:root {
  --bg: #0c1018;
  --surface: #101725;
  --card: #131c2e;
  --text: #e9eef6;
  --muted: #9fb0c6;
  --accent: #23ffd4;
  --accent-2: #21c9ff;
  --header-h: 80px;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0,0,0,.25);
}

/* Light Mode */
:root.light {
  --bg: #fdfdfd;
  --surface: #f8faff;
  --card: #ffffff;
  --text: #1a1a1a;
  --muted: #5a667a;
  --accent: #0077ff;
  --accent-2: #00b894;
  --shadow: 0 8px 22px rgba(0,0,0,.08);
}

/* Apply themed backgrounds */
html, body {
  background: radial-gradient(1200px 700px at 20% -10%, rgba(33,201,255,.08), transparent 60%),
              radial-gradient(1000px 600px at 120% 20%, rgba(35,255,212,.08), transparent 60%),
              var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
}

/* Light mode background gradient variant */
:root.light body {
  background: radial-gradient(1200px 700px at 20% -10%, rgba(0,119,255,.08), transparent 60%),
              radial-gradient(1000px 600px at 120% 20%, rgba(0,184,148,.08), transparent 60%),
              var(--bg);
}

/* Hero adjustments for light mode */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16,23,37,.68) 0%, rgba(16,23,37,.85) 60%, rgba(16,23,37,.95) 100%);
}
:root.light .hero::after {
  background: linear-gradient(180deg, rgba(255,255,255,.65) 0%, rgba(255,255,255,.85) 60%, rgba(255,255,255,.95) 100%);
}

/* Cards look brighter in light mode */
:root.light .card {
  background: linear-gradient(180deg, rgba(255,255,255,.95), rgba(250,250,250,.9));
  border: 1px solid rgba(0,0,0,.06);
}

/* Inputs for light mode */
:root.light input,
:root.light textarea {
  background: #f1f5f9;
  color: #222;
  border: 1px solid rgba(0,0,0,.1);
}
:root.light input:focus,
:root.light textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,119,255,.15);
}

/* Footer light variant */
:root.light footer {
  background: rgba(255,255,255,.85);
  border-top: 1px solid rgba(0,0,0,.08);
}

#themeToggle {
  padding: .5rem 1rem;
  font-size: 0.9rem;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid rgba(0,0,0,.1);
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
:root.light #themeToggle {
  background: #f1f5f9;
  border: 1px solid rgba(0,0,0,.1);
}


/* === Neon hex grid with scroll-reactive glow === */
.hero {
  /* base controls (tweak freely) */
  --hexOpacity: 0.77;         /* overall visibility */
  --pulseFactor: 1;            /* pulsing multiplier (animated) */
  --scrollBoost: 1;            /* JS sets this based on scroll speed */
  --glowBrightness: 3.5;       /* base brightness (animated) */
  --glowSize: 16px;            /* base drop-shadow size (animated) */
  --glowColor: #23ffd4;        /* animated colour */
}

/* Animated hex pattern over the hero */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url('../images/hero-hex.svg');
  background-size: 260px 226px;
  background-repeat: repeat;
  mix-blend-mode: screen;
  /* visibility now = base * pulse * scroll */
  opacity: calc(var(--hexOpacity) * var(--pulseFactor) * var(--scrollBoost));
  /* brightness & glow scale with scroll too */
  filter:
    brightness(calc(var(--glowBrightness) * var(--scrollBoost)))
    drop-shadow(0 0 calc(var(--glowSize) * var(--scrollBoost)) var(--glowColor));
  will-change: background-position, filter, opacity;
  z-index: 1;
  animation:
    hexDrift 10s linear infinite,
    hexPulse 4s ease-in-out infinite;
}

/* background drift */
@keyframes hexDrift {
  from { background-position: 0 0; }
  to   { background-position: 520px 226px; }
}

/* Stronger pulse + alt colours (turquoise → cyan → white → cyan → turquoise) */
@keyframes hexPulse {
  0% {
    --pulseFactor: 1;
    --glowBrightness: 3.8;
    --glowSize: 16px;
    --glowColor: #23ffd4;
  }
  25% {
    --pulseFactor: 1.05;
    --glowBrightness: 4.6;
    --glowSize: 20px;
    --glowColor: #21c9ff;
  }
  50% {
    --pulseFactor: 0.95;
    --glowBrightness: 5.4;
    --glowSize: 26px;
    --glowColor: #ffffff;
  }
  75% {
    --pulseFactor: 1.05;
    --glowBrightness: 4.4;
    --glowSize: 20px;
    --glowColor: #21c9ff;
  }
  100% {
    --pulseFactor: 1;
    --glowBrightness: 3.8;
    --glowSize: 16px;
    --glowColor: #23ffd4;
  }
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  .hero::before { animation: none; }
  .hero { --scrollBoost: 1 !important; }
}

/* your existing code ... */

/* === Light-mode mobile menu fix === */
@media (max-width: 900px) {
  :root.light header {
    background: rgba(255,255,255,.85);
    border-bottom: 1px solid rgba(0,0,0,.06);
  }

  :root.light .hamburger span { background: #222; }

  :root.light nav {
    background: rgba(255,255,255,.98);
    border: 1px solid rgba(0,0,0,.08);
    box-shadow: 0 12px 30px rgba(0,0,0,.12);
  }

  :root.light nav a {
    color: #111;
    opacity: 1;
  }

  :root.light nav a:hover {
    background: rgba(0,0,0,.06);
    color: #000;
    text-decoration: none;
  }

  :root.light nav a.active {
    color: var(--accent);
    border-color: var(--accent);
  }

  :root.light #themeToggle {
    background: #f1f5f9;
    border: 1px solid rgba(0,0,0,.12);
    color: #111;
  }
}

/* --- Theme selector UI --- */
.theme-control {
  display: inline-flex; align-items: center; gap: .5rem;
  font-weight: 700; font-size: .95rem;
}
.theme-control label { opacity: .9; }
.select-wrap { position: relative; }
#themeSelect {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  padding: .5rem 2rem .5rem .8rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: var(--surface);
  color: var(--text);
  font-weight: 700; cursor: pointer;
}
.chev {
  position: absolute; right: .7rem; top: 50%; transform: translateY(-50%);
  pointer-events: none; opacity: .7;
}

/* Light-mode visuals for the selector */
:root.light #themeSelect {
  background: #f1f5f9;
  border: 1px solid rgba(0,0,0,.12);
  color: #111;
}
:root.light .chev { color: #222; }

/* Mobile menu spacing */
@media (max-width: 900px) {
  .theme-control { width: 100%; justify-content: space-between; }
  #themeSelect { width: 170px; }
}

/* ========= PARTY THEME ========= */
:root.party {
  --bg: #0b0b12;             /* keep dark base so colours pop */
  --surface: #111224;
  --card: #12152b;
  --text: #fefefe;
  --muted: #c8d0ff;
  --accent: #ff4d9d;          /* hot pink */
  --accent-2: #22d3ee;        /* cyan */
  --shadow: 0 12px 32px rgba(0,0,0,.35);
}

/* Colourful animated background */
:root.party body {
  background:
    radial-gradient(900px 600px at 15% -10%, rgba(255,77,157,.20), transparent 60%),
    radial-gradient(900px 600px at 110% 10%, rgba(34,211,238,.22), transparent 60%),
    conic-gradient(from var(--spin, 0deg),
      rgba(255,77,157,.20),
      rgba(255,196,45,.15),
      rgba(34,211,238,.18),
      rgba(154,119,255,.18),
      rgba(255,77,157,.20)
    ),
    var(--bg);
  animation: partySpin 18s linear infinite;
}
@keyframes partySpin { to { --spin: 360deg; } }

/* Hero overlay a bit lighter so headline pops */
:root.party .hero::after {
  background: linear-gradient(180deg, rgba(14,16,34,.55) 0%, rgba(14,16,34,.78) 60%, rgba(14,16,34,.92) 100%);
}

/* Buttons: rainbow sweep */
:root.party .button, :root.party .btn {
  background: linear-gradient(90deg,
    #ff4d9d, #ffc42d, #22d3ee, #9a77ff, #ff4d9d);
  background-size: 300% 100%;
  color: #0b0b12;
  box-shadow: 0 12px 28px rgba(255,77,157,.22), 0 10px 24px rgba(34,211,238,.18);
  animation: partyBtn 6s linear infinite;
}
@keyframes partyBtn { 0%{background-position:0%} 100%{background-position:100%} }

/* Links + nav accents */
:root.party a { color: #ffc42d; }
:root.party nav a.active { color: var(--accent); border-color: var(--accent); }
:root.party nav a:hover { color: #fff; }

/* Cards get subtle neon edge */
:root.party .card {
  background: linear-gradient(180deg, rgba(18,21,43,.92), rgba(18,21,43,.84));
  border: 1px solid rgba(255,196,45,.18);
  box-shadow: 0 12px 30px rgba(0,0,0,.35),
              0 0 0 1px rgba(34,211,238,.10) inset;
}

/* Gallery hover pop */
:root.party .gallery-grid img:hover { transform: scale(1.03) rotate(.3deg); }

/* Inputs */
:root.party input, :root.party textarea {
  background: #0f1330; color: #f8f9ff;
  border: 1px solid rgba(154,119,255,.35);
}
:root.party input:focus, :root.party textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255,77,157,.25);
}

/* Footer */
:root.party footer {
  background: linear-gradient(180deg, rgba(18,19,42,.75), rgba(18,19,42,.9));
  border-top: 1px solid rgba(255,196,45,.18);
}

/* Mobile menu background in Party */
@media (max-width: 900px) {
  :root.party nav {
    background: rgba(13,14,35,.98);
    border: 1px solid rgba(255,196,45,.18);
    box-shadow: 0 16px 40px rgba(0,0,0,.45);
  }
  :root.party .hamburger span { background: #fff; }
}
