/* ==========================================================================
   Mwibale Senior School — Stylesheet
   Design system: solid colours only (no gradients), mobile-first, accessible.
   ========================================================================== */

/* ---------- Design tokens ---------- */
:root {
  --primary: #385C65;       /* Deep Teal */
  --primary-dark: #2C4951;
  --secondary: #A7CADB;     /* Sky Blue */
  --secondary-light: #D6E7EE;
  --accent: #7A4654;        /* Burgundy */
  --accent-dark: #5F353F;
  --support: #2A3D36;       /* Forest Green */
  --support-light: #3F5A50;
  --gold: #C2B989;          /* Warm Gold */
  --gold-dark: #A89E6A;
  --bg: #F4F7F8;            /* Very Light Blue-Gray */
  --surface: #FFFFFF;
  --surface-alt: #EEF3F5;
  --border: #DBE4E7;
  --border-strong: #C3D0D4;
  --text: #2C4951;
  --text-muted: #5C7178;
  --text-light: #8AA0A6;
  --white: #FFFFFF;
  --shadow-sm: 0 1px 2px rgba(44, 73, 81, 0.06), 0 1px 3px rgba(44, 73, 81, 0.05);
  --shadow-md: 0 4px 12px rgba(44, 73, 81, 0.08), 0 2px 4px rgba(44, 73, 81, 0.05);
  --shadow-lg: 0 12px 32px rgba(44, 73, 81, 0.12), 0 4px 10px rgba(44, 73, 81, 0.06);
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --container: 1180px;
  --header-h: 72px;
  --font-head: "Poppins", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;
  --transition: 180ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-dark); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--primary); line-height: 1.2; font-weight: 700; }
