/* ===============================================
   TEETH CARE DENTAL CLINIC - STYLESHEET
   Modern, clean dental website design
=============================================== */

/* -- CSS Variables ---------------------------- */
:root {
  --primary: #0ea5e9;
  --primary-dark: #0284c7;
  --primary-light: #e0f2fe;
  --secondary: #14b8a6;
  --accent: #f59e0b;
  --dark: #0f172a;
  --dark-2: #1e293b;
  --gray: #64748b;
  --light-gray: #f1f5f9;
  --white: #ffffff;
  --text: #334155;
  --heading: #0f172a;

  --font-body: "Inter", sans-serif;
  --font-heading: "Playfair Display", serif;

  --radius: 12px;
  --radius-lg: 20px;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.18);
  --transition: all 0.3s ease;
}

/* -- Reset & Base ----------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
  font-size: 16px;
}
body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}
a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
ul {
  list-style: none;
}
button {
  cursor: pointer;
  font-family: var(--font-body);
  border: none;
  outline: none;
}

a,
button {
  -webkit-tap-highlight-color: rgba(14, 165, 233, 0.2);
}

/* -- Utility ---------------------------------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.section {
  padding: 90px 0;
}
.hidden {
  display: none !important;
}
.highlight {
  color: var(--primary);
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-tag {
  display: inline-block;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 6px 18px;
  border-radius: 50px;
  margin-bottom: 14px;
}
.section-tag.light {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}
.section-header h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.9rem, 3.5vw, 2.8rem);
  color: var(--heading);
  margin-bottom: 16px;
}
.section-header p {
  font-size: 1.05rem;
  color: var(--gray);
  max-width: 600px;
  margin: 0 auto;
}

/* -- Buttons ---------------------------------- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 50px;
  box-shadow: 0 4px 20px rgba(14, 165, 233, 0.35);
  transition: var(--transition);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(14, 165, 233, 0.45);
}
.btn-primary.btn-full {
  width: 100%;
  justify-content: center;
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 50px;
  border: 2px solid rgba(255, 255, 255, 0.6);
  transition: var(--transition);
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: #fff;
}

.btn-white {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--primary-dark);
  font-size: 0.95rem;
  font-weight: 700;
  padding: 14px 28px;
  border-radius: 50px;
  transition: var(--transition);
}
.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-outline-white {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 13px 28px;
  border-radius: 50px;
  border: 2px solid #fff;
  transition: var(--transition);
}
.btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.15);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(14, 165, 233, 0.45);
  outline-offset: 2px;
}

/* ════════════════════════════════════════════
   ENQUIRY MODAL
════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: modalFadeIn 0.3s ease;
  padding: 20px;
}
@keyframes modalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-box {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 30px 28px;
  width: 100%;
  max-width: 470px;
  position: relative;
  box-shadow: var(--shadow-lg);
  animation: modalSlideUp 0.35s ease;
  max-height: calc(100vh - 24px);
  overflow: hidden;
}
@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--light-gray);
  color: var(--gray);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.modal-close:hover {
  background: #fee2e2;
  color: #ef4444;
}

.modal-header {
  text-align: center;
  margin-bottom: 20px;
}
.modal-clinic-name {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--primary-dark);
  margin-bottom: 8px;
}
.modal-logo-img {
  width: 56px;
  margin: 0 auto 8px;
}
.modal-header h2 {
  font-family: var(--font-heading);
  font-size: 1.52rem;
  color: var(--heading);
  margin-bottom: 6px;
}
.modal-header p {
  color: var(--gray);
  font-size: 0.9rem;
}

.enquiry-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.form-group label {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--dark-2);
  display: flex;
  align-items: center;
  gap: 7px;
}
.form-group label i {
  color: var(--primary);
}
.required {
  color: #ef4444;
}

.form-group input,
.form-group textarea {
  padding: 10px 14px;
  border: 2px solid #e2e8f0;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-family: var(--font-body);
  color: var(--text);
  transition: var(--transition);
  background: var(--light-gray);
}
.form-group textarea {
  min-height: 74px;
  resize: none;
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}
.form-group input.invalid,
.form-group textarea.invalid {
  border-color: #ef4444;
  background: #fff5f5;
}
.field-error {
  font-size: 0.76rem;
  color: #ef4444;
  min-height: 0;
  line-height: 1.2;
}

.enquiry-form .btn-primary {
  padding: 12px 20px;
}

.form-success {
  text-align: center;
  padding: 10px;
  background: #dcfce7;
  color: #16a34a;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.form-error-msg {
  text-align: center;
  padding: 10px;
  background: #fee2e2;
  color: #dc2626;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

@media (max-height: 760px) {
  .modal-box {
    padding: 24px 20px;
    max-width: 440px;
  }
  .modal-logo-img {
    width: 48px;
    margin: 0 auto 6px;
  }
  .modal-header {
    margin-bottom: 14px;
  }
  .modal-header h2 {
    font-size: 1.36rem;
  }
  .enquiry-form {
    gap: 10px;
  }
  .form-group input,
  .form-group textarea {
    padding: 9px 12px;
    font-size: 0.86rem;
  }
  .form-group textarea {
    min-height: 64px;
  }
}

/* ════════════════════════════════════════════
   HEADER
════════════════════════════════════════════ */
#mainHeader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 18px 0;
  transition: var(--transition);
}
#mainHeader.scrolled {
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
  padding: 12px 0;
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
}
.logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.logo-img {
  width: 44px;
  height: 44px;
  filter: drop-shadow(0 2px 6px rgba(14, 165, 233, 0.4));
}
.logo-text {
  font-weight: 800;
  font-size: 1.15rem;
  color: #fff;
  line-height: 1.2;
  transition: var(--transition);
}
.logo-text span {
  display: block;
  font-weight: 400;
  font-size: 0.8rem;
  opacity: 0.8;
}
#mainHeader.scrolled .logo-text {
  color: var(--heading);
}

#mainNav {
  flex: 1;
  display: flex;
  justify-content: center;
}
#mainNav ul {
  display: flex;
  gap: 6px;
  align-items: center;
}
#mainNav a {
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  padding: 8px 14px;
  border-radius: 8px;
  transition: var(--transition);
}
#mainNav a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
}
#mainHeader.scrolled #mainNav a {
  color: var(--text);
}
#mainHeader.scrolled #mainNav a:hover {
  color: var(--primary);
  background: var(--primary-light);
}

.btn-appt {
  padding: 10px 22px !important;
  font-size: 0.88rem !important;
  flex-shrink: 0;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  margin-left: auto;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}
.hamburger span {
  display: block;
  width: 26px;
  height: 2.5px;
  background: #fff;
  border-radius: 4px;
  transition: var(--transition);
}
#mainHeader.scrolled .hamburger span {
  background: var(--dark);
}

/* ════════════════════════════════════════════
   HERO
════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}
#heroBgVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(15, 23, 42, 0.8) 0%,
    rgba(2, 132, 199, 0.55) 60%,
    rgba(15, 23, 42, 0.7) 100%
  );
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  color: #fff;
  padding-top: 100px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 7px 18px;
  border-radius: 50px;
  margin-bottom: 22px;
}
.hero-badge i {
  color: var(--accent);
}
.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  line-height: 1.15;
  margin-bottom: 22px;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}
.hero-sub {
  font-size: 1.15rem;
  opacity: 0.9;
  margin-bottom: 36px;
  max-width: 560px;
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

.hero-stats {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
}
.stat {
  text-align: center;
}
.stat-num {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--accent);
  display: inline;
}
.stat-label {
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.75;
  margin-top: 2px;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  animation: bounce 2s infinite;
}
.hero-scroll-hint a {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.5);
  color: #fff;
  font-size: 1rem;
}
@keyframes bounce {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(-8px);
  }
}

/* ════════════════════════════════════════════
   SERVICES
════════════════════════════════════════════ */
.services-section {
  background: var(--light-gray);
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}
.service-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid #e2e8f0;
  cursor: default;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}
