/* ═══════════════════════════════════════════════
   KG HOSPITAL — DEPARTMENTS LANDING PAGE
   Consistent with KGH Design System
   Fonts: Cormorant Garamond + Outfit
   Colors: Brand purple #362C6A, deep navy #1a1340
═══════════════════════════════════════════════ */
:root {
  --kg:       #362C6A;
  --kg-mid:   #0b0171;
  --kg-deep:  #1a1340;
  --kg-light: #5046a0;
  --kg-pale:  #ece9f8;
  --kg-palest:#f6f4fc;
  --red:      #c8404a;
  --red-dark: #9e2f37;
  --gold:     #c9973e;
  --text:     #0f0d22;
  --text-mid: #3d3660;
  --text-soft:#7a74a8;
  --border:   rgba(54,44,106,0.1);
  --white:    #ffffff;
  --off:      #f8f7fc;
}
*,*::before,*::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: "Outfit", sans-serif; background: var(--white); color: var(--text); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }



/* ── BREADCRUMB ── */
.breadcrumb {
  background: var(--kg-palest);
  border-bottom: 1px solid var(--border);
  padding: 10px 5%;
  font-size: 12.5px;
  color: var(--text-soft);
  display: flex;
  align-items: center;
  gap: 6px;
}
.breadcrumb a { color: var(--text-mid); }
.breadcrumb a:hover { color: var(--kg); text-decoration: underline; }
.breadcrumb-sep { color: var(--text-soft); }

/* ── HERO ── */
.hero {
  background: var(--kg-deep);
  padding: 64px 5% 60px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 60px 60px;
}
.hero::after {
  content: '';
  position: absolute;
  right: -100px;
  top: -60px;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(54,44,106,0.5) 0%, transparent 65%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 900px;
}
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: 20px;
}
.hero-tag::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--gold);
}
.hero h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(36px, 5vw, 58px);
  font-weight: 600;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 16px;
}
.hero h1 em { font-style: italic; color: #b8aff0; }
.hero-desc {
  font-size: 16px;
  color: rgba(255,255,255,0.6);
  max-width: 600px;
  line-height: 1.75;
  margin-bottom: 32px;
}
.hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.hero-stat strong {
  display: block;
  font-family: "Cormorant Garamond", serif;
  font-size: 36px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}
.hero-stat span {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-top: 4px;
  display: block;
}

/* ── SEARCH BAR ── */
.search-bar-wrap {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 20px 5%;
  display: flex;
  align-items: center;
  gap: 12px;
  position: sticky;
  top: 68px;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(54,44,106,0.06);
}
.search-bar {
  flex: 1;
  max-width: 480px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--kg-palest);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 10px 16px;
  transition: border-color .2s;
}
.search-bar:focus-within { border-color: var(--kg-light); }
.search-bar svg { color: var(--text-soft); flex-shrink: 0; }
.search-bar input {
  border: none;
  background: transparent;
  outline: none;
  font-family: "Outfit", sans-serif;
  font-size: 14px;
  color: var(--text);
  width: 100%;
}
.search-bar input::placeholder { color: var(--text-soft); }
.filter-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.filter-tab {
  padding: 7px 14px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--text-mid);
  transition: all .2s;
  font-family: "Outfit", sans-serif;
}
.filter-tab:hover { border-color: var(--kg); color: var(--kg); }
.filter-tab.active { background: var(--kg); border-color: var(--kg); color: #fff; }

/* ── FEATURED DEPARTMENTS (CoE) ── */
.section-featured {
  background: var(--off);
  padding: 60px 5%;
  border-bottom: 1px solid var(--border);
}
.section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 6px;
}
.section-title {
  font-family: "Cormorant Garamond", serif;
  font-size: 34px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}
.section-desc {
  font-size: 15px;
  color: var(--text-mid);
  max-width: 600px;
  line-height: 1.75;
  margin-bottom: 36px;
}

.coe-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.coe-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px 24px 24px;
  transition: box-shadow .25s, transform .25s, border-color .25s;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.coe-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--kg);
  border-radius: 14px 14px 0 0;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s ease;
}
.coe-card:hover { box-shadow: 0 8px 32px rgba(54,44,106,0.12); transform: translateY(-3px); border-color: rgba(54,44,106,0.2); }
.coe-card:hover::before { transform: scaleX(1); }

.coe-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--kg-pale);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.coe-icon img { width: 28px; height: 28px; object-fit: contain; }
.coe-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #fff8e6;
  border: 1px solid #f0d080;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 10.5px;
  font-weight: 600;
  color: #96700a;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  width: fit-content;
}
.coe-badge::before { content: '★'; font-size: 9px; }
.coe-name {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}
.coe-tagline {
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.55;
}
.coe-stats {
  display: flex;
  gap: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}