ul { list-style: none; padding: 0; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section--tight { padding: 48px 0; }
.section--alt { background: var(--surface-alt); }
.center-btn { text-align: center; margin-top: 36px; }
.hide-sm { display: inline; }
.text-green { color: var(--support); }
.text-accent { color: var(--accent); }

.section__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 36px; flex-wrap: wrap; }
.section__head--center { flex-direction: column; align-items: center; text-align: center; }
.section__title { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; }
.section__title--sm { font-size: 1.25rem; }
.section__sub { color: var(--text-muted); max-width: 620px; margin-top: 10px; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-weight: 600; font-size: 0.8rem;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent);
}
.eyebrow--center { justify-content: center; }
.eyebrow--light { color: var(--secondary); }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 1000;
  background: var(--primary); color: #fff; padding: 10px 16px; border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-head); font-weight: 600; font-size: 0.95rem;
  padding: 12px 22px; border-radius: var(--radius); border: 2px solid transparent;
  transition: all var(--transition); text-align: center; line-height: 1.2;
}
.btn--lg { padding: 15px 30px; font-size: 1.02rem; }
.btn--block { width: 100%; }
.btn--solid { background: var(--primary); color: #fff; }
.btn--solid:hover { background: var(--primary-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--gold { background: var(--gold); color: var(--support); }
.btn--gold:hover { background: var(--gold-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--ghost { background: transparent; color: var(--primary); border-color: var(--border-strong); }
.btn--ghost:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn--outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,0.6); }
.btn--outline-light:hover { background: #fff; color: var(--primary); border-color: #fff; }
.btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ---------- Topbar ---------- */
.topbar { background: var(--support); color: #E8EFEC; font-size: 0.82rem; }
.topbar__inner { display: flex; justify-content: space-between; align-items: center; padding-top: 8px; padding-bottom: 8px; gap: 12px; flex-wrap: wrap; }
.topbar__left { display: flex; gap: 20px; flex-wrap: wrap; }
.topbar__left a { color: #E8EFEC; }
.topbar__left a:hover { color: #fff; }
.topbar__left i { color: var(--gold); margin-right: 4px; }
.topbar__right { display: flex; gap: 8px; }
.badge-pill { background: rgba(255,255,255,0.12); padding: 3px 10px; border-radius: 999px; font-size: 0.72rem; font-weight: 600; }
.badge-pill--alt { background: var(--gold); color: var(--support); }

/* ---------- Header / nav ---------- */
.header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; box-shadow: var(--shadow-sm); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-h); }

.brand { display: flex; align-items: center; gap: 12px; color: var(--primary); flex-shrink: 0; }
.brand:hover { color: var(--primary); }
.brand-logo {
  height: auto; width: auto; max-height: 48px; max-width: 200px; display: block;
  object-fit: contain; border-radius: 4px;
}

.nav-toggle { display: none; width: 44px; height: 44px; border-radius: var(--radius-sm); position: relative; }
.nav-toggle span { position: absolute; left: 11px; width: 22px; height: 2px; background: var(--primary); transition: var(--transition); }
.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 21px; }
.nav-toggle span:nth-child(3) { top: 27px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: rotate(45deg); top: 21px; }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: rotate(-45deg); top: 21px; }

.nav { flex: 1; min-width: 0; }
.nav__list { display: flex; align-items: center; justify-content: space-between; gap: 0; }
.nav__link {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 7px 10px; border-radius: var(--radius-sm); font-family: var(--font-head);
  font-weight: 600; font-size: 0.82rem; color: var(--primary); transition: var(--transition);
  background: transparent; border: 2px solid transparent; white-space: nowrap;
}
.nav__link:hover, .nav__link.is-active { background: var(--secondary-light); color: var(--primary-dark); }
.nav__link--solid { background: var(--accent); color: #fff; }
.nav__link--solid:hover { background: var(--accent-dark); color: #fff; }
.nav__link--gold { background: var(--gold); color: var(--support); }
.nav__link--gold:hover { background: var(--gold-dark); color: #fff; }
.nav__caret { font-size: 0.7rem; }

.nav__item-has-children { position: relative; }
.dropdown {
  position: absolute; top: 100%; right: 0; min-width: 240px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 8px; opacity: 0; visibility: hidden;
  transform: translateY(8px); transition: var(--transition); z-index: 110;
}
.nav__item-has-children:hover .dropdown,
.nav__item-has-children:focus-within .dropdown,
.nav__item-has-children.is-open .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown li a {
  display: flex; align-items: center; gap: 10px; padding: 12px 12px; border-radius: var(--radius-sm);
  color: var(--text); font-weight: 500; font-size: 0.9rem; min-height: 44px;
}
.dropdown li a i { color: var(--accent); width: 18px; text-align: center; }
.dropdown li a:hover { background: var(--secondary-light); color: var(--primary); }

.nav-backdrop { position: fixed; inset: 0; background: rgba(44,73,81,0.4); z-index: 99; }

/* Mobile nav close button (inside drawer) */
.nav-close {
  display: none; position: absolute; top: 18px; right: 18px;
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  align-items: center; justify-content: center; color: var(--primary);
  font-size: 1.4rem; transition: var(--transition); z-index: 101;
}
.nav-close:hover { background: var(--secondary-light); color: var(--primary-dark); }

/* ---------- Hero ---------- */
.hero { background: var(--primary); color: #fff; padding: 64px 0 80px; position: relative; overflow: hidden; }
.hero__bg {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  background-repeat: no-repeat; z-index: 0;
}
.hero__overlay {
  position: absolute; inset: 0; background: rgba(56, 92, 101, 0.86); z-index: 1;
}
.hero::before {
  content: ""; position: absolute; right: -120px; top: -120px; width: 360px; height: 360px;
  background: var(--primary-dark); border-radius: 50%; opacity: 0.5; z-index: 1;
}
.hero::after {
  content: ""; position: absolute; left: -80px; bottom: -160px; width: 320px; height: 320px;
  background: var(--support); border-radius: 50%; opacity: 0.35; z-index: 1;
}
.hero__inner { display: grid; grid-template-columns: 1.5fr 1fr; gap: 48px; align-items: center; position: relative; z-index: 2; }
.hero__content { max-width: 620px; }
.hero__title { color: #fff; font-size: clamp(2.2rem, 5vw, 3.4rem); font-weight: 800; letter-spacing: -0.01em; margin: 14px 0; }
.hero__lead { font-size: 1.12rem; color: #D6E7EE; max-width: 560px; }
.hero__lead strong { color: var(--gold); }
.hero__actions { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero__meta { display: flex; gap: 24px; margin-top: 28px; flex-wrap: wrap; font-size: 0.9rem; color: #BFD0D6; }
.hero__meta i { color: var(--gold); margin-right: 6px; }

.hero__card { background: #fff; color: var(--text); border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow-lg); border-top: 4px solid var(--gold); }
.hero__card-title { font-size: 1.15rem; margin-bottom: 16px; }
.hero__card-list { display: grid; gap: 12px; margin-bottom: 22px; }
.hero__card-list li { display: flex; align-items: center; gap: 12px; font-weight: 500; color: var(--text); }
.hero__card-list i { color: var(--accent); width: 22px; font-size: 1.05rem; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.stats--compact { grid-template-columns: repeat(4, 1fr); }
.stat-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px 16px; text-align: center; transition: var(--transition); border-bottom: 3px solid var(--secondary);
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-bottom-color: var(--gold); }
.stat-card__value { font-family: var(--font-head); font-weight: 800; font-size: 2rem; color: var(--primary); line-height: 1; }
.stat-card__label { font-size: 0.82rem; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ---------- Cards grid ---------- */
.cards { display: grid; gap: 24px; }
.cards--2 { grid-template-columns: repeat(2, 1fr); }
.cards--3 { grid-template-columns: repeat(3, 1fr); }
.cards--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; box-shadow: var(--shadow-sm); transition: var(--transition); display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card__icon {
  width: 52px; height: 52px; border-radius: 12px; background: var(--secondary-light);
  display: grid; place-items: center; color: var(--primary); font-size: 1.3rem; margin-bottom: 16px;
}
.card__icon--teal { background: var(--primary); color: #fff; }
.card__icon--green { background: var(--support); color: #fff; }
.card__icon--gold { background: var(--gold); color: var(--support); }
.card__title { font-size: 1.2rem; margin-bottom: 10px; }
.card__title--sm { font-size: 1.05rem; }
.card__text { color: var(--text-muted); font-size: 0.95rem; }
.card__list { margin-top: 14px; display: grid; gap: 8px; }
.card__list li { position: relative; padding-left: 22px; font-size: 0.9rem; color: var(--text); }
.card__list li::before { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; left: 0; color: var(--support); font-size: 0.8rem; }

.card--facility .card__media {
  height: 200px; border-radius: var(--radius); margin-bottom: 16px;
  border: 1px solid var(--border); overflow: hidden; position: relative;
}
.card--facility .card__media img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 400ms cubic-bezier(0.4, 0, 0.2, 1);
}
.card--facility:hover .card__media img { transform: scale(1.06); }
.card--facility .card__media--icon {
  background: var(--secondary); display: grid; place-items: center; color: var(--primary); font-size: 2.4rem;
}
.card__tag { align-self: flex-start; background: var(--support); color: #fff; font-size: 0.7rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; margin-bottom: 10px; letter-spacing: 0.04em; text-transform: uppercase; }
.card__date { font-size: 0.78rem; color: var(--accent); font-weight: 600; font-family: var(--font-head); }
.card__audience { margin-top: auto; padding-top: 12px; font-size: 0.76rem; color: var(--text-light); border-top: 1px solid var(--border); }

/* ---------- Two column ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.two-col--contact, .two-col--apply { align-items: start; }
.two-col__media { display: grid; }
.media-block {
  border-radius: var(--radius-lg); padding: 60px 40px; text-align: center; color: #fff;
  min-height: 320px; display: grid; place-content: center; gap: 16px; box-shadow: var(--shadow-md);
}
.media-block i { font-size: 3.5rem; }
.media-block span { font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; }
.media-block--teal { background: var(--primary); }
.media-block--green { background: var(--support); }
.media-block--gold { background: var(--gold); color: var(--support); }

/* Real image media block */
.media-image {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md);
  position: relative; min-height: 340px; background: var(--surface-alt);
}
.media-image img { width: 100%; height: 100%; min-height: 340px; object-fit: cover; display: block; }
.media-image__caption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 20px;
  background: rgba(42, 61, 54, 0.88); color: #fff; font-family: var(--font-head);
  font-weight: 600; font-size: 0.92rem;
}
.media-image__caption i { color: var(--gold); margin-right: 8px; }

.tick-list { display: grid; gap: 10px; margin-top: 16px; }
.tick-list li { position: relative; padding-left: 26px; color: var(--text); }
.tick-list li::before { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; left: 0; top: 2px; color: var(--support); }

/* ---------- Page hero ---------- */
.page-hero { background: var(--primary); color: #fff; padding: 56px 0; position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; right: -100px; top: -100px; width: 300px; height: 300px; background: var(--support); border-radius: 50%; opacity: 0.3; }
.page-hero__title { color: #fff; font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 10px 0; }
.page-hero__title--sm { font-size: 1.6rem; }
.page-hero__lead { color: #D6E7EE; max-width: 640px; font-size: 1.05rem; }
.page-hero--compact { padding: 36px 0; }
.page-hero__row { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; position: relative; z-index: 1; }

/* ---------- Profile grid ---------- */
.profile-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }
.profile-item { display: flex; flex-direction: column; padding: 20px 24px; border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); }
.profile-item:nth-child(2n) { border-right: none; }
.profile-item:nth-last-child(-n+2) { border-bottom: none; }
.profile-item__label { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-light); font-weight: 600; }
.profile-item__value { font-family: var(--font-head); font-weight: 600; color: var(--primary); margin-top: 4px; }

/* ---------- Leadership cards ---------- */
.leader-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: var(--transition); display: flex; flex-direction: column;
}
.leader-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.leader-card__media { height: 280px; overflow: hidden; background: var(--surface-alt); }
.leader-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 400ms cubic-bezier(0.4, 0, 0.2, 1); }
.leader-card:hover .leader-card__media img { transform: scale(1.05); }
.leader-card__body { padding: 22px; }
.leader-card__name { font-family: var(--font-head); font-weight: 700; font-size: 1.15rem; color: var(--primary); }
.leader-card__role { display: inline-block; background: var(--secondary-light); color: var(--primary); font-size: 0.76rem; font-weight: 600; padding: 4px 12px; border-radius: 999px; margin: 8px 0 12px; }
.leader-card__bio { color: var(--text-muted); font-size: 0.9rem; }

/* ---------- Results gallery (academics) ---------- */
.results-strip { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.results-figure { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); position: relative; background: var(--surface); border: 1px solid var(--border); }
.results-figure img { width: 100%; height: 280px; object-fit: cover; display: block; transition: transform 500ms cubic-bezier(0.4, 0, 0.2, 1); }
.results-figure:hover img { transform: scale(1.04); }
.results-figure figcaption { padding: 14px 18px; font-family: var(--font-head); font-weight: 600; color: var(--primary); font-size: 0.95rem; border-top: 1px solid var(--border); }
.results-figure figcaption i { color: var(--accent); margin-right: 8px; }

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.chip { background: var(--surface); border: 1px solid var(--border); color: var(--primary); padding: 11px 20px; border-radius: 999px; font-weight: 500; font-size: 0.9rem; transition: var(--transition); min-height: 44px; display: inline-flex; align-items: center; }
.chip:hover { background: var(--secondary-light); border-color: var(--secondary); }
.chip--filter { cursor: pointer; }
.chip--filter.is-active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ---------- Gallery ---------- */
.gallery-filter { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 32px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.gallery-item { border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm); transition: var(--transition); }
.gallery-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.gallery-item.is-hidden { display: none; }
.gallery-item__media { height: 220px; overflow: hidden; position: relative; }
.gallery-item__media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 500ms cubic-bezier(0.4, 0, 0.2, 1); }
.gallery-item:hover .gallery-item__media img { transform: scale(1.07); }
.gallery-item__media--icon { background: var(--secondary); display: grid; place-items: center; color: var(--primary); font-size: 2.6rem; }
.gallery-item:nth-child(3n) .gallery-item__media { background: var(--secondary-light); }
.gallery-item:nth-child(3n+1) .gallery-item__media { background: var(--support); color: #fff; }
.gallery-item__caption { padding: 14px 18px; display: flex; justify-content: space-between; align-items: center; }
.gallery-item__title { font-family: var(--font-head); font-weight: 600; color: var(--primary); font-size: 0.95rem; }
.gallery-item__group { font-size: 0.72rem; color: var(--text-light); background: var(--surface-alt); padding: 3px 8px; border-radius: 999px; }
.gallery-note { text-align: center; color: var(--text-muted); margin-top: 28px; font-size: 0.88rem; }
.gallery-note i { color: var(--gold); }

/* ---------- CTA band ---------- */
.cta-band { background: var(--support); color: #fff; padding: 56px 0; }
.cta-band__inner { display: flex; justify-content: space-between; align-items: center; gap: 28px; flex-wrap: wrap; }
.cta-band__text h2 { color: #fff; font-size: clamp(1.5rem, 3vw, 2rem); }
.cta-band__text p { color: #C9D6D1; margin-top: 6px; }
.cta-band__actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 18px; max-width: 640px; }
.form__section { font-family: var(--font-head); font-weight: 600; color: var(--primary); font-size: 1.05rem; padding-bottom: 8px; border-bottom: 2px solid var(--secondary); margin-top: 8px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form__group { display: flex; flex-direction: column; gap: 6px; }
.form__group label { font-weight: 600; font-size: 0.88rem; color: var(--text); }
.req { color: var(--accent); }
.form__group input, .form__group select, .form__group textarea {
  padding: 12px 14px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); transition: var(--transition);
}
.form__group input:focus, .form__group select:focus, .form__group textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(56,92,101,0.15);
}
.form__group textarea { resize: vertical; }

.alert { padding: 14px 18px; border-radius: var(--radius); display: flex; gap: 10px; align-items: flex-start; font-weight: 500; font-size: 0.92rem; }
.alert--success { background: #E6F0EC; border: 1px solid #BFD9CD; color: var(--support); }
.alert--error { background: #F5E6E9; border: 1px solid #E0C2C9; color: var(--accent); }
.alert--info { background: var(--secondary-light); border: 1px solid var(--secondary); color: var(--primary); }
.alert--sm { padding: 10px 14px; font-size: 0.84rem; margin-top: 12px; }
.alert i { margin-top: 2px; }

.demo-note { margin-top: 18px; padding: 14px 16px; background: var(--surface-alt); border-radius: var(--radius); font-size: 0.84rem; color: var(--text-muted); border: 1px dashed var(--border-strong); }
.demo-note code { background: var(--surface); padding: 2px 8px; border-radius: 4px; color: var(--accent); font-weight: 600; }

/* ---------- Contact info / side panels ---------- */
.contact-info { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow-sm); }
.contact-info__list { display: grid; gap: 18px; margin-top: 16px; }
.contact-info__list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-info__icon { width: 40px; height: 40px; border-radius: 10px; background: var(--secondary-light); color: var(--primary); display: grid; place-items: center; flex-shrink: 0; }
.contact-info__hours { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--border); }
.contact-info__hours h3 { font-size: 1rem; margin-bottom: 6px; }
.contact-info__hours p { color: var(--text-muted); font-size: 0.9rem; }

.apply-side { display: grid; gap: 24px; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 26px; box-shadow: var(--shadow-sm); }
.panel--highlight { border-top: 4px solid var(--gold); }
.panel__title { font-size: 1.15rem; display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.panel__title i { color: var(--accent); }
.panel__note { font-size: 0.84rem; color: var(--text-muted); margin-top: 14px; }
.panel__note i { color: var(--gold); }

.fees-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px dashed var(--border); }
.fees-row--bold { font-weight: 700; border-bottom: none; padding-top: 12px; }
.fees-table { display: grid; gap: 4px; }

.steps { counter-reset: step; display: grid; gap: 14px; margin-top: 8px; }
.steps li { position: relative; padding-left: 38px; }
.steps li::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: 0; width: 26px; height: 26px; background: var(--primary); color: #fff; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-head); font-weight: 700; font-size: 0.85rem; }

.pay-box { background: var(--surface-alt); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 14px; border-left: 4px solid var(--support); }
.pay-box h3 { font-size: 0.95rem; margin-bottom: 6px; color: var(--support); }
.pay-box p { font-size: 0.9rem; margin: 2px 0; }
.pay-box__big { font-size: 1.05rem; }
.pay-box__big strong { color: var(--accent); font-family: var(--font-head); }

/* ---------- Dashboard ---------- */
.dash-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card--stat { border-top: 4px solid var(--secondary); }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table thead th { text-align: left; padding: 12px 16px; background: var(--surface-alt); color: var(--primary); font-family: var(--font-head); font-weight: 600; font-size: 0.88rem; border-bottom: 2px solid var(--border); }
.table tbody td { padding: 12px 16px; border-bottom: 1px solid var(--border); }
.table tbody tr:hover { background: var(--surface-alt); }
.grade { display: inline-block; padding: 3px 12px; border-radius: 999px; font-weight: 700; font-family: var(--font-head); font-size: 0.85rem; }
.grade--A { background: #E6F0EC; color: var(--support); }
.grade--B { background: var(--secondary-light); color: var(--primary); }
.grade--C { background: #F5EFE0; color: var(--gold-dark); }
.grade--D, .grade--E { background: #F5E6E9; color: var(--accent); }

/* ---------- Footer ---------- */
.footer { background: var(--support); color: #C9D6D1; padding-top: 56px; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 36px; padding-bottom: 40px; }
.footer__col--brand .brand__name { color: #fff; }
.footer__about { margin: 16px 0; font-size: 0.9rem; color: #A8BBB4; max-width: 320px; }
.footer__social { display: flex; gap: 10px; }
.footer__social a { width: 44px; height: 44px; border-radius: 10px; background: rgba(255,255,255,0.1); display: grid; place-items: center; color: #fff; transition: var(--transition); font-size: 1.1rem; }
.footer__social a:hover { background: var(--gold); color: var(--support); }
.footer__heading { color: #fff; font-size: 1rem; margin-bottom: 16px; }
.footer__links, .footer__contact { display: grid; gap: 10px; }
.footer__links a, .footer__contact a { color: #C9D6D1; font-size: 0.9rem; }
.footer__links a:hover, .footer__contact a:hover { color: var(--gold); }
.footer__contact li { display: flex; gap: 10px; font-size: 0.9rem; }
.footer__contact i { color: var(--gold); margin-top: 4px; }
.brand-logo-footer { max-height: 64px; }
.footer__bar { border-top: 1px solid rgba(255,255,255,0.12); padding: 18px 0; }
.footer__bar-inner { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 0.82rem; color: #8FA59E; }
.footer__bar a { color: #C9D6D1; }

/* ---------- Floating action buttons ---------- */
.fab-group { position: fixed; right: 22px; bottom: 22px; z-index: 200; display: flex; flex-direction: column; gap: 14px; }
.fab { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 1.5rem; box-shadow: var(--shadow-lg); transition: var(--transition); position: relative; }
.fab:hover { transform: scale(1.08); }
.fab--whatsapp { background: #25D366; }
.fab--whatsapp:hover { background: #1ebd5a; color: #fff; }
.fab--call { background: var(--accent); }
.fab--call:hover { background: var(--accent-dark); color: #fff; }
.fab__pulse { position: absolute; inset: 0; border-radius: 50%; background: #25D366; opacity: 0.5; animation: pulse 2s ease-out infinite; z-index: -1; }
@keyframes pulse { 0% { transform: scale(1); opacity: 0.5; } 100% { transform: scale(1.8); opacity: 0; } }

/* ==========================================================================
   Responsive
   Nav hamburger: ≤1180px (10 items need ≥1181px to fit without overflow)
   Layout breakpoints: 1024 / 860 / 768 / 560 / 430 / 360
   ========================================================================== */

/* ---- Nav → hamburger drawer (triggers at container max-width) ----------- */
@media (max-width: 1180px) {
  .nav-toggle { display: block; }
  .nav-close { display: inline-flex; }
  .brand-logo { max-height: 56px; }
  .nav {
    position: fixed; top: 0; right: -100%; width: 100vw; height: 100vh;
    background: var(--surface); box-shadow: var(--shadow-lg); padding: 70px 16px 20px;
    overflow-y: auto; transition: right 280ms ease; z-index: 100;
    border-left: 1px solid var(--border); flex: none;
  }
  .nav.is-open { right: 0; }
  .nav__list { flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 1px; }
  .nav__link { width: 100%; justify-content: flex-start; padding: 10px 14px; font-size: 0.95rem; min-height: 42px; white-space: normal; }
  .nav__link--solid, .nav__link--gold { margin-top: 4px; }
  .nav__item-has-children { width: 100%; }
  .nav__item-has-children .nav__link--btn { width: 100%; justify-content: space-between; }
  .dropdown {
    position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none;
    border: none; padding: 2px 0 2px 12px; min-width: 0; display: none;
  }
  .dropdown li a { padding: 8px 12px; min-height: 38px; font-size: 0.85rem; }
  .nav__item-has-children.is-open .dropdown { display: block; }
}

/* ---- Grid layout at tablet/large-phone sizes ---------------------------- */
@media (max-width: 1024px) {
  .stats { grid-template-columns: repeat(3, 1fr); }
  .stats--compact { grid-template-columns: repeat(2, 1fr); }
  .cards--4 { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__col--brand { grid-column: 1 / -1; }
}

@media (max-width: 860px) {
  .hero__inner { grid-template-columns: 1fr; gap: 28px; }
  .hero { padding: 44px 0 52px; }
  .two-col { grid-template-columns: 1fr; gap: 28px; }
  .two-col__media { order: -1; }
  .cards--3 { grid-template-columns: repeat(2, 1fr); }
  .cards--2 { grid-template-columns: repeat(2, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .results-strip { grid-template-columns: repeat(2, 1fr); }
  .form__row { grid-template-columns: 1fr; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-item { border-right: none; }
  .hide-sm { display: none; }
  .section { padding: 52px 0; }
  .section__head { margin-bottom: 28px; }
  .media-image, .media-image img { min-height: 280px; }
  .media-block { min-height: 260px; padding: 48px 32px; }
  .leader-card__media { height: 200px; }
  .leader-card__body { padding: 14px; }
  .leader-card__name { font-size: 1.05rem; }
  .leader-card__role { font-size: 0.72rem; padding: 3px 10px; margin: 6px 0 8px; }
  .leader-card__bio { font-size: 0.84rem; }
  .results-figure img { height: 240px; }
}

@media (max-width: 768px) {
  .section { padding: 48px 0; }
  .section__head { margin-bottom: 24px; }
  .cards { gap: 10px; }
  .card { padding: 14px; }
  .card__icon { width: 38px; height: 38px; font-size: 1rem; margin-bottom: 8px; }
  .card__title { font-size: 1.05rem; margin-bottom: 6px; }
  .card__text { font-size: 0.86rem; }
  .card__list { margin-top: 8px; gap: 5px; }
  .card__list li { font-size: 0.82rem; padding-left: 18px; }
  .stats { gap: 10px; }
  .stat-card { padding: 14px 10px; }
  .stat-card__value { font-size: 1.6rem; }
  .stat-card__label { font-size: 0.76rem; margin-top: 3px; }
  .hero { padding: 40px 0 48px; }
  .hero__title { font-size: clamp(1.8rem, 6vw, 2.4rem); }
  .hero__lead { font-size: 1.05rem; }
  .hero__card { padding: 22px; }
  .hero__card-list { gap: 10px; }
  .page-hero { padding: 44px 0; }
  .cta-band { padding: 44px 0; }
  .footer { padding-top: 44px; }
  .footer__grid { gap: 28px; padding-bottom: 32px; }
  .two-col { gap: 24px; }
  .center-btn { margin-top: 28px; }
}

@media (max-width: 560px) {
  .stats { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stats--compact { grid-template-columns: repeat(2, 1fr); }
  .cards--4 { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr; }
  .topbar__left { gap: 12px; font-size: 0.8rem; }
  .hero__actions { flex-direction: row; flex-wrap: nowrap; gap: 10px; }
  .hero__actions .btn { flex: 1 1 0; width: auto; padding: 11px 12px; font-size: 0.9rem; }
  .cta-band__actions .btn { width: 100%; }
  .cta-band__actions { flex-direction: column; }
  .fab { width: 50px; height: 50px; font-size: 1.3rem; }
  .fab-group { right: 16px; bottom: 16px; gap: 12px; }
  .brand-logo { max-height: 50px; }
  .brand-logo-footer { max-height: 48px; }
  .container { padding: 0 16px; }

  /* Reduce padding to cut scroll depth */
  .section { padding: 40px 0; }
  .section--tight { padding: 32px 0; }
  .section__head { margin-bottom: 22px; }
  .cards { gap: 8px; }
  .card { padding: 12px; }
  .card__icon { width: 34px; height: 34px; font-size: 0.9rem; margin-bottom: 6px; }
  .card__title { font-size: 1rem; margin-bottom: 4px; }
  .card__text { font-size: 0.82rem; }
  .card__list { margin-top: 6px; gap: 4px; }
  .card__list li { font-size: 0.78rem; padding-left: 16px; }
  .panel { padding: 20px; }
  .contact-info { padding: 20px; }
  .hero { padding: 36px 0 40px; }
  .hero__card { padding: 20px; }
  .page-hero { padding: 36px 0; }
  .cta-band { padding: 36px 0; }
  .footer { padding-top: 36px; }
  .footer__grid { gap: 24px; padding-bottom: 28px; }
  .center-btn { margin-top: 24px; }
  .two-col { gap: 20px; }

  /* Compact media on phones */
  .media-image, .media-image img { min-height: 220px; }
  .media-block { min-height: 200px; padding: 36px 24px; }
  .media-block i { font-size: 2.5rem; }
  .leader-card__media { height: 170px; }
  .leader-card__body { padding: 12px; }
  .leader-card__name { font-size: 1rem; }
  .leader-card__role { font-size: 0.68rem; padding: 2px 8px; margin: 5px 0 6px; }
  .leader-card__bio { font-size: 0.8rem; }
  .results-figure img { height: 200px; }
  .gallery-item__media { height: 180px; }
  .card--facility .card__media { height: 180px; }
  .stat-card { padding: 12px 8px; }
  .stat-card__value { font-size: 1.4rem; }
  .stat-card__label { font-size: 0.72rem; margin-top: 2px; }
}

@media (max-width: 430px) {
  .cards--3 { grid-template-columns: repeat(2, 1fr); }
  .cards--2 { grid-template-columns: 1fr; }
  .results-strip { grid-template-columns: 1fr; }
  .dash-grid { grid-template-columns: 1fr; }
  .hero__title { font-size: 1.7rem; }
  .hero__lead { font-size: 1rem; }
  .hero__meta { gap: 14px; font-size: 0.85rem; }
  .hero__actions { gap: 8px; }
  .hero__actions .btn { padding: 10px 8px; font-size: 0.82rem; }
  .section__title { font-size: 1.4rem; }
  .page-hero__title { font-size: 1.5rem; }
  .page-hero__lead { font-size: 0.98rem; }
  .card { padding: 10px; }
  .card__icon { width: 30px; height: 30px; font-size: 0.85rem; margin-bottom: 5px; }
  .card__title { font-size: 0.95rem; margin-bottom: 3px; }
  .card__text { font-size: 0.78rem; }
  .card__list li { font-size: 0.74rem; padding-left: 14px; }
  .panel { padding: 18px; }
  .hero__card { padding: 18px; }
  .hero__card-list li { font-size: 0.9rem; }
  .topbar__inner { padding-top: 6px; padding-bottom: 6px; }
  .topbar__left { font-size: 0.76rem; gap: 8px; }
  .topbar__left .hide-xs { display: none; }
  .badge-pill { font-size: 0.68rem; padding: 2px 8px; }
  .gallery-item__media { height: 160px; }
  .card--facility .card__media { height: 160px; }
  .media-image, .media-image img { min-height: 200px; }
  .leader-card__media { height: 150px; }
  .leader-card__body { padding: 10px; }
  .leader-card__name { font-size: 0.92rem; }
  .leader-card__role { font-size: 0.64rem; padding: 2px 7px; margin: 4px 0 5px; }
  .leader-card__bio { font-size: 0.76rem; }
}

@media (max-width: 360px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats--compact { grid-template-columns: repeat(2, 1fr); }
  .cards--4 { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .stat-card { padding: 10px 6px; }
  .stat-card__value { font-size: 1.3rem; }
  .stat-card__label { font-size: 0.68rem; margin-top: 2px; }
  .hero__title { font-size: 1.55rem; }
  .hero__actions .btn { padding: 9px 6px; font-size: 0.76rem; gap: 5px; }
  .section__title { font-size: 1.3rem; }
  .container { padding: 0 14px; }
  .fab { width: 46px; height: 46px; font-size: 1.2rem; }
  .fab-group { right: 12px; bottom: 12px; gap: 10px; }
  .brand-logo { max-height: 46px; }
}

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