:root {
  --bg: #060816;
  --bg-soft: #0c1226;
  --surface: rgba(14, 23, 46, 0.78);
  --surface-strong: rgba(12, 19, 40, 0.92);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --line: rgba(255,255,255,0.12);
  --primary: #f59e0b;
  --primary-strong: #ef4444;
  --accent: #7c3aed;
  --success: #22c55e;
  --danger: #f87171;
  --shadow: 0 22px 60px rgba(0,0,0,0.35);
  --radius-xl: 32px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --container: min(1180px, calc(100vw - 32px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Manrope', system-ui, sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top, #171d39 0%, var(--bg) 55%, #04050d 100%);
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .92em;
  background: rgba(255,255,255,.06);
  border-radius: 10px;
  padding: .15rem .4rem;
}

.site-bg {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 12% 18%, rgba(239,68,68,0.18), transparent 18%),
    radial-gradient(circle at 88% 12%, rgba(124,58,237,0.22), transparent 16%),
    radial-gradient(circle at 50% 82%, rgba(245,158,11,0.12), transparent 18%);
  pointer-events: none;
  z-index: -1;
}

.container { width: var(--container); margin-inline: auto; }
.section { padding: 42px 0 92px; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: rgba(6,8,22,0.72);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 78px;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
}
.brand-kicker {
  font-family: 'Barlow', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .34em;
  color: #fbbf24;
}
.brand-name {
  font-family: 'Barlow', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
}

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
}
.nav a {
  color: var(--muted);
  font-weight: 600;
  transition: color .25s ease;
}
.nav a:hover { color: var(--text); }

.btn {
  border: 0;
  border-radius: 999px;
  padding: 14px 22px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: transform .22s ease, box-shadow .22s ease, opacity .22s ease, background .22s ease;
  font-weight: 800;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  color: #0b1120;
  background: linear-gradient(135deg, #fde68a 0%, var(--primary) 45%, var(--primary-strong) 100%);
  box-shadow: 0 16px 32px rgba(239,68,68,0.24);
}
.btn-secondary {
  color: var(--text);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
}
.btn-small { padding: 10px 16px; font-size: .92rem; }

.hero {
  padding: 48px 0 44px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.02fr 1.18fr;
  gap: 26px;
  align-items: stretch;
}

.glass-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-copy {
  padding: 38px;
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.pill,
.eyebrow,
.hero-tag,
.mini-label,
.timeline-year,
.alias-tag,
.gallery-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  font-size: .84rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-weight: 800;
}

.hero-copy h1,
.event-hero-copy h1 {
  margin: 16px 0 14px;
  font-family: 'Barlow', sans-serif;
  font-size: clamp(2.8rem, 6vw, 5.2rem);
  line-height: .95;
  letter-spacing: -.03em;
}

.lead, .section-heading p, .timeline-card p, .event-card p, .donate-card p, .form-note, .identity-card p, .footer p, .modal p, .medals-copy p, .subsection-head p, .empty-state p, .event-info-card p, .event-callout p {
  color: var(--muted);
  line-height: 1.72;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}
.hero-metrics div,
.event-highlight-grid div {
  padding: 18px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.09);
}
.hero-metrics strong,
.event-highlight-grid strong {
  display: block;
  font-family: 'Barlow', sans-serif;
  font-size: 1.15rem;
}
.hero-metrics span,
.event-highlight-grid span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: .94rem;
}

