/* ==========================================================
   Baptist Medical Centre (BMC) website styles
   Brand colours come from the BMC logo (blue, cyan and magenta)
   ========================================================== */

:root {
  --navy: #063B66;
  --navy-deep: #042a49;
  --blue: #0878B9;
  --cyan: #00B0F0;
  --soft: #EAF4FA;
  --white: #FFFFFF;
  --accent: #C72BA9;        /* BMC logo magenta, tuned for text contrast */
  --accent-bright: #D030B0; /* exact logo magenta, for large decorative use */
  --accent-soft: #FBEAF7;
  --ink: #0f2438;
  --muted: #4b6074;
  --line: #d6e5ef;

  --font-head: "Plus Jakarta Sans", "Manrope", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 10px;
  --radius-lg: 22px;
  --shadow: 0 18px 50px -24px rgba(6, 59, 102, .35);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

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

img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-head); margin: 0; line-height: 1.1; color: var(--navy); }
p { margin: 0 0 1em; }

.wrap { width: min(1180px, 100% - 2.5rem); margin-inline: auto; }
.section { padding: clamp(4.5rem, 9vw, 8rem) 0; }

.sprite { position: absolute; }
.skip {
  position: absolute; left: -999px; top: 8px; z-index: 200;
  background: var(--navy); color: #fff; padding: .6rem 1rem; border-radius: 6px;
}
.skip:focus { left: 8px; }

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: 600 .98rem/1 var(--font-head);
  padding: 1rem 1.6rem; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer;
  transition: transform .25s var(--ease), background .25s, color .25s, border-color .25s, box-shadow .25s;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--navy); color: #fff; }
.btn--primary:hover { background: var(--blue); box-shadow: 0 12px 26px -12px rgba(8, 120, 185, .7); }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: #a82190; box-shadow: 0 12px 26px -12px rgba(199, 43, 169, .7); }
.btn--ghost { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn--ghost:hover { background: var(--navy); color: #fff; }
.btn--block { width: 100%; }

/* ---------- Navigation ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background .3s, box-shadow .3s, padding .3s;
  padding: 1rem 0;
}
.nav.is-scrolled {
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line), 0 10px 30px -22px rgba(6, 59, 102, .5);
  padding: .55rem 0;
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }

.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; }
.brand__plus { width: 34px; height: 34px; color: var(--accent-bright); flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__text strong { font: 800 1.55rem/1 var(--font-head); color: var(--navy); letter-spacing: .06em; }
.brand__text small { font: 600 .68rem/1.2 var(--font-head); color: var(--blue); letter-spacing: .14em; text-transform: uppercase; margin-top: .25rem; }
.brand--light .brand__text strong { color: #fff; }
.brand--light .brand__text small { color: #9fd3ef; }

.nav__links { display: flex; align-items: center; gap: 2rem; }
.nav__links a:not(.btn) {
  font: 600 .95rem/1 var(--font-head); color: var(--navy); text-decoration: none; position: relative; padding: .5rem 0;
}
.nav__links a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%;
  background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav__links a:not(.btn):hover::after,
.nav__links a.is-active::after { transform: scaleX(1); }
.nav__cta { padding: .85rem 1.3rem; }

.burger { display: none; width: 46px; height: 46px; border: 0; background: transparent; cursor: pointer; border-radius: 50%; }
.burger span { display: block; width: 24px; height: 2.5px; background: var(--navy); margin: 5px auto; border-radius: 2px; transition: transform .3s, opacity .3s; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: 8.5rem 0 3.5rem;
  background:
    radial-gradient(900px 500px at 90% 10%, rgba(0, 176, 240, .14), transparent 60%),
    linear-gradient(180deg, var(--soft) 0%, #f6fbfe 70%, #fff 100%);
}
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font: 700 .8rem/1 var(--font-head); letter-spacing: .16em; text-transform: uppercase; color: var(--blue);
  margin-bottom: 1.4rem;
}
.eyebrow__plus { width: 18px; height: 18px; color: var(--accent-bright); }
.eyebrow__plus svg { width: 100%; height: 100%; }

.hero h1 {
  font-size: clamp(2.6rem, 6.4vw, 5.2rem);
  font-weight: 800; letter-spacing: -.035em; line-height: 1.02;
  margin-bottom: 1.5rem;
}
.hero h1 span { color: var(--blue); }
.hero__lead { font-size: 1.2rem; color: var(--muted); max-width: 34rem; margin-bottom: 2rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .9rem; margin-bottom: 2rem; }
.hero__badge {
  display: inline-flex; align-items: center; gap: .5rem;
  font: 600 .9rem/1.2 var(--font-head); color: var(--navy); margin: 0;
}
.hero__badge svg { width: 22px; height: 22px; color: var(--accent); }

.hero__media { position: relative; }
.hero__photo {
  border-radius: 28px 28px 28px 120px; overflow: hidden; aspect-ratio: 4 / 4.6;
  box-shadow: var(--shadow);
}
.hero__photo img { width: 100%; height: 100%; object-fit: cover; object-position: 45% 30%; }
.hero__photo::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(180deg, rgba(6, 59, 102, 0) 55%, rgba(6, 59, 102, .28));
}
.hero__plus {
  position: absolute; width: 92px; height: 92px; top: -26px; right: -14px;
  color: var(--accent-bright); filter: drop-shadow(0 14px 18px rgba(199, 43, 169, .35));
  animation: float 6s ease-in-out infinite;
}
.hero__chip {
  position: absolute; left: -26px; bottom: 38px; z-index: 2;
  background: #fff; border-radius: 16px; padding: 1rem 1.3rem; box-shadow: var(--shadow);
  display: flex; flex-direction: column; line-height: 1.25; border-left: 5px solid var(--accent);
}
.hero__chip strong { font: 700 1rem/1.2 var(--font-head); color: var(--navy); }
.hero__chip span { font-size: .9rem; color: var(--muted); }

@keyframes float { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-10px) rotate(4deg); } }

/* ---------- Stats ---------- */
.stats {
  list-style: none; margin: 4rem 0 0; padding: 1.6rem 2rem;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem;
  background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow); border: 1px solid var(--line);
}
.stats li { text-align: center; padding: .4rem 1rem; position: relative; }
.stats li + li::before { content: ""; position: absolute; left: 0; top: 18%; bottom: 18%; width: 1px; background: var(--line); }
.stats strong { display: block; font: 800 clamp(2rem, 4vw, 2.9rem)/1 var(--font-head); color: var(--navy); letter-spacing: -.03em; }
.stats span { display: block; margin-top: .45rem; font-size: .95rem; color: var(--muted); }

/* ---------- Shared headings ---------- */
.kicker {
  font: 700 .82rem/1 var(--font-head); letter-spacing: .18em; text-transform: uppercase; color: var(--accent);
  margin-bottom: 1.1rem; display: flex; align-items: center; gap: .7rem;
}
.kicker::before { content: ""; width: 34px; height: 2px; background: currentColor; }
h2 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); font-weight: 800; letter-spacing: -.03em; margin-bottom: 1.3rem; }
h2 em { font-style: normal; color: var(--blue); }
.section__head { max-width: 46rem; margin-bottom: 3.2rem; }
.section__head p:last-child { color: var(--muted); font-size: 1.15rem; margin-bottom: 0; }

