/* ============================================================================
   BLUEBIRD GLOBAL — Shared Stylesheet
   bluebird.global

   This is the single source of truth for all common styles across the
   Bluebird static website. Each HTML page links to this file and only
   keeps page-specific overrides in an inline <style> block.
   ============================================================================ */

/* ============================================================================
   1. CSS CUSTOM PROPERTIES
   ============================================================================ */
:root {
  /* Primary Blues */
  --blue: #0077B6;
  --blue-dark: #023E8A;
  --blue-deeper: #01256E;
  --blue-light: #90E0EF;
  --blue-lightest: #CAF0F8;
  --blue-bg: #F0F7FA;

  /* Accents */
  --orange: #F77F00;
  --orange-light: #FCBF49;
  --green: #2D6A4F;
  --green-light: #52B788;
  --purple: #6C63FF;
  --purple-light: #8B83FF;

  /* Neutrals */
  --charcoal: #1D1D1D;
  --gray-dark: #4A4A4A;
  --gray-medium: #6B7280;
  --gray-light: #D1D5DB;
  --gray-lightest: #F3F4F6;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-400: #9CA3AF;
  --gray-500: #6B7280;
  --gray-600: #4B5563;
  --gray-700: #374151;
  --gray-800: #1F2937;
  --white: #FFFFFF;

  /* Typography */
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  /* Layout */
  --nav-height: 72px;

  /* Transition */
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ============================================================================
   2. RESET & BASE
   ============================================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-size: 1rem;
  color: var(--charcoal);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.25s ease;
}

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

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.2;
  color: var(--charcoal);
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.25rem; }

p {
  margin-bottom: 1rem;
  color: var(--gray-dark);
}

/* ============================================================================
   3. TYPOGRAPHY UTILITIES
   ============================================================================ */
.text-gradient {
  background: linear-gradient(135deg, var(--blue), #00B4D8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-eyebrow,
.sh-eyebrow,
.section-label {
  display: inline-block;
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--blue);
  margin-bottom: 12px;
}

.section-title,
.sh-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.03em;
}

.section-subtitle,
.sh-sub {
  font-size: 1.1rem;
  color: var(--gray-500);
  max-width: 640px;
  line-height: 1.7;
}

.text-center {
  text-align: center;
}

.text-center .section-subtitle,
.text-center .sh-sub {
  margin: 0 auto;
}

/* Section header block (index.html pattern) */
.sh {
  text-align: center;
  margin-bottom: 64px;
}

.sh .sh-sub {
  margin: 0 auto;
}