.service-icon {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 22px;
  transition: var(--transition);
}
.service-card:hover .service-icon {
  background: var(--primary);
  color: #fff;
  transform: scale(1.1);
}
.service-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 12px;
}
.service-card p {
  font-size: 0.92rem;
  color: var(--gray);
  line-height: 1.65;
}

/* ════════════════════════════════════════════
   WHY US
════════════════════════════════════════════ */
.why-us-section {
  background: #f7f8f6;
  color: var(--heading);
  padding-bottom: 84px;
}
.why-us-inner {
  display: grid;
  grid-template-columns: minmax(280px, 1.05fr) minmax(320px, 1fr);
  gap: 56px;
  align-items: start;
  margin-bottom: 34px;
}
.why-us-section .section-tag {
  background: transparent;
  color: #0f766e;
  padding: 0;
  border-radius: 0;
  letter-spacing: 3px;
  font-size: 0.74rem;
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.why-us-section .section-tag::before {
  content: "";
  width: 32px;
  height: 1px;
  background: rgba(15, 118, 110, 0.45);
}
.why-about-copy h2 {
  font-family: var(--font-heading);
  font-size: clamp(2.05rem, 3.4vw, 3.3rem);
  color: #122026;
  line-height: 1.12;
  margin-bottom: 22px;
}
.why-about-copy h2 em {
  font-style: italic;
  font-weight: 500;
}
.why-about-copy p {
  color: #4f6470;
  font-size: 1.05rem;
  line-height: 1.72;
  max-width: 620px;
  margin-bottom: 16px;
}
.why-about-copy .btn-primary {
  margin-top: 12px;
}
.why-about-media {
  position: relative;
}
.why-media-frame {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.16);
}
.why-media-frame img {
  width: 100%;
  height: 100%;
  min-height: 520px;
  object-fit: cover;
}
.why-media-quote {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  background: #0f766e;
  color: rgba(255, 255, 255, 0.92);
  font-family: var(--font-heading);
  font-size: 1.02rem;
  font-style: italic;
  padding: 14px 24px;
}
.why-proof-badge {
  position: absolute;
  left: -28px;
  bottom: -26px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #fff;
  border: 1px solid #d9e1df;
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.14);
  padding: 14px 16px;
  max-width: 330px;
}
.why-proof-badge i {
  color: #0f766e;
  margin-top: 2px;
}
.why-proof-badge strong {
  display: block;
  color: #0f172a;
  font-size: 0.88rem;
  line-height: 1.4;
}
.why-proof-badge span {
  color: #64748b;
  font-size: 0.8rem;
}

.why-metrics {
  border-top: 1px solid #d6dddb;
  border-bottom: 1px solid #d6dddb;
  margin: 18px 0 58px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.metric-item {
  padding: 24px 18px;
  border-right: 1px solid #d6dddb;
}
.metric-item:last-child {
  border-right: none;
}
.metric-item strong {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(2rem, 3vw, 2.7rem);
  line-height: 1;
  color: #0f172a;
  margin-bottom: 8px;
}
.metric-item span {
  text-transform: uppercase;
  letter-spacing: 1.8px;
  font-size: 0.77rem;
  color: #5f7179;
  font-weight: 600;
}

.why-team-head {
  margin-bottom: 24px;
}
.why-team-head h3 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 3.1vw, 3rem);
  color: #122026;
  line-height: 1.12;
  margin-bottom: 10px;
}
.why-team-head h3 em {
  font-style: italic;
  font-weight: 500;
}
.why-team-head p {
  color: #60717a;
  font-size: 1rem;
}

