/* ==========================================================================
   VishwaShanti Homoeo & Research Clinic — Design tokens & base stylesheet
   Hand-written CSS with custom properties (PRD Section 3), no build step.
   ========================================================================== */

:root {
  --color-primary: #1E7A4C;
  --color-primary-dark: #14331F;
  --color-primary-light: #E3F3E6;
  --color-accent: #5EBF7C;
  --color-bg: #FFFFFF;
  --color-surface: #FFFFFF;
  --color-text: #14231A;
  --color-text-muted: #5C6F63;
  --color-border: #D7EADB;
  --color-whatsapp: #25D366;

  --font-heading: 'Fraunces', 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(43, 33, 30, 0.08);
  --shadow-md: 0 6px 20px rgba(43, 33, 30, 0.10);
  --shadow-lg: 0 16px 40px rgba(43, 33, 30, 0.14);
  --container-w: 1180px;
  --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--color-primary-dark);
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 4vw, 3rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; color: var(--color-text); }
.text-muted { color: var(--color-text-muted); }

.container { max-width: var(--container-w); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section-tight { padding: 40px 0; }
.section-light { background: var(--color-primary-light); }
.section-surface { background: var(--color-surface); }
.eyebrow {
  display: inline-block;
  color: var(--color-accent);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
  margin-bottom: 10px;
}
.section-head { max-width: 680px; margin: 0 auto 40px; text-align: center; }
.section-head p { color: var(--color-text-muted); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px) scale(1.02); }
.btn-primary { background: var(--color-primary); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--color-primary-dark); box-shadow: var(--shadow-md); }
.btn-accent { background: var(--color-accent); color: #fff; }
.btn-accent:hover { filter: brightness(1.08); box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; border-color: var(--color-primary); color: var(--color-primary); }
.btn-outline:hover { background: var(--color-primary); color: #fff; }
.btn-whatsapp { background: var(--color-whatsapp); color: #fff; }
.btn-whatsapp:hover { filter: brightness(1.05); box-shadow: var(--shadow-md); }
.btn-sm { padding: 9px 18px; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 249, 246, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
  transition: box-shadow 200ms ease, height 200ms ease;
  height: var(--header-h);
  display: flex;
  align-items: center;
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); height: 62px; }
.header-inner { display: flex; align-items: center; justify-content: space-between; width: 100%; flex-wrap: nowrap; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-heading); font-weight: 700; color: var(--color-primary-dark); font-size: 1.05rem; flex-shrink: 0; min-width: 0; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 10px;
  background: var(--color-primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading); font-weight: 700; font-size: 1.1rem;
  flex-shrink: 0;
}
.brand-word { display: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (min-width: 640px) { .brand-word { display: inline; } }
@media (min-width: 640px) and (max-width: 1279px) { .brand-word { max-width: 150px; } }

.main-nav { display: none; min-width: 0; }
.main-nav ul { display: flex; gap: 18px; align-items: center; flex-wrap: nowrap; }
.main-nav a { font-weight: 500; font-size: 0.88rem; color: var(--color-text); transition: color 150ms; position: relative; white-space: nowrap; }
.main-nav a:hover { color: var(--color-primary); }
@media (min-width: 1024px) { .main-nav { display: block; } }

.header-cta { display: flex; align-items: center; gap: 10px; }
.header-cta .btn-sm { display: none; }
@media (min-width: 480px) { .header-cta .btn-sm { display: inline-flex; } }

.hamburger {
  display: flex; flex-direction: column; gap: 5px; justify-content: center;
  width: 40px; height: 40px; border: 1px solid var(--color-border); border-radius: 8px;
  background: var(--color-surface); cursor: pointer; padding: 0;
}
@media (min-width: 1024px) { .hamburger { display: none; } }
.hamburger span { width: 20px; height: 2px; background: var(--color-primary-dark); margin: 0 auto; transition: 200ms; }

.mobile-nav {
  position: fixed; inset: var(--header-h) 0 0 0; background: var(--color-bg); z-index: 99;
  padding: 24px 20px; overflow-y: auto;
}
.mobile-nav ul { display: flex; flex-direction: column; gap: 4px; }
.mobile-nav a { display: block; padding: 14px 6px; font-size: 1.05rem; font-weight: 600; border-bottom: 1px solid var(--color-border); }
.mobile-nav .btn { margin-top: 20px; }

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 64px 0 56px;
  background:
    radial-gradient(600px 300px at 85% -10%, rgba(184,134,11,0.10), transparent),
    radial-gradient(500px 260px at -5% 100%, rgba(139,29,26,0.10), transparent),
    var(--color-bg);
}
.hero-grid { display: grid; gap: 40px; align-items: center; }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.1fr 0.9fr; } }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--color-primary-light); color: var(--color-primary-dark);
  padding: 7px 16px; border-radius: 999px; font-weight: 600; font-size: 0.82rem; margin-bottom: 18px;
}
.hero h1 { margin-bottom: 18px; }
.hero-sub { font-size: 1.08rem; color: var(--color-text-muted); max-width: 560px; margin-bottom: 28px; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.hero-timings {
  display: flex; flex-wrap: wrap; gap: 10px 24px; font-size: 0.88rem; color: var(--color-text-muted);
  border-top: 1px solid var(--color-border); padding-top: 18px;
}
.hero-timings strong { color: var(--color-text); }

.hero-art {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  aspect-ratio: 4/3; background: linear-gradient(135deg, var(--color-primary-light), #fff 70%);
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
}
.hero-art .blob {
  position: absolute; border-radius: 50%; filter: blur(2px); opacity: 0.5;
  animation: float 9s ease-in-out infinite;
}
.hero-art .blob.b1 { width: 180px; height: 180px; background: var(--color-accent); top: -40px; left: -40px; opacity: 0.25; }
.hero-art .blob.b2 { width: 140px; height: 140px; background: var(--color-primary); bottom: -30px; right: -20px; opacity: 0.2; animation-delay: -3s; }
.hero-art .mark { font-family: var(--font-heading); font-size: 5rem; color: var(--color-primary); font-weight: 700; z-index: 1; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-18px); } }

.illustration { position: relative; z-index: 1; width: 46%; max-width: 220px; height: auto; filter: drop-shadow(0 10px 18px rgba(20, 51, 31, 0.15)); }
.illustration-dropper { animation: float 7s ease-in-out infinite; }
.illustration .drop { animation: drip 2.2s ease-in infinite; transform-origin: center; }
@keyframes drip { 0% { transform: translateY(0); opacity: 1; } 65% { opacity: 1; } 100% { transform: translateY(28px); opacity: 0; } }
.illustration .granule { animation: pulseDot 2.6s ease-in-out infinite; transform-origin: center; }
.illustration .granule:nth-child(3) { animation-delay: 0.4s; }
.illustration .granule:nth-child(4) { animation-delay: 0.8s; }
@keyframes pulseDot { 0%, 100% { transform: scale(1); opacity: 0.8; } 50% { transform: scale(1.3); opacity: 1; } }
.stat-chip {
  position: absolute; left: 18px; bottom: 18px; z-index: 1;
  background: var(--color-primary-dark); color: #fff; font-family: var(--font-heading); font-weight: 700;
  font-size: 1.1rem; padding: 8px 16px; border-radius: 999px; box-shadow: var(--shadow-md);
}

/* Trust strip */
.trust-strip { background: var(--color-primary-dark); color: #fff; padding: 34px 0; }
.trust-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; text-align: center; }
@media (min-width: 768px) { .trust-grid { grid-template-columns: repeat(4, 1fr); } }
.trust-item .stat { font-family: var(--font-heading); font-size: 2.1rem; font-weight: 700; color: #fff; }
.trust-item .label { font-size: 0.82rem; color: rgba(255,255,255,0.78); margin-top: 4px; }

/* Cards */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }
.grid > [data-reveal]:nth-child(2) { transition-delay: 80ms; }
.grid > [data-reveal]:nth-child(3) { transition-delay: 160ms; }
.grid > [data-reveal]:nth-child(4) { transition-delay: 240ms; }

