/* ============================================================
   ACSA — Applied Comfort Solutions of America
   Master Stylesheet v1.0
   Brand Identity Kit Compliant
   ============================================================ */

/* Fonts loaded via <link> in HTML with preconnect — no @import needed */

/* ============================================================
   CSS CUSTOM PROPERTIES — DARK MODE (Default per Brand Kit)
   ============================================================ */
:root {
  /* --- Primary Palette --- */
  --navy: #0e1e2e;
  --navy-mid: #1a3a5c;
  --blue: #1a5f96;
  --blue-light: #2e8bc0;

  /* --- Accent Palette --- */
  --gold: #c8973a;
  --gold-light: #e8c06a;
  --gold-pale: #f5edda;

  /* --- Neutral Palette --- */
  --white: #ffffff;
  --off-white: #f4f6f9;
  --gray-100: #eef1f5;
  --gray-300: #c8d0da;
  --gray-500: #7a8a9a;
  --gray-700: #3a4a5a;
  --text: #1e2a38;

  /* --- Theme Tokens (Dark Mode Default) --- */
  --bg-primary: #0e1e2e;
  --bg-secondary: #132639;
  --bg-tertiary: #1a3a5c;
  --bg-card: rgba(26, 58, 92, 0.35);
  --bg-card-hover: rgba(26, 58, 92, 0.55);
  --bg-input: rgba(26, 58, 92, 0.4);
  --text-primary: #f4f6f9;
  --text-secondary: #c8d0da;
  --text-muted: #7a8a9a;
  --text-heading: #ffffff;
  --text-accent: #e8c06a;
  --border-color: rgba(200, 208, 218, 0.12);
  --border-hover: rgba(200, 208, 218, 0.25);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 6px 24px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 12px 48px rgba(0, 0, 0, 0.3);
  --overlay: rgba(15, 30, 46, 0.85);
  --nav-bg: #0e1e2e;
  --nav-blur: blur(0px);
  --hero-gradient: linear-gradient(135deg, #0e1e2e 0%, #1a3a5c 50%, #1a5f96 100%);
  --section-alt-bg: #132639;
  --gold-bar: linear-gradient(90deg, #c8973a, #e8c06a);
  --code-bg: rgba(26, 58, 92, 0.5);
  --scrollbar-thumb: #1a5f96;
  --scrollbar-track: #0e1e2e;
  --logo-display-dark: block;
  --logo-display-light: none;
  --diagonal-opacity: 0.03;
  --orb-opacity: 0.06;

  /* --- Layout --- */
  --max-width: 1200px;
  --nav-height: 72px;
  --border-radius-sm: 4px;
  --border-radius-md: 8px;
  --border-radius-lg: 16px;
  --border-radius-pill: 32px;

  /* --- Transitions --- */
  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;
  --transition-theme: 0.5s ease;
}

/* ============================================================
   LIGHT MODE OVERRIDES
   ============================================================ */
[data-theme="light"] {
  --bg-primary: #ffffff;
  --bg-secondary: #f4f6f9;
  --bg-tertiary: #eef1f5;
  --bg-card: rgba(238, 241, 245, 0.7);
  --bg-card-hover: rgba(238, 241, 245, 1);
  --bg-input: rgba(238, 241, 245, 0.8);
  --text-primary: #1e2a38;
  --text-secondary: #3a4a5a;
  --text-muted: #7a8a9a;
  --text-heading: #0e1e2e;
  --text-accent: #c8973a;
  --border-color: rgba(200, 208, 218, 0.35);
  --border-hover: rgba(200, 208, 218, 0.6);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 6px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 48px rgba(0, 0, 0, 0.1);
  --overlay: rgba(255, 255, 255, 0.9);
  --nav-bg: #ffffff;
  --hero-gradient: linear-gradient(135deg, #f4f6f9 0%, #eef1f5 50%, #e0e8f0 100%);
  --section-alt-bg: #f4f6f9;
  --code-bg: rgba(238, 241, 245, 0.8);
  --scrollbar-thumb: #c8d0da;
  --scrollbar-track: #f4f6f9;
  --logo-display-dark: none;
  --logo-display-light: block;
  --diagonal-opacity: 0.04;
  --orb-opacity: 0.05;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
}

html::-webkit-scrollbar { width: 8px; }
html::-webkit-scrollbar-track { background: var(--scrollbar-track); }
html::-webkit-scrollbar-thumb { background: var(--scrollbar-thumb); border-radius: 4px; }

body {
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 400;
  line-height: 1.65;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  transition: background-color var(--transition-theme), color var(--transition-theme);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, video, svg, iframe, embed, object {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--blue-light);
  text-decoration: none;
  transition: color var(--transition-base);
  overflow-wrap: break-word;
}

a:hover { color: var(--gold-light); }

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

ul, ol { list-style: none; }

::selection {
  background: var(--gold);
  color: var(--navy);
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  line-height: 1.15;
  color: var(--text-heading);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  transition: color var(--transition-theme);
  overflow-wrap: break-word;
  word-break: break-word;
}

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

.subtitle, .section-label {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.tagline {
  font-family: 'Lora', serif;
  font-style: italic;
  font-weight: 400;
  color: var(--text-accent);
}

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
  transition: color var(--transition-theme);
  overflow-wrap: break-word;
}

p:last-child { margin-bottom: 0; }

.text-gold { color: var(--gold); }
.text-blue { color: var(--blue-light); }
.text-accent { color: var(--text-accent); }

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

/* Safe area insets for notched/rounded devices */
@supports (padding: env(safe-area-inset-left)) {
  .container {
    padding-left: max(1.5rem, env(safe-area-inset-left));
    padding-right: max(1.5rem, env(safe-area-inset-right));
  }
  .footer__bottom {
    padding-bottom: max(1.5rem, env(safe-area-inset-bottom));
  }
}

.section {
  padding: 5rem 0;
  position: relative;
  overflow-x: hidden;
  transition: background-color var(--transition-theme);
}

.section--alt { background-color: var(--section-alt-bg); }

.section--navy {
  background-color: var(--navy);
  color: var(--off-white);
}

[data-theme="light"] .section--navy {
  background-color: var(--navy);
  color: var(--off-white);
}
[data-theme="light"] .section--navy .text-secondary,
[data-theme="light"] .section--navy p { color: var(--gray-300); }
[data-theme="light"] .section--navy h1,
[data-theme="light"] .section--navy h2,
[data-theme="light"] .section--navy h3,
[data-theme="light"] .section--navy h4 { color: var(--white); }

.grid {
  display: grid;
  gap: 2rem;
}

/* Prevent grid children from overflowing their track */
.grid > * { min-width: 0; }

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Responsive grid utilities (replace inline styles) */
.grid--2col { grid-template-columns: 1fr 1fr; }
.grid--gap-lg { gap: 4rem; }
.grid--gap-md { gap: 3rem; }
.grid--gap-sm { gap: 2.5rem; }
.grid--align-center { align-items: center; }
.grid--align-start { align-items: start; }

/* Inner grids (small cards that stay 2-col longer) */
.grid--inner-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }

.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* ============================================================
   GOLD ACCENT BAR (Brand Element)
   ============================================================ */
.gold-bar {
  display: block;
  width: 48px;
  height: 4px;
  background: var(--gold-bar);
  border-radius: 2px;
}

.gold-bar--wide { width: 80px; }
.gold-bar--center { margin: 1rem auto; }
.gold-bar--full { width: 100%; }

/* ============================================================
   SECTION HEADER
   ============================================================ */
.section-header {
  margin-bottom: 3.5rem;
}

.section-header .section-label {
  font-size: 0.85rem;
  color: var(--text-accent);
  margin-bottom: 0.75rem;
  display: block;
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-header .section-desc {
  font-size: 1.1rem;
  max-width: 640px;
  color: var(--text-secondary);
  line-height: 1.7;
}

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

.section-header--center .section-desc {
  margin: 0 auto;
}

.section-header--center .gold-bar {
  margin: 1rem auto;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.8rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: var(--border-radius-sm);
  transition: all var(--transition-base);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  min-height: 44px; /* Minimum touch target */
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  transform: translateX(-100%);
  transition: transform var(--transition-base);
}

.btn:hover::after {
  transform: translateX(0);
}

.btn--primary {
  background: var(--gold);
  color: var(--navy);
  border: 2px solid var(--gold);
}

.btn--primary:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--navy);
  box-shadow: 0 4px 20px rgba(200, 151, 58, 0.3);
  transform: translateY(-1px);
}

.btn--secondary {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border-color);
}