.doctor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.doctor-card {
  background: #fff;
  border: 1px solid #d8e2df;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: var(--transition);
}
.doctor-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.14);
}
.doctor-media {
  position: relative;
}
.doctor-media img {
  width: 100%;
  height: 390px;
  object-fit: cover;
  display: block;
}
.doctor-rating,
.doctor-tenure {
  position: absolute;
  top: 14px;
  background: rgba(255, 255, 255, 0.9);
  color: #486069;
  font-size: 0.82rem;
  padding: 6px 10px;
  font-weight: 600;
}
.doctor-rating {
  left: 14px;
}
.doctor-rating i {
  color: #f59e0b;
  margin-right: 4px;
}
.doctor-tenure {
  right: 14px;
}
.doctor-speciality {
  position: absolute;
  left: 14px;
  bottom: 14px;
  background: #e0f2fe;
  color: #0c4a6e;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  padding: 7px 10px;
}
.doctor-body {
  padding: 18px 20px 22px;
}
.doctor-body h4 {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  color: #122026;
  margin-bottom: 4px;
  line-height: 1.1;
}
.doctor-role {
  text-transform: uppercase;
  letter-spacing: 1.6px;
  color: #0f766e;
  font-size: 0.74rem;
  font-weight: 700;
  margin-bottom: 12px;
}
.doctor-body p {
  color: #5e7079;
  line-height: 1.7;
  font-size: 0.97rem;
}
.doctor-bio {
  max-height: 5em;
  overflow: hidden;
  position: relative;
  transition: max-height 0.45s ease;
}
.doctor-bio::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2.2em;
  background: linear-gradient(transparent, #fff);
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.doctor-bio.expanded {
  max-height: 600px;
}
.doctor-bio.expanded::after {
  opacity: 0;
}
.bio-expand-btn {
  background: none;
  border: none;
  padding: 0;
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--primary-dark);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: color 0.2s ease;
}
.bio-expand-btn:hover {
  color: var(--primary);
}
.bio-expand-btn i {
  font-size: 0.78rem;
  transition: transform 0.3s ease;
}
.bio-expand-btn.open i {
  transform: rotate(180deg);
}

/* ════════════════════════════════════════════
   GALLERY
════════════════════════════════════════════ */
.gallery-section {
  background: #fff;
  perspective: 1200px;
}
.gallery-carousel-wrap {
  position: relative;
  overflow: hidden;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  max-width: 100vw;
  height: clamp(320px, 38vw, 520px);
  margin-top: 12px;
  perspective: 1200px;
  background: radial-gradient(
    circle at center,
    rgba(14, 165, 233, 0.12),
    transparent 68%
  );
  border-radius: 28px;
}
.gallery-carousel-track {
  position: relative;
  width: 100%;
  height: 100%;
}
.gallery-item {
  border-radius: 18px;
  overflow: hidden;
  width: clamp(320px, 42vw, 720px);
  aspect-ratio: 16 / 10;
  position: absolute;
  left: 50%;
  top: 50%;
  background: #fff;
  transform: translate(-50%, -50%) scale(0.6);
  transition:
    transform 0.72s cubic-bezier(0.22, 0.61, 0.36, 1),
    opacity 0.58s ease,
    filter 0.58s ease,
    box-shadow 0.58s ease;
  opacity: 0;
  filter: blur(2px) brightness(0.58);
  pointer-events: none;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

/* Fallback: keep gallery visible if JS class assignment is interrupted. */
.gallery-track-nojs .gallery-item,
#galleryTrack:not(:has(.gallery-item.is-center)) .gallery-item {
  opacity: 1;
  filter: none;
  pointer-events: auto;
}

#galleryTrack:not(:has(.gallery-item.is-center)) .gallery-item:nth-child(1) {
  transform: translate(-50%, -50%) scale(1.12);
  z-index: 7;
}

#galleryTrack:not(:has(.gallery-item.is-center)) .gallery-item:nth-child(2) {
  transform: translate(-126%, -47%) scale(0.95);
  z-index: 5;
}

#galleryTrack:not(:has(.gallery-item.is-center)) .gallery-item:nth-child(3) {
  transform: translate(26%, -47%) scale(0.95);
  z-index: 5;
}

#galleryTrack:not(:has(.gallery-item.is-center))
  .gallery-item:nth-child(n + 4) {
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}
.gallery-item:hover {
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.28);
  border-color: #0ea5e9;
}

