/* ==========================================================================
   EXELENTIA EDGE ACADEMY — Design System
   Concept website by Driss Digitals
   ========================================================================== */

/* -------------------------------------------------------------------------
   1. FONTS
   ------------------------------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,500;0,9..144,600;1,9..144,500&family=Inter:wght@400;500;600;700&display=swap');

/* -------------------------------------------------------------------------
   2. DESIGN TOKENS
   ------------------------------------------------------------------------- */
:root{
  /* Color: grown out of the logo's botanical teal-green */
  --primary:        #1F8A70;
  --primary-dark:   #10493C;
  --accent:         #2FBF9F;
  --background:     #FAF8F3;
  --surface:        #FFFFFF;
  --surface-tint:   #F1F0E8;
  --text:           #16221D;
  --muted:          #5B6A62;
  --border:         #E3E1D6;
  --border-strong:  #C9D3CB;

  /* Typography */
  --font-display: 'Fraunces', 'Georgia', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Spacing scale */
  --space-2xs: 0.4rem;
  --space-xs:  0.8rem;
  --space-sm:  1.2rem;
  --space-md:  2rem;
  --space-lg:  3.2rem;
  --space-xl:  5.2rem;
  --space-2xl: 8rem;

  /* Layout */
  --container-max: 1180px;
  --radius-sm: 4px;
  --radius-md: 10px;
  --radius-lg: 20px;

  /* Motion */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --speed: 0.35s;
}

/* -------------------------------------------------------------------------
   3. RESET
   ------------------------------------------------------------------------- */
*, *::before, *::after{ box-sizing: border-box; }
html{
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
body{
  margin: 0;
  font-family: var(--font-body);
  background: var(--background);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img{ max-width: 100%; display: block; }
a{ color: inherit; text-decoration: none; }
ul, ol{ list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4, p, figure{ margin: 0; }
button{ font-family: inherit; cursor: pointer; }
input, textarea, select{ font-family: inherit; font-size: inherit; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible{
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* -------------------------------------------------------------------------
   4. TYPE SCALE
   ------------------------------------------------------------------------- */
h1, h2, h3, h4{
  font-family: var(--font-display);
  color: var(--primary-dark);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
h1{ font-size: clamp(2.4rem, 5vw, 4rem); }
h2{ font-size: clamp(1.9rem, 3.4vw, 2.7rem); }
h3{ font-size: clamp(1.3rem, 2vw, 1.6rem); }
h4{ font-size: 1.1rem; }

p{ max-width: 62ch; }
.lede{
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--muted);
}
.section-kicker{
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--primary);
  display: block;
  margin-bottom: var(--space-xs);
}

/* -------------------------------------------------------------------------
   5. LAYOUT HELPERS
   ------------------------------------------------------------------------- */
.container{
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-md);
}
section{ padding-block: var(--space-2xl); }
.section-tight{ padding-block: var(--space-xl); }
.section-head{
  max-width: 640px;
  margin-bottom: var(--space-lg);
}
.section-head.centered{
  margin-inline: auto;
  text-align: center;
}
.surface{ background: var(--surface); }
.tint{ background: var(--surface-tint); }

.grid{ display: grid; gap: var(--space-md); }
.grid-2{ grid-template-columns: repeat(2, 1fr); }
.grid-3{ grid-template-columns: repeat(3, 1fr); }
.grid-4{ grid-template-columns: repeat(4, 1fr); }

@media (max-width: 900px){
  .grid-3, .grid-4{ grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px){
  .grid-2, .grid-3, .grid-4{ grid-template-columns: 1fr; }
  section{ padding-block: var(--space-xl); }
}

/* -------------------------------------------------------------------------
   6. BUTTONS
   ------------------------------------------------------------------------- */
.btn{
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.7rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.98rem;
  border: 1px solid transparent;
  transition: transform var(--speed) var(--ease), background var(--speed) var(--ease), color var(--speed) var(--ease), border-color var(--speed) var(--ease);
  white-space: nowrap;
}
.btn-primary{
  background: var(--primary-dark);
  color: #fff;
}
.btn-primary:hover{ background: var(--primary); transform: translateY(-2px); }
.btn-outline{
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-outline:hover{
  border-color: var(--primary-dark);
  color: var(--primary-dark);
  transform: translateY(-2px);
}
.btn-ghost-light{
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.5);
  color: #fff;
}
.btn-ghost-light:hover{ background: rgba(255,255,255,0.22); transform: translateY(-2px); }
.btn-row{ display: flex; flex-wrap: wrap; gap: var(--space-sm); }

/* -------------------------------------------------------------------------
   7. IMAGE PLACEHOLDERS
   ------------------------------------------------------------------------- */
.ph{
  position: relative;
  display: block;
  width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(31,138,112,0.14), rgba(16,73,60,0.22)),
    repeating-linear-gradient(45deg, rgba(16,73,60,0.05) 0, rgba(16,73,60,0.05) 2px, transparent 2px, transparent 14px);
  border: 1px solid var(--border);
}
.ph::after{
  content: attr(data-label);
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary-dark);
  background: rgba(255,255,255,0.85);
  padding: 0.5rem 0.9rem;
  border-radius: 100px;
  text-align: center;
  white-space: nowrap;
}
.ph-16-9{ aspect-ratio: 16 / 9; }
.ph-4-3{ aspect-ratio: 4 / 3; }
.ph-1-1{ aspect-ratio: 1 / 1; }
.ph-3-4{ aspect-ratio: 3 / 4; }
.ph-hero{ aspect-ratio: 4 / 3; }
@media (min-width: 760px){ .ph-hero{ aspect-ratio: 3 / 2; } }

/* -------------------------------------------------------------------------
   8. HEADER / NAVIGATION
   ------------------------------------------------------------------------- */
.site-header{
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
}
/* The translucent blurred background lives on a ::before instead of directly
   on .site-header. backdrop-filter (like transform/filter/perspective) makes
   an element a "containing block" for any position:fixed descendant, which
   was clipping the mobile nav-links panel down to the header's own height
   (this is why only "Home" was visible — the panel had almost no room).
   Keeping backdrop-filter off .site-header lets .nav-links (fixed) size
   itself against the real viewport instead. */
.site-header::before{
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(250, 248, 243, 0.92);
  backdrop-filter: blur(8px);
}
.nav{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-xs);
  gap: var(--space-md);
}
.brand{
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-shrink: 0;
}
.brand img{
  width: 40px;
  height: 40px;
  object-fit: contain;
}
.brand-name{
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--primary-dark);
  line-height: 1.1;
}
.brand-name small{
  display: block;
  font-family: var(--font-body);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.nav-links{
  display: flex;
  align-items: center;
  gap: var(--space-md);
}
.nav-links a{
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  position: relative;
  padding-block: 0.3rem;
}
.nav-links a::after{
  content: '';
  position: absolute;
  left: 0; right: 100%;
  bottom: 0;
  height: 2px;
  background: var(--primary);
  transition: right var(--speed) var(--ease);
}
.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after{ right: 0; }
.nav-links a[aria-current="page"]{ color: var(--primary-dark); font-weight: 600; }
.nav-actions{ display: flex; align-items: center; gap: var(--space-sm); }

.nav-toggle{
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
}
.nav-toggle span{
  display: block;
  width: 20px;
  height: 2px;
  background: var(--primary-dark);
  margin-inline: auto;
  transition: transform var(--speed) var(--ease), opacity var(--speed) var(--ease);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1){ transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2){ opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3){ transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px){
  .nav-toggle{ display: flex; }
  .nav-links{
    /* --header-h is set by main.js from the header's real, measured
       offsetHeight (see setHeaderHeightVar), so this never depends on a
       guessed pixel value that could be wrong on a different phone/font
       size. The 68px after each var() is only a fallback for the brief
       instant before JS runs. */
    position: fixed;
    top: var(--header-h, 68px);
    left: 0;
    right: 0;
    bottom: 0;
    height: calc(100vh - var(--header-h, 68px));
    height: calc(100dvh - var(--header-h, 68px));
    background: var(--background);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: var(--space-md);
    gap: var(--space-sm);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--speed) var(--ease), transform var(--speed) var(--ease), visibility var(--speed);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 99;
  }
  .nav-links.is-open{
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
  }
  .nav-links a{
    width: 100%;
    padding: 0.9rem 0.2rem;
    border-bottom: 1px solid var(--border);
    font-size: 1.05rem;
  }
  .nav-actions{ display: none; }
  .nav-links .nav-actions-mobile{
    display: flex;
    margin-top: var(--space-sm);
    width: 100%;
  }
  .nav-links .nav-actions-mobile .btn{ width: 100%; justify-content: center; }
}