.card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-md); padding: 26px; box-shadow: var(--shadow-sm);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.card:hover { transform: translateY(-4px) scale(1.01); box-shadow: var(--shadow-md); }
.card:hover .card-icon { transform: scale(1.1) rotate(-4deg); }
.card-icon {
  transition: transform 250ms ease;
  width: 48px; height: 48px; border-radius: var(--radius-sm); background: var(--color-primary-light);
  display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin-bottom: 16px;
}
.card h3 { margin-bottom: 8px; }
.card .card-link { color: var(--color-primary); font-weight: 600; font-size: 0.88rem; display: inline-flex; align-items: center; gap: 4px; margin-top: 10px; }
.card .card-link:hover { color: var(--color-primary-dark); }

.badge {
  display: inline-block; background: var(--color-primary-light); color: var(--color-primary-dark);
  padding: 5px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 600;
}

/* Testimonials */
.testi-track { display: flex; overflow: hidden; }
.testi-slide { min-width: 100%; padding: 4px; transition: transform 400ms ease; }
@media (min-width: 860px) { .testi-slide { min-width: 50%; } }
.testi-card {
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  padding: 28px; margin: 8px; box-shadow: var(--shadow-sm); height: 100%;
}
.testi-stars { color: var(--color-accent); letter-spacing: 2px; margin-bottom: 12px; }

/* Image slider (reuses .testi-track carousel engine) */
.slider-card {
  aspect-ratio: 16/9; margin: 8px; border-radius: var(--radius-lg); overflow: hidden;
  background: linear-gradient(135deg, var(--color-primary-light), var(--color-border));
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  border: 1px solid var(--color-border); box-shadow: var(--shadow-sm);
}
.slider-ph { font-size: 2.6rem; }
.slider-label { font-weight: 600; color: var(--color-primary-dark); font-size: 0.95rem; }
.testi-name { font-weight: 700; margin-top: 14px; color: var(--color-primary-dark); }
.testi-controls { display: flex; justify-content: center; gap: 12px; margin-top: 20px; }
.testi-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--color-border); cursor: pointer; border: none; }
.testi-dot.active { background: var(--color-primary); }

/* FAQ accordion */
.accordion-item { border-bottom: 1px solid var(--color-border); }
.accordion-btn {
  width: 100%; text-align: left; background: none; border: none; cursor: pointer;
  padding: 20px 4px; display: flex; justify-content: space-between; align-items: center;
  font-weight: 600; font-size: 1rem; color: var(--color-text);
}
.accordion-btn .plus { transition: transform 200ms ease; color: var(--color-primary); font-size: 1.3rem; flex-shrink: 0; margin-left: 12px; }
.accordion-btn[aria-expanded="true"] .plus { transform: rotate(45deg); }
.accordion-panel { overflow: hidden; max-height: 0; transition: max-height 300ms ease; }
.accordion-panel-inner { padding: 0 4px 20px; color: var(--color-text-muted); }

/* Footer */
.site-footer { background: var(--color-primary-dark); color: rgba(255,255,255,0.85); padding: 60px 0 24px; }
.site-footer .badge { background: rgba(255,255,255,0.15); color: #fff; border: 1px solid rgba(255,255,255,0.35); }
.site-footer h4 { color: #fff; font-family: var(--font-body); font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 16px; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: 1fr; margin-bottom: 40px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-grid a, .footer-grid p { color: rgba(255,255,255,0.75); font-size: 0.9rem; }
.footer-grid ul li { margin-bottom: 10px; }
.footer-grid a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.15); padding-top: 20px; font-size: 0.82rem; color: rgba(255,255,255,0.6); }
.footer-bottom strong { color: rgba(255,255,255,0.85); }
.social-row { display: flex; gap: 12px; }
.social-row a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; }
.social-row a:hover { background: var(--color-accent); }

/* Floating WhatsApp */
.whatsapp-float {
  position: fixed; bottom: 22px; right: 22px; z-index: 90;
  width: 58px; height: 58px; border-radius: 50%; background: var(--color-whatsapp);
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-lg);
  transition: transform 200ms ease;
}
.whatsapp-float:hover { transform: scale(1.08); }

/* Breadcrumb */
.breadcrumb { font-size: 0.85rem; color: var(--color-text-muted); padding: 18px 0; }
.breadcrumb a:hover { color: var(--color-primary); }
.breadcrumb .sep { margin: 0 6px; }

/* Page hero (interior pages) */
.page-hero { padding: 44px 0; background: var(--color-primary-light); border-bottom: 1px solid var(--color-border); }
.page-hero .eyebrow { color: var(--color-primary); }
.page-hero h1 { margin-bottom: 10px; }

