/* ============================================
   CEAP - CubeSat Engineering & Applications Program
   ISU Brand System: Dark Blue #06359D, Bright Blue #229ED9
   Fonts: Manrope (body), Outfit (headings)
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;500;700;800&family=Manrope:wght@300;400;500;600;700;800&family=Fira+Code:wght@400;700&display=swap');

:root {
  --isu-navy: #06359D;
  --isu-bright: #229ED9;
  --isu-gold: #C8A951;
  --bg-deep: #030A1A;
  --bg-surface: #0A1628;
  --bg-card: rgba(10, 22, 40, 0.7);
  --glass-border: rgba(34, 158, 217, 0.15);
  --text-primary: #E8EDF5;
  --text-muted: #8A9BB5;
  --accent-color: #229ED9;
  --accent-glow: rgba(34, 158, 217, 0.3);
  --gold: #C8A951;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Manrope', sans-serif;
  --font-mono: 'Fira Code', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font-body);
  background: var(--bg-deep);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Background effects */
.bg-grid {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(34, 158, 217, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34, 158, 217, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  z-index: 0;
  pointer-events: none;
}

.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.15;
  z-index: 0;
  pointer-events: none;
}
.blob-1 { width: 600px; height: 600px; background: var(--isu-navy); top: -200px; right: -200px; }
.blob-2 { width: 500px; height: 500px; background: var(--isu-bright); bottom: -200px; left: -200px; }
.blob-3 { width: 400px; height: 400px; background: var(--gold); top: 50%; left: 50%; transform: translate(-50%, -50%); opacity: 0.05; }

/* ===== NAV ===== */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  padding: 0.8rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(3, 10, 26, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.logo-container img { height: 36px; width: auto; filter: brightness(0) invert(1); }

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
}
.logo-text .accent { color: var(--isu-bright); }

.nav-menu { display: flex; gap: 1.5rem; }
.nav-menu a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-menu a:hover { color: var(--isu-bright); }
.nav-menu a.highlight { color: var(--gold); }

.nav-cta {
  background: var(--isu-bright);
  color: #fff;
  padding: 0.5rem 1.2rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.3s;
  border: none;
  cursor: pointer;
}
.nav-cta:hover { background: #1a8bc2; transform: translateY(-1px); box-shadow: 0 4px 15px var(--accent-glow); }

/* ===== HERO ===== */
header {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero-image-container {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(3, 10, 26, 0.4) 0%,
    rgba(3, 10, 26, 0.7) 50%,
    rgba(3, 10, 26, 1) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 6rem 2rem 2rem;
}

.badge {
  display: inline-block;
  background: rgba(34, 158, 217, 0.15);
  border: 1px solid rgba(34, 158, 217, 0.3);
  color: var(--isu-bright);
  padding: 0.4rem 1.2rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.hero-content h1 {
  font-family: var(--font-heading);
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  letter-spacing: -1px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--isu-bright), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 2.5rem;
  line-height: 1.8;
}

.cta-group {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 2rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.3s;
  cursor: pointer;
  border: none;
  font-family: var(--font-body);
}
.cta-button.primary {
  background: var(--isu-bright);
  color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
}
.cta-button.primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px var(--accent-glow); }
.cta-button.secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid var(--glass-border);
}
.cta-button.secondary:hover { background: rgba(255, 255, 255, 0.1); }
.cta-button.gold {
  background: linear-gradient(135deg, var(--gold), #E8C860);
  color: #0A1628;
}

/* ===== STATS BAR ===== */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--glass-border);
  border-radius: 16px;
  overflow: hidden;
  margin: 4rem auto 0;
  max-width: 800px;
}
.stat-item {
  background: var(--bg-card);
  padding: 1.5rem;
  text-align: center;
}
.stat-number {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  color: var(--isu-bright);
}
.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 0.3rem;
}

/* ===== SECTIONS ===== */
main { position: relative; z-index: 1; }

.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 3rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== CARDS ===== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}
.card:hover {
  border-color: rgba(34, 158, 217, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

/* ===== PROGRAM GRID ===== */
.program-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.program-card {
  position: relative;
  overflow: hidden;
}
.program-card .card-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}
.program-card h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 0.8rem;
}
.program-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}
.program-card .card-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.3rem 0.8rem;
  border-radius: 6px;
  margin-top: 1rem;
}
.tag-online { background: rgba(16, 185, 129, 0.15); color: var(--success); }
.tag-campus { background: rgba(34, 158, 217, 0.15); color: var(--isu-bright); }
.tag-launch { background: rgba(200, 169, 81, 0.15); color: var(--gold); }

/* ===== TIMELINE ===== */
.timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding-left: 3rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--isu-bright), var(--gold), var(--success));
}
.timeline-item {
  position: relative;
  padding-bottom: 3rem;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -3.45rem;
  top: 0.5rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--isu-bright);
  border: 3px solid var(--bg-deep);
  box-shadow: 0 0 15px var(--accent-glow);
}
.timeline-item.gold::before { background: var(--gold); }
.timeline-item.green::before { background: var(--success); }

