/* ─────────────────────────────────────────────────────────────
   Dr. Hari Kishan Gonuguntla — design system
   Palette   : petrol pine + porcelain + Yashoda orange
   Type      : Fraunces (display) · Public Sans (body) · IBM Plex Mono (data)
   Signature : spirometry breath-line + arched portrait + chart vitals
   ───────────────────────────────────────────────────────────── */

:root {
  --ink:        #0f2b3d;
  --pine:       #12455e;
  --pine-deep:  #0c3349;
  --accent:     #f26b21;
  --accent-dark:#d4560f;
  --porcelain:  #f5f8fa;
  --surface:    #ffffff;
  --mist:       #dce6ec;
  --muted:      #52697a;
  --tint:       #edf3f6;

  --font-display: "Fraunces", Georgia, serif;
  --font-body:    "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, monospace;

  --radius:    14px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(15, 43, 61, .05), 0 2px 8px rgba(15, 43, 61, .06);
  --shadow-md: 0 10px 30px rgba(15, 43, 61, .12);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

section[id], header[id] { scroll-margin-top: 96px; }

::selection { background: rgba(242, 107, 33, .25); }

a { color: var(--accent-dark); }
a:hover { color: var(--accent); }

/* ── Reveal-on-scroll (JS adds .in) ─────────────────────────── */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation: none !important; }
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn { border-radius: 10px; font-weight: 600; letter-spacing: .01em; }
.btn-accent {
  background: var(--accent); border: 1px solid var(--accent); color: #fff;
  box-shadow: 0 6px 18px rgba(242, 107, 33, .32);
  transition: background .2s ease, transform .15s ease, box-shadow .2s ease;
}
.btn-accent:hover, .btn-accent:focus {
  background: var(--accent-dark); border-color: var(--accent-dark); color: #fff;
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent; border: 1.5px solid var(--mist); color: var(--pine);
}
.btn-ghost:hover { border-color: var(--pine); color: var(--pine); background: var(--tint); }
.btn-ghost-dark { border: 1.5px solid var(--pine); color: var(--pine); background: transparent; }
.btn-ghost-dark:hover { background: var(--pine); color: #fff; }
.btn-whatsapp { background: #1faa53; border-color: #1faa53; color: #fff; font-weight: 600; }
.btn-whatsapp:hover { background: #178a43; border-color: #178a43; color: #fff; }
.btn:focus-visible { outline: 3px solid rgba(242, 107, 33, .45); outline-offset: 2px; }

/* ── Topbar ─────────────────────────────────────────────────── */
.topbar {
  background: var(--pine-deep); color: #cfe0e9;
  font-size: .8rem; padding: .45rem 0;
}
.topbar i { color: var(--accent); margin-right: .35rem; }
.topbar-phone { color: #fff; text-decoration: none; font-weight: 600; }
.topbar-phone:hover { color: var(--accent); }

/* ── Navbar ─────────────────────────────────────────────────── */
.navbar-main {
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  padding: .7rem 0;
  transition: border-color .25s ease, box-shadow .25s ease;
}
.navbar-main.scrolled { border-bottom-color: var(--mist); box-shadow: var(--shadow-sm); }
.navbar-brand { display: flex; align-items: center; gap: .7rem; }
.brand-logo {
  width: 44px; height: 44px; display: block; flex: 0 0 auto;
  border-radius: 11px;
  filter: drop-shadow(0 2px 6px rgba(15, 43, 61, .18));
}
.brand-text { line-height: 1.15; font-family: var(--font-display); font-weight: 600; color: var(--ink); font-size: 1.02rem; }
.brand-text span { color: var(--pine); }
.brand-text small {
  display: block; font-family: var(--font-mono); font-size: .58rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.navbar-main .nav-link {
  color: var(--ink); font-weight: 500; font-size: .93rem; padding: .5rem .85rem; border-radius: 8px;
}
.navbar-main .nav-link:hover { color: var(--accent-dark); background: var(--tint); }
.navbar-main .nav-link.active { color: var(--accent-dark); }
.btn-nav { padding: .55rem 1.1rem; font-size: .9rem; }

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  position: relative;
  background:
    radial-gradient(900px 420px at 88% -10%, rgba(242, 107, 33, .10), transparent 60%),
    radial-gradient(700px 420px at -10% 110%, rgba(18, 69, 94, .08), transparent 60%),
    var(--porcelain);
  padding: 4.5rem 0 0;
  overflow: hidden;
}
.eyebrow {
  font-family: var(--font-mono); font-size: .72rem; letter-spacing: .18em;
  text-transform: uppercase; color: var(--accent-dark); margin-bottom: 1rem;
}
.eyebrow::before {
  content: ""; display: inline-block; width: 26px; height: 2px;
  background: var(--accent); vertical-align: middle; margin-right: .6rem;
}
.eyebrow-light { color: #ffb98a; }
.hero-name {
  font-family: var(--font-display); font-weight: 600; color: var(--ink);
  font-size: clamp(2.4rem, 5vw, 3.9rem); line-height: 1.06; letter-spacing: -.01em;
}
.hero-cred { color: var(--muted); font-size: .92rem; margin: 1.1rem 0 .4rem; max-width: 56ch; }
.hero-desig { font-weight: 600; color: var(--pine); margin-bottom: .9rem; }
.hero-intro { color: var(--muted); font-size: 1.04rem; max-width: 54ch; }
.cta-row { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 1.4rem; }
.lang-chips { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.chip-label { font-size: .8rem; color: var(--muted); margin-right: .2rem; }
.chip {
  background: var(--surface); border: 1px solid var(--mist); color: var(--pine);
  font-size: .78rem; font-weight: 600; padding: .28rem .7rem; border-radius: 999px;
}

/* Portrait */
.portrait-wrap { position: relative; max-width: 330px; margin: 0 auto; }
.portrait-arch {
  position: relative;
  border-radius: 165px 165px var(--radius-lg) var(--radius-lg);
  background: linear-gradient(180deg, #ffffff 0%, #eef4f7 100%);
  border: 1px solid var(--mist);
  box-shadow: var(--shadow-md);
  padding: 14px;
}
.portrait-arch::before {
  content: ""; position: absolute; inset: -14px 14px 14px -14px;
  border-radius: inherit; border: 2px solid rgba(18, 69, 94, .18); z-index: -1;
}
.portrait-arch img {
  width: 100%; height: auto; display: block;
  border-radius: 150px 150px 12px 12px;
  background: #fff;
}
.float-chip {
  position: absolute; display: flex; align-items: center; gap: .6rem;
  background: var(--surface); border: 1px solid var(--mist); border-radius: 12px;
  box-shadow: var(--shadow-md); padding: .6rem .85rem;
}
.float-chip i { font-size: 1.15rem; color: var(--accent); }
.float-chip strong { display: block; font-size: .82rem; color: var(--ink); line-height: 1.2; }
.float-chip small { display: block; font-size: .68rem; color: var(--muted); }
.float-chip-top { top: 12%; right: -8%; }
.float-chip-bottom { bottom: 8%; left: -10%; }

/* Vitals strip — patient-chart header */
.vitals {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
  margin: 3rem 0 0; overflow: hidden;
}
.vital-cell { padding: 1.05rem 1.3rem; border-left: 1px solid var(--mist); }
.vital-cell:first-child { border-left: 0; }
.vital-label {
  display: block; font-family: var(--font-mono); font-size: .62rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-bottom: .3rem;
}
.vital-value { font-weight: 600; color: var(--pine); font-size: .92rem; }

/* Breath-line signature */
.breathline { color: var(--accent); margin-top: 2.6rem; opacity: .85; }
.breathline svg { display: block; width: 100%; height: 64px; }
.breathline path {
  stroke-dasharray: 2400; stroke-dashoffset: 2400;
  animation: breathe 3.2s ease-out .3s forwards;
}
@keyframes breathe { to { stroke-dashoffset: 0; } }

/* ── Stats band ─────────────────────────────────────────────── */
.stats-band { background: var(--surface); border-bottom: 1px solid var(--mist); padding: 2.6rem 0; }
.stat-num {
  font-family: var(--font-display); font-weight: 600; color: var(--pine);
  font-size: 2.5rem; line-height: 1; display: block;
}
.stat-num sup { color: var(--accent); font-size: 1.2rem; top: -0.8em; }
.stat-label { display: block; color: var(--muted); font-size: .84rem; margin-top: .45rem; max-width: 22ch; margin-inline: auto; }
.stat + .stat { position: relative; }
@media (min-width: 992px) {
  .stats-band .stat:not(:first-child)::before {
    content: ""; position: absolute; left: 0; top: 12%; height: 76%;
    width: 1px; background: var(--mist);
  }
}

/* ── Sections ───────────────────────────────────────────────── */
.section { padding: 5.5rem 0; }
.section-tint { background: var(--porcelain); }
.section-head { max-width: 640px; margin-bottom: 3rem; }
.section-head-light { color: #fff; }
.sec-title {
  font-family: var(--font-display); font-weight: 600; color: var(--ink);
  font-size: clamp(1.7rem, 3.2vw, 2.4rem); line-height: 1.15; letter-spacing: -.01em;
}
.sec-title em { font-style: italic; color: var(--accent-dark); }
.section-head-light .sec-title { color: #fff; }
.sec-sub { color: var(--muted); margin-top: .8rem; }
.section-head-light .sec-sub { color: #c4d7e1; }

/* ── About ──────────────────────────────────────────────────── */
.about-lead {
  font-family: var(--font-display); font-size: 1.28rem; line-height: 1.5;
  color: var(--pine); font-weight: 500;
}
.about-body { color: var(--muted); line-height: 1.8; }
.about-side { display: grid; gap: 1rem; }
.about-side-item {
  display: flex; gap: .95rem; background: var(--porcelain);
  border: 1px solid var(--mist); border-radius: var(--radius); padding: 1rem 1.1rem;
}
.about-side-item i { color: var(--accent); font-size: 1.25rem; margin-top: .1rem; }
.about-side-item strong { display: block; color: var(--ink); font-size: .92rem; }
.about-side-item span { color: var(--muted); font-size: .85rem; line-height: 1.55; }

/* ── Focus strip (special interests) ────────────────────────── */
.focus-strip {
  background: linear-gradient(120deg, var(--pine-deep), var(--pine));
  padding: 3rem 0;
}
.focus-grid { display: flex; flex-wrap: wrap; gap: .7rem; }
.focus-item {
  border: 1px solid rgba(255, 255, 255, .22); color: #eaf3f7;
  padding: .55rem 1.05rem; border-radius: 999px; font-size: .86rem; font-weight: 500;
  transition: background .2s ease, border-color .2s ease;
}
.focus-item:hover { background: rgba(242, 107, 33, .18); border-color: rgba(242, 107, 33, .6); }

/* ── Service cards ──────────────────────────────────────────── */
.svc-card {
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: var(--radius-lg); padding: 1.7rem 1.6rem; height: 100%;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.svc-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: transparent; }
.svc-icon {
  width: 52px; height: 52px; border-radius: 14px 14px 14px 4px;
  background: rgba(242, 107, 33, .12); color: var(--accent-dark);
  display: grid; place-items: center; font-size: 1.45rem; margin-bottom: 1.1rem;
}
.svc-card h3 { font-family: var(--font-display); font-size: 1.12rem; font-weight: 600; color: var(--ink); }
.svc-card ul { list-style: none; margin: .9rem 0 0; padding: 0; }
.svc-card li {
  position: relative; padding: .3rem 0 .3rem 1.3rem; color: var(--muted); font-size: .9rem;
}
.svc-card li::before {
  content: ""; position: absolute; left: 0; top: .78em;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); opacity: .75;
}

/* ── Timelines ──────────────────────────────────────────────── */
.tl-heading {
  font-family: var(--font-display); font-size: 1.15rem; font-weight: 600;
  color: var(--pine); margin-bottom: 1.4rem;
}
.tl-heading i { color: var(--accent); }
.timeline { position: relative; padding-left: 0; }
.timeline::before {
  content: ""; position: absolute; left: 34px; top: 8px; bottom: 8px;
  width: 2px; background: var(--mist);
}
.tl-item { position: relative; display: flex; gap: 1.15rem; padding: .65rem 0; }
.tl-year {
  flex: 0 0 68px; text-align: center; z-index: 1;
  font-family: var(--font-mono); font-size: .74rem; font-weight: 500;
  background: var(--surface); border: 1.5px solid var(--mist); color: var(--pine);
  border-radius: 999px; padding: .3rem 0; height: fit-content; margin-top: .1rem;
}
.tl-current .tl-year { background: var(--accent); border-color: var(--accent); color: #fff; }
.tl-body strong { display: block; color: var(--ink); font-size: .96rem; }
.tl-body span { color: var(--muted); font-size: .86rem; }
.section-tint .tl-year { background: var(--porcelain); }
.section-tint .tl-current .tl-year { background: var(--accent); }

/* ── Awards & memberships ───────────────────────────────────── */
.award-card {
  display: flex; gap: 1rem; background: var(--surface); border: 1px solid var(--mist);
  border-left: 4px solid var(--accent); border-radius: var(--radius);
  padding: 1.15rem 1.25rem; margin-bottom: 1rem; box-shadow: var(--shadow-sm);
}
.award-card i { font-size: 1.5rem; color: var(--accent); }
.award-card strong { display: block; color: var(--ink); font-size: .95rem; line-height: 1.4; }
.award-card span { color: var(--muted); font-size: .84rem; }
.member-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.member-item {
  background: var(--surface); border: 1px solid var(--mist); border-radius: 12px;
  padding: .85rem 1rem; font-size: .88rem; font-weight: 500; color: var(--ink);
}
.member-item span {
  display: block; font-family: var(--font-mono); font-size: .66rem;
  letter-spacing: .1em; text-transform: uppercase; color: var(--accent-dark); margin-top: .25rem;
}

/* ── Publications ───────────────────────────────────────────── */
.pub-list { list-style: none; counter-reset: pub; margin: 0; padding: 0; }
.pub-list[start="4"] { counter-reset: pub 3; }
.pub-item {
  counter-increment: pub; position: relative;
  padding: .95rem 0 .95rem 3rem; border-bottom: 1px solid var(--mist);
}
.pub-item::before {
  content: counter(pub, decimal-leading-zero);
  position: absolute; left: 0; top: 1rem;
  font-family: var(--font-display); font-style: italic; font-weight: 500;
  color: var(--accent); font-size: 1.15rem;
}
.pub-item strong { display: block; color: var(--ink); font-size: .93rem; line-height: 1.45; }
.pub-item span { color: var(--muted); font-size: .83rem; }

/* ── Book section ───────────────────────────────────────────── */
.book-section {
  background:
    radial-gradient(700px 380px at 105% 0%, rgba(242, 107, 33, .16), transparent 60%),
    linear-gradient(150deg, var(--pine-deep), var(--pine));
  padding: 5.5rem 0;
}
.book-info {
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .16);
  border-radius: var(--radius-lg); padding: 1.8rem 1.6rem; color: #e8f1f5; height: 100%;
}
.book-info h3 { font-family: var(--font-display); font-size: 1.2rem; color: #fff; margin-bottom: 1.2rem; }
.book-info-item { display: flex; gap: .9rem; margin-bottom: 1.15rem; }
.book-info-item i { color: var(--accent); font-size: 1.1rem; margin-top: .15rem; }
.book-info-item strong { display: block; color: #fff; font-size: .92rem; }
.book-info-item span { color: #bcd2dd; font-size: .85rem; line-height: 1.55; }
.book-info-item a { color: #ffd3b5; text-decoration: none; font-weight: 600; }
.book-info-item a:hover { color: #fff; }
.book-note {
  margin: 1.3rem 0 0; padding: .85rem 1rem; border-radius: 10px;
  background: rgba(242, 107, 33, .14); border: 1px solid rgba(242, 107, 33, .35);
  color: #ffe1cd; font-size: .8rem; line-height: 1.55;
}
.book-note i { color: var(--accent); }

.book-form-card {
  background: var(--surface); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md); padding: 2rem 1.9rem;
}
.form-label { font-weight: 600; font-size: .86rem; color: var(--ink); }
.req { color: var(--accent-dark); }
.form-hint { font-size: .76rem; color: var(--muted); margin-top: .3rem; }
.form-control, .form-select {
  border-color: var(--mist); border-radius: 10px; padding: .6rem .85rem; font-size: .95rem;
}
.form-control:focus, .form-select:focus {
  border-color: var(--accent); box-shadow: 0 0 0 .2rem rgba(242, 107, 33, .18);
}
.input-group-text { background: var(--porcelain); border-color: var(--mist); font-weight: 600; color: var(--muted); }
.pill-radios { display: flex; flex-wrap: wrap; gap: .6rem; }
.pill {
  border: 1.5px solid var(--mist); border-radius: 999px; padding: .55rem 1.1rem;
  font-size: .88rem; font-weight: 500; color: var(--muted); cursor: pointer;
  transition: all .18s ease;
}
.btn-check:checked + .pill {
  background: var(--pine); border-color: var(--pine); color: #fff;
}
.btn-check:focus-visible + .pill { outline: 3px solid rgba(242, 107, 33, .45); outline-offset: 2px; }
.hp-field { position: absolute !important; left: -9999px; top: -9999px; height: 0; overflow: hidden; }
.privacy-note { font-size: .76rem; color: var(--muted); text-align: center; margin: .8rem 0 0; }

/* Success panel */
.success-panel { text-align: center; padding: 2.5rem 1rem; }
.success-panel > i { font-size: 3rem; color: #1faa53; }
.success-panel h3 { font-family: var(--font-display); margin: .8rem 0 .4rem; color: var(--ink); }
.success-panel p { color: var(--muted); margin-bottom: .3rem; }
.success-ref {
  font-family: var(--font-mono); font-size: 1.35rem; font-weight: 500;
  color: var(--pine); background: var(--porcelain); border: 1px dashed var(--mist);
  display: inline-block; padding: .5rem 1.3rem; border-radius: 10px; margin: .4rem 0 .9rem;
}
.success-msg { max-width: 44ch; margin-inline: auto; }

/* ── Footer ─────────────────────────────────────────────────── */
.footer-logo { display: block; margin-bottom: .9rem; border-radius: 11px; }
.site-footer { background: var(--pine-deep); color: #a9c2cf; padding: 3.5rem 0 0; }
.footer-brand { font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; color: #fff; }
.footer-about { font-size: .88rem; line-height: 1.7; margin-top: .8rem; max-width: 46ch; }
.footer-reg { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .08em; color: #7fa0b0; }
.footer-head {
  font-family: var(--font-mono); font-size: .68rem; letter-spacing: .16em;
  text-transform: uppercase; color: #7fa0b0; margin-bottom: 1rem;
}
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: .55rem; font-size: .88rem; }
.footer-links a { color: #cfe0e9; text-decoration: none; }
.footer-links a:hover { color: var(--accent); }
.footer-contact li { display: flex; gap: .6rem; line-height: 1.55; }
.footer-contact i { color: var(--accent); margin-top: .2rem; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 2.6rem; padding: 1.2rem 0;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem;
  font-size: .76rem; color: #7fa0b0;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 991.98px) {
  .hero { padding-top: 3rem; }
  .vitals { grid-template-columns: 1fr 1fr; }
  .vital-cell:nth-child(3) { border-left: 0; }
  .vital-cell:nth-child(n+3) { border-top: 1px solid var(--mist); }
  .float-chip-top { right: 0; }
  .float-chip-bottom { left: 0; }
}
@media (max-width: 575.98px) {
  .vitals { grid-template-columns: 1fr; }
  .vital-cell { border-left: 0; }
  .vital-cell + .vital-cell { border-top: 1px solid var(--mist); }
  .member-grid { grid-template-columns: 1fr; }
  .book-form-card { padding: 1.4rem 1.1rem; }
  .cta-row .btn { width: 100%; }
  .float-chip { position: static; margin-top: .8rem; width: fit-content; }
  .portrait-wrap { display: flex; flex-direction: column; align-items: center; }
}