.coe-stat strong {
  display: block;
  font-family: "Cormorant Garamond", serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--kg);
}
.coe-stat span { font-size: 10.5px; color: var(--text-soft); text-transform: uppercase; letter-spacing: 0.05em; }
.coe-arrow {
  position: absolute;
  bottom: 22px; right: 22px;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--kg-pale);
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, transform .2s;
}
.coe-card:hover .coe-arrow { background: var(--kg); transform: translateX(2px); }
.coe-card:hover .coe-arrow svg { color: #fff; }
.coe-arrow svg { color: var(--kg); }

/* ── ALL DEPARTMENTS GRID ── */
.section-all {
  padding: 60px 5%;
  background: var(--white);
}

.dept-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.dept-card {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 20px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
}
.dept-card:hover {
  border-color: var(--kg);
  background: var(--kg-palest);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(54,44,106,0.1);
}
.dept-card:hover .dept-name { color: var(--kg); }
.dept-icon-wrap {
  width: 44px; height: 44px;
  border-radius: 10px;
  background: var(--kg-pale);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background .2s;
}
.dept-card:hover .dept-icon-wrap { background: var(--kg); }
.dept-card:hover .dept-icon-wrap img { filter: brightness(0) invert(1); }
.dept-icon-wrap img { width: 24px; height: 24px; object-fit: contain; }
.dept-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-mid);
  line-height: 1.35;
  transition: color .2s;
}

/* ── EMERGENCY STRIP ── */
.emergency-strip {
  background: var(--red);
  padding: 22px 5%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.em-left {
  display: flex;
  align-items: center;
  gap: 16px;
}
.em-icon {
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.em-text strong {
  display: block;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
}
.em-text span { font-size: 13px; color: rgba(255,255,255,0.75); }
.em-ctas { display: flex; gap: 10px; flex-wrap: wrap; }
.em-btn {
  padding: 10px 22px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  font-family: "Outfit", sans-serif;
  white-space: nowrap;
}
.em-btn-primary { background: #fff; color: var(--red); border: 2px solid #fff; }
.em-btn-primary:hover { background: transparent; color: #fff; }
.em-btn-outline { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,0.5); }
.em-btn-outline:hover { background: rgba(255,255,255,0.15); border-color: #fff; }

/* ── WHY KGH ── */
.section-why {
  background: var(--kg-palest);
  padding: 64px 5%;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 36px;
}
.why-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px 22px;
}
.why-num {
  font-family: "Cormorant Garamond", serif;
  font-size: 42px;
  font-weight: 700;
  color: var(--kg);
  line-height: 1;
  margin-bottom: 6px;
}
.why-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.why-sub { font-size: 13px; color: var(--text-soft); line-height: 1.55; }

/* ── SEO TEXT SECTION ── */
.section-seo {
  padding: 60px 5%;
  background: var(--white);
}
.seo-inner {
  max-width: 800px;
}
.seo-inner h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: 30px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
}
.seo-inner h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--kg);
  margin: 28px 0 10px;
}
.seo-inner p {
  font-size: 14.5px;
  color: var(--text-mid);
  line-height: 1.8;
  margin-bottom: 14px;
}

/* ── FAQ ── */
.section-faq {
  background: var(--off);
  padding: 64px 5%;
  border-top: 1px solid var(--border);
}
.faq-list { max-width: 780px; margin-top: 36px; }
.faq-item {
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}
.faq-q {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  font-family: "Outfit", sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  transition: color .2s;
}
.faq-q:hover { color: var(--kg); }
.faq-icon {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--kg-pale);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background .2s, transform .3s;
}
.faq-item.open .faq-icon { background: var(--kg); transform: rotate(45deg); }
.faq-icon svg { color: var(--kg); }
.faq-item.open .faq-icon svg { color: #fff; }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s ease;
}
.faq-a p {
  padding: 0 0 18px;
  font-size: 14px;
  color: var(--text-mid);
  line-height: 1.75;
}
.faq-item.open .faq-a { max-height: 300px; }

/* ── FOOTER ── */
.footer {
  background: var(--kg-deep);
  padding: 48px 5% 24px;
  color: rgba(255,255,255,0.55);
  font-size: 13px;
}
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 8px;
}
.footer-brand p { line-height: 1.7; max-width: 280px; }
.footer-contact { margin-top: 16px; display: flex; flex-direction: column; gap: 6px; }
.footer-contact a { color: rgba(255,255,255,0.8); }
.footer-contact a:hover { color: #fff; }
.footer-col h4 { font-size: 13px; font-weight: 600; color: #fff; margin-bottom: 14px; letter-spacing: 0.05em; text-transform: uppercase; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-col ul li a { color: rgba(255,255,255,0.55); transition: color .2s; }
.footer-col ul li a:hover { color: #fff; }
.footer-bottom {
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.nabh-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ── HIDDEN (for search filter) ── */
.dept-card.hidden { display: none; }

/* ── NO RESULTS ── */
#no-results {
  display: none;
  padding: 32px;
  text-align: center;
  color: var(--text-soft);
  font-size: 15px;
  grid-column: 1 / -1;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 600px) {
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .hero-stats { gap: 24px; }
  .hero-stat strong { font-size: 28px; }
  .search-bar-wrap { flex-direction: column; align-items: flex-start; top: 68px; }
  .coe-grid { grid-template-columns: 1fr; }
  .filter-tabs { display: none; }
}