/* ---------- About ---------- */
.about__grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.about__media { position: relative; max-width: 360px; }
.about__media img {
  width: 100%; height: auto; border-radius: 120px 120px 18px 18px; box-shadow: var(--shadow);
  aspect-ratio: 275 / 414; object-fit: cover;
}
.about__media::before {
  content: ""; position: absolute; inset: 28px -26px -26px 28px; border-radius: 120px 120px 18px 18px;
  background: var(--soft); z-index: -1;
}
.about__tag {
  position: absolute; right: -22px; bottom: 34px; display: flex; align-items: center; gap: .6rem;
  background: var(--navy); color: #fff; padding: .85rem 1.2rem; border-radius: 999px;
  font: 600 .9rem/1 var(--font-head); box-shadow: var(--shadow);
}
.about__tag svg { width: 20px; height: 20px; color: var(--accent-bright); }
.about__copy p { color: var(--muted); }
.mv { display: grid; grid-template-columns: 1fr 1.6fr; gap: 1.2rem; margin-top: 2rem; }
.mv__item { background: var(--soft); border-radius: var(--radius-lg); padding: 1.6rem; border-top: 4px solid var(--accent); }
.mv__item h3 { font-size: .85rem; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); margin-bottom: .7rem; }
.mv__item p { margin: 0; color: var(--navy); font-weight: 500; font-size: 1.02rem; line-height: 1.55; }