.hero-banner {
  position: relative;
  overflow: hidden;
  border-radius: 36px;
  padding: 28px;
  background:
    linear-gradient(160deg, rgba(17,24,39,0.94), rgba(30,41,59,0.82)),
    radial-gradient(circle at top right, rgba(239,68,68,0.22), transparent 28%),
    radial-gradient(circle at bottom left, rgba(124,58,237,0.24), transparent 30%);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
}
.hero-banner::before,
.hero-banner::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(20px);
  opacity: .45;
}
.hero-banner::before {
  width: 180px;
  height: 180px;
  background: rgba(245,158,11,0.35);
  top: -40px;
  right: -20px;
}
.hero-banner::after {
  width: 240px;
  height: 240px;
  background: rgba(239,68,68,0.24);
  left: -60px;
  bottom: -70px;
}
.hero-banner-copy {
  position: relative;
  z-index: 2;
  max-width: 520px;
  margin-bottom: 24px;
}
.hero-banner-copy h2 {
  margin: 16px 0 12px;
  font-family: 'Barlow', sans-serif;
  font-size: clamp(2rem, 4.2vw, 3rem);
  line-height: 1.02;
}
.hero-banner-copy p { color: #dbeafe; line-height: 1.66; }

.hero-collage {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1.08fr 1fr;
  gap: 16px;
  align-items: end;
}
.photo-card {
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 20px 42px rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.04);
}
.photo-card img { width: 100%; height: 100%; object-fit: cover; }
.photo-card-center { transform: translateY(24px); }
.tilt-card {
  transition: transform .35s ease, box-shadow .35s ease;
}
.tilt-card:hover {
  transform: translateY(-8px) rotate(-1deg);
  box-shadow: 0 30px 56px rgba(0,0,0,0.34);
}
.photo-card-center:hover {
  transform: translateY(12px) rotate(1deg);
}

.goal { padding: 10px 0 36px; }
.goal-image,
.event-poster img {
  width: 100%;
  border-radius: 32px;
  box-shadow: var(--shadow);
}

.two-col {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 24px;
  align-items: center;
}
.section-heading h2,
.donate-card h2,
.form-card h2,
.event-card h2,
.modal-panel h2,
.event-info-card h2,
.event-callout h2 {
  margin: 12px 0 12px;
  font-family: 'Barlow', sans-serif;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.04;
}
.section-heading.center { text-align: center; max-width: 820px; margin-inline: auto; }

.identity-card {
  display: flex;
  gap: 20px;
  padding: 26px;
  border-radius: 28px;
  align-items: center;
}
.identity-card img {
  width: min(180px, 42%);
  filter: drop-shadow(0 10px 22px rgba(0,0,0,.25));
}
.identity-card h3 {
  margin: 10px 0 8px;
  font-family: 'Barlow', sans-serif;
  font-size: 1.6rem;
}

.gallery-section { padding-top: 22px; }
.gallery-layout {
  margin-top: 32px;
  display: grid;
  grid-template-columns: 1.08fr .92fr .92fr;
  gap: 18px;
}
.gallery-card {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,.04);
  box-shadow: var(--shadow);
  cursor: pointer;
}
.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}
.gallery-card:hover img { transform: scale(1.04); }
.gallery-card-lg {
  grid-row: span 2;
  min-height: 580px;
}
.gallery-overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 18px;
  background: linear-gradient(180deg, transparent, rgba(3, 6, 18, 0.88) 56%, rgba(3,6,18,0.96));
}
.gallery-overlay h3 {
  margin: 10px 0 6px;
  font-family: 'Barlow', sans-serif;
  font-size: 1.42rem;
}
.gallery-overlay p { margin: 0; color: #dbeafe; line-height: 1.55; }
.play-pill {
  margin-top: 10px;
  border: 0;
  color: white;
  background: rgba(255,255,255,.14);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 800;
}

.sponsors { overflow: hidden; }
.logo-marquee {
  position: relative;
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  padding-top: 12px;
}
.logo-track {
  display: flex;
  align-items: center;
  gap: 18px;
  width: max-content;
  animation: marquee 34s linear infinite;
}
.logo-marquee:hover .logo-track { animation-play-state: paused; }
.logo-item {
  flex: 0 0 auto;
  width: 280px;
  padding: 8px;
  border-radius: 28px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 20px 40px rgba(0,0,0,0.16);
}
.logo-item img { width: 100%; }

.dynamic-sponsors-wrap {
  margin-top: 34px;
}
.subsection-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}
.subsection-head h3 {
  margin: 12px 0 0;
  font-family: 'Barlow', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}
.dynamic-sponsor-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.dynamic-sponsor-card {
  padding: 16px;
  border-radius: 24px;
}
.dynamic-sponsor-card strong {
  display: block;
  margin-top: 14px;
  font-family: 'Barlow', sans-serif;
  font-size: 1.12rem;
}
.dynamic-sponsor-card span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: .92rem;
}
.dynamic-sponsor-logo {
  height: 120px;
  border-radius: 18px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 12px;
}
.dynamic-sponsor-logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.empty-state {
  display: flex;
  gap: 18px;
  align-items: center;
  padding: 22px;
  border-radius: 28px;
}
.empty-state img {
  width: 120px;
  filter: drop-shadow(0 10px 22px rgba(0,0,0,.28));
}
.empty-state strong {
  display: block;
  font-family: 'Barlow', sans-serif;
  font-size: 1.5rem;
}

.timeline-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 30px;
}
.timeline-card {
  padding: 26px;
  border-radius: 28px;
}
.timeline-card h3 {
  margin: 16px 0 12px;
  font-family: 'Barlow', sans-serif;
  font-size: 1.6rem;
}

.medals-panel {
  margin-top: 26px;
  padding: 28px;
  border-radius: 30px;
  display: grid;
  grid-template-columns: .95fr 1.05fr;
  gap: 24px;
  align-items: center;
}
.medals-copy h3 {
  margin: 12px 0 10px;
  font-family: 'Barlow', sans-serif;
  font-size: 2rem;
  line-height: 1.06;
}
.medal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.medal {
  min-height: 160px;
  padding: 20px;
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(255,255,255,0.12);
}
.medal span { font-size: 2.2rem; }
.medal strong {
  font-size: 1.15rem;
  font-family: 'Barlow', sans-serif;
}
.medal small { color: rgba(255,255,255,0.76); }
.medal-gold { background: linear-gradient(160deg, rgba(253,230,138,0.34), rgba(245,158,11,0.18)); }
.medal-silver { background: linear-gradient(160deg, rgba(226,232,240,0.3), rgba(148,163,184,0.12)); }
.medal-bronze { background: linear-gradient(160deg, rgba(251,146,60,0.28), rgba(194,65,12,0.16)); }
.medal-dark { background: linear-gradient(160deg, rgba(59,130,246,0.18), rgba(17,24,39,0.32)); }
.medal-image-card {
  padding: 0;
  overflow: hidden;
}
.medal-image-card img { width: 100%; height: 100%; object-fit: cover; }