.btn--secondary:hover {
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-1px);
}

.btn--navy {
  background: var(--navy);
  color: var(--off-white);
  border: 2px solid var(--navy);
}

.btn--navy:hover {
  background: var(--navy-mid);
  border-color: var(--navy-mid);
  transform: translateY(-1px);
}

[data-theme="light"] .btn--secondary {
  border-color: var(--gray-300);
  color: var(--text);
}

.btn--lg {
  padding: 1rem 2.4rem;
  font-size: 1.05rem;
}

.btn--sm {
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
}

.btn-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border-color);
  transition: background var(--transition-theme), border-color var(--transition-theme),
              box-shadow var(--transition-base);
}

.nav.scrolled {
  box-shadow: var(--shadow-md);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.nav__logo {
  display: flex;
  align-items: center;
  height: 42px;
  flex-shrink: 0;
}

.nav__logo img {
  height: 42px;
  width: auto;
  object-fit: contain;
}

.nav__logo-dark { display: var(--logo-display-dark); background-color: #0e1e2e; }
.nav__logo-light { display: var(--logo-display-light); background-color: #ffffff; }

.nav__links {
  display: flex;
  align-items: center;
  gap: 0;
  height: 100%;
}

.nav__item {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.nav__link {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  height: 100%;
  padding: 0 1rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  transition: color var(--transition-base);
  cursor: pointer;
  border: none;
  background: none;
  white-space: nowrap;
}

.nav__link:hover, .nav__link--active {
  color: var(--gold);
}

.nav__link svg {
  width: 12px;
  height: 12px;
  transition: transform var(--transition-base);
}

.nav__item:hover .nav__link svg {
  transform: rotate(180deg);
}

/* Dropdown */
.nav__dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  min-width: 240px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  padding: 0.5rem 0;
  pointer-events: none;
}

.nav__item:hover .nav__dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: all;
}

.nav__dropdown-link {
  display: block;
  padding: 0.7rem 1.2rem;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.nav__dropdown-link:hover {
  background: var(--bg-card);
  color: var(--gold);
  padding-left: 1.5rem;
}

/* Nav Actions */
.nav__actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Theme Toggle */
.theme-toggle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  transition: all var(--transition-base);
  cursor: pointer;
}

.theme-toggle:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--bg-card-hover);
}

.theme-toggle svg { width: 18px; height: 18px; }

.theme-toggle .icon-sun { display: block; }
.theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: block; }

/* Mobile Menu Toggle */
.nav__mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px 8px;
  cursor: pointer;
  background: none;
  border: none;
  align-items: center;
  justify-content: center;
}

.nav__mobile-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 1px;
  transition: all var(--transition-base);
}

.nav__mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav__mobile-toggle.active span:nth-child(2) { opacity: 0; }
.nav__mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Nav Overlay */
.nav__mobile-menu {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-primary);
  z-index: 999;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 1.5rem;
  padding-bottom: max(1.5rem, env(safe-area-inset-bottom, 1.5rem));
}

.nav__mobile-menu.active {
  display: block;
  animation: fadeSlideIn 0.3s ease;
}

.nav__mobile-menu .mobile-link {
  display: block;
  padding: 1rem 0;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
  transition: color var(--transition-base);
}

.nav__mobile-menu .mobile-link:hover { color: var(--gold); }

.nav__mobile-menu .mobile-sublinks {
  padding-left: 1rem;
}

.nav__mobile-menu .mobile-sublink {
  display: block;
  padding: 0.6rem 0;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh; /* Modern mobile viewport unit */
  display: flex;
  align-items: center;
  padding-top: var(--nav-height);
  background: var(--hero-gradient);
  overflow: hidden;
}

/* Diagonal pattern background */
.hero__pattern {
  position: absolute;
  inset: 0;
  opacity: var(--diagonal-opacity);
  background-image: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 30px,
    currentColor 30px,
    currentColor 31px
  );
  color: var(--text-primary);
  pointer-events: none;
}

/* Orb effects */
.hero__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  opacity: var(--orb-opacity);
  contain: strict;
  will-change: opacity;
}

.hero__orb--blue {
  width: 500px;
  height: 500px;
  background: var(--blue);
  top: -10%;
  right: -5%;
}

.hero__orb--gold {
  width: 350px;
  height: 350px;
  background: var(--gold);
  bottom: -5%;
  left: -3%;
}

.hero__content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  padding: 3rem 0;
}

.hero__label {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.hero__label::before {
  content: '';
  display: block;
  width: 32px;
  height: 2px;
  background: var(--gold);
}

.hero__title {
  margin-bottom: 1.25rem;
}

.hero__title .highlight {
  color: var(--blue-light);
}

[data-theme="light"] .hero__title .highlight {
  color: var(--blue);
}

.hero__tagline {
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 1.35rem;
  color: var(--text-accent);
  margin-bottom: 1.5rem;
}

.hero__desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  line-height: 1.75;
  max-width: 560px;
}

.hero__stats {
  display: flex;
  gap: 2.5rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.hero__stat {
  text-align: center;
}

.hero__stat-number {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 2.2rem;
  color: var(--text-heading);
  line-height: 1;
}

.hero__stat-number .counter-suffix {
  color: var(--gold);
}

.hero__stat-label {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 500;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-top: 0.35rem;
}

/* Page-level hero (smaller) */
.hero--page {
  min-height: auto;
  padding: calc(var(--nav-height) + 4rem) 0 4rem;
}

.hero--page .hero__content {
  max-width: 100%;
  padding: 0;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  padding: 2rem;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gold-bar);
  transform: scaleX(0);
  transition: transform var(--transition-base);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.card:hover::after {
  transform: scaleX(1);
}

.card__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--border-radius-md);
  background: linear-gradient(135deg, var(--blue), var(--blue-light));
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  flex-shrink: 0;
}

.card__icon svg {
  width: 24px;
  height: 24px;
  color: white;
}

.card__title {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.card__desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Pillar cards with left accent bar */
.card--pillar {
  border-left: 4px solid var(--gold);
  border-radius: 0 var(--border-radius-md) var(--border-radius-md) 0;
}

.card--pillar::after { display: none; }

/* Feature card (horizontal layout) */
.card--feature {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

/* Stat card */
.card--stat {
  text-align: center;
  padding: 2.5rem 1.5rem;
}

.card--stat .card__number {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 3rem;
  color: var(--blue-light);
  line-height: 1;
}

[data-theme="light"] .card--stat .card__number {
  color: var(--blue);
}

.card--stat .card__suffix {
  color: var(--gold);
}

/* ============================================================
   IMPACT COUNTER STRIP
   ============================================================ */
.impact-strip {
  background: var(--navy);
  padding: 3rem 0;
  position: relative;
  overflow: hidden;
}

.impact-strip::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gold-bar);
}

.impact-strip__inner {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 2rem;
}

.impact-item {
  text-align: center;
  flex: 1;
  min-width: 140px;
}

.impact-item__number {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 2.8rem;
  color: var(--white);
  line-height: 1;
}

.impact-item__suffix { color: var(--gold); }

.impact-item__label {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 500;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gray-500);
  margin-top: 0.5rem;
}

/* ============================================================
   PROGRAMS / SERVICES SECTION
   ============================================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  overflow: hidden;
  transition: all var(--transition-base);
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-hover);
}

.service-card__header {
  padding: 1.75rem 1.75rem 0;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.service-card__number {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 2rem;
  color: var(--gold);
  line-height: 1;
}

.service-card__body {
  padding: 1.25rem 1.75rem 1.75rem;
}

.service-card__title {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
}

.service-card__bar {
  width: 100%;
  height: 4px;
  background: var(--gold-bar);
}

/* ============================================================
   TESTIMONIAL / QUOTE
   ============================================================ */
.quote-block {
  position: relative;
  padding: 2.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--gold);
  border-radius: 0 var(--border-radius-md) var(--border-radius-md) 0;
}

.quote-block__text {
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.7;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.quote-block__author {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
}

/* ============================================================
   TIMELINE
   ============================================================ */
.timeline {
  position: relative;
  padding-left: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border-color);
}

.timeline__item {
  position: relative;
  padding-bottom: 2rem;
  padding-left: 1.5rem;
}

.timeline__item::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 0.35rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gold);
  border: 2px solid var(--bg-primary);
  margin-left: -5px;
}

.timeline__phase {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold);
  margin-bottom: 0.25rem;
}

.timeline__title {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.cta-section {
  position: relative;
  padding: 5rem 0;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  overflow: hidden;
}

.cta-section .hero__pattern { opacity: 0.02; }

.cta-section .hero__orb--blue {
  width: 400px; height: 400px;
  top: auto; bottom: -15%;
  right: 10%;
}

.cta-section__inner {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.cta-section h2 { color: var(--white); margin-bottom: 1rem; }
.cta-section p { color: var(--gray-300); font-size: 1.1rem; margin-bottom: 2rem; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--navy);
  color: var(--gray-300);
  padding: 4rem 0 0;
  position: relative;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gold-bar);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer__brand-desc {
  font-size: 0.95rem;
  line-height: 1.7;
  margin: 1.25rem 0;
  color: var(--gray-500);
}

.footer__tagline {
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 0.95rem;
  color: var(--gold-light);
}

.footer__heading {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--white);
  margin-bottom: 1.25rem;
}

.footer__link {
  display: block;
  padding: 0.35rem 0;
  font-size: 0.9rem;
  color: var(--gray-500);
  transition: all var(--transition-base);
}

.footer__link:hover {
  color: var(--gold-light);
  padding-left: 0.3rem;
}

.footer__contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--gray-500);
}

.footer__contact-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: var(--gold);
}

.footer__bottom {
  border-top: 1px solid rgba(200, 208, 218, 0.1);
  padding: 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--gray-500);
}

.footer__bottom a { color: var(--gray-500); }
.footer__bottom a:hover { color: var(--gold-light); }

.footer__socials {
  display: flex;
  gap: 0.75rem;
}

.footer__social {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(200, 208, 218, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  color: var(--gray-500);
}

.footer__social:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(200, 151, 58, 0.1);
}

.footer__social svg { width: 16px; height: 16px; }

.footer__logo {
  height: 36px;
  width: auto;
  margin-bottom: 0.5rem;
  background-color: #0e1e2e;
}

/* ============================================================
   PAGE VIEWS (SPA routing)
   ============================================================ */
.page-view {
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.page-view.active {
  display: block;
  opacity: 1;
  animation: pageFadeIn 0.4s ease forwards;
}

/* ============================================================
   FORM STYLES
   ============================================================ */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  max-width: 100%;
  padding: 0.8rem 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  color: var(--text-primary);
  font-family: 'Source Sans 3', sans-serif;
  font-size: 1rem; /* Prevents iOS zoom on focus */
  transition: all var(--transition-base);
  -webkit-appearance: none; /* Consistent cross-browser */
  appearance: none;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--blue-light);
  box-shadow: 0 0 0 3px rgba(46, 139, 192, 0.15);
}

.form-textarea {
  resize: vertical;
  min-height: 140px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

/* ============================================================
   ACCORDION
   ============================================================ */
.accordion-item {
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  margin-bottom: 0.75rem;
  overflow: hidden;
  transition: all var(--transition-base);
}

.accordion-item:hover {
  border-color: var(--border-hover);
}

.accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 1.1rem 1.25rem;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-heading);
  text-align: left;
  transition: color var(--transition-base);
  min-height: 48px; /* Minimum touch target */
}

.accordion-header:hover { color: var(--gold); }

.accordion-header svg {
  width: 18px; height: 18px;
  transition: transform var(--transition-base);
  flex-shrink: 0;
  color: var(--text-muted);
}

.accordion-item.active .accordion-header svg {
  transform: rotate(180deg);
  color: var(--gold);
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.accordion-body__inner {
  padding: 0 1.25rem 1.25rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.75;
}

/* ============================================================
   PARTNER LOGO STRIP
   ============================================================ */
.partner-strip {
  padding: 3rem 0;
  overflow: hidden;
}

.partner-strip__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 3rem;
  opacity: 0.4;
  filter: grayscale(100%);
  transition: all var(--transition-base);
}

.partner-strip__inner:hover {
  opacity: 0.7;
  filter: grayscale(50%);
}

/* ============================================================
   SCROLL REVEAL ANIMATIONS
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s 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; }
.reveal-delay-4 { transition-delay: 0.4s; }

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

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

/* ============================================================
   BACK TO TOP
   ============================================================ */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  bottom: max(2rem, env(safe-area-inset-bottom, 2rem));
  right: 2rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  z-index: 900;
  box-shadow: var(--shadow-md);
  cursor: pointer;
  border: none;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  background: var(--gold-light);
}

.back-to-top svg { width: 20px; height: 20px; }

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */

/* --- Tablet landscape / small desktop (1024px) --- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr) !important; }
  .services-grid { grid-template-columns: repeat(2, 1fr) !important; }
  .footer__grid { grid-template-columns: 1fr 1fr !important; gap: 2rem; }
  .grid--gap-lg { gap: 2.5rem; }
  .grid--gap-md { gap: 2rem; }
}

/* --- Content 2-col collapse (900px) — forms, text blocks need more room --- */
@media (max-width: 900px) {
  /* Override ALL 2-column grids, including inline styles */
  .grid--2col,
  .grid-2,
  .grid[style],
  div[style*="1fr 1fr"],
  div[style*="1fr  1fr"] {
    grid-template-columns: 1fr !important;
    gap: 2.5rem !important;
  }
}