.gallery-item.is-center {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.18);
  filter: blur(0) brightness(1);
  z-index: 7;
  pointer-events: auto;
  box-shadow: 0 28px 68px rgba(0, 0, 0, 0.26);
}

.gallery-item.is-left {
  opacity: 0.82;
  transform: translate(-130%, -47%) scale(1.02);
  filter: blur(0.4px) brightness(0.88);
  z-index: 5;
}

.gallery-item.is-right {
  opacity: 0.82;
  transform: translate(30%, -47%) scale(1.02);
  filter: blur(0.4px) brightness(0.88);
  z-index: 5;
}

.gallery-item.is-far-left {
  opacity: 0.45;
  transform: translate(-200%, -45%) scale(0.86);
  filter: blur(1px) brightness(0.7);
  z-index: 3;
}

.gallery-item.is-far-right {
  opacity: 0.45;
  transform: translate(100%, -45%) scale(0.86);
  filter: blur(1px) brightness(0.7);
  z-index: 3;
}

.gallery-item.is-hidden {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.55);
  filter: blur(2px) brightness(0.58);
  z-index: 1;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.gallery-item:hover img {
  transform: scale(1.12);
}
.gallery-overlay {
  position: absolute;
  inset: 0;
  background: rgba(14, 165, 233, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.6rem;
  opacity: 0;
  transition: var(--transition);
}
.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

@media (max-width: 900px) {
  .gallery-carousel-wrap {
    height: clamp(280px, 68vw, 420px);
    border-radius: 20px;
  }
  .gallery-item {
    width: clamp(250px, 84vw, 500px);
  }
  .gallery-item.is-far-left,
  .gallery-item.is-far-right {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.58);
  }
  .gallery-item.is-left {
    transform: translate(-98%, -48%) scale(0.9);
    opacity: 0.58;
  }
  .gallery-item.is-right {
    transform: translate(-2%, -48%) scale(0.9);
    opacity: 0.58;
  }
}

/* ════════════════════════════════════════════
   TESTIMONIALS
════════════════════════════════════════════ */
.testimonials-section {
  background: var(--light-gray);
}
.testimonials-track-wrap {
  overflow: hidden;
  border-radius: var(--radius-lg);
}
.testimonials-track {
  display: flex;
  gap: 24px;
  transition: transform 0.5s ease;
}
.testimonial-card {
  min-width: calc(33.333% - 16px);
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
  border: 1px solid #e2e8f0;
}
.stars {
  color: var(--accent);
  font-size: 0.95rem;
  margin-bottom: 16px;
  letter-spacing: 2px;
}
.testimonial-card p {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.7;
  margin-bottom: 22px;
  font-style: italic;
}
.patient-info {
  display: flex;
  align-items: center;
  gap: 14px;
}
.patient-avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.patient-info strong {
  display: block;
  font-size: 0.95rem;
  color: var(--heading);
}
.patient-info span {
  font-size: 0.82rem;
  color: var(--gray);
}

.testimonial-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 28px;
}
.testimonial-dots .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #cbd5e1;
  cursor: pointer;
  transition: var(--transition);
  border: 0;
  padding: 0;
}
.testimonial-dots .dot.active {
  background: var(--primary);
  width: 28px;
  border-radius: 5px;
}

/* ════════════════════════════════════════════
   FAQ
════════════════════════════════════════════ */
.faq-section {
  background: #fff;
}
.faq-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.faq-item {
  border: 1px solid #e2e8f0;
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
}
.faq-item.open {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--heading);
  background: #fff;
  text-align: left;
  gap: 12px;
  transition: var(--transition);
}
.faq-question i {
  flex-shrink: 0;
  transition: transform 0.3s ease;
  color: var(--primary);
}
.faq-item.open .faq-question {
  background: var(--primary-light);
  color: var(--primary-dark);
}
.faq-item.open .faq-question i {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.4s ease,
    padding 0.3s ease;
}
.faq-item.open .faq-answer {
  max-height: 300px;
}
.faq-answer p {
  padding: 0 24px 22px;
  color: var(--gray);
  line-height: 1.7;
  font-size: 0.95rem;
}
.faq-answer a {
  color: var(--primary);
  font-weight: 600;
}

/* ════════════════════════════════════════════
   CONTACT
════════════════════════════════════════════ */
.contact-section {
  background: var(--light-gray);
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
  align-items: stretch;
}
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contact-card {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  background: #fff;
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  border: 1px solid #e2e8f0;
  transition: var(--transition);
}
.contact-card:hover {
  border-color: var(--primary);
  transform: translateX(4px);
}
.contact-card > i {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}
.contact-card h4 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 5px;
}
.contact-card p {
  font-size: 0.88rem;
  color: var(--gray);
  line-height: 1.55;
}
.contact-card a {
  color: var(--primary);
  font-weight: 600;
}
.contact-card a:hover {
  text-decoration: underline;
}

.social-links {
  display: flex;
  gap: 12px;
  margin-top: 4px;
}
.social-links a {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.social-links a:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-3px);
}

.contact-map {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  min-height: 380px;
  border: 1px solid #e2e8f0;
}
.contact-map iframe {
  display: block;
}

/* ════════════════════════════════════════════
   CTA BANNER
════════════════════════════════════════════ */
.cta-banner {
  background: linear-gradient(
    135deg,
    var(--primary-dark) 0%,
    var(--secondary) 100%
  );
  padding: 70px 0;
}
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta-inner h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  color: #fff;
  margin-bottom: 8px;
}
.cta-inner p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
}
.cta-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════ */
.footer {
  background: var(--dark);
  color: rgba(255, 255, 255, 0.7);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  gap: 48px;
  padding: 70px 0 48px;
}
.footer-brand .logo-text {
  color: #fff;
}
.footer-brand p {
  font-size: 0.9rem;
  margin-top: 16px;
  line-height: 1.7;
}
.footer-logo {
  width: 48px;
  filter: brightness(0) invert(1) opacity(0.9);
}

.footer h4 {
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(14, 165, 233, 0.4);
  display: inline-block;
}
.footer ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer ul a {
  font-size: 0.9rem;
  transition: var(--transition);
}
.footer ul a:hover {
  color: var(--primary);
  padding-left: 6px;
}
.footer-contact p {
  font-size: 0.9rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  line-height: 1.5;
}
.footer-contact p i {
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 3px;
}
.footer-contact a {
  color: rgba(255, 255, 255, 0.7);
}
.footer-contact a:hover {
  color: var(--primary);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 22px 0;
  text-align: center;
}
.footer-bottom p {
  font-size: 0.85rem;
}

/* ════════════════════════════════════════════
   FLOATING ELEMENTS
════════════════════════════════════════════ */
.whatsapp-float {
  position: fixed;
  bottom: 80px;
  right: 24px;
  width: 58px;
  height: 58px;
  background: #25d366;
  color: #fff;
  border-radius: 50%;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  z-index: 900;
  transition: var(--transition);
  animation: pulse 2.5s infinite;
}
.whatsapp-float:hover {
  transform: scale(1.1);
}
@keyframes pulse {
  0%,
  100% {
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  }
  50% {
    box-shadow: 0 4px 35px rgba(37, 211, 102, 0.7);
  }
}

.scroll-top-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 46px;
  height: 46px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  z-index: 900;
  opacity: 0;
  transform: translateY(20px);
  transition: var(--transition);
  pointer-events: none;
}
.scroll-top-btn.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.scroll-top-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
}

