/* Maruti Diagnostics - bright clinical design, palette from the clinic logo */
@font-face {
  font-family: "Bricolage Grotesque";
  src: url("../assets/fonts/BricolageGrotesque-var.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --navy: #002050;
  --navy-deep: #001233;
  --navy-soft: #16386e;
  --orange: #d86818;
  --orange-bright: #f07c24;
  --orange-dark: #b85511;
  --ink: #17202c;
  --muted: #46505e;
  --bg: #ffffff;
  --soft: #f5f7fb;
  --line: #e3e8f0;
  --radius: 16px;
  --radius-lg: 28px;
  --ring: inset 0 0 0 1px rgba(0,32,80,.07);
  --shadow-card: 0 2px 6px rgba(0,32,80,.06), 0 18px 44px rgba(0,32,80,.1);
  --shadow-float: 0 6px 16px rgba(0,32,80,.08), 0 30px 70px rgba(0,32,80,.14);
  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  --body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans", sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --z-sticky: 20;
  --z-actionbar: 30;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
@supports (overflow-x: clip) {
  html, body { overflow-x: clip; }
}
body {
  font-family: var(--body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 64px; /* room for the mobile action bar */
}
img { max-width: 100%; display: block; }
a { color: var(--navy); }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; text-wrap: balance; color: var(--navy); }

.wrap { width: min(100% - 3rem, 1120px); margin-inline: auto; }

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

:focus-visible {
  outline: 3px solid rgba(240,124,36,.6);
  outline-offset: 2px;
  border-radius: 4px;
}

/* scroll reveals: only when JS runs; content stays visible without it */
html.js [data-reveal] {
  opacity: 0; transform: translateY(16px);
  transition: opacity .65s var(--ease), transform .65s var(--ease);
}
html.js [data-reveal].in { opacity: 1; transform: none; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: var(--z-sticky);
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .35s var(--ease);
}
.site-header.scrolled { box-shadow: 0 8px 30px rgba(0,18,51,.08); }
.header-row { display: flex; align-items: center; gap: 1rem; padding: .6rem 0; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; }
.brand-emblem { width: 30px; height: auto; }
.brand-word { font-family: var(--display); font-size: 1.02rem; letter-spacing: .01em; line-height: 1.05; display: block; }
.brand-word strong { color: var(--navy); font-weight: 800; }
.brand-word em { color: var(--orange); font-style: normal; font-weight: 700; }
.brand-word small { display: block; font-family: var(--body); font-size: .58rem; color: var(--muted); letter-spacing: .02em; }
.main-nav { display: none; }
.header-call {
  margin-left: auto; display: inline-flex; align-items: center; gap: .45rem;
  background: var(--navy); color: #fff; text-decoration: none;
  font-weight: 600; font-size: .88rem; padding: .55rem .9rem; border-radius: 999px;
  transition: background .2s var(--ease);
}
.header-call:hover, .header-call:active { background: var(--navy-soft); }
.nav-toggle {
  display: inline-flex; flex-direction: column; gap: 5px; justify-content: center;
  background: none; border: 0; padding: .5rem; cursor: pointer;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--navy); transition: transform .25s var(--ease), opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.main-nav.open {
  display: flex; flex-direction: column;
  position: absolute; inset: 100% 0 auto 0;
  background: #fff; border-bottom: 1px solid var(--line);
  padding: .5rem 1.5rem 1rem;
  box-shadow: 0 20px 40px rgba(0,18,51,.1);
}
.main-nav a { text-decoration: none; font-weight: 600; padding: .65rem 0; border-bottom: 1px solid var(--soft); }
.main-nav a.nav-cta { color: var(--orange-dark); border-bottom: 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-weight: 700; font-size: .95rem; text-decoration: none;
  padding: .85rem 1.4rem; border-radius: 999px; border: 0; cursor: pointer;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease), border-color .2s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.985); }
