/* =========================================================
   C.R.R. MATRICULATION HIGHER SECONDARY SCHOOL
   Design System — "Ribbon & Flame"
   Palette drawn directly from the school crest:
   navy ring, gold book, red stars, white field, torch flame.
   ========================================================= */

:root{
  --navy-deep:   #0a1638;
  --navy:        #12275e;
  --navy-soft:   #1c3a82;
  --royal:       #2547a0;
  --gold:        #f2b705;
  --gold-soft:   #ffd84d;
  --gold-pale:   #fff3c9;
  --flame-red:   #e0472a;
  --flame-orange:#f79c1f;
  --cream:       #fbf8ef;
  --paper:       #ffffff;
  --ink:         #16192b;
  --ink-soft:    #4a4f6a;
  --line:        #e4dfd0;

  --display: "Fraunces", "Georgia", serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1200px;
  --radius: 14px;
  --radius-sm: 8px;

  --shadow-sm: 0 2px 10px rgba(10,22,56,0.06);
  --shadow-md: 0 10px 30px rgba(10,22,56,0.10);
  --shadow-lg: 0 24px 60px rgba(10,22,56,0.18);

  --ease: cubic-bezier(.22,.9,.28,1);
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *,*::before,*::after{ animation-duration:0.001ms !important; animation-iteration-count:1 !important; transition-duration:0.001ms !important; scroll-behavior:auto !important; }
}

body{
  margin:0;
  font-family:var(--body);
  color:var(--ink);
  background:var(--cream);
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
}