/* ════════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .why-us-inner {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .why-media-frame img {
    min-height: 460px;
  }
  .why-proof-badge {
    left: 20px;
    bottom: -22px;
  }
  .doctor-grid {
    gap: 18px;
  }
  .doctor-media img {
    height: 340px;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
  .testimonial-card {
    min-width: calc(50% - 12px);
  }
}

/* Tablet header behavior to avoid nav/button overlap */
@media (max-width: 1100px) {
  #mainNav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.97);
    backdrop-filter: blur(12px);
    padding: 20px;
    border-radius: 0 0 16px 16px;
  }
  #mainNav.open {
    display: block;
  }
  #mainNav ul {
    flex-direction: column;
    gap: 4px;
  }
  #mainNav a {
    color: rgba(255, 255, 255, 0.9) !important;
    display: block;
    padding: 12px 16px;
    border-radius: 8px;
  }
  #mainNav a:hover {
    background: rgba(255, 255, 255, 0.1) !important;
  }
  .hamburger {
    display: flex;
  }
  .btn-appt {
    display: none;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 64px 0;
  }

  /* Why us */
  .why-us-section {
    padding-bottom: 64px;
  }
  .why-about-copy h2 {
    font-size: clamp(1.8rem, 8vw, 2.5rem);
  }
  .why-media-frame img {
    min-height: 360px;
  }
  .why-media-quote {
    font-size: 0.9rem;
    padding: 12px 16px;
  }
  .why-proof-badge {
    position: static;
    margin-top: 12px;
    max-width: 100%;
  }
  .why-metrics {
    grid-template-columns: 1fr;
    margin: 12px 0 40px;
  }
  .metric-item {
    border-right: none;
    border-bottom: 1px solid #d6dddb;
  }
  .metric-item:last-child {
    border-bottom: none;
  }
  .doctor-grid {
    grid-template-columns: 1fr;
  }
  .doctor-media img {
    height: 300px;
  }
  .doctor-body h4 {
    font-size: 1.6rem;
  }

  /* Hero */
  .hero-stats {
    gap: 24px;
  }
  .stat-num {
    font-size: 1.7rem;
  }
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .hero-actions .btn-primary,
  .hero-actions .btn-outline {
    width: min(360px, 100%);
    justify-content: center;
  }

  /* Services */
  .services-grid {
    grid-template-columns: 1fr;
  }

  /* Gallery */
  .gallery-carousel-wrap {
    height: clamp(260px, 72vw, 390px);
    border-radius: 18px;
  }
  .gallery-item {
    width: clamp(230px, 86vw, 430px);
  }
  .gallery-item.is-left {
    transform: translate(-92%, -48%) scale(0.84);
    opacity: 0.46;
  }
  .gallery-item.is-right {
    transform: translate(-8%, -48%) scale(0.84);
    opacity: 0.46;
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .contact-map {
    min-height: 280px;
  }

  /* CTA */
  .cta-inner {
    flex-direction: column;
    text-align: center;
  }
  .cta-actions {
    justify-content: center;
    width: 100%;
  }
  .cta-actions .btn-white,
  .cta-actions .btn-outline-white {
    width: min(360px, 100%);
    justify-content: center;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  /* Testimonials */
  .testimonial-card {
    min-width: 100%;
  }

  /* Modal */
  .modal-box {
    padding: 32px 24px;
  }

  .whatsapp-float {
    width: 52px;
    height: 52px;
    font-size: 1.55rem;
    right: 16px;
    bottom: 74px;
  }
  .scroll-top-btn {
    right: 16px;
    bottom: 16px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }
  .why-us-section .section-tag {
    gap: 10px;
    letter-spacing: 2.4px;
  }
  .why-us-section .section-tag::before {
    width: 24px;
  }
  .why-about-copy p {
    font-size: 0.96rem;
  }
  .metric-item strong {
    font-size: 2rem;
  }
  .doctor-rating,
  .doctor-tenure {
    font-size: 0.74rem;
    padding: 5px 8px;
  }
  .doctor-speciality {
    font-size: 0.72rem;
    padding: 6px 8px;
  }
  .logo-text {
    font-size: 1rem;
  }
  .logo-text span {
    font-size: 0.72rem;
  }
  .hero h1 {
    font-size: 2rem;
  }
  .gallery-carousel-wrap {
    height: 290px;
    margin-top: 8px;
    border-radius: 16px;
  }
  .gallery-item {
    width: min(90vw, 360px);
  }
  .gallery-item.is-left,
  .gallery-item.is-right {
    opacity: 0.35;
  }
  .hero-stats {
    gap: 16px;
  }
}