.btn-orange { background: linear-gradient(180deg, var(--orange-bright), var(--orange)); color: #fff; box-shadow: 0 8px 22px rgba(216,104,24,.35); }
.btn-orange:hover { box-shadow: 0 12px 28px rgba(216,104,24,.45); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-soft); }
.btn-outline { background: #fff; color: var(--navy); border: 1.5px solid var(--line); }
.btn-outline:hover { border-color: var(--navy); }
.btn-outline-light { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.4); }
.btn-outline-light:hover { border-color: #fff; }

/* ---------- hero ---------- */
.hero {
  background:
    radial-gradient(1100px 520px at 88% -10%, rgba(93,139,255,.08), transparent 60%),
    linear-gradient(180deg, #fbfcfe 0%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero-grid {
  display: grid; gap: 2.5rem;
  padding: clamp(3rem, 8vw, 6rem) 0 clamp(2.5rem, 6vw, 4.5rem);
}
.hero-kicker {
  font-weight: 700; font-size: .85rem; letter-spacing: .01em;
  color: var(--orange-dark); margin-bottom: 1rem;
}
.hero h1 {
  font-size: clamp(2.5rem, 7.5vw, 4.4rem);
  font-weight: 800; letter-spacing: -0.022em;
  margin-bottom: 1.2rem;
}
.hero h1 .hl { color: var(--orange); }
.hero-sub { max-width: 46ch; color: var(--muted); font-size: 1.06rem; margin-bottom: 1.8rem; text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 1.8rem; }
.hero-services { list-style: none; display: flex; flex-wrap: wrap; gap: .35rem 0; align-items: center; color: var(--muted); font-size: .84rem; font-weight: 600; }
.hero-services li { display: flex; align-items: center; }
.hero-services li + li::before {
  content: ""; width: 4px; height: 4px; border-radius: 50%;
  background: var(--orange); margin: 0 .6rem; flex: none;
}
.hero-media { position: relative; }
.hero-frame {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--ring), var(--shadow-float);
}
.hero-frame { aspect-ratio: 4 / 3; }
.hero-frame img { width: 100%; height: 100%; object-fit: cover; }
.hero-mini {
  display: none; position: absolute; right: -1.4rem; bottom: -2.2rem;
  width: 44%; aspect-ratio: 4 / 3; overflow: hidden;
  border-radius: 18px; border: 5px solid #fff;
  box-shadow: var(--shadow-float);
}
.hero-mini img { width: 100%; height: 100%; object-fit: cover; }
.rating-card {
  position: absolute; left: 1rem; bottom: -1.1rem;
  display: flex; align-items: center; gap: .7rem;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: .6rem .9rem; text-decoration: none;
  box-shadow: 0 10px 30px rgba(0,32,80,.14);
}
.rating-num { font-family: var(--display); font-weight: 800; font-size: 1.6rem; color: var(--navy); }
.rating-detail { font-size: .74rem; color: var(--muted); line-height: 1.35; font-weight: 600; }
.stars { color: #e8961e; letter-spacing: .08em; }

/* ---------- trust strip ---------- */
.trust { border-bottom: 1px solid var(--line); background: #fff; }
.trust-row {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 1.2rem 2rem; padding: 1.6rem 0;
}
.trust-item strong { display: block; font-family: var(--display); color: var(--navy); font-size: 1.02rem; margin-bottom: .1rem; }
.trust-item span { font-size: .8rem; color: var(--muted); line-height: 1.45; }

/* ---------- sections ---------- */
.section { padding: clamp(3.8rem, 9vw, 6.5rem) 0; }
.section-soft { background: var(--soft); }
.section h2 {
  font-size: clamp(1.9rem, 5vw, 2.9rem);
  font-weight: 800; letter-spacing: -0.02em;
  margin-bottom: .8rem;
}
.section-head { max-width: 62ch; margin-bottom: clamp(2rem, 5vw, 3.2rem); }
.section-lead { color: var(--muted); font-size: 1.02rem; text-wrap: pretty; }

h2.brand-rule::after {
  content: ""; display: block;
  width: 64px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--orange-bright), var(--orange));
  margin-top: .95rem;
}

/* ---------- services scrolly ---------- */
.services-scrolly { display: grid; gap: 1.6rem; }
.svc-visual { align-self: start; } /* static on mobile; sticky only on desktop */
.svc-visual, .tech-media { will-change: top; }
.svc-frame {
  position: relative; overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--ring), var(--shadow-float);
  aspect-ratio: 16 / 7;
  background: var(--navy-deep);
}
.svc-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transform: scale(1.045);
  transition: opacity 1s cubic-bezier(.4, 0, .2, 1), transform 2.4s var(--ease);
}
.svc-img.is-on { opacity: 1; transform: scale(1); }

.service-table { border-top: 1px solid var(--line); }
.service-row {
  display: grid; gap: .3rem 2.5rem;
  padding: 1.15rem 0; border-bottom: 1px solid var(--line);
}
.service-row dt {
  font-family: var(--display); font-weight: 700; font-size: 1.12rem; color: var(--navy);
  transition: color .5s ease;
}
.service-row dt span { font-weight: 600; color: var(--muted); font-size: .9rem; }
.service-row dd { color: var(--muted); font-size: .95rem; max-width: 68ch; }
.service-row.active dt { color: var(--orange-dark); }

/* ---------- technology ---------- */
.tech-grid { display: grid; gap: 2.2rem; }
.tech-media { align-self: start; }
.tech-media img {
  width: 100%; object-fit: cover; aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  box-shadow: var(--ring), var(--shadow-float);
}
.tech-copy .section-lead { margin-bottom: 1.8rem; }
.tech-list { display: grid; gap: 1.5rem; }
.tech-item { border-top: 1px solid var(--line); padding-top: 1.1rem; }
.tech-item h3 { font-size: 1.1rem; margin-bottom: .35rem; }
.tech-item p { color: var(--muted); font-size: .94rem; max-width: 60ch; }