img{ max-width:100%; display:block; height:auto; }
a{ color:inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
button{ font-family:inherit; cursor:pointer; }
/* Component classes below (e.g. .news-card, .photo-card) set their own
   `display`, which otherwise wins the cascade over the browser's default
   [hidden] rule at equal specificity and silently un-hides "filtered out"
   cards. Force it here so any element toggled via el.hidden = true always
   actually disappears, on every page. */
[hidden]{ display:none !important; }
h1,h2,h3,h4{ font-family:var(--display); margin:0 0 .5em; color:var(--navy-deep); line-height:1.15; font-weight:600; }
p{ margin:0 0 1em; }

.container{ max-width:var(--container); margin:0 auto; padding:0 24px; }

:focus-visible{ outline:3px solid var(--gold); outline-offset:3px; border-radius:4px; }

/* ---------- Skip link ---------- */
.skip-link{
  position:absolute; left:-999px; top:auto;
  background:var(--navy-deep); color:#fff; padding:12px 20px; border-radius:8px; z-index:9999;
}
.skip-link:focus{ left:16px; top:16px; }

/* ---------- Eyebrow / labels ---------- */
.eyebrow{
  display:inline-flex; align-items:center; gap:8px;
  font-family:var(--body); font-weight:700; letter-spacing:.14em; text-transform:uppercase;
  font-size:.75rem; color:var(--flame-red);
  margin-bottom:14px;
}
.eyebrow::before{
  content:""; width:22px; height:2px; background:var(--gold); display:inline-block;
}

/* =========================================================
   RIBBON DIVIDER — signature motif borrowed from the crest's
   diagonal banner ("LEARN WITH PLEASURE" stripe across the seal)
   ========================================================= */
.ribbon-divider{
  position:relative;
  height:64px;
  overflow:hidden;
  background:var(--cream);
}
.ribbon-divider svg{ width:100%; height:100%; display:block; }
.ribbon-divider.flip svg{ transform:scaleY(-1); }

/* =========================================================
   HEADER / NAV
   ========================================================= */
.site-header{
  position:sticky; top:0; z-index:1000;
  background:rgba(251,248,239,0.92);
  backdrop-filter:saturate(160%) blur(10px);
  border-bottom:1px solid var(--line);
  transition:box-shadow .3s var(--ease), background .3s var(--ease);
}
.site-header.is-scrolled{ box-shadow:var(--shadow-sm); }

.topbar{
  background:var(--navy-deep);
  color:var(--gold-pale);
  font-size:.8rem;
}
.topbar .container{
  display:flex; align-items:center; justify-content:space-between;
  padding-top:6px; padding-bottom:6px; gap:16px; flex-wrap:wrap;
}
.topbar a{ color:var(--gold-pale); }
.topbar a:hover{ color:var(--gold-soft); }
.topbar-info{ display:flex; gap:20px; flex-wrap:wrap; }
.topbar-info span{ display:inline-flex; align-items:center; gap:6px; }
/* The contact/address bar takes up valuable space on small screens and
   duplicates info already in the footer and mobile menu — hide it below
   tablet width and let the sticky nav bar sit right at the top instead. */
@media (max-width:640px){
  .topbar{ display:none; }
}

.navbar{
  display:flex; align-items:center; justify-content:space-between;
  padding-top:12px; padding-bottom:12px;
  gap:20px;
  max-width:1520px;
}
.brand{ display:flex; align-items:center; gap:12px; flex:none; }
.brand img{ width:52px; height:52px; border-radius:50%; flex:none; }
.brand-text{ display:flex; flex-direction:column; line-height:1.2; }
.brand-text .name{ font-family:var(--display); font-weight:700; font-size:1.05rem; color:var(--navy-deep); white-space:nowrap; }
.brand-text .tagline{ font-size:.72rem; color:var(--flame-red); letter-spacing:.04em; font-weight:600; }

.nav-links{ display:flex; align-items:center; gap:1px; }
.nav-links > li{ position:relative; }
.nav-links > li > a{
  display:flex; align-items:center; gap:3px;
  padding:10px 13px; font-weight:600; font-size:.88rem; color:var(--navy);
  border-radius:8px; transition:color .2s, background .2s;
  white-space:nowrap;
}
.nav-links > li > a:hover, .nav-links > li > a.active{ color:var(--flame-red); background:var(--gold-pale); }
.nav-links .chev{ transition:transform .2s var(--ease); border-radius:50%; padding:2px; margin:-2px; }
.nav-links li:hover .chev, .nav-links li.is-open .chev{ transform:rotate(180deg); }
.nav-links li.is-open > a .chev{ background:rgba(0,0,0,.06); }

.dropdown{
  position:absolute; top:100%; left:0; min-width:240px;
  background:var(--paper); border-radius:var(--radius-sm); box-shadow:var(--shadow-lg);
  padding:8px; opacity:0; visibility:hidden; transform:translateY(8px);
  transition:opacity .22s var(--ease), transform .22s var(--ease), visibility .22s;
  border:1px solid var(--line);
}
.nav-links li:hover .dropdown, .nav-links li:focus-within .dropdown, .nav-links li.is-open .dropdown{
  opacity:1; visibility:visible; transform:translateY(0);
}
.dropdown a{ display:block; padding:10px 12px; border-radius:6px; font-size:.9rem; color:var(--ink-soft); font-weight:500; }
.dropdown a:hover{ background:var(--cream); color:var(--flame-red); }
.dropdown a.active{ background:var(--gold-pale); color:var(--flame-red); font-weight:700; }

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

.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  padding:11px 22px; border-radius:999px; font-weight:700; font-size:.88rem;
  border:2px solid transparent; transition:transform .2s var(--ease), box-shadow .2s var(--ease), background .2s, color .2s, border-color .2s;
  white-space:nowrap;
}
.btn-primary{ background:var(--flame-red); color:#fff; box-shadow:0 8px 20px rgba(224,71,42,.28); }
.btn-primary:hover{ transform:translateY(-2px); box-shadow:0 12px 26px rgba(224,71,42,.36); }
.btn-gold{ background:var(--gold); color:var(--navy-deep); box-shadow:0 8px 20px rgba(242,183,5,.3); }
.btn-gold:hover{ transform:translateY(-2px); }
.btn-outline{ background:transparent; border-color:var(--navy-deep); color:var(--navy-deep); }
.btn-outline:hover{ background:var(--navy-deep); color:#fff; }
.btn-outline-light{ background:transparent; border-color:rgba(255,255,255,.5); color:#fff; }
.btn-outline-light:hover{ background:#fff; color:var(--navy-deep); border-color:#fff; }
.btn-sm{ padding:9px 18px; font-size:.85rem; }
.btn-block{ width:100%; }

.nav-toggle{
  display:none; flex-direction:column; gap:5px; background:none; border:0; padding:8px;
  position:relative; z-index:1600; /* stays above the open mobile panel (z-index:1500) so it can always be tapped again to close */
}
.nav-toggle span{ width:26px; height:3px; background:var(--navy-deep); border-radius:2px; transition:transform .3s var(--ease), opacity .3s; }
.nav-toggle.is-active span:nth-child(1){ transform:translateY(8px) rotate(45deg); }
.nav-toggle.is-active span:nth-child(2){ opacity:0; }
.nav-toggle.is-active span:nth-child(3){ transform:translateY(-8px) rotate(-45deg); }

/* =========================================================
   HERO
   ========================================================= */
.hero{
  position:relative;
  background:linear-gradient(160deg, var(--navy-deep) 0%, var(--navy) 55%, var(--royal) 100%);
  color:#fff;
  overflow:hidden;
  padding:64px 0 0;
}
.hero-grain{
  position:absolute; inset:0; opacity:.05; pointer-events:none;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-ribbon{
  position:absolute; left:-10%; right:-10%; top:18%;
  height:90px; background:linear-gradient(90deg, var(--gold-soft), var(--gold));
  transform:rotate(-4deg);
  box-shadow:0 20px 50px rgba(0,0,0,.2);
  opacity:.14;
}
.hero-inner{
  position:relative; z-index:2;
  display:grid; grid-template-columns:1.15fr .85fr; gap:48px; align-items:center;
  padding-bottom:56px;
}
.hero-eyebrow{
  display:inline-flex; align-items:center; gap:10px;
  background:rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.18);
  padding:8px 16px; border-radius:999px; font-size:.78rem; font-weight:700;
  letter-spacing:.1em; text-transform:uppercase; color:var(--gold-soft);
  margin-bottom:22px;
}
.hero h1{
  color:#fff; font-size:clamp(2.2rem, 4.4vw, 3.6rem); margin-bottom:.4em;
}
.hero h1 em{ font-style:normal; color:var(--gold-soft); }
.hero-sub{
  font-size:1.15rem; color:rgba(255,255,255,.82); max-width:56ch; margin-bottom:1.6em;
}
.hero-motto{
  font-family:var(--display); font-style:italic; font-size:1.3rem; color:var(--gold-soft);
  margin-bottom:1.4em; display:block;
}
.hero-actions{ display:flex; gap:14px; flex-wrap:wrap; margin-bottom:36px; }

.hero-stats{
  display:grid; grid-template-columns:repeat(4,1fr); gap:0;
  border-top:1px solid rgba(255,255,255,.16);
  padding-top:28px;
}
.hero-stats .stat{ padding:0 16px; border-right:1px solid rgba(255,255,255,.14); }
.hero-stats .stat:last-child{ border-right:none; }
.stat-num{ font-family:var(--display); font-size:clamp(1.6rem,2.6vw,2.3rem); font-weight:700; color:var(--gold-soft); display:flex; align-items:baseline; gap:2px; }
.stat-label{ font-size:.78rem; color:rgba(255,255,255,.7); margin-top:2px; }

/* Hero visual: crest + flame */
.hero-visual{ position:relative; display:flex; align-items:center; justify-content:center; }
.hero-badge-ring{
  position:relative; width:min(360px, 80%); aspect-ratio:1/1;
  display:flex; align-items:center; justify-content:center;
}
.hero-badge-ring img{
  width:100%; height:100%; border-radius:50%;
  box-shadow:0 30px 70px rgba(0,0,0,.35), 0 0 0 10px rgba(255,255,255,.05);
  animation: float-badge 6s ease-in-out infinite;
}
@keyframes float-badge{ 0%,100%{ transform:translateY(0) rotate(0deg);} 50%{ transform:translateY(-14px) rotate(2deg);} }

.flame-accent{ position:absolute; width:64px; height:84px; right:-6px; bottom:-10px; filter:drop-shadow(0 8px 14px rgba(224,71,42,.5)); }
.flame-accent .tip{ transform-origin:50% 100%; animation:flicker 2.4s ease-in-out infinite; }
.flame-accent .tip2{ transform-origin:50% 100%; animation:flicker 2.1s ease-in-out infinite reverse; }
@keyframes flicker{
  0%,100%{ transform:scale(1,1) skewX(0deg); }
  25%{ transform:scale(1.03,.97) skewX(-2deg); }
  50%{ transform:scale(.97,1.04) skewX(2deg); }
  75%{ transform:scale(1.02,.98) skewX(-1deg); }
}

/* =========================================================
   SECTIONS (generic)
   ========================================================= */
section{ padding:88px 0; }
.section-head{ max-width:720px; margin-bottom:52px; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }
.section-head h2{ font-size:clamp(1.8rem,3vw,2.6rem); }
.section-head p{ color:var(--ink-soft); font-size:1.06rem; }

.bg-navy{ background:var(--navy-deep); color:#fff; }
.bg-navy h2, .bg-navy h3, .bg-navy h4{ color:#fff; }
.bg-navy .section-head p{ color:rgba(255,255,255,.72); }
.bg-cream{ background:var(--cream); }
.bg-paper{ background:var(--paper); }

/* ---------- Reveal-on-scroll ---------- */
.reveal{ opacity:0; transform:translateY(28px); transition:opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible{ opacity:1; transform:translateY(0); }
.reveal-scale{ opacity:0; transform:scale(.94); transition:opacity .7s var(--ease), transform .7s var(--ease); }
.reveal-scale.is-visible{ opacity:1; transform:scale(1); }
.stagger > *{ transition-delay:calc(var(--i, 0) * 90ms); }

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

.card{
  background:var(--paper); border-radius:var(--radius); padding:32px 26px;
  box-shadow:var(--shadow-sm); border:1px solid var(--line);
  transition:transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s;
  position:relative; overflow:hidden;
}
.card:hover{ transform:translateY(-6px); box-shadow:var(--shadow-md); border-color:var(--gold); }
.card-icon{
  width:56px; height:56px; border-radius:14px; display:flex; align-items:center; justify-content:center;
  background:var(--gold-pale); color:var(--flame-red); margin-bottom:18px; flex:none;
  transition:transform .35s var(--ease), background .35s;
}
.card:hover .card-icon{ transform:scale(1.08) rotate(-4deg); background:var(--gold); }
.card h3{ font-size:1.18rem; margin-bottom:.4em; }
.card p{ color:var(--ink-soft); font-size:.96rem; margin-bottom:0; }

.icon-strip{ display:flex; align-items:center; justify-content:center; width:24px;height:24px; }

/* Photo card */
.photo-card{ border-radius:var(--radius); overflow:hidden; position:relative; box-shadow:var(--shadow-sm); background:#ddd; }
.photo-card .ph-wrap{ aspect-ratio:4/3; overflow:hidden; }
.photo-card img{ width:100%; height:100%; object-fit:cover; transition:transform .6s var(--ease); }
.photo-card:hover img{ transform:scale(1.08); }
.photo-card .cap{ padding:16px 18px; }
.photo-card .cap h3{ font-size:1.02rem; margin-bottom:.2em; }
.photo-card .cap p{ font-size:.85rem; color:var(--ink-soft); margin:0; }

/* Lazy-load fade */
img.lazy{ opacity:0; background:linear-gradient(120deg,#eee 25%,#f6f6f6 37%,#eee 63%); background-size:400% 100%; animation:shimmer 1.6s ease-in-out infinite; }
img.lazy.loaded{ opacity:1; animation:none; background:none; transition:opacity .5s var(--ease); }
@keyframes shimmer{ 0%{ background-position:100% 0;} 100%{ background-position:0 0;} }

/* =========================================================
   TIMELINE (History)
   ========================================================= */
.timeline{ position:relative; padding-left:32px; }
.timeline::before{ content:""; position:absolute; left:6px; top:6px; bottom:6px; width:2px; background:var(--line); }
.timeline-item{ position:relative; padding-bottom:36px; }
.timeline-item:last-child{ padding-bottom:0; }
.timeline-item::before{
  content:""; position:absolute; left:-32px; top:4px; width:14px; height:14px; border-radius:50%;
  background:var(--gold); border:3px solid var(--navy-deep);
}
.timeline-item h4{ margin-bottom:.2em; font-size:1.05rem; }
.timeline-item p{ color:var(--ink-soft); margin-bottom:0; }

/* =========================================================
   PEOPLE / LEADERSHIP
   ========================================================= */
.people-grid{ display:grid; grid-template-columns:repeat(auto-fit,minmax(230px,1fr)); gap:26px; }
.person-card{ text-align:center; background:var(--paper); border-radius:var(--radius); padding:30px 22px; box-shadow:var(--shadow-sm); border:1px solid var(--line); transition:transform .3s var(--ease), box-shadow .3s var(--ease); }
.person-card:hover{ transform:translateY(-6px); box-shadow:var(--shadow-md); }
.person-avatar{
  width:88px; height:88px; border-radius:50%; margin:0 auto 16px; overflow:hidden;
  border:3px solid var(--gold); display:flex; align-items:center; justify-content:center; background:var(--gold-pale);
}
.person-avatar img{ width:100%; height:100%; object-fit:cover; }
.person-card h3{ font-size:1.05rem; margin-bottom:.15em; }
.person-role{ color:var(--flame-red); font-weight:700; font-size:.8rem; text-transform:uppercase; letter-spacing:.06em; margin-bottom:10px; display:block; }
.person-card p{ font-size:.88rem; color:var(--ink-soft); margin:0; }

/* =========================================================
   TOPPERS / STAT BLOCKS
   ========================================================= */
.topper-card{
  background:var(--paper); border-radius:var(--radius); padding:26px; text-align:center; position:relative;
  border:1px solid var(--line); box-shadow:var(--shadow-sm); transition:transform .3s var(--ease), box-shadow .3s var(--ease);
}
.topper-card:hover{ transform:translateY(-6px) scale(1.02); box-shadow:var(--shadow-md); }
.topper-card .rank{
  position:absolute; top:-14px; left:50%; transform:translateX(-50%);
  background:var(--flame-red); color:#fff; font-weight:800; font-size:.75rem;
  padding:5px 14px; border-radius:999px; box-shadow:0 6px 14px rgba(224,71,42,.35);
}
.topper-card .score{ font-family:var(--display); font-size:1.9rem; font-weight:700; color:var(--navy-deep); margin:14px 0 4px; }
.topper-card h4{ margin-bottom:4px; font-size:1.05rem; }
.topper-card .badge-note{ color:var(--flame-red); font-size:.82rem; font-weight:600; }

.result-banner{
  background:linear-gradient(120deg,var(--flame-red),var(--flame-orange));
  color:#fff; border-radius:var(--radius); padding:36px; text-align:center; position:relative; overflow:hidden;
}
.result-banner .big{ font-family:var(--display); font-size:clamp(2.4rem,5vw,3.6rem); font-weight:800; }

/* =========================================================
   ACCORDION (rules etc.)
   ========================================================= */
.accordion-item{ border-bottom:1px solid var(--line); }
.accordion-item:first-child{ border-top:1px solid var(--line); }
.accordion-trigger{
  width:100%; text-align:left; background:none; border:0; padding:22px 4px;
  display:flex; align-items:center; justify-content:space-between; gap:16px;
  font-family:var(--display); font-size:1.12rem; font-weight:600; color:var(--navy-deep);
}
.accordion-trigger .plus{ flex:none; width:28px; height:28px; border-radius:50%; background:var(--gold-pale); color:var(--flame-red); display:flex; align-items:center; justify-content:center; transition:transform .3s var(--ease), background .3s; font-size:1.1rem; font-weight:700; }
.accordion-item.is-open .accordion-trigger .plus{ transform:rotate(135deg); background:var(--gold); }
.accordion-panel{ max-height:0; overflow:hidden; transition:max-height .4s var(--ease); }
.accordion-panel-inner{ padding:0 4px 24px; color:var(--ink-soft); }
.accordion-panel-inner ul{ margin-top:8px; }
.accordion-panel-inner li{ position:relative; padding-left:22px; margin-bottom:8px; }
.accordion-panel-inner li::before{ content:"—"; position:absolute; left:0; color:var(--flame-red); font-weight:700; }

/* =========================================================
   TABS (used on About / Campus pages)
   ========================================================= */
.tabs-nav{ display:flex; gap:8px; flex-wrap:wrap; margin-bottom:40px; border-bottom:2px solid var(--line); }
.tabs-nav button{
  background:none; border:0; padding:14px 20px; font-weight:700; font-size:.95rem; color:var(--ink-soft);
  position:relative; top:2px; border-bottom:3px solid transparent; transition:color .25s, border-color .25s;
}
.tabs-nav button.is-active{ color:var(--flame-red); border-color:var(--flame-red); }
.tab-panel{ display:none; }
.tab-panel.is-active{ display:block; animation:fadeIn .5s var(--ease); }
@keyframes fadeIn{ from{ opacity:0; transform:translateY(10px);} to{ opacity:1; transform:translateY(0);} }

/* =========================================================
   GALLERY
   ========================================================= */
.filter-bar{ display:flex; flex-wrap:wrap; gap:10px; margin-bottom:40px; }
.filter-chip{
  padding:9px 18px; border-radius:999px; border:2px solid var(--line); background:var(--paper);
  font-weight:600; font-size:.85rem; color:var(--ink-soft); transition:all .25s var(--ease);
}
.filter-chip:hover{ border-color:var(--gold); }
.filter-chip.is-active{ background:var(--navy-deep); color:#fff; border-color:var(--navy-deep); }
.masonry{ column-count:3; column-gap:22px; }
.masonry .photo-card{ break-inside:avoid; margin-bottom:22px; }

/* Lightbox */
.lightbox{
  position:fixed; inset:0; background:rgba(8,12,28,.92); z-index:2000;
  display:flex; align-items:center; justify-content:center; opacity:0; visibility:hidden;
  transition:opacity .3s var(--ease), visibility .3s;
  padding:40px 20px;
}
.lightbox.is-open{ opacity:1; visibility:visible; }
.lightbox img{ max-width:min(900px,90vw); max-height:80vh; border-radius:12px; box-shadow:0 30px 80px rgba(0,0,0,.5); object-fit:contain; }
.lightbox-caption{ color:#fff; text-align:center; margin-top:14px; font-size:.95rem; opacity:.85; }
.lightbox-close{
  position:absolute; top:26px; right:30px; background:rgba(255,255,255,.12); color:#fff;
  border:0; width:44px; height:44px; border-radius:50%; font-size:1.4rem; display:flex; align-items:center; justify-content:center;
}
.lightbox-close:hover{ background:var(--flame-red); }

/* =========================================================
   NEWS
   ========================================================= */
.news-card{ background:var(--paper); border-radius:var(--radius); overflow:hidden; border:1px solid var(--line); box-shadow:var(--shadow-sm); transition:transform .3s var(--ease), box-shadow .3s var(--ease); display:flex; flex-direction:column; }
.news-card:hover{ transform:translateY(-6px); box-shadow:var(--shadow-md); }
.news-card .ph-wrap{ aspect-ratio:16/10; overflow:hidden; }
.news-card img{ width:100%; height:100%; object-fit:cover; transition:transform .6s var(--ease); }
.news-card:hover img{ transform:scale(1.06); }
.news-body{ padding:22px; display:flex; flex-direction:column; gap:10px; flex:1; }
.news-tag{ align-self:flex-start; background:var(--gold-pale); color:var(--flame-red); font-weight:700; font-size:.72rem; text-transform:uppercase; letter-spacing:.05em; padding:5px 12px; border-radius:999px; }
.news-date{ font-size:.8rem; color:var(--ink-soft); font-weight:600; }
.news-body h3{ font-size:1.08rem; margin-bottom:0; }
.news-body p{ font-size:.9rem; color:var(--ink-soft); flex:1; }
.news-link{ font-weight:700; font-size:.85rem; color:var(--flame-red); display:inline-flex; align-items:center; gap:6px; }
.news-link svg{ transition:transform .25s var(--ease); }
.news-link:hover svg{ transform:translateX(4px); }

/* =========================================================
   CONTACT
   ========================================================= */
.contact-grid{ display:grid; grid-template-columns:.9fr 1.1fr; gap:44px; align-items:start; }
.contact-info-card{ background:var(--navy-deep); color:#fff; border-radius:var(--radius); padding:38px; }
.contact-info-card h3{ color:#fff; }
.info-row{ display:flex; gap:16px; padding:30px 0; border-bottom:1px solid rgba(255,255,255,.12); }
.info-row:last-child{ border-bottom:0; }
.info-row .ic{ width:42px; height:42px; border-radius:10px; background:rgba(242,183,5,.16); color:var(--gold-soft); display:flex; align-items:center; justify-content:center; flex:none; }
.info-row h4{ color:#fff; font-size:.95rem; margin-bottom:.25em; }
.info-row p, .info-row a{ color:rgba(255,255,255,.75); font-size:.9rem; margin:0; }
.info-row a:hover{ color:var(--gold-soft); }

.form-card{ background:var(--paper); border-radius:var(--radius); padding:10px 25px; box-shadow:var(--shadow-sm); border:1px solid var(--line); }
.form-row{ display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.field{ margin-bottom:18px; }
.field label{ display:block; font-weight:700; font-size:.85rem; margin-bottom:6px; color:var(--navy-deep); }
.field input, .field select, .field textarea{
  width:100%; padding:13px 14px; border-radius:10px; border:1.5px solid var(--line); font-family:inherit; font-size:.95rem;
  background:var(--cream); transition:border-color .25s, box-shadow .25s;
}
.field input:focus, .field select:focus, .field textarea:focus{ border-color:var(--gold); box-shadow:0 0 0 4px rgba(242,183,5,.18); outline:none; }
.field textarea{ resize:vertical; min-height:120px; }
.form-note{ font-size:.82rem; color:var(--ink-soft); margin-top:10px; }

/* Success / error banners shown after a form submission attempt */
.form-alert{
  display:none; align-items:center; gap:10px; margin-top:16px;
  padding:14px 18px; border-radius:10px; font-weight:600; font-size:.9rem;
}
.form-alert svg{ flex:none; }
.form-alert.is-visible{ display:flex; }
.form-alert.is-success{ background:var(--gold-pale); color:var(--navy-deep); }
.form-alert.is-error{ background:rgba(224,71,42,.1); color:var(--flame-red); }

/* Honeypot spam-trap field: kept in the tab order's blind spot (off-screen,
   not display:none, so basic bots that skip hidden inputs still fill it in),
   invisible and unreachable for real visitors. */
.hp-field{ position:absolute; left:-9999px; top:-9999px; width:1px; height:1px; overflow:hidden; opacity:0;}

.map-wrap{ border-radius:var(--radius); overflow:hidden; box-shadow:var(--shadow-sm); border:1px solid var(--line); margin-top:28px; }
.map-wrap iframe{ width:100%; height:340px; border:0; display:block; }

/* =========================================================
   CTA BAND
   ========================================================= */
.cta-band{
  background:linear-gradient(120deg,var(--navy-deep),var(--royal));
  color:#fff; border-radius:24px; padding:56px; text-align:center; position:relative; overflow:hidden;
}
.cta-band::before{
  content:""; position:absolute; width:500px; height:500px; background:radial-gradient(circle, rgba(242,183,5,.25), transparent 70%);
  top:-200px; right:-150px;
}
.cta-band h2{ color:#fff; }
.cta-band p{ color:rgba(255,255,255,.78); max-width:52ch; margin:0 auto 28px; }
.cta-actions{ display:flex; gap:16px; justify-content:center; flex-wrap:wrap; }

/* =========================================================
   MARQUEE (achievements ticker)
   ========================================================= */
.marquee-wrap{ background:var(--navy-deep); color:var(--gold-soft); overflow:hidden; padding:14px 0; border-top:1px solid rgba(255,255,255,.08); border-bottom:1px solid rgba(255,255,255,.08); }
.marquee-track{ display:flex; gap:56px; white-space:nowrap; width:max-content; animation:marquee 32s linear infinite; }

/* =========================================================
   TESTIMONIALS — deliberately distinct from the rest of the
   site: dark flame/navy gradient, floating blurred orbs, a
   horizontally snap-scrolling row of quote-bubble cards.
   ========================================================= */
.testimonials-section{
  position:relative; overflow:hidden;
  background:
    radial-gradient(circle at 12% 18%, rgba(242,183,5,.20), transparent 42%),
    radial-gradient(circle at 88% 82%, rgba(224,71,42,.22), transparent 45%),
    linear-gradient(150deg, var(--navy-deep) 0%, var(--navy) 55%, #0d1f4a 100%);
  color:#fff;
}
.testimonials-section::before{
  content:""; position:absolute; inset:0; pointer-events:none; opacity:.08;
  background-image:radial-gradient(rgba(255,255,255,.9) 1px, transparent 1px);
  background-size:26px 26px;
}
.testimonials-head{ position:relative; z-index:1; text-align:center; max-width:640px; margin:0 auto 48px; }
.testimonials-head .eyebrow{ justify-content:center; color:var(--gold-soft); }
.testimonials-head h2{ color:#fff; }
.testimonials-head p{ color:rgba(255,255,255,.72); }

.testimonial-row{
  position:relative; z-index:1;
  display:flex; gap:26px; overflow-x:auto; padding:8px 4px 28px;
  scroll-snap-type:x mandatory; scrollbar-width:thin; scrollbar-color:var(--gold) transparent;
}
.testimonial-row::-webkit-scrollbar{ height:8px; }
.testimonial-row::-webkit-scrollbar-thumb{ background:rgba(242,183,5,.55); border-radius:8px; }
.testimonial-card{
  scroll-snap-align:start; flex:0 0 auto; width:min(400px,84vw);
  background:rgba(255,255,255,.06); backdrop-filter:blur(6px);
  border:1px solid rgba(255,255,255,.14); border-radius:22px;
  padding:34px 30px 28px; position:relative;
  transition:transform .35s var(--ease), background .35s;
}
.testimonial-card:hover{ transform:translateY(-6px); background:rgba(255,255,255,.1); }
.testimonial-quote-mark{
  font-family:var(--display); font-size:3.4rem; line-height:1; color:var(--gold);
  opacity:.85; margin-bottom:4px; display:block;
}
.testimonial-stars{ display:flex; gap:3px; color:var(--gold); margin-bottom:14px; }
.testimonial-card p.quote{
  font-family:var(--display); font-style:italic; font-size:1.05rem; line-height:1.6;
  color:rgba(255,255,255,.92); margin-bottom:22px;
}
.testimonial-person{ display:flex; align-items:center; gap:14px; }
.testimonial-avatar{
  width:52px; height:52px; border-radius:50%; flex:none; object-fit:cover;
  border:2px solid var(--gold); padding:2px;
}
.testimonial-person .who{ font-weight:700; font-size:.95rem; color:#fff; }
.testimonial-person .role{ font-size:.8rem; color:var(--gold-soft); }
.testimonial-dots{ position:relative; z-index:1; display:flex; gap:8px; justify-content:center; margin-top:4px; }
.testimonial-dots span{
  width:8px; height:8px; border-radius:50%; background:rgba(255,255,255,.25);
  cursor:pointer; transition:background .25s, width .25s;
}
.testimonial-dots span:hover{ background:rgba(255,255,255,.5); }
.testimonial-dots span.is-active{ background:var(--gold); width:22px; border-radius:5px; }
.testimonial-dots span:focus-visible{ outline:2px solid var(--gold); outline-offset:3px; }
@media (max-width:640px){
  .testimonial-card{ padding:26px 22px 22px; }
}
.marquee-wrap:hover .marquee-track{ animation-play-state:paused; }
.marquee-track span{ font-weight:600; font-size:.92rem; display:inline-flex; align-items:center; gap:12px; }
.marquee-track span::before{ content:"★"; color:var(--flame-red); }
@keyframes marquee{ from{ transform:translateX(0);} to{ transform:translateX(-50%);} }

/* =========================================================
   BREADCRUMB / PAGE HERO (inner pages)
   ========================================================= */
.page-hero{
  background:linear-gradient(160deg, var(--navy-deep), var(--navy) 60%, var(--royal));
  color:#fff; padding:70px 0 50px; position:relative; overflow:hidden;
}
.page-hero .container{ position:relative; z-index:2; }
.breadcrumb{ display:flex; align-items:center; gap:8px; font-size:.85rem; color:rgba(255,255,255,.65); margin-bottom:16px; }
.breadcrumb a:hover{ color:var(--gold-soft); }
.page-hero h1{ color:#fff; font-size:clamp(2rem,4vw,2.8rem); margin-bottom:.3em; }
.page-hero p{ color:rgba(255,255,255,.75); max-width:60ch; margin:0; }
.page-hero-ribbon{
  position:absolute; left:-5%; right:-5%; bottom:-30px; height:70px;
  background:var(--gold); transform:rotate(-2.5deg); opacity:.1;
}
/* Friendly cartoon mascot illustration on each inner page's hero band —
   kid-appropriate visual accent, themed to match the page's topic. */
.page-hero-mascot{
  position:absolute; z-index:1; right:4%; bottom:-6px; width:250px; height:auto;
  filter:drop-shadow(0 10px 18px rgba(0,0,0,.25));
}
@media (max-width:900px){ .page-hero-mascot{ display:none; } }

/* Small decorative doodle cluster tucked into a corner of the home hero */
.hero-doodle{ position:absolute; z-index:1; pointer-events:none; }
@media (max-width:900px){ .hero-doodle{ display:none; } }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer{ background:#020d2c; color:rgba(255,255,255,.75); padding-top:70px; }
.footer-grid{ display:grid; grid-template-columns:1.3fr 1fr 1fr 1.1fr; gap:40px; padding-bottom:50px; }
.footer-brand{ display:flex; gap:14px; margin-bottom:18px; }
.footer-brand img{ width:56px; height:56px; border-radius:50%; flex:none; }
.footer-brand .name{ font-family:var(--display); color:#fff; font-size:1.1rem; font-weight:700; }
.footer-brand .tagline{ color:var(--gold-soft); font-size:.8rem; margin-top:2px; }
.site-footer h4{ color:#fff; font-size:.95rem; text-transform:uppercase; letter-spacing:.06em; margin-bottom:18px; }
.footer-links li{ margin-bottom:10px; }
.footer-links a{ font-size:.9rem; transition:color .2s, padding-left .2s; }
.footer-links a:hover{ color:var(--gold-soft); padding-left:4px; }
.footer-contact li{ display:flex; gap:12px; margin-bottom:16px; font-size:.9rem; align-items:flex-start; }
.footer-contact .ic{ color:var(--gold-soft); flex:none; margin-top:2px; }
.footer-social{ display:flex; gap:10px; margin-top:8px; }
.footer-social a{ width:38px; height:38px; border-radius:50%; background:rgba(255,255,255,.08); display:flex; align-items:center; justify-content:center; transition:background .25s, transform .25s; }
.footer-social a:hover{ background:var(--gold); color:var(--navy-deep); transform:translateY(-3px); }
.footer-bottom{ border-top:1px solid rgba(255,255,255,.1); padding:22px 0; display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:12px; font-size:.82rem; }
.footer-bottom a:hover{ color:var(--gold-soft); }

/* Back to top */
.back-to-top{
  position:fixed; right:24px; bottom:24px; width:48px; height:48px; border-radius:50%;
  background:var(--flame-red); color:#fff; display:flex; align-items:center; justify-content:center;
  box-shadow:var(--shadow-md); opacity:0; visibility:hidden; transform:translateY(12px);
  transition:opacity .3s var(--ease), transform .3s var(--ease), visibility .3s; z-index:900; border:0;
}
.back-to-top.is-visible{ opacity:1; visibility:visible; transform:translateY(0); }
.back-to-top:hover{ background:var(--navy-deep); }

/* WhatsApp float — ring pulse + a periodic gentle bounce to draw the eye,
   plus a responsive hover/tap lift. The bounce pauses on hover so it
   doesn't fight with the hover feedback. Wrapped in .whatsapp-widget so a
   "Chat with us on WhatsApp" tooltip bubble can appear alongside it on hover.
   Sits on the right edge, stacked directly above the back-to-top button,
   and its right edge lines up with the back-to-top button's right edge. */
.whatsapp-widget{
  position:fixed; right:20px; bottom:88px; z-index:900;
  display:flex; align-items:center; flex-direction:row-reverse;
}
.whatsapp-float{
  position:relative; width:56px; height:56px; border-radius:50%; flex:none;
  background:#25D366; color:#fff; display:flex; align-items:center; justify-content:center;
  box-shadow:var(--shadow-md);
  animation:pulse-wa 2.6s ease-in-out infinite, wa-bounce 3.4s ease-in-out infinite;
  transition:transform .25s var(--ease), box-shadow .25s var(--ease);
  will-change:transform;
}
.whatsapp-float svg{ transition:transform .25s var(--ease); }
.whatsapp-widget:hover .whatsapp-float{
  animation:pulse-wa 2.6s ease-in-out infinite;
  transform:scale(1.12);
  box-shadow:0 12px 28px rgba(37,211,102,.45);
}
.whatsapp-widget:hover .whatsapp-float svg{ transform:rotate(-8deg) scale(1.08); }
.whatsapp-float:active{ transform:scale(.96); }

/* Small red notification dot, top-right of the icon */
.whatsapp-badge{
  position:absolute; top:-1px; right:-1px; width:14px; height:14px; border-radius:50%;
  background:#ff3b30; border:2px solid #fff; box-shadow:0 1px 3px rgba(0,0,0,.25);
}

/* "Chat with us on WhatsApp" tooltip bubble — the widget now sits on the
   right edge of the screen, so the tooltip opens to the LEFT of the icon. */
.whatsapp-tooltip{
  position:relative; margin-right:14px;
  background:#fff; color:var(--navy-deep); font-weight:700; font-size:.85rem;
  padding:11px 18px; border-radius:999px; box-shadow:var(--shadow-md); white-space:nowrap;
  opacity:0; visibility:hidden; transform:translateX(10px);
  transition:opacity .25s var(--ease), transform .25s var(--ease), visibility .25s;
  pointer-events:none;
}
.whatsapp-tooltip::before{
  content:""; position:absolute; right:-6px; top:50%; transform:translateY(-50%);
  border-width:6px 0 6px 7px; border-style:solid; border-color:transparent transparent transparent #fff;
}
.whatsapp-widget:hover .whatsapp-tooltip{ opacity:1; visibility:visible; transform:translateX(0); }
@media (max-width:640px){
  /* Tooltip relies on hover, which touch devices don't have reliably — hide it there
     so it can't get stuck open, the button itself remains fully tappable. */
  .whatsapp-tooltip{ display:none; }
}

@keyframes pulse-wa{ 0%,100%{ box-shadow:0 0 0 0 rgba(37,211,102,.45), var(--shadow-md);} 50%{ box-shadow:0 0 0 10px rgba(37,211,102,0), var(--shadow-md);} }
@keyframes wa-bounce{
  0%, 76%, 100%{ transform:translateY(0) scale(1); }
  82%{ transform:translateY(-9px) scale(1.04); }
  88%{ transform:translateY(0) scale(1); }
  92%{ transform:translateY(-4px) scale(1.02); }
  96%{ transform:translateY(0) scale(1); }
}

/* =========================================================
   UTIL
   ========================================================= */
.mt-0{ margin-top:0 !important;}
.text-center{ text-align:center; }
.flex{ display:flex; }
.flex-wrap{ flex-wrap:wrap; }
.gap-12{ gap:12px; }
.mx-auto{ margin-left:auto; margin-right:auto; }
.max-60{ max-width:60ch; }
.pill-list{ display:flex; flex-wrap:wrap; gap:10px; }
.pill{ background:var(--paper); border:1.5px solid var(--line); padding:8px 16px; border-radius:999px; font-size:.85rem; font-weight:600; color:var(--navy); display:inline-flex; align-items:center; gap:8px; }
.pill .dot{ width:6px; height:6px; border-radius:50%; background:var(--flame-red); }

.two-col{ display:grid; grid-template-columns:1fr 1fr; gap:56px; align-items:center; }
.two-col img{ border-radius:var(--radius); box-shadow:var(--shadow-md); }

.quote-block{
  border-left:4px solid var(--gold); padding:6px 0 6px 26px; font-family:var(--display);
  font-style:italic; font-size:1.3rem; color:var(--navy-deep); margin:28px 0;
}

.check-list li{ position:relative; padding-left:30px; margin-bottom:12px; }
.check-list li::before{
  content:"✓"; position:absolute; left:0; top:0; width:20px; height:20px; border-radius:50%;
  background:var(--gold); color:var(--navy-deep); font-size:.7rem; font-weight:800;
  display:flex; align-items:center; justify-content:center;
}

.table-wrap{ overflow-x:auto; }
table{ width:100%; border-collapse:collapse; background:var(--paper); border-radius:var(--radius); overflow:hidden; }
table th, table td{ padding:14px 18px; text-align:left; border-bottom:1px solid var(--line); font-size:.92rem; }
table th{ background:var(--navy-deep); color:#fff; font-weight:700; }
table tr:last-child td{ border-bottom:0; }
table tr:hover td{ background:var(--cream); }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1024px){
  .hero-inner{ grid-template-columns:1fr; }
  .hero-visual{ order:-1; }
  .footer-grid{ grid-template-columns:1fr 1fr; }
  .grid-4{ grid-template-columns:repeat(2,1fr); }
  .grid-3{ grid-template-columns:repeat(2,1fr); }
  .contact-grid{ grid-template-columns:1fr; }
  .two-col{ grid-template-columns:1fr; gap:32px; }
  .masonry{ column-count:2; }
}
/* Nav collapses to hamburger once the top-level items + CTA no longer
   fit the nav container. Keep this value in sync with the JS breakpoint
   in js/main.js (initMobileNav / initMobileDropdowns). */
@media (max-width: 1240px){
  .topbar .container{ justify-content:center; text-align:center; }
  .nav-links, .nav-cta{ display:none; }
  .nav-toggle{ display:flex; }
  .nav-links.is-open{
    display:flex; flex-direction:column; align-items:stretch; position:fixed;
    top:0; right:0; bottom:0; left:auto; height:100vh; width:82%; max-width:340px;
    background:var(--paper); padding:100px 24px 24px; z-index:1500; box-shadow:var(--shadow-lg); overflow-y:auto;
    animation:slideIn .3s var(--ease);
  }
  @keyframes slideIn{ from{ transform:translateX(100%);} to{ transform:translateX(0);} }
  .nav-links.is-open > li{ width:100%; }
  .nav-links.is-open > li > a{ width:100%; justify-content:space-between; }
  .nav-links .dropdown{ position:static; opacity:1; visibility:visible; transform:none; box-shadow:none; border:none; display:none; padding-left:12px; }
  .nav-links li.is-open .dropdown{ display:block; }
  .nav-overlay{ position:fixed; inset:0; background:rgba(10,22,56,.5); z-index:1400; opacity:0; visibility:hidden; transition:opacity .3s; }
  .nav-overlay.is-open{ opacity:1; visibility:visible; }
  /* The desktop CTA button (.nav-cta, hidden above) has no room in the
     collapsed bar, so the same "Enquire Now" action re-appears as a full
     -width button at the bottom of the slide-in mobile panel instead. */
  .nav-mobile-cta{ display:block; margin-top:24px; padding-top:20px; border-top:1px solid var(--line); }
}
@media (max-width: 640px){
  .hero-stats{ grid-template-columns:repeat(2,1fr); row-gap:20px; }
  .hero-stats .stat:nth-child(2){ border-right:none; }
  .grid-4, .grid-3, .grid-2{ grid-template-columns:1fr; }
  .form-row{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns:1fr; gap:36px; }
  .masonry{ column-count:1; }
  section{ padding:64px 0; }
}