/* ============================================================================
   4. LAYOUT
   ============================================================================ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-wide,
.container-lg {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
}

.section,
section {
  padding: 100px 0;
}

/* ============================================================================
   5. BUTTONS
   ============================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-full);
  font-family: var(--font);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s var(--ease);
  border: 2px solid transparent;
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
}
.btn-primary:hover {
  background: var(--blue-dark);
  border-color: var(--blue-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,119,182,0.35);
}

.btn-secondary {
  background: transparent;
  color: var(--blue);
  border-color: var(--blue);
}
.btn-secondary:hover {
  background: var(--blue);
  color: var(--white);
  transform: translateY(-2px);
}

.btn-accent,
.btn-orange {
  background: var(--orange);
  color: var(--white);
  border-color: var(--orange);
}
.btn-accent:hover,
.btn-orange:hover {
  background: #E67300;
  border-color: #E67300;
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(247,127,0,0.35);
}

.btn-white {
  background: var(--white);
  color: var(--blue-dark);
  border-color: var(--white);
}
.btn-white:hover {
  background: var(--blue-lightest);
  border-color: var(--blue-lightest);
  color: var(--blue-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-w,
.btn-outline-white {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.45);
}
.btn-outline-w:hover,
.btn-outline-white:hover {
  background: rgba(255,255,255,0.1);
  border-color: #fff;
  transform: translateY(-2px);
}

.btn-blue {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
}
.btn-blue:hover {
  background: var(--blue-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,119,182,0.3);
}

.btn-blue-outline {
  background: transparent;
  color: var(--blue);
  border: 2px solid var(--blue);
}
.btn-blue-outline:hover {
  background: var(--blue);
  color: var(--white);
}

.btn-green {
  background: var(--green);
  color: var(--white);
  border-color: var(--green);
}
.btn-green:hover {
  background: #1B4332;
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(45,106,79,0.3);
}

.btn-green-outline {
  background: transparent;
  color: var(--green);
  border: 2px solid var(--green);
}
.btn-green-outline:hover {
  background: var(--green);
  color: var(--white);
}

.btn-purple {
  background: var(--purple);
  color: var(--white);
  border-color: var(--purple);
}
.btn-purple:hover {
  background: #5A52D5;
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(108,99,255,0.3);
}

.btn-purple-outline {
  background: transparent;
  color: var(--purple);
  border: 2px solid var(--purple);
}
.btn-purple-outline:hover {
  background: var(--purple);
  color: var(--white);
}

.btn-orange-outline {
  background: transparent;
  color: var(--orange);
  border: 2px solid var(--orange);
}
.btn-orange-outline:hover {
  background: var(--orange);
  color: var(--white);
}

.btn-sm { padding: 10px 24px; font-size: 0.9rem; }
.btn-lg { padding: 18px 40px; font-size: 1.1rem; }

.btn-arrow::after {
  content: '\2192';
  transition: transform 0.3s ease;
}
.btn-arrow:hover::after {
  transform: translateX(4px);
}

.btn-arrow span.arrow {
  transition: transform 0.3s var(--ease);
  display: inline-block;
}
.btn-arrow:hover span.arrow {
  transform: translateX(4px);
}

/* ============================================================================
   6. NAVIGATION (shared across pages using .navbar pattern)
   ============================================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: all 0.35s ease;
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
  background: rgba(255,255,255,0.97);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--blue);
  text-decoration: none;
  flex-shrink: 0;
  letter-spacing: -0.02em;
}

.nav-logo:hover {
  color: var(--blue);
}

.logo-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.nav-logo .logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--blue), var(--blue-light));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.nav-links a,
.nav-links li a {
  display: block;
  padding: 8px 16px;
  font-size: 0.925rem;
  font-weight: 500;
  color: var(--gray-600);
  border-radius: var(--radius-sm);
  transition: all 0.25s ease;
}

.nav-links a:hover,
.nav-links li a:hover {
  color: var(--blue);
  background: var(--blue-bg);
}

.nav-links a.active,
.nav-links li a.active {
  color: var(--blue);
  background: var(--blue-bg);
  font-weight: 600;
}

.nav-links a::after {
  /* Reset the underline effect - pages that want it add it back */
  content: none;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  width: 40px;
  height: 40px;
  position: relative;
  border-radius: var(--radius-sm);
}

.mobile-toggle:hover {
  background: var(--gray-100);
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--charcoal);
  border-radius: 2px;
  transition: all 0.3s ease;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.mobile-toggle span:nth-child(1) { top: 12px; }
.mobile-toggle span:nth-child(2) { top: 19px; }
.mobile-toggle span:nth-child(3) { top: 26px; }