/* -------------------------------------------------------------------------
   9. HERO (shared pattern for interior pages)
   ------------------------------------------------------------------------- */
.page-hero{
  background: var(--primary-dark);
  color: #fff;
  padding-block: var(--space-xl);
}
.page-hero h1{ color: #fff; }
.page-hero .lede{ color: rgba(255,255,255,0.78); }
.breadcrumb{
  font-size: 0.85rem;
  color: rgba(255,255,255,0.65);
  margin-bottom: var(--space-sm);
}
.breadcrumb a{ color: rgba(255,255,255,0.85); }
.breadcrumb a:hover{ text-decoration: underline; }

/* -------------------------------------------------------------------------
   10. CARDS
   ------------------------------------------------------------------------- */
.card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-md);
}
.card-index{
  font-family: var(--font-display);
  font-style: italic;
  color: var(--primary);
  font-size: 1.4rem;
  display: block;
  margin-bottom: var(--space-xs);
}

/* -------------------------------------------------------------------------
   11. PROCESS / STEPS
   ------------------------------------------------------------------------- */
.steps{
  display: grid;
  gap: var(--space-md);
  grid-template-columns: repeat(4, 1fr);
  counter-reset: step;
}
.step{
  position: relative;
  padding-top: var(--space-md);
  border-top: 2px solid var(--border-strong);
}
.step-num{
  font-family: var(--font-display);
  font-style: italic;
  color: var(--primary);
  font-size: 1.6rem;
  display: block;
  margin-bottom: var(--space-2xs);
}
@media (max-width: 900px){ .steps{ grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px){ .steps{ grid-template-columns: 1fr; } }

/* -------------------------------------------------------------------------
   12. FOOTER
   ------------------------------------------------------------------------- */
.site-footer{
  background: var(--primary-dark);
  color: rgba(255,255,255,0.85);
  padding-block: var(--space-xl) var(--space-md);
}
.footer-grid{
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: var(--space-lg);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.footer-brand{ display: flex; gap: 0.7rem; margin-bottom: var(--space-sm); }
.footer-brand img{ width: 38px; height: 38px; object-fit: contain; }
.footer-brand-name{ font-family: var(--font-display); color: #fff; font-size: 1.1rem; }
.footer-tagline{ font-style: italic; font-family: var(--font-display); color: var(--accent); margin-bottom: var(--space-sm); }
.footer-desc{ font-size: 0.92rem; color: rgba(255,255,255,0.65); max-width: 34ch; }
.footer-heading{ color: #fff; font-weight: 600; font-size: 0.92rem; margin-bottom: var(--space-sm); }
.footer-col a{
  display: block;
  padding-block: 0.35rem;
  font-size: 0.92rem;
  color: rgba(255,255,255,0.72);
  transition: color var(--speed);
}
.footer-col a:hover{ color: #fff; }
.footer-bottom{
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-xs);
  padding-top: var(--space-md);
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
}
.footer-bottom a{ color: rgba(255,255,255,0.8); font-weight: 600; }
.footer-bottom a:hover{ text-decoration: underline; }

@media (max-width: 900px){
  .footer-grid{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px){
  .footer-grid{ grid-template-columns: 1fr; }
  .footer-bottom{ flex-direction: column; }
}

/* -------------------------------------------------------------------------
   13. REVEAL ANIMATION (single orchestrated on-scroll reveal)
   ------------------------------------------------------------------------- */
.reveal{
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-visible{ opacity: 1; transform: translateY(0); }

/* -------------------------------------------------------------------------
   14. FORMS
   ------------------------------------------------------------------------- */
.form-field{ margin-bottom: var(--space-sm); }
.form-field label{
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--primary-dark);
}
.form-field input,
.form-field textarea{
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
}
.form-field input:focus,
.form-field textarea:focus{
  outline: 2px solid var(--primary);
  outline-offset: 1px;
  border-color: var(--primary);
}
.form-note{
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: var(--space-sm);
}
.form-success{
  display: none;
  background: var(--surface-tint);
  border: 1px solid var(--border-strong);
  border-left: 4px solid var(--primary);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-md);
}
.form-success.is-shown{ display: block; }

/* -------------------------------------------------------------------------
   15. MISC UTILITIES
   ------------------------------------------------------------------------- */
.pill{
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 100px;
  background: rgba(31,138,112,0.1);
  color: var(--primary-dark);
  font-size: 0.78rem;
  font-weight: 600;
}
.divider{
  height: 1px;
  background: var(--border);
  border: none;
  margin-block: var(--space-lg);
}
.two-col{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
}
@media (max-width: 800px){
  .two-col{ grid-template-columns: 1fr; }
}
.stack{ display: flex; flex-direction: column; gap: var(--space-sm); }
.tag-list{ display: flex; flex-wrap: wrap; gap: 0.6rem; }
.notice{
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: var(--space-sm) var(--space-md);
  font-size: 0.92rem;
  color: var(--muted);
}

/* ==========================================================================
   HOMEPAGE-SPECIFIC SECTIONS
   ========================================================================== */

/* --- Hero --- */
.hero{
  background: var(--surface);
  padding-block: var(--space-lg) var(--space-2xl);
  overflow: hidden;
}
.hero-grid{
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: var(--space-xl);
  align-items: center;
}
.hero-eyebrow{
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  color: var(--primary);
  margin-bottom: var(--space-sm);
  display: block;
}
.hero h1{ margin-bottom: var(--space-sm); }
.hero .lede{ margin-bottom: var(--space-md); }
.hero-visual{ position: relative; }
.hero-visual .ph{ width: 100%; }
.hero-visual::before{
  content: '';
  position: absolute;
  top: -18px; left: -18px;
  width: 70%; height: 70%;
  border: 2px solid var(--primary);
  border-radius: var(--radius-md);
  z-index: -1;
}
@media (max-width: 800px){
  .hero-grid{ grid-template-columns: 1fr; }
  .hero-visual{ order: -1; }
  .hero-visual::before{ display: none; }
}

/* --- Introduction --- */
.intro-grid{
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: var(--space-xl);
  align-items: center;
}
@media (max-width: 800px){ .intro-grid{ grid-template-columns: 1fr; } }

/* --- Programme cards --- */
.programme-card{
  border-top: 3px solid var(--primary);
  background: var(--surface);
  padding: var(--space-md);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

/* --- Why cards --- */
.why-card{
  padding: var(--space-md) 0;
  border-top: 1px solid var(--border);
}
.why-card h3{ margin-bottom: var(--space-2xs); }
.why-card p{ color: var(--muted); }

/* --- Learning approach (editorial, distinctive) --- */
.approach{
  background: var(--primary-dark);
  color: #fff;
  position: relative;
}
.approach h2{ color: #fff; }
.approach .section-head .lede{ color: rgba(255,255,255,0.72); }
.approach-list{
  border-top: 1px solid rgba(255,255,255,0.2);
}
.approach-item{
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: var(--space-md);
  padding-block: var(--space-md);
  border-bottom: 1px solid rgba(255,255,255,0.2);
  align-items: baseline;
}
.approach-item .approach-num{
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--accent);
}
.approach-item h3{ color: #fff; margin-bottom: 0.4rem; }
.approach-item p{ color: rgba(255,255,255,0.72); max-width: 55ch; }
@media (max-width: 640px){
  .approach-item{ grid-template-columns: 1fr; gap: var(--space-2xs); }
}

/* --- Facilities --- */
.facility-card figure{ margin-bottom: var(--space-sm); }
.facility-card h3{ font-size: 1.05rem; margin-bottom: 0.3rem; }

/* --- Student life feature strip --- */
.life-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}
.life-clubs{ display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-sm) var(--space-md); }
.life-clubs li{
  padding-block: var(--space-xs);
  border-bottom: 1px solid var(--border);
  font-weight: 500;
}
@media (max-width: 800px){
  .life-grid{ grid-template-columns: 1fr; }
  .life-clubs{ grid-template-columns: 1fr; }
}

/* --- Admissions CTA / process --- */
.admissions-cta{
  background: var(--surface-tint);
}
.process-strip{
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
  margin-block: var(--space-lg);
}
@media (max-width: 800px){ .process-strip{ grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px){ .process-strip{ grid-template-columns: 1fr; } }

/* --- News cards --- */
.news-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.news-card .ph{ border-radius: 0; border: none; }
.news-card-body{ padding: var(--space-sm) var(--space-md) var(--space-md); flex: 1; display: flex; flex-direction: column; gap: 0.5rem; }
.news-meta{ font-size: 0.8rem; color: var(--muted); display: flex; gap: 0.6rem; align-items: center; }
.news-card h3{ font-size: 1.1rem; }
.news-card p{ color: var(--muted); font-size: 0.95rem; }
.news-read-more{ margin-top: auto; font-weight: 600; color: var(--primary-dark); }

/* --- Final CTA band --- */
.final-cta{
  background: var(--primary-dark);
  color: #fff;
  text-align: center;
  padding-block: var(--space-2xl);
}
.final-cta h2{ color: #fff; }
.final-cta .lede{ color: rgba(255,255,255,0.75); margin-inline: auto; margin-bottom: var(--space-md); }
.final-cta .btn-row{ justify-content: center; }

/* ==========================================================================
   INTERIOR PAGE COMPONENTS
   ========================================================================== */

.value-list{ display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); }
@media (max-width: 800px){ .value-list{ grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px){ .value-list{ grid-template-columns: 1fr; } }

.principal-block{
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: var(--space-xl);
  align-items: start;
}
@media (max-width: 800px){ .principal-block{ grid-template-columns: 1fr; } }
.signature{
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--primary-dark);
  margin-top: var(--space-sm);
}

.dept-block{ margin-bottom: var(--space-lg); }
.dept-block h3{ margin-bottom: var(--space-sm); color: var(--primary-dark); }
.subject-tags{ display: flex; flex-wrap: wrap; gap: 0.6rem; }

.future-slot{
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  text-align: center;
  color: var(--muted);
  background: var(--surface-tint);
}
.future-slot strong{ display: block; color: var(--primary-dark); margin-bottom: 0.4rem; }

.contact-grid{
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: var(--space-xl);
}
@media (max-width: 900px){ .contact-grid{ grid-template-columns: 1fr; } }
.contact-detail{ display: flex; gap: var(--space-sm); padding-block: var(--space-sm); border-bottom: 1px solid var(--border); }
.contact-detail h4{ margin-bottom: 0.2rem; }
.contact-detail p{ color: var(--muted); margin: 0; }

.map-ph{
  aspect-ratio: 16/10;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface-tint);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
  padding: var(--space-md);
}

/* ==========================================================================
   16. REAL IMAGE FRAMES
   Same aspect-ratio system as .ph placeholders, but for actual <img> content.
   Reuses .ph-16-9 / .ph-4-3 / .ph-1-1 / .ph-3-4 / .ph-hero for aspect-ratio.
   ========================================================================== */
.img-frame{
  position: relative;
  display: block;
  width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-tint);
}
.img-frame img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.news-card .img-frame{ border-radius: 0; border: none; }

/* ==========================================================================
   17. ADMISSIONS APPLICATION SYSTEM
   Multi-step form, review screen, confirmation screen and print form.
   ========================================================================== */

/* --- Progress indicator --- */
.app-progress{
  display: flex;
  justify-content: space-between;
  gap: var(--space-sm);
  flex-wrap: wrap;
  margin-bottom: var(--space-lg);
}
.app-progress-step{
  flex: 1 1 130px;
  text-align: center;
  padding-bottom: var(--space-sm);
  border-bottom: 3px solid var(--border-strong);
  color: var(--muted);
  transition: border-color var(--speed) var(--ease), color var(--speed) var(--ease);
}
.app-progress-num{
  display: block;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.2rem;
  color: inherit;
}
.app-progress-label{
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
}
.app-progress-step.is-active{ border-color: var(--primary); color: var(--primary-dark); }
.app-progress-step.is-done{ border-color: var(--primary); color: var(--primary); }

/* --- Application card / steps --- */
.app-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
}
.app-step legend{
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--primary-dark);
  margin-bottom: var(--space-md);
  padding: 0;
  width: 100%;
}
.app-step{ border: none; margin: 0; padding: 0; animation: app-step-in 0.35s var(--ease); }
@keyframes app-step-in{
  from{ opacity: 0; transform: translateY(8px); }
  to{ opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce){
  .app-step{ animation: none; }
}
.app-actions{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
  flex-wrap: wrap;
}

/* --- Radio "cards" (programme / gender) --- */
.radio-group{ display: flex; gap: var(--space-sm); flex-wrap: wrap; }
.radio-card{
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.8rem 1.1rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 500;
  transition: border-color var(--speed) var(--ease), background var(--speed) var(--ease), color var(--speed) var(--ease);
}
.radio-card input{ accent-color: var(--primary); width: 17px; height: 17px; }
.radio-card:has(input:checked),
.radio-card.is-checked{
  border-color: var(--primary);
  background: rgba(31,138,112,0.08);
  color: var(--primary-dark);
}
.radio-card:has(input:focus-visible){ outline: 2px solid var(--primary); outline-offset: 2px; }

/* --- Checkbox confirmation field --- */
.checkbox-field{
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-weight: 500;
  cursor: pointer;
}
.checkbox-field input{
  margin-top: 0.2rem;
  accent-color: var(--primary);
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* --- Validation messages --- */
.field-error{
  color: #B3261E;
  font-size: 0.85rem;
  margin-top: 0.35rem;
  min-height: 1.1em;
}
.form-field input:invalid[data-touched="true"],
.form-field select:invalid[data-touched="true"]{
  border-color: #B3261E;
}

/* --- Review screen --- */
.review-block{ padding-block: var(--space-md); border-bottom: 1px solid var(--border); }
.review-block:last-of-type{ border-bottom: none; }
.review-block-head{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}
.review-block-head h3{ margin: 0; font-size: 1.05rem; }
.review-edit{
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.8rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary-dark);
  transition: border-color var(--speed) var(--ease);
}
.review-edit:hover{ border-color: var(--primary-dark); }
.review-list{ display: grid; gap: 0.4rem; margin: 0; }
.review-row{
  display: flex;
  justify-content: space-between;
  gap: var(--space-md);
  font-size: 0.95rem;
  padding-block: 0.3rem;
  border-bottom: 1px dashed var(--border);
}
.review-row dt{ color: var(--muted); font-weight: 500; margin: 0; }
.review-row dd{ margin: 0; font-weight: 600; color: var(--text); text-align: right; }

/* --- Confirmation screen --- */
.app-confirmation{ text-align: center; }
.confirmation-icon{
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.7rem;
  margin: 0 auto var(--space-md);
}
.app-confirmation .review-list{
  text-align: left;
  max-width: 480px;
  margin-inline: auto;
  margin-block: var(--space-md);
}
.app-confirmation .notice{ max-width: 480px; margin-inline: auto; }

@media (max-width: 700px){
  .app-card{ padding: var(--space-md); }
  .app-progress-label{ font-size: 0.72rem; }
  .app-progress-step{ flex-basis: 45%; }
  .app-actions{ flex-direction: column-reverse; }
  .app-actions .btn{ width: 100%; justify-content: center; }
  .review-row{ flex-direction: column; gap: 0.15rem; }
  .review-row dd{ text-align: left; }
}

/* --- Public "Check Application Status" (admissions.html) --- */
.status-check-card{ max-width: 560px; margin-inline: auto; }
.status-check-result{
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border);
}
.status-check-heading{
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--primary-dark);
  margin: 0 0 var(--space-xs);
}
.status-check-result.is-notice .status-check-heading{ color: var(--text); }
.status-check-details{ margin-top: var(--space-sm); }
.status-check-pill{
  display: inline-block;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
}
.status-check-pill.is-pending{ background: rgba(191, 143, 47, 0.15); color: #8A6412; }
.status-check-pill.is-approved{ background: rgba(31, 138, 112, 0.15); color: var(--primary-dark); }
.status-check-pill.is-rejected{ background: rgba(179, 38, 30, 0.12); color: #B3261E; }

/* ==========================================================================
   18. PRINTABLE APPLICATION FORM
   Hidden on screen; shown only inside the print dialog.
   ========================================================================== */
.print-sheet{ display: none; }

@media print{
  @page{ size: A4; margin: 16mm; }

  body > *:not(.print-sheet){ display: none !important; }

  .print-sheet{
    display: block !important;
    color: #000;
    font-family: var(--font-body);
  }

  .print-header{ text-align: center; margin-bottom: 8mm; }
  .print-logo{ width: 52px; height: 52px; object-fit: contain; margin-bottom: 2mm; }
  .print-header h1{
    font-family: var(--font-display);
    font-size: 1.4rem;
    margin: 0;
    color: #10493C;
  }
  .print-tagline{ font-style: italic; margin: 1mm 0; color: #10493C; }
  .print-address{ font-size: 0.85rem; color: #333; margin: 0; }

  .print-title{
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 1.05rem;
    border-top: 1px solid #000;
    border-bottom: 1px solid #000;
    padding-block: 2mm;
    margin-block: 6mm;
  }

  .print-meta{
    margin-bottom: 6mm;
    padding-bottom: 4mm;
    border-bottom: 1px solid #999;
  }

  .print-section{ margin-bottom: 6mm; page-break-inside: avoid; }
  .print-section h3{
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 1px solid #999;
    padding-bottom: 1.5mm;
    margin-bottom: 3mm;
    color: #10493C;
    font-family: var(--font-body);
    font-weight: 700;
  }
  .print-grid{ display: grid; grid-template-columns: 1fr 1fr; gap: 3mm 6mm; }
  .print-grid div{ display: flex; flex-direction: column; font-size: 0.92rem; }
  .print-grid strong{
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #555;
    margin-bottom: 0.5mm;
    font-weight: 700;
  }

  .print-status-bottom{
    font-weight: 700;
    font-size: 0.95rem;
    margin-top: 8mm;
    padding-top: 4mm;
    border-top: 1px solid #999;
  }

  .print-footnote{ margin-top: 4mm; font-size: 0.72rem; color: #555; text-align: center; }
}