/* --- Tablet portrait (768px) --- */
@media (max-width: 768px) {
  .nav__links { display: none; }
  .nav__mobile-toggle { display: flex; }

  .grid-3, .grid-4 { grid-template-columns: 1fr !important; }
  .services-grid { grid-template-columns: 1fr !important; }

  .grid--gap-lg,
  .grid--gap-md,
  .grid--gap-sm { gap: 2rem; }

  .hero { min-height: auto; padding-top: calc(var(--nav-height) + 2rem); padding-bottom: 3rem; }
  .hero__content { padding: 2rem 0; max-width: 100%; }
  .hero__stats { flex-direction: column; gap: 1.5rem; align-items: flex-start; }
  .hero__desc { max-width: 100%; }

  .hero--page { padding: calc(var(--nav-height) + 2.5rem) 0 2.5rem; }

  .section { padding: 3.5rem 0; }

  .section-header { margin-bottom: 2.5rem; }

  .footer__grid { grid-template-columns: 1fr !important; gap: 2rem; }
  .footer__bottom { flex-direction: column; gap: 1rem; text-align: center; }

  .btn-group { flex-direction: column; }
  .btn-group .btn { text-align: center; justify-content: center; }

  .form-row { grid-template-columns: 1fr !important; }

  .impact-strip__inner { flex-direction: column; gap: 1.5rem; }
  .impact-strip { padding: 2rem 0; }

  .cta-section { padding: 3.5rem 0; }
  .cta-section__inner { max-width: 100%; }

  .quote-block { padding: 1.75rem; }
  .quote-block__text { font-size: 1.1rem; }

  .timeline { padding-left: 1.5rem; }
  .timeline__item { padding-left: 1rem; }

  .nav__dropdown { min-width: 200px; }

  /* Reduce orb sizes on tablet for performance */
  .hero__orb--blue { width: 300px; height: 300px; filter: blur(60px); }
  .hero__orb--gold { width: 200px; height: 200px; filter: blur(60px); }
  .cta-section .hero__orb--blue { width: 250px; height: 250px; }
}

/* --- Small devices / large phones (576px) --- */
@media (max-width: 576px) {
  .hero__title { font-size: clamp(1.8rem, 7vw, 2.5rem); }
  .hero__desc { font-size: 1rem; margin-bottom: 2rem; }
  .hero__tagline { font-size: 1.15rem; }

  .hero__stats { gap: 1.25rem; }
  .hero__stat-number { font-size: 1.8rem; }

  .btn--lg { padding: 0.9rem 1.8rem; font-size: 1rem; }

  .section { padding: 2.5rem 0; }
  .section-header { margin-bottom: 2rem; }

  .impact-item__number { font-size: 2.2rem; }
  .impact-strip { padding: 1.75rem 0; }

  .service-card__header { padding: 1.25rem 1.25rem 0; }
  .service-card__body { padding: 1rem 1.25rem 1.25rem; }

  .card--stat { padding: 1.75rem 1rem; }
  .card--stat .card__number { font-size: 2.4rem; }

  .cta-section { padding: 2.5rem 0; }

  /* Force ALL grids to single-column — catches any inline styles */
  .grid--inner-2col,
  [style*="grid-template-columns"],
  [style*="1fr 1fr"],
  div[style*="display: grid"][style*="1fr"] {
    grid-template-columns: 1fr !important;
  }

  /* Hide orbs on small screens for performance */
  .hero__orb { display: none; }
}

/* --- Extra-small devices (480px) --- */
@media (max-width: 480px) {
  html { font-size: 15px; }
  .container { padding-left: 1rem; padding-right: 1rem; }
  .card { padding: 1.5rem; }
  .card--feature { flex-direction: column !important; }

  .nav__inner { padding: 0 1rem; }
  .nav__mobile-menu { padding: 1.25rem 1rem; }

  .footer { padding: 3rem 0 0; }
  .footer__grid { gap: 1.5rem; }
}

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
  .nav, .footer, .back-to-top, .theme-toggle, .btn { display: none !important; }
  body { color: #000; background: #fff; }
  .section { padding: 1rem 0; }
}