.mobile-toggle.active span:nth-child(1) { top: 19px; transform: translateX(-50%) rotate(45deg); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { top: 19px; transform: translateX(-50%) rotate(-45deg); }

/* Mobile Navigation Overlay */
.nav-links.mobile-open {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 72px;
  left: 0;
  right: 0;
  background: var(--white);
  padding: 24px;
  gap: 16px;
  box-shadow: var(--shadow-lg);
  border-top: 1px solid var(--gray-light);
  z-index: 999;
}

/* ============================================================================
   7. FOOTER
   ============================================================================ */
.footer {
  background: var(--charcoal);
  color: rgba(255,255,255,0.7);
  padding: 64px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand .nav-logo,
.footer-brand .footer-logo {
  color: var(--white);
  margin-bottom: 16px;
}

.footer-brand .nav-logo:hover {
  color: var(--white);
}

.footer-brand p {
  color: rgba(255,255,255,0.55);
  font-size: 0.9rem;
  line-height: 1.65;
  max-width: 320px;
}

.footer-parent {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.4);
  line-height: 1.6;
}

.footer-col h4,
.footer-col-title {
  color: var(--white);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 18px;
  font-weight: 700;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 10px;
}

.footer-col a,
.footer-link {
  color: rgba(255,255,255,0.55);
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-col a:hover,
.footer-link:hover {
  color: var(--white);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-copy {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

.footer-bottom p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

.footer-accreditations,
.footer-accr {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.accred-badge,
.footer-accr-badge {
  padding: 4px 12px;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.05em;
  background: rgba(255,255,255,0.05);
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 14px;
}

/* ============================================================================
   8. CARDS (common patterns)
   ============================================================================ */
/* Generic card hover pattern used across many pages */
[class*="-card"]:not(.hero-card):not(.hcard) {
  transition: all 0.3s var(--ease);
}

/* ============================================================================
   9. REVEAL / SCROLL ANIMATIONS
   ============================================================================ */

/* Pattern 1: fade-up (programs, admissions, cities, experience, story) */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Pattern 2: anim (index.html) */
.anim {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1), transform 0.7s cubic-bezier(0.4,0,0.2,1);
}

.anim.show {
  opacity: 1;
  transform: translateY(0);
}

.anim.d1 { transition-delay: 0.1s; }
.anim.d2 { transition-delay: 0.2s; }
.anim.d3 { transition-delay: 0.3s; }
.anim.d4 { transition-delay: 0.4s; }

/* Pattern 3: reveal (blog, original shared css) */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* Stagger children (programs.html) */
.stagger-children > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}

.stagger-children.visible > * { opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(1) { transition-delay: 0s; }
.stagger-children.visible > *:nth-child(2) { transition-delay: 0.08s; }
.stagger-children.visible > *:nth-child(3) { transition-delay: 0.16s; }
.stagger-children.visible > *:nth-child(4) { transition-delay: 0.24s; }
.stagger-children.visible > *:nth-child(5) { transition-delay: 0.32s; }
.stagger-children.visible > *:nth-child(6) { transition-delay: 0.4s; }

/* Common keyframes */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================================
   10. CTA SECTION (shared across most pages)
   ============================================================================ */
.cta-section {
  padding: 100px 0;
  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue) 50%, #0096C7 100%);
  text-align: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -25%;
  width: 150%;
  height: 200%;
  background: radial-gradient(ellipse, rgba(0,180,216,0.15) 0%, transparent 60%);
  pointer-events: none;
}

.cta-inner,
.cta-content {
  position: relative;
  z-index: 2;
}

.cta-section h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  color: var(--white);
  margin-bottom: 16px;
  letter-spacing: -0.03em;
}

.cta-section p,
.cta-text {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.75);
  margin-bottom: 36px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.cta-btns,
.cta-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-note {
  margin-top: 24px;
  font-size: 0.875rem;
  color: rgba(255,255,255,0.5);
}

/* ============================================================================
   11. RESPONSIVE
   ============================================================================ */
@media (max-width: 1024px) {
  h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); }
  h2 { font-size: clamp(1.5rem, 3.5vw, 2rem); }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 768px) {
  /* Navigation */
  .nav-links {
    display: none;
  }

  .nav-cta .btn-secondary {
    display: none;
  }

  .mobile-toggle {
    display: flex;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  /* CTA */
  .cta-btns,
  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }
}

/* ============================================================================
   12. UTILITY CLASSES
   ============================================================================ */
.text-blue { color: var(--blue); }
.text-blue-dark { color: var(--blue-dark); }
.text-orange { color: var(--orange); }
.text-green { color: var(--green); }
.text-purple { color: var(--purple); }
.text-gray { color: var(--gray-500); }
.bg-blue { background: var(--blue); }
.bg-blue-dark { background: var(--blue-dark); }
.bg-blue-bg { background: var(--blue-bg); }
.bg-orange { background: var(--orange); }
.bg-green { background: var(--green); }
.bg-purple { background: var(--purple); }