.event-card {
  padding: 32px;
  border-radius: 32px;
  background:
    linear-gradient(145deg, rgba(245,158,11,0.14), rgba(124,58,237,0.18)),
    rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.donate-grid {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 24px;
}
.donate-card,
.form-card {
  padding: 30px;
  border-radius: 30px;
}
.alias-box {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 24px;
  border-radius: 26px;
  margin: 18px 0 20px;
  background: linear-gradient(135deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  border: 1px solid rgba(255,255,255,0.12);
}
.alias-box strong {
  font-family: 'Barlow', sans-serif;
  font-size: clamp(2rem, 6vw, 3.3rem);
  letter-spacing: -.02em;
}
.qr-wrap {
  max-width: 200px;
  background: rgba(255,255,255,0.06);
  padding: 12px;
  border-radius: 26px;
  border: 1px solid rgba(255,255,255,0.12);
}

.sponsor-form { margin-top: 12px; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.form-grid label {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.form-grid .full { grid-column: 1 / -1; }
.form-grid span { color: #e2e8f0; font-weight: 700; }
.form-grid input,
.form-grid textarea {
  width: 100%;
  padding: 15px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(6,8,22,0.66);
  color: var(--text);
  outline: none;
  transition: border-color .22s ease, box-shadow .22s ease;
}
.form-grid input:focus,
.form-grid textarea:focus {
  border-color: rgba(253,230,138,0.85);
  box-shadow: 0 0 0 4px rgba(245,158,11,0.12);
}
.form-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
}
.logo-preview {
  min-height: 110px;
  flex: 1;
  border-radius: 22px;
  border: 1px dashed rgba(255,255,255,0.16);
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--muted);
  font-weight: 600;
}
.logo-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
  background: white;
}
.form-note {
  margin: 14px 0 0;
  font-size: .95rem;
}
.flash-message {
  margin: 0 0 16px;
  padding: 14px 16px;
  border-radius: 16px;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,0.12);
}
.flash-message.success {
  background: rgba(34,197,94,0.12);
  color: #dcfce7;
  border-color: rgba(34,197,94,0.28);
}
.flash-message.error {
  background: rgba(248,113,113,0.12);
  color: #fee2e2;
  border-color: rgba(248,113,113,0.28);
}

.footer {
  padding: 24px 0 40px;
}
.footer-inner {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
}
.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.footer-links a { color: var(--muted); font-weight: 600; }
.footer-links a:hover { color: var(--text); }

.modal {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  z-index: 60;
}
.modal.active { display: grid; }
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3,6,18,.7);
  backdrop-filter: blur(8px);
}
.modal-panel {
  position: relative;
  z-index: 2;
  width: min(860px, calc(100vw - 30px));
  padding: 30px;
  border-radius: 30px;
  background: linear-gradient(180deg, rgba(17,24,39,0.96), rgba(13,17,30,0.96));
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
}
.modal-panel-gallery { max-width: 920px; }
.modal-close {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.05);
  color: white;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
}
.gallery-modal-media {
  margin: 18px 0 16px;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
}
.gallery-modal-media img {
  width: 100%;
  display: block;
}
.gallery-video-placeholder {
  position: relative;
}
.gallery-video-placeholder::after {
  content: 'VIDEO DEMO';
  position: absolute;
  right: 16px;
  bottom: 16px;
  background: rgba(3,6,18,.78);
  color: white;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: .08em;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  opacity: 0;
  pointer-events: none;
  background: rgba(15, 23, 42, 0.94);
  color: white;
  padding: 14px 20px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 18px 34px rgba(0,0,0,0.28);
  transition: opacity .25s ease, transform .25s ease;
  z-index: 80;
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.delay-1 { transition-delay: .12s; }
.delay-2 { transition-delay: .22s; }

.event-page-main { padding-top: 18px; }
.event-hero-grid,
.event-info-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: stretch;
}
.event-hero-copy,
.event-info-card,
.event-callout {
  padding: 32px;
  border-radius: 30px;
}
.event-highlight-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}
.event-list {
  margin: 18px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.85;
}
.event-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-50% - 9px)); }
}

@media (max-width: 1100px) {
  .gallery-layout,
  .dynamic-sponsor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .gallery-card-lg { grid-row: span 1; min-height: 420px; }
}

@media (max-width: 1024px) {
  .hero-grid,
  .two-col,
  .donate-grid,
  .medals-panel,
  .timeline-grid,
  .event-hero-grid,
  .event-info-layout,
  .event-highlight-grid {
    grid-template-columns: 1fr;
  }

  .hero-banner-copy { max-width: none; }
  .hero-collage { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .event-card,
  .footer-inner,
  .form-footer,
  .subsection-head,
  .event-callout {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 780px) {
  .nav { display: none; }
  .desktop-only { display: none; }
  .topbar-inner { min-height: 70px; }
  .hero { padding-top: 28px; }
  .hero-copy,
  .hero-banner,
  .donate-card,
  .form-card,
  .modal-panel,
  .event-card,
  .medals-panel,
  .timeline-card,
  .event-info-card,
  .event-hero-copy,
  .event-callout { padding: 22px; }
  .hero-metrics,
  .form-grid,
  .medal-grid,
  .gallery-layout,
  .dynamic-sponsor-grid { grid-template-columns: 1fr; }
  .hero-collage { grid-template-columns: 1fr; }
  .photo-card-center { transform: none; }
  .identity-card,
  .empty-state {
    flex-direction: column;
    align-items: flex-start;
  }
  .identity-card img,
  .empty-state img {
    width: 180px;
  }
  .logo-item { width: 230px; }
  .gallery-card,
  .gallery-card-lg { min-height: 280px; }
}