/* ---------- Services ---------- */
.services { background: linear-gradient(180deg, #fff, var(--soft)); }
.svc { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.svc__item {
  position: relative; padding: 2.2rem 2rem 2.4rem; border-bottom: 1px solid var(--line);
  transition: background .35s var(--ease);
}
.svc__item:not(:nth-child(3n+1)) { border-left: 1px solid var(--line); }
.svc__item::before {
  content: ""; position: absolute; left: 0; top: -1px; height: 3px; width: 0; background: var(--accent);
  transition: width .5s var(--ease);
}
.svc__item:hover { background: #fff; }
.svc__item:hover::before { width: 100%; }
.svc__no { position: absolute; top: 1.4rem; right: 1.6rem; font: 700 .85rem/1 var(--font-head); color: #a9bfcf; letter-spacing: .1em; }
.svc__icon { width: 52px; height: 52px; color: var(--blue); margin-bottom: 1.4rem; transition: transform .4s var(--ease), color .3s; }
.svc__item:hover .svc__icon { transform: translateY(-4px) scale(1.06); color: var(--accent); }
.svc__item h3 { font-size: 1.35rem; font-weight: 700; margin-bottom: .6rem; letter-spacing: -.01em; }
.svc__item p { color: var(--muted); margin: 0; font-size: 1rem; }
.svc__item a { color: var(--accent); font-weight: 600; }
.svc__item--emergency .svc__icon { color: var(--accent); }

/* ---------- Why ---------- */
.why { background: var(--navy); color: #fff; position: relative; overflow: hidden; }
.why::before {
  content: ""; position: absolute; right: -8%; top: -12%; width: 520px; height: 520px; opacity: .06;
  background: var(--cyan); border-radius: 50%;
}
.why h2, .why h3 { color: #fff; }
.why h2 em { color: #7cc9f0; }
.section__head--light .kicker { color: #f3a3e2; }
.why__grid { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); gap: 1.5rem; }
.why__item {
  grid-column: span 2; padding: 2rem; border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12);
  transition: transform .35s var(--ease), background .35s;
}
.why__item:nth-child(4) { grid-column: 2 / span 2; }
.why__item:nth-child(5) { grid-column: 4 / span 2; }
.why__item:hover { transform: translateY(-6px); background: rgba(255, 255, 255, .1); }
.why__item svg { width: 30px; height: 30px; color: var(--accent-bright); margin-bottom: 1.2rem; }
.why__item h3 { font-size: 1.25rem; margin-bottom: .6rem; }
.why__item p { margin: 0; color: #c4dcec; font-size: 1rem; }

/* ---------- Contact ---------- */
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 6vw, 5.5rem); align-items: start; }
.contact__info > p { color: var(--muted); }
.contact__list { list-style: none; margin: 2.2rem 0 0; padding: 0; display: grid; gap: 1.4rem; }
.contact__list li { display: flex; gap: 1.1rem; align-items: flex-start; }
.ci {
  flex: none; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center;
  background: var(--soft); color: var(--blue);
}
.ci svg { width: 22px; height: 22px; }
.ci--wa { background: #e3f7ea; color: #128c4a; }
.contact__list h3 { font-size: 1rem; margin-bottom: .2rem; }
.contact__list p { margin: 0; color: var(--muted); }
.contact__list a { text-decoration: none; color: var(--navy); font-weight: 600; border-bottom: 1px solid var(--line); transition: color .2s, border-color .2s; }
.contact__list a:hover { color: var(--accent); border-color: var(--accent); }
.sep { color: #9fb4c4; margin: 0 .3rem; }

.form {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 4vw, 2.6rem); box-shadow: var(--shadow); border-top: 5px solid var(--accent);
}
.form h3 { font-size: 1.6rem; margin-bottom: 1.4rem; }
.field { margin-bottom: 1.1rem; }
.field label { display: block; font: 600 .9rem/1 var(--font-head); color: var(--navy); margin-bottom: .5rem; }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--soft);
  border: 1.5px solid transparent; border-radius: var(--radius); padding: .9rem 1rem;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field textarea:focus { outline: none; background: #fff; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(8, 120, 185, .15); }
.field.is-invalid input, .field.is-invalid textarea { border-color: #b3261e; background: #fff7f6; }
.err { display: block; min-height: 1.1em; margin-top: .35rem; font-size: .85rem; color: #b3261e; }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }
.form__status { margin: 1rem 0 0; padding: 0; font-weight: 500; }
.form__status.is-ok { color: #11663a; background: #e3f7ea; padding: .8rem 1rem; border-radius: var(--radius); }
.form__status.is-error { color: #8a1c15; background: #fdecea; padding: .8rem 1rem; border-radius: var(--radius); }
.form__note { margin: 1rem 0 0; font-size: .88rem; color: var(--muted); }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* ---------- Location ---------- */
.location { background: var(--soft); padding: clamp(3.5rem, 7vw, 5.5rem) 0; }
.location__grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(1.8rem, 5vw, 4rem); align-items: center; }
.location__text h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); }
.location__text p { color: var(--muted); }
.location__map { border-radius: var(--radius-lg); overflow: hidden; height: 320px; box-shadow: var(--shadow); background: #dbe9f2; border: 4px solid #fff; }
.location__map iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- Footer ---------- */
.footer { background: var(--navy-deep); color: #c4dcec; padding: 4.5rem 0 0; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 2.5rem; padding-bottom: 3rem; }
.footer__brand p { margin-top: 1.2rem; max-width: 22rem; }
.footer h4 { color: #fff; font-size: .85rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 1.2rem; }
.footer__col { display: flex; flex-direction: column; gap: .65rem; }
.footer__col a { text-decoration: none; color: #c4dcec; transition: color .2s, transform .2s; width: fit-content; }
.footer__col a:hover { color: #fff; transform: translateX(3px); }
.footer__bar {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 2rem;
  padding: 1.4rem 0; border-top: 1px solid rgba(255, 255, 255, .12); font-size: .9rem;
}
.footer__bar p { margin: 0; }

/* ---------- Floating buttons ---------- */
.float { position: fixed; right: 18px; bottom: 18px; z-index: 90; display: flex; flex-direction: column; gap: .7rem; align-items: flex-end; }
.float__btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; text-decoration: none;
  height: 54px; min-width: 54px; padding: 0 1.1rem; border-radius: 999px; color: #fff;
  font: 700 .95rem/1 var(--font-head); box-shadow: 0 14px 30px -12px rgba(0, 0, 0, .5);
  transition: transform .25s var(--ease);
}
.float__btn:hover { transform: translateY(-3px) scale(1.04); }
.float__btn svg { width: 24px; height: 24px; }
.float__btn--wa { background: #128c4a; padding: 0; width: 54px; }
.float__btn--call { background: var(--accent); }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hero__grid, .about__grid, .contact__grid, .location__grid { grid-template-columns: 1fr; }
  .hero { padding-top: 7.5rem; }
  .hero__media { max-width: 560px; margin-inline: auto; width: 100%; }
  .hero__chip { left: 10px; }
  .about__media { margin-inline: auto; }
  .svc { grid-template-columns: repeat(2, 1fr); }
  .svc__item:not(:nth-child(3n+1)) { border-left: 0; }
  .svc__item:nth-child(even) { border-left: 1px solid var(--line); }
  .why__grid { grid-template-columns: repeat(2, 1fr); }
  .why__item, .why__item:nth-child(4), .why__item:nth-child(5) { grid-column: auto; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .burger { display: block; }
  .nav__links {
    position: fixed; inset: 0 0 auto 0; top: 0; padding: 5.5rem 1.5rem 2rem;
    flex-direction: column; align-items: stretch; gap: .2rem; background: #fff;
    box-shadow: 0 30px 60px -30px rgba(6, 59, 102, .5);
    transform: translateY(-110%); transition: transform .4s var(--ease); z-index: -1;
  }
  .nav__links.is-open { transform: none; }
  .nav__links a:not(.btn) { font-size: 1.15rem; padding: 1rem .25rem; border-bottom: 1px solid var(--line); }
  .nav__links a:not(.btn)::after { display: none; }
  .nav__cta { margin-top: 1rem; padding: 1.05rem; }
  .nav.menu-open { background: #fff; }
}

@media (max-width: 640px) {
  body { font-size: 1rem; }
  .stats { grid-template-columns: repeat(2, 1fr); padding: 1.2rem; row-gap: 1.4rem; margin-top: 3rem; }
  .stats li:nth-child(3)::before { display: none; }
  .mv { grid-template-columns: 1fr; }
  .svc { grid-template-columns: 1fr; }
  .svc__item:nth-child(even) { border-left: 0; }
  .why__grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero__plus { width: 68px; height: 68px; right: -4px; top: -20px; }
  .about__tag { right: 6px; }
  .about__media::before { inset: 20px -10px -16px 20px; }
  .float__btn--call span { display: none; }
  .float__btn--call { width: 54px; padding: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* Map fallback, shown only if the embed is blocked */
.location__map { position: relative; }
.map__fallback { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .6rem; text-align: center; background: var(--soft); padding: 1.5rem; }
.map__fallback[hidden] { display: none; }
.map__fallback svg { width: 44px; height: 44px; color: var(--accent-bright); }
.map__fallback p { margin: 0 0 .4rem; color: var(--navy); font-weight: 600; }
