/*
  V LEGACY — modern, mobile-first CSS using progressive enhancement.
  Uses CSS variables, fluid type, container queries, and reduced-motion fallbacks.
*/

:root {
  --bg: #0a0f1a; /* deep navy */
  --surface: #101725; /* cooler surface */
  --text: #f7f9ff;
  --muted: #b7c2d9;
  /* Electric blue brand palette to match reference image */
  --brand: #1d6fff; /* electric blue */
  --brand-accent: #5de0ff; /* cyan accent */
  --brand-dark: #0e3ea8;
  --card: #131a28;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-1: 0 10px 30px rgba(0,0,0,.35);
  --shadow-2: 0 20px 60px rgba(0,0,0,.45);
  --container: clamp(960px, 85vw, 1200px);
}

/* Fluid type scale */
html { font-size: 16px; }
@media (min-width: 480px) { html { font-size: 17px; } }
@media (min-width: 768px) { html { font-size: 18px; } }

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background: radial-gradient(1200px 600px at 20% -10%, rgba(29,111,255,.14), transparent 60%),
              radial-gradient(1000px 500px at 120% 10%, rgba(93,224,255,.08), transparent 50%),
              var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container { width: min(var(--container), 100%); margin-inline: auto; padding: 24px; }
.stack { display: inline-flex; gap: 12px; flex-wrap: wrap; }

h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; font-family: "Space Grotesk", Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Helvetica, Arial; }
.display { font-size: clamp(2.25rem, 6vw, 4.25rem); font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 800; }
h3 { font-size: clamp(1.125rem, 2.2vw, 1.375rem); font-weight: 700; }

.kicker { color: var(--muted); font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }

/* Header */
.site-header { position: fixed; inset-inline: 0; top: 0; z-index: 40; backdrop-filter: saturate(1.1) blur(10px); background: color-mix(in srgb, var(--bg) 70%, transparent); border-bottom: 1px solid rgba(255,255,255,.06); transition: background .25s ease, box-shadow .25s ease, border-color .25s ease, height .25s ease; height: 120px; }
.site-header .brand img { height: 92px; width: auto; margin-block: 8px; transition: height .25s ease, opacity .25s ease, margin .25s ease; }
.site-header .header-inner { height: 100%; display: flex; align-items: center; }
.site-header.is-scrolled { background: color-mix(in srgb, var(--bg) 85%, transparent); border-color: rgba(255,255,255,.10); box-shadow: 0 10px 28px rgba(0,0,0,.35); height: 64px; }
.site-header.is-scrolled .brand img { height: 44px; opacity: .98; }
.main { padding-top: 120px; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 16px; color: var(--text); text-decoration: none; font-weight: 800; letter-spacing: .02em; }
.nav { display: inline-flex; gap: 18px; align-items: center; }
.nav a { color: #dfe3ee; text-decoration: none; font-weight: 700; letter-spacing: .01em; }
.nav a:hover { color: #ffffff; }

/* Mobile: hide desktop nav and show hamburger */
@media (max-width: 880px) {
  .nav { display: none; }
}

.menu-toggle { display: none; position: relative; width: 44px; height: 44px; border-radius: 10px; border: 1px solid rgba(255,255,255,.2); background: rgba(0,0,0,.35); cursor: pointer; align-items: center; justify-content: center; }
.menu-toggle .bar { display: block; width: 22px; height: 2px; background: #fff; margin: 3px 0; transition: transform .25s ease, opacity .25s ease; }
@media (max-width: 880px) {
  .menu-toggle { display: inline-flex; }
}
.menu-toggle.is-open .bar:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.menu-toggle.is-open .bar:nth-child(2) { opacity: 0; }
.menu-toggle.is-open .bar:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

/* Mobile menu overlay */
.mobile-menu { position: fixed; inset: 0; z-index: 39; display: grid; place-items: end; background: rgba(11,12,16,0); pointer-events: none; transition: background .25s ease; }
.mobile-menu .menu-panel { width: 100%; max-height: 85vh; transform: translateY(8%); opacity: 0; padding: 20px 24px 32px; background: linear-gradient(180deg, rgba(20,22,29,.98), rgba(11,12,16,.96)); border-top: 1px solid rgba(255,255,255,.08); box-shadow: 0 -20px 50px rgba(0,0,0,.45); border-radius: 16px 16px 0 0; transition: transform .3s ease, opacity .3s ease; display: grid; gap: 12px; }
.mobile-menu a { color: #f1f2f6; text-decoration: none; font-weight: 700; font-size: 1.1rem; padding: 12px 8px; border-radius: 10px; }
.mobile-menu a:hover { background: rgba(255,255,255,.06); }
.mobile-menu[aria-hidden="false"] { background: rgba(11,12,16,.45); pointer-events: auto; }
.mobile-menu[aria-hidden="false"] .menu-panel { transform: translateY(0); opacity: 1; }

/* Buttons */
.btn { --_bg: var(--card); --_fg: var(--text); display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 10px 16px; border-radius: var(--radius-sm); color: var(--_fg); background: var(--_bg); text-decoration: none; border: 1px solid rgba(255,255,255,.08); box-shadow: var(--shadow-1); transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease; }
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-2); }
.btn:active { transform: translateY(0); }
.btn-cta { --_bg: linear-gradient(135deg, var(--brand), var(--brand-accent)); --_fg: #0a0f1a; font-weight: 800; border: none; }
.site-header .btn-cta {
  box-shadow: 0 8px 24px rgba(29, 111, 255, .35), 0 2px 0 rgba(0,0,0,.25);
}
.site-header .btn-cta:hover { box-shadow: 0 14px 38px rgba(29, 111, 255, .5), 0 2px 0 rgba(0,0,0,.25); }
.btn-outline { background: transparent; border-color: rgba(255,255,255,.25); color: var(--text); }
.btn-lg { padding: 14px 22px; font-size: 1.05rem; }

/* Hero */
.hero { position: relative; min-height: 80svh; display: grid; place-items: center; overflow: clip; }
.hero-media { position: absolute; inset: 0; }
.hero-video { width: 100%; height: 100%; object-fit: cover; filter: saturate(1.05) contrast(1.05) brightness(.94); }
.hero-gradient {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    /* subtle colour energy */
    radial-gradient(1400px 700px at 20% 0%, rgba(29,111,255,.18), transparent 45%),
    /* softened black grade */
    linear-gradient(180deg, rgba(0,0,0,.28), rgba(0,0,0,.38)),
    /* top fade for readability */
    linear-gradient(to top, rgba(11,11,12,.60), rgba(11,11,12,.20));
  box-shadow:
    inset 0 -80px 120px rgba(0,0,0,.30),
    inset 0 0 160px rgba(0,0,0,.18);
}
.hero-content { position: relative; text-align: center; max-width: 900px; text-shadow: 0 2px 18px rgba(0,0,0,.35); }
.hero.is-bright .hero-content { text-shadow: 0 4px 26px rgba(0,0,0,.55); }
.hero.is-bright .kicker { color: #eef1f8; }
.hero-cta { margin-top: 18px; display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* Sections */
.section { padding-block: clamp(48px, 10vw, 96px); }
.section-header { text-align: center; max-width: 840px; margin-inline: auto  ; margin-bottom: 24px; }

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
@media (min-width: 900px) {
  .grid-2 { grid-template-columns: 1.1fr .9fr; align-items: center; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.media-card { border-radius: var(--radius); overflow: hidden; background: color-mix(in srgb, var(--card) 75%, transparent); border: 1px solid rgba(255,255,255,.06); box-shadow: var(--shadow-1); }
.media-card img { display: block; width: 100%; height: auto; }

.cards { container-type: inline-size; }
.card { background: linear-gradient(180deg, color-mix(in srgb, var(--card) 65%, transparent), color-mix(in srgb, var(--surface) 95%, transparent)); border: 1px solid rgba(255,255,255,.06); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-1); }
@container (min-width: 700px) { .card { padding: 28px; } }

/* Contributors */
.contributors-grid { display: grid; gap: 24px; grid-template-columns: repeat(1, minmax(0, 1fr)); }
@media (min-width: 680px) { .contributors-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .contributors-grid { grid-template-columns: repeat(3, 1fr); } }
.person { background: var(--card); border: 1px solid rgba(255,255,255,.06); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow-1); display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.person img { width: 100%; height: auto; border-radius: calc(var(--radius) - 6px); }
.person .role { color: var(--muted); margin-top: -6px; }
.person blockquote { margin: 4px 0 0; color: #d6d7de; font-style: italic; }

/* Mobile mentors: stack vertically (no horizontal scroll) */
@media (max-width: 679px) {
  .contributors-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    overflow: visible;
  }
}

/* CTA */
.cta { background: radial-gradient(700px 350px at 10% 10%, rgba(93,224,255,.18), transparent 60%), radial-gradient(800px 400px at 100% 10%, rgba(29,111,255,.22), transparent 65%), linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01)); border-block: 1px solid rgba(255,255,255,.06); text-align: center; }
.cta .deadline { margin-top: 14px; color: var(--muted); }
.cta .small { color: var(--muted); max-width: 900px; margin-inline: auto; }

/* Partners */
.logos { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; align-items: center; justify-items: center; opacity: .95; }
.logos img { filter: grayscale(100%) brightness(1.1); max-width: 160px; height: auto; aspect-ratio: 1 / 1; object-fit: contain; background: rgba(255,255,255,.02); border: 1px solid rgba(255,255,255,.06); border-radius: 12px; padding: 12px; }
@media (min-width: 800px) { .logos { grid-template-columns: repeat(7, 1fr); } }

/* Footer */
.site-footer { padding: 32px 0 48px; text-align: center; color: var(--muted); }
.powered-by { margin-top: 10px; display: inline-flex; align-items: center; gap: 10px; color: #ffffff; opacity: .9; font-weight: 500; letter-spacing: .02em; text-transform: lowercase; }
.powered-by .fa-kit.fa-db-icon { font-size: 24px; }



/* Reveal on scroll */
[data-reveal] { opacity: 0; translate: 0 14px; transition: opacity .6s ease, translate .6s ease; }
[data-reveal].is-visible { opacity: 1; translate: 0 0; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .btn, [data-reveal] { transition: none; }
  .hero-video { display: none; }
}