/* ---------- pathology ---------- */
.lab-grid { display: grid; gap: 2.2rem; align-items: center; }
.lab-copy .section-lead { margin-bottom: 1.6rem; }
.lab-media {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--ring), var(--shadow-float);
}
.lab-media img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- doctors ---------- */
.doc-grid { display: grid; gap: 1.4rem; max-width: 880px; }
.doc {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow .3s var(--ease), transform .3s var(--ease);
}
.doc:hover { box-shadow: var(--shadow-card); transform: translateY(-3px); }
.doc-photo { aspect-ratio: 1 / 1; overflow: hidden; background: var(--soft); }
.doc-photo img {
  width: 100%; height: 100%; object-fit: cover; object-position: center top;
  transition: transform 1.2s var(--ease);
}
.doc:hover .doc-photo img { transform: scale(1.035); }
.doc-photo-placeholder {
  display: grid; place-items: center;
  background: linear-gradient(150deg, var(--navy-soft), var(--navy));
}
.doc-photo-placeholder span {
  font-family: var(--display); font-weight: 800; font-size: 3.2rem;
  color: rgba(255,255,255,.85); letter-spacing: .04em;
}
.doc-info { padding: 1.3rem 1.5rem 1.5rem; }
.doc h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.doc-creds { color: var(--muted); font-size: .92rem; line-height: 1.6; }

/* ---------- reviews ---------- */
.review-cols { columns: 1; column-gap: 1.2rem; }
.review {
  break-inside: avoid; margin-bottom: 1.2rem;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.4rem 1.4rem 1.2rem;
  position: relative;
}
.review::before {
  content: "\201C";
  font-family: var(--display); font-weight: 800; font-size: 2rem; line-height: .8;
  color: var(--orange); display: block; margin-bottom: .45rem;
}
.review p { font-size: .95rem; color: var(--ink); margin-bottom: .9rem; }
.review footer { font-weight: 700; color: var(--navy); font-size: .85rem; }
.review-featured { background: linear-gradient(160deg, var(--navy) 0%, var(--navy-deep) 95%); border: 0; }
.review-featured::before { color: var(--orange-bright); }
.review-featured p { color: #e8eef8; font-size: 1.05rem; }
.review-featured footer { color: #fff; }
.review footer::before { content: "★★★★★ "; color: #e8961e; letter-spacing: .08em; font-weight: 400; }

/* ---------- visit ---------- */
.visit-grid { display: grid; gap: 2.2rem; }
.visit-info address { font-style: normal; color: var(--ink); margin-bottom: 1.1rem; font-size: 1.02rem; }
.contact-list { list-style: none; margin-bottom: 1.5rem; display: grid; gap: .4rem; }
.contact-list a { font-weight: 600; }
.visit-info h3 { font-size: 1.05rem; margin-bottom: .4rem; }
.hours { border-collapse: collapse; margin-bottom: 1.5rem; }
.hours th, .hours td { text-align: left; padding: .3rem 1.2rem .3rem 0; font-size: .94rem; }
.hours th { color: var(--muted); font-weight: 600; }
.visit-map iframe {
  width: 100%; aspect-ratio: 4 / 3; border: 0;
  border-radius: var(--radius-lg); box-shadow: var(--ring), var(--shadow-card);
}
.map-fallback { font-size: .8rem; color: var(--muted); margin-top: .6rem; }

/* ---------- booking ---------- */
.section-book { background: linear-gradient(165deg, var(--navy) 0%, var(--navy-deep) 92%); }
.book-grid { display: grid; gap: 2.2rem; }
.book-copy h2 { color: #fff; }
.book-copy p { color: #cfd9ea; max-width: 46ch; margin-bottom: 1rem; text-wrap: pretty; }
.form-hint { font-size: .88rem; color: #9fb0c8; }
.form-hint a { color: #ffc890; font-weight: 600; }
#bookForm {
  display: grid; gap: 1rem;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: var(--radius-lg);
  padding: clamp(1.2rem, 4vw, 2rem);
}
.field { display: grid; gap: .35rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field label { font-weight: 600; font-size: .88rem; color: #dbe3ef; }
.optional { font-weight: 400; color: #9fb0c8; }
.book-grid > *, #bookForm, .field { min-width: 0; }
.field input, .field select, .field textarea {
  font: inherit; color: var(--ink);
  padding: .72rem .85rem; border-radius: 12px; border: 1.5px solid transparent;
  background: #fff; width: 100%; min-width: 0; max-width: 100%;
}
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: none; border-color: var(--orange-bright);
  box-shadow: 0 0 0 3px rgba(240,124,36,.25);
}
.form-error { color: #ffc2a1; font-weight: 600; font-size: .9rem; }
.form-actions { display: flex; flex-wrap: wrap; gap: .8rem; }

/* ---------- footer ---------- */
.site-footer {
  background: var(--navy-deep); color: #b9c6da; font-size: .88rem;
  border-top: 3px solid var(--orange);
}
.foot-grid { display: grid; gap: 1.6rem; padding: 2.6rem 0 1.5rem; }
.foot-brand { font-family: var(--display); font-size: 1.1rem; }
.foot-brand strong { color: #fff; } .foot-brand em { color: var(--orange-bright); font-style: normal; }
.site-footer a { color: #e8edf5; }
.site-footer strong { color: #fff; }
.foot-note { border-top: 1px solid rgba(255,255,255,.12); padding: 1rem 0 1.2rem; font-size: .78rem; }

/* ---------- mobile action bar ---------- */
.action-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: var(--z-actionbar);
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.action-bar a {
  display: flex; flex-direction: column; align-items: center; gap: .15rem;
  padding: .5rem 0 .55rem; text-decoration: none;
  color: var(--navy); font-size: .68rem; font-weight: 600;
}
.action-bar .action-book { color: var(--orange-dark); }

/* ---------- tablet ---------- */
@media (min-width: 640px) {
  .doc-grid { grid-template-columns: 1fr 1fr; }
  .field-row { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 700px) {
  .trust-row { grid-template-columns: repeat(4, 1fr); }
  .trust-item + .trust-item { border-left: 1px solid var(--line); padding-left: 1.6rem; }
  .visit-grid { grid-template-columns: 1fr 1.25fr; align-items: center; gap: 2.5rem; }
}

/* ---------- desktop ---------- */
@media (min-width: 720px) {
  .service-row { grid-template-columns: 280px 1fr; }
  .review-cols { columns: 2; }
}

@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .action-bar { display: none; }
  .nav-toggle { display: none; }
  .main-nav { display: flex; align-items: center; gap: 1.5rem; margin-left: auto; }
  .main-nav a { text-decoration: none; font-weight: 600; font-size: .92rem; border: 0; padding: 0; transition: color .2s var(--ease); }
  .main-nav a:hover { color: var(--orange-dark); }
  .main-nav a.nav-cta {
    background: linear-gradient(180deg, var(--orange-bright), var(--orange));
    color: #fff; padding: .5rem 1rem; border-radius: 999px;
  }
  .main-nav a.nav-cta:hover { color: #fff; filter: brightness(1.06); }
  .header-call { margin-left: 0; }

  .hero-grid { grid-template-columns: 1.05fr .95fr; align-items: center; gap: 3.5rem; }
  .hero-media { margin-bottom: 2.4rem; }
  .hero-mini { display: block; }
  .trust-row { grid-template-columns: repeat(4, 1fr); }
  .services-scrolly { grid-template-columns: .95fr 1.05fr; gap: 3.2rem; align-items: start; }
  .svc-visual {
    position: sticky; top: 96px; z-index: 1; /* refined at runtime to pin at viewport centre */
    margin-left: calc((100vw - min(100vw - 3rem, 1120px)) / -2);
  }
  .svc-frame {
    aspect-ratio: 4 / 3; width: 100%;
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  }
  .tech-grid { grid-template-columns: .9fr 1.1fr; gap: 3.5rem; align-items: start; }
  .tech-media { position: sticky; top: 96px; }
  .lab-grid { grid-template-columns: 1fr 1.05fr; gap: 3.5rem; }
  .lab-media {
    margin-right: calc((100vw - min(100vw - 3rem, 1120px)) / -2);
    border-radius: var(--radius-lg) 0 0 var(--radius-lg);
  }
  .doc-grid { grid-template-columns: 1fr 1fr; }
  .review-cols { columns: 3; }
  .visit-grid { grid-template-columns: 1fr 1.25fr; align-items: center; gap: 3rem; }
  .book-grid { grid-template-columns: .8fr 1.2fr; gap: 3.5rem; align-items: start; }
}

/* ---------- very small phones ---------- */
@media (max-width: 430px) {
  .header-call span { display: none; }
  .header-call { padding: .55rem .65rem; }
  .wrap { width: min(100% - 2rem, 1120px); }
  .brand-word { font-size: .94rem; }
  .hero h1 { font-size: clamp(2.15rem, 10vw, 2.5rem); }
  .btn { padding: .8rem 1.15rem; font-size: .9rem; }
  .rating-card { left: .7rem; bottom: -.9rem; padding: .5rem .75rem; }
  .svc-frame { border-radius: var(--radius); }
}

/* ---------- motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html.js [data-reveal] { opacity: 1; transform: none; }
}