.timeline-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--isu-bright);
  margin-bottom: 0.3rem;
}
.timeline-item h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.timeline-item p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ===== COHORT STORIES ===== */
.cohort-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}
.cohort-card {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  padding: 2.5rem 2rem;
}
.cohort-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
}
.cohort-africa::before { background: linear-gradient(90deg, #10B981, #34D399); }
.cohort-women::before { background: linear-gradient(90deg, #8B5CF6, #C084FC); }
.cohort-sids::before { background: linear-gradient(90deg, #229ED9, #67E8F9); }

.cohort-emoji {
  font-size: 3rem;
  margin-bottom: 1rem;
}
.cohort-card h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}
.cohort-card .mission-name {
  color: var(--gold);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.cohort-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}
.cohort-stat {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.8rem 0;
  border-top: 1px solid rgba(255,255,255,0.05);
  font-size: 0.85rem;
  color: var(--text-muted);
}
.cohort-stat strong { color: var(--text-primary); }

/* ===== BUDGET SECTION ===== */
.budget-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.budget-card h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.budget-row {
  display: flex;
  justify-content: space-between;
  padding: 0.7rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 0.9rem;
}
.budget-row .label { color: var(--text-muted); }
.budget-row .value { font-weight: 700; font-family: var(--font-mono); }
.budget-row.total { border-top: 2px solid var(--isu-bright); border-bottom: none; padding-top: 1rem; }
.budget-row.total .value { color: var(--isu-bright); font-size: 1.1rem; }
.budget-row.surplus .value { color: var(--success); }

/* ===== FACULTY ===== */
.faculty-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
}
.faculty-card {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.faculty-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--isu-navy), var(--isu-bright));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  flex-shrink: 0;
}
.faculty-info h4 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
}
.faculty-info .role {
  color: var(--isu-bright);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.faculty-info p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 0.3rem;
}

/* ===== COMPARISON TABLE ===== */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.compare-table th {
  background: rgba(34, 158, 217, 0.1);
  padding: 1rem;
  text-align: left;
  font-weight: 700;
  border-bottom: 2px solid var(--glass-border);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--isu-bright);
}
.compare-table td {
  padding: 0.8rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  color: var(--text-muted);
}
.compare-table tr:hover td { background: rgba(34, 158, 217, 0.03); }
.compare-table .check { color: var(--success); font-weight: 700; }
.compare-table .cross { color: var(--danger); opacity: 0.5; }
.compare-table .isu-row td { color: var(--text-primary); font-weight: 600; background: rgba(34, 158, 217, 0.05); }

/* ===== CTA SECTION ===== */
.cta-section {
  background: linear-gradient(135deg, rgba(6, 53, 157, 0.3), rgba(34, 158, 217, 0.1));
  border: 1px solid rgba(34, 158, 217, 0.2);
  border-radius: 24px;
  padding: 4rem;
  text-align: center;
}
.cta-section h2 {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
}
.cta-section p {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

/* ===== FOOTER ===== */
footer {
  text-align: center;
  padding: 3rem 2rem;
  border-top: 1px solid var(--glass-border);
  color: var(--text-muted);
  font-size: 0.85rem;
}
footer a { color: var(--isu-bright); text-decoration: none; }

/* ===== SCROLL ANIMATION ===== */
.animate {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero-content h1 { font-size: 2.5rem; }
  .program-grid, .cohort-grid, .budget-grid, .faculty-grid { grid-template-columns: 1fr; }
  .stats-bar { grid-template-columns: repeat(2, 1fr); }
  .nav-menu { display: none; }
  .cta-section { padding: 2.5rem 1.5rem; }
  .section { padding: 3rem 1.5rem; }
}

/* ===== MISSION PATCH FLOAT ===== */
.mission-patch-float {
  display: none;
}
.hero-patch-inline {
  width: 140px;
  height: 140px;
  margin: 0 auto 1.5rem;
  animation: float 6s ease-in-out infinite;
}
.hero-patch-inline img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 30px rgba(34, 158, 217, 0.3));
  border-radius: 50%;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-12px) rotate(2deg); }
}

/* ===== SUBSYSTEM GRID ===== */
.subsystem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.subsystem-card {
  text-align: center;
  padding: 1.2rem 0.8rem;
  border-radius: 12px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  transition: all 0.3s;
}
.subsystem-card:hover {
  border-color: var(--isu-bright);
  background: rgba(34, 158, 217, 0.05);
}
.subsystem-card .sub-icon { font-size: 1.8rem; margin-bottom: 0.5rem; }
.subsystem-card .sub-name { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.subsystem-card .sub-label { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.2rem; }

@media (max-width: 768px) {
  .subsystem-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Back to top */
#back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--isu-bright);
  color: #fff;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s;
  z-index: 999;
}
#back-to-top.visible { opacity: 1; transform: translateY(0); }
#back-to-top:hover { background: #1a8bc2; }