/* Scroll reveal */
[data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity 500ms ease, transform 500ms ease; }
[data-reveal].is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .hero-art .blob, .illustration, .illustration .drop, .illustration .granule { animation: none; }
  .card:hover, .card:hover .card-icon { transform: none; }
  html { scroll-behavior: auto; }
}

/* Gallery */
.gallery-grid { columns: 1; gap: 16px; }
@media (min-width: 640px) { .gallery-grid { columns: 2; } }
@media (min-width: 960px) { .gallery-grid { columns: 3; } }
.gallery-item { break-inside: avoid; margin-bottom: 16px; border-radius: var(--radius-md); overflow: hidden; cursor: pointer; border: 1px solid var(--color-border); }
.gallery-item .ph { aspect-ratio: 4/3; background: linear-gradient(135deg, var(--color-primary-light), var(--color-border)); display: flex; align-items: center; justify-content: center; color: var(--color-primary); font-size: 2rem; }
.gallery-item:nth-child(3n+2) .ph { aspect-ratio: 3/4; }

/* Forms */
.form-field { margin-bottom: 18px; }
.form-field label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; }
.form-field input, .form-field select, .form-field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--color-border); border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: 0.95rem; background: var(--color-surface); color: var(--color-text);
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus { outline: 2px solid var(--color-primary); outline-offset: 1px; }
.form-hp { position: absolute; left: -9999px; }
.form-alert { padding: 14px 16px; border-radius: var(--radius-sm); margin-bottom: 18px; font-size: 0.9rem; }
.form-alert.success { background: #e9f2e8; color: var(--color-accent); border: 1px solid var(--color-accent); }
.form-alert.error { background: #fbeceb; color: #a4342c; border: 1px solid #d98f88; }

/* Doctor / dept detail */
.doctor-avatar {
  width: 72px; height: 72px; border-radius: 50%; background: var(--color-primary);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading); font-size: 1.4rem; font-weight: 700; flex-shrink: 0;
}
.list-check li { position: relative; padding-left: 26px; margin-bottom: 10px; }
.list-check li::before { content: "✓"; position: absolute; left: 0; color: var(--color-accent); font-weight: 700; }

table.timings { width: 100%; border-collapse: collapse; }
table.timings td { padding: 10px 0; border-bottom: 1px solid var(--color-border); }
table.timings td:last-child { text-align: right; color: var(--color-text-muted); }

.map-facade {
  position: relative; aspect-ratio: 16/9; border-radius: var(--radius-lg); overflow: hidden;
  background: linear-gradient(135deg, var(--color-primary-light), var(--color-border));
  display: flex; align-items: center; justify-content: center; cursor: pointer; border: 1px solid var(--color-border);
}
.map-facade .play {
  width: 60px; height: 60px; border-radius: 50%; background: var(--color-primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1.4rem; box-shadow: var(--shadow-md);
}
.video-facade {
  position: relative; aspect-ratio: 9/16; max-width: 260px; margin: 0 auto; border-radius: var(--radius-md); overflow: hidden; cursor: pointer;
  background-color: #1c1512;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-sm); transition: transform 200ms ease, box-shadow 200ms ease;
}
.video-facade::before { content: ""; position: absolute; inset: 0; background: rgba(20, 35, 26, 0.28); transition: background 200ms ease; }
.video-facade:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.video-facade:hover::before { background: rgba(20, 35, 26, 0.12); }
.video-facade .play {
  position: relative; z-index: 1; width: 56px; height: 56px; border-radius: 50%;
  background: rgba(255,255,255,0.92); color: var(--color-primary); display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; transition: transform 200ms ease;
}
.video-facade:hover .play { transform: scale(1.1); }
.video-facade iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; z-index: 2; }

.counter { font-family: var(--font-heading); }

.two-col { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1.4fr 1fr; } }
.two-col.reverse { direction: rtl; }
.two-col.reverse > * { direction: ltr; }

.stack { display: flex; flex-direction: column; gap: 16px; }
.pill-row { display: flex; flex-wrap: wrap; gap: 10px; }

.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--color-primary); color: #fff;
  padding: 12px 20px; z-index: 200; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }
