/* ═══════════════════════════════════════════
   USHODAYA MERIT SCHOOL — Main Stylesheet
   Bootstrap 5 + Custom Variables
═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700;800&family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
  --primary:    #8B1A1A;
  --primary-dk: #5C0F0F;
  --accent:     #E8871A;
  --accent-lt:  #FFF0DC;
  --blue:       #1565C0;
  --green:      #2E7D32;
  --cream:      #FFFBF5;
  --offwhite:   #F8F4EE;
  --border:     #E8D9C0;
  --text:       #1C1410;
  --muted:      #6B5744;
  --white:      #FFFFFF;
  --shadow-sm:  0 2px 12px rgba(139,26,26,.07);
  --shadow-md:  0 6px 30px rgba(139,26,26,.11);
  --shadow-lg:  0 16px 50px rgba(139,26,26,.15);
  --radius:     12px;
  --radius-lg:  20px;
}

/* ── Reset & Base ── */
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Poppins', sans-serif; background: #fff; color: var(--text); overflow-x: hidden; }
h1, h2, h3, h4, h5, h6 { font-family: 'Playfair Display', serif; }
a { text-decoration: none; transition: .2s; }
img { max-width: 100%; }
section { scroll-margin-top: 76px; }

/* ── Utility ── */
.bg-cream    { background: var(--cream) !important; }
.bg-offwhite { background: var(--offwhite) !important; }
.bg-primary-custom { background: var(--primary) !important; }
.text-primary-custom { color: var(--primary) !important; }
.text-accent  { color: var(--accent) !important; }
.text-muted-custom { color: var(--muted) !important; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.section-py { padding: 80px 0; }
.border-custom { border-color: var(--border) !important; }

/* ── Section Header ── */
.section-badge {
  display: inline-block;
  background: rgba(232,135,26,.13);
  color: var(--primary);
  border: 1px solid rgba(232,135,26,.35);
  border-radius: 100px;
  padding: 4px 18px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.section-title {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 800;
  color: var(--primary);
  line-height: 1.2;
}
.section-sub {
  color: var(--muted);
  font-size: .97rem;
  line-height: 1.8;
}
.title-line {
  width: 60px; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 2px;
  margin: 14px auto 0;
}
.title-line.left { margin: 14px 0 0; }

/* ══════════════════════════════
   TOP INFO BAR
══════════════════════════════ */
.top-bar {
  background: var(--primary);
  padding: 7px 0;
  font-size: .74rem;
}
.top-bar a, .top-bar span { color: rgba(255,248,240,.82); }
.top-bar a:hover { color: var(--accent); }
.top-bar .divider { color: rgba(255,248,240,.3); margin: 0 8px; }

/* ══════════════════════════════
   NAVBAR
══════════════════════════════ */
.main-navbar {
  background: rgba(255,255,255,.98) !important;
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
  transition: all .35s;
}
.main-navbar.scrolled {
  box-shadow: var(--shadow-md);
  border-bottom: 2px solid var(--accent);
  padding: 4px 0;
}
/* Logo in navbar */
.nav-logo-ring {
  width: 62px; height: 62px;
  border-radius: 50%;
  border: 3px solid var(--accent);
  box-shadow: 0 0 0 2px var(--primary), 0 4px 16px rgba(139,26,26,.22);
  overflow: hidden; background: #fff; flex-shrink: 0;
}
.nav-logo-ring img { width: 100%; height: 100%; object-fit: cover; }
.brand-name  { font-family: 'Playfair Display', serif; font-weight: 800; font-size: 1.12rem; color: var(--primary); line-height: 1.1; letter-spacing: .03em; }
.brand-sub   { font-family: 'Playfair Display', serif; font-weight: 700; font-size: .88rem; color: var(--accent); line-height: 1.1; letter-spacing: .06em; }
.brand-tag   { font-size: .6rem; color: var(--muted); letter-spacing: .14em; margin-top: 2px; }
.navbar-nav .nav-link {
  font-size: .82rem; font-weight: 500;
  color: var(--text) !important; padding: .5rem .8rem !important;
  border-radius: 7px; transition: .2s;
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--primary) !important;
  background: rgba(139,26,26,.07);
}
.navbar-nav .nav-link.active { font-weight: 600; }
.btn-nav-apply {
  background: var(--primary);
  color: #fff !important; font-size: .8rem !important; font-weight: 700 !important;
  padding: .48rem 1.3rem !important; border-radius: 22px !important;
  border: none !important; box-shadow: 0 3px 12px rgba(139,26,26,.3);
  transition: .2s !important;
}
.btn-nav-apply:hover { background: var(--primary-dk) !important; transform: translateY(-1px); }

/* ══════════════════════════════
   HERO / SLIDER
══════════════════════════════ */
.hero-section {
  background: var(--cream);
  padding-top: 100px; padding-bottom: 60px;
  min-height: 92vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
}
.hero-decor-tr {
  position: absolute; top: 0; right: 0; width: 520px; height: 520px;
  background: rgba(232,135,26,.08); border-radius: 0 0 0 100%;
  pointer-events: none;
}
.hero-decor-bl {
  position: absolute; bottom: 0; left: 0; width: 380px; height: 380px;
  background: rgba(21,101,192,.05); border-radius: 0 100% 0 0;
  pointer-events: none;
}
.hero-badge {
  display: inline-block;
  background: rgba(232,135,26,.14); border: 1px solid rgba(232,135,26,.38);
  border-radius: 100px; padding: 5px 18px;
  font-size: .76rem; font-weight: 600; color: var(--primary); letter-spacing: .06em;
}
.hero-h1 { font-size: clamp(2.4rem,5vw,3.8rem); font-weight: 800; color: var(--primary); line-height: 1.1; }
.hero-h1 span { color: var(--accent); }
.hero-sub { color: var(--muted); font-size: 1rem; line-height: 1.85; max-width: 520px; }
/* Logo showcase */
.logo-showcase-wrap { position: relative; text-align: center; }
.logo-hero-ring {
  width: 240px; height: 240px; border-radius: 50%;
  border: 5px solid var(--accent);
  box-shadow: 0 0 0 3px #fff, 0 0 0 9px rgba(232,135,26,.2), 0 0 0 16px rgba(139,26,26,.07), 0 24px 60px rgba(139,26,26,.2);
  overflow: hidden; background: #fff;
  display: inline-flex; align-items: center; justify-content: center;
}
.logo-hero-ring img { width: 100%; height: 100%; object-fit: cover; }
.logo-est {
  position: absolute; bottom: -14px; left: 50%; transform: translateX(-50%);
  background: var(--primary); color: #fff;
  border-radius: 100px; padding: 5px 20px;
  font-size: .67rem; font-weight: 700; letter-spacing: .14em;
  border: 2px solid var(--accent); white-space: nowrap;
  box-shadow: 0 4px 14px rgba(139,26,26,.28);
}
/* Stat cards */
.stat-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; text-align: center; box-shadow: var(--shadow-sm); }
.stat-val { font-family: 'Playfair Display', serif; font-size: 1.7rem; font-weight: 800; color: var(--primary); line-height: 1; }
.stat-lbl { font-size: .67rem; color: var(--muted); margin-top: 4px; letter-spacing: .04em; }
/* Slide dots */
.slide-dots { display: flex; gap: 8px; }
.slide-dot { width: 10px; height: 10px; border-radius: 5px; border: none; cursor: pointer; transition: all .35s; background: rgba(139,26,26,.22); padding: 0; }
.slide-dot.active { width: 30px; background: var(--accent); }

/* ══════════════════════════════
   BUTTONS
══════════════════════════════ */
.btn-primary-c {
  background: var(--primary); color: #fff; border: none;
  border-radius: var(--radius); padding: .82rem 1.9rem;
  font-weight: 600; font-size: .93rem; letter-spacing: .04em;
  transition: .2s; display: inline-block;
}
.btn-primary-c:hover { background: var(--primary-dk); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(139,26,26,.3); }
.btn-outline-c {
  background: transparent; color: var(--primary);
  border: 2px solid var(--primary);
  border-radius: var(--radius); padding: .82rem 1.9rem;
  font-weight: 600; font-size: .93rem; transition: .2s; display: inline-block;
}
.btn-outline-c:hover { background: var(--primary); color: #fff; }
.btn-accent-c {
  background: var(--accent); color: #fff; border: none;
  border-radius: var(--radius); padding: .82rem 1.9rem;
  font-weight: 600; font-size: .93rem; letter-spacing: .04em;
  transition: .2s; display: inline-block;
}
.btn-accent-c:hover { background: #c4711a; color: #fff; transform: translateY(-1px); }

/* ══════════════════════════════
   ABOUT SECTION
══════════════════════════════ */
.school-img-wrap { position: relative; }
.school-img-main { border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); width: 100%; object-fit: cover; height: 420px; }
.school-img-badge {
  position: absolute; bottom: -20px; right: -20px;
  background: var(--primary); color: #fff;
  border-radius: var(--radius); padding: 18px 24px; text-align: center;
  box-shadow: var(--shadow-md);
}
.school-img-badge .num { font-family: 'Playfair Display', serif; font-size: 2.2rem; font-weight: 800; color: var(--accent); line-height: 1; }
.school-img-badge .txt { font-size: .72rem; letter-spacing: .08em; color: rgba(255,248,240,.8); }
.feature-pill { display: flex; align-items: center; gap: 10px; background: var(--offwhite); border: 1px solid var(--border); border-radius: 10px; padding: 10px 16px; font-size: .87rem; font-weight: 600; color: var(--text); }
.vision-item { border-left: 4px solid; border-radius: 0 var(--radius) var(--radius) 0; padding: 1.2rem 1.5rem; transition: .2s; }
.vision-item:hover { transform: translateX(4px); }

/* ══════════════════════════════
   PROGRAMS
══════════════════════════════ */
.prog-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2rem;
  border-top: 4px solid; transition: transform .3s, box-shadow .3s;
  box-shadow: var(--shadow-sm); height: 100%;
}
.prog-card:hover { transform: translateY(-7px); box-shadow: var(--shadow-lg); }
.prog-icon { font-size: 2.8rem; margin-bottom: .75rem; }
.prog-badge { display: inline-block; border-radius: 100px; padding: 3px 12px; font-size: .7rem; font-weight: 700; letter-spacing: .1em; margin-bottom: .75rem; }

/* ══════════════════════════════
   FACILITIES
══════════════════════════════ */
.fac-card {
  background: var(--offwhite); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem 1.75rem;
  border-left: 4px solid; display: flex; gap: 16px; align-items: flex-start;
  transition: transform .25s, box-shadow .25s, background .2s; height: 100%;
}
.fac-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); background: #fff; }
.fac-icon { font-size: 2rem; flex-shrink: 0; line-height: 1; margin-top: 4px; }
.fac-card h5 { font-size: .98rem; font-weight: 700; color: var(--primary); margin-bottom: .35rem; }
.fac-card p  { font-size: .84rem; color: var(--muted); line-height: 1.75; margin: 0; }

/* ══════════════════════════════
   RESULTS / ACHIEVEMENTS
══════════════════════════════ */
.result-main-card {
  background: #fff; border: 2px solid rgba(212,160,23,.5);
  border-radius: var(--radius-lg); padding: 2.5rem;
  box-shadow: 0 8px 40px rgba(212,160,23,.12);
}
.score-circle {
  width: 165px; height: 165px; border-radius: 50%;
  border: 5px solid var(--accent); background: rgba(212,160,23,.07);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.score-num { font-family: 'Playfair Display', serif; font-size: 2.9rem; font-weight: 800; color: var(--primary); line-height: 1; }
.score-of  { font-size: .68rem; color: var(--muted); letter-spacing: .1em; }
.subj-pill {
  background: var(--offwhite); border: 1px solid var(--border);
  border-left: 3px solid; border-radius: 0 8px 8px 0;
  padding: 7px 14px; display: flex; justify-content: space-between; align-items: center;
  font-size: .84rem; font-weight: 500;
}
.milestone-bar { background: var(--primary); border-radius: var(--radius-lg); }
.m-val { font-family: 'Playfair Display', serif; font-size: 2.5rem; font-weight: 800; color: var(--accent); line-height: 1; }
.m-lbl { color: rgba(255,248,240,.7); font-size: .82rem; }

/* ══════════════════════════════
   GALLERY
══════════════════════════════ */
.gal-item { border-radius: var(--radius); overflow: hidden; position: relative; cursor: pointer; display: block; }
.gal-item img { width: 100%; height: 220px; object-fit: cover; transition: transform .4s; display: block; }
.gal-item:hover img { transform: scale(1.06); }
.gal-overlay {
  position: absolute; inset: 0;
  background: rgba(139,26,26,.6);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: .3s;
}
.gal-item:hover .gal-overlay { opacity: 1; }
.gal-overlay span { color: #fff; font-size: .88rem; font-weight: 600; }

/* ══════════════════════════════
   MANAGEMENT / PRINCIPAL
══════════════════════════════ */
.principal-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-md);
}
.principal-img { width: 100%; height: 300px; object-fit: cover; object-position: top; }
.principal-info { background: var(--primary); padding: 1.2rem; text-align: center; }
.principal-info h5 { color: var(--accent); font-size: 1rem; margin-bottom: .2rem; }
.principal-info p  { color: rgba(255,248,240,.78); font-size: .8rem; margin: 0; }
.quote-card {
  background: var(--offwhite); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2.5rem;
  border-left: 5px solid var(--accent);
}
.quote-mark { font-family: 'Playfair Display', serif; font-size: 5rem; color: var(--accent); line-height: .8; }

/* ══════════════════════════════
   TESTIMONIALS
══════════════════════════════ */
.testi-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2rem;
  border-bottom: 4px solid var(--accent);
  box-shadow: var(--shadow-sm); height: 100%;
}
.testi-avatar {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Playfair Display', serif; font-weight: 800; font-size: 1.15rem; flex-shrink: 0;
}
.stars { color: #F4C40F; letter-spacing: 2px; }

/* ══════════════════════════════
   ADMISSIONS
══════════════════════════════ */
.admission-section {
  background: linear-gradient(135deg, rgba(232,135,26,.09) 0%, rgba(139,26,26,.05) 100%);
  border-top: 2px solid rgba(232,135,26,.28);
}
.step-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.75rem; text-align: center;
  box-shadow: var(--shadow-sm); height: 100%; transition: .25s;
}
.step-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.step-num { font-size: .7rem; font-weight: 700; color: var(--accent); letter-spacing: .12em; margin-bottom: 4px; }

/* ══════════════════════════════
   NEWS / EVENTS
══════════════════════════════ */
.news-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: .3s; height: 100%;
}
.news-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.news-img { width: 100%; height: 200px; object-fit: cover; }
.news-date { background: var(--primary); color: #fff; font-size: .75rem; font-weight: 700; padding: 4px 12px; border-radius: 100px; display: inline-block; margin-bottom: 8px; }
.news-body { padding: 1.5rem; }
.news-body h5 { font-size: 1rem; color: var(--primary); margin-bottom: .5rem; }
.news-body p { font-size: .85rem; color: var(--muted); line-height: 1.75; }

/* ══════════════════════════════
   CONTACT
══════════════════════════════ */
.contact-icon-box {
  width: 48px; height: 48px; border-radius: 12px;
  background: rgba(139,26,26,.08); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; flex-shrink: 0;
}
.contact-form-box {
  background: var(--offwhite); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2.5rem;
}
.form-control, .form-select {
  border: 1.5px solid var(--border); border-radius: var(--radius);
  font-size: .88rem; color: var(--text); padding: .75rem 1rem;
  background: #fff; font-family: 'Poppins', sans-serif;
}
.form-control:focus, .form-select:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px rgba(232,135,26,.15);
}
.form-label { font-size: .8rem; font-weight: 600; color: var(--primary); margin-bottom: 6px; }
.btn-form-submit {
  background: var(--primary); color: #fff; border: none;
  border-radius: var(--radius); padding: .88rem; font-weight: 700;
  font-size: .93rem; letter-spacing: .06em; width: 100%;
  transition: .2s; font-family: 'Poppins', sans-serif;
}
.btn-form-submit:hover { background: var(--primary-dk); }

/* ══════════════════════════════
   PAGE HEADER (inner pages)
══════════════════════════════ */
.page-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dk) 100%);
  padding: 100px 0 50px; position: relative; overflow: hidden;
}
.page-header::before {
  content: ''; position: absolute; inset: 0;
  background: url('images/school-building.jpg') center/cover no-repeat;
  opacity: .12;
}
.page-header .container { position: relative; z-index: 1; }
.page-header h1 { font-size: clamp(2rem,4vw,3rem); font-weight: 800; color: #fff; }
.page-header .breadcrumb { background: transparent; margin: 0; padding: 0; }
.page-header .breadcrumb-item, .page-header .breadcrumb-item a { color: rgba(255,248,240,.75); font-size: .85rem; }
.page-header .breadcrumb-item.active { color: var(--accent); }
.page-header .breadcrumb-item + .breadcrumb-item::before { color: rgba(255,248,240,.4); }

/* ══════════════════════════════
   FOOTER
══════════════════════════════ */
.main-footer { background: var(--primary); }
.footer-logo-wrap { display: flex; align-items: center; gap: 14px; }
.footer-logo-ring {
  width: 58px; height: 58px; border-radius: 50%;
  border: 3px solid var(--accent); overflow: hidden; background: #fff; flex-shrink: 0;
}
.footer-logo-ring img { width: 100%; height: 100%; object-fit: cover; }
.footer-brand-name { color: var(--accent); font-family: 'Playfair Display', serif; font-weight: 800; font-size: 1rem; }
.footer-brand-sub  { color: rgba(255,248,240,.65); font-size: .7rem; letter-spacing: .12em; }
.footer-text { color: rgba(255,248,240,.62); font-size: .85rem; line-height: 1.85; }
.footer-link {
  display: block; color: rgba(255,248,240,.62);
  font-size: .85rem; padding: 3px 0;
  transition: .2s; background: none; border: none; text-align: left; cursor: pointer;
}
.footer-link:hover { color: var(--accent); padding-left: 5px; }
.footer-heading { color: #fff; font-family: 'Playfair Display', serif; font-weight: 700; font-size: .95rem; margin-bottom: 1rem; letter-spacing: .04em; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 8px;
  background: rgba(255,248,240,.1); color: rgba(255,248,240,.7);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1rem; transition: .2s;
}
.footer-social a:hover { background: var(--accent); color: #fff; }
.footer-divider { border-color: rgba(255,248,240,.14); }
.footer-copy { color: rgba(255,248,240,.42); font-size: .78rem; }

/* ══════════════════════════════
   WHATSAPP FAB + SCROLL TOP
══════════════════════════════ */
.wa-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 9999;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; box-shadow: 0 4px 20px rgba(37,211,102,.45);
  transition: transform .3s;
}
.wa-fab:hover { transform: scale(1.12); color: #fff; }
.scroll-top-btn {
  position: fixed; bottom: 96px; right: 28px; z-index: 9999;
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--primary); color: #fff; border: none;
  display: none; align-items: center; justify-content: center;
  font-size: 1.1rem; box-shadow: 0 4px 14px rgba(139,26,26,.35);
  cursor: pointer; transition: .2s;
}
.scroll-top-btn.show { display: flex; }
.scroll-top-btn:hover { background: var(--primary-dk); }

/* ══════════════════════════════
   COUNTER SECTION
══════════════════════════════ */
.counter-section { background: var(--primary); }
.counter-box { text-align: center; }
.counter-num { font-family: 'Playfair Display', serif; font-size: 3rem; font-weight: 800; color: var(--accent); line-height: 1; }
.counter-lbl { color: rgba(255,248,240,.78); font-size: .85rem; margin-top: 6px; }
.counter-divider { width: 1px; background: rgba(255,248,240,.18); }

/* ══════════════════════════════
   FLEX BANNER STRIP
══════════════════════════════ */
.flex-banner img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }

/* ══════════════════════════════
   RESPONSIVE
══════════════════════════════ */
@media (max-width: 991px) {
  .hero-section { padding-top: 80px; padding-bottom: 40px; min-height: auto; }
  .school-img-badge { right: 0; bottom: -16px; }
}
@media (max-width: 768px) {
  .section-py { padding: 56px 0; }
  .logo-hero-ring { width: 190px; height: 190px; }
  .score-circle { width: 130px; height: 130px; }
  .score-num { font-size: 2.2rem; }
  .hero-decor-tr, .hero-decor-bl { display: none; }
}
