/* Polyclinique Maya — shared responsive finish */

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: clip !important;
}

body.index-page main.main {
  width: 100%;
  max-width: 100%;
  overflow-x: clip !important;
}

/* Desktop navigation uses the full viewport; the existing mobile drawer is retained. */
@media (min-width: 1200px) {
  #header .branding > .container {
    width: 100%;
    max-width: none;
    padding-inline: clamp(1.1rem, 2.4vw, 3.2rem);
    gap: clamp(.5rem, 1.2vw, 1.4rem);
  }

  #header .branding .logo {
    flex: 0 0 auto;
    margin-right: clamp(.3rem, 1vw, 1.4rem) !important;
  }

  #header .navmenu {
    flex: 1 1 auto;
    min-width: 0;
    margin-inline: 0;
  }

  #header .navmenu > ul {
    width: 100%;
    align-items: center;
    justify-content: space-evenly;
    gap: clamp(0px, .38vw, 8px);
  }

  #header .navmenu > ul > li > a {
    justify-content: center;
    padding-inline: clamp(3px, .46vw, 10px);
    font-size: clamp(.65rem, .73vw, .82rem);
    white-space: nowrap;
  }

  #header #appointmentCta {
    flex: 0 0 auto;
    padding-inline: clamp(12px, 1.15vw, 22px);
    font-size: clamp(.68rem, .73vw, .83rem);
  }
}

@media (min-width: 1200px) and (max-width: 1399.98px) {
  #header .brand-text-inline { font-size: .73rem; }
  #header .navmenu > ul > li > a { letter-spacing: -.015em; }
  #header #appointmentCta .cta-hint,
  #header #appointmentCta .cta-badge { display: none !important; }
}

@media (max-width: 1199.98px) {
  #header .branding > .container {
    width: 100%;
    max-width: none;
    padding-inline: clamp(.65rem, 3vw, 1.2rem);
  }

  #header .branding .logo {
    min-width: 0;
    margin-right: auto !important;
  }

  #header .navmenu > ul {
    max-height: calc(100dvh - 88px);
    overscroll-behavior: contain;
  }

  #header .navmenu .dropdown ul {
    max-height: 52dvh;
    overscroll-behavior: contain;
  }
}

/* The home statistics remain legible over either the default gradient or an admin photo. */
#stats.home-stats-premium {
  width: 100%;
  max-width: 100%;
  margin-inline: 0 !important;
  border-radius: 0 !important;
  overflow-x: clip !important;
  overflow-y: visible !important;
}

#stats.home-stats-premium .home-stats-heading {
  width: min(100%, 760px);
  padding: clamp(1rem, 2.6vw, 1.7rem);
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 24px;
  background: rgba(3, 29, 21, .82);
  box-shadow: 0 20px 44px -32px rgba(0, 0, 0, .9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

#stats.home-stats-premium .home-stats-heading h2,
#stats.home-stats-premium .home-stats-heading p,
#stats.home-stats-premium .home-stats-kicker {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

#stats.home-stats-premium .home-stats-kicker {
  border-color: rgba(167, 243, 208, .28);
  background: rgba(255, 255, 255, .09);
}

#stats.home-stats-premium .home-stat-card {
  color: #123b2b !important;
  border: 1px solid rgba(8, 76, 48, .1) !important;
  background: #fff !important;
  box-shadow: 0 24px 48px -34px rgba(2, 32, 21, .68), inset 0 1px 0 #fff !important;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

#stats.home-stats-premium .home-stat-index { color: #74877d !important; }
#stats.home-stats-premium .home-stat-value { color: #0b432e !important; }
#stats.home-stats-premium .home-stat-card p { color: #52695e !important; }
#stats.home-stats-premium .home-stat-icon { background: color-mix(in srgb, var(--stat-accent) 14%, white); }
#stats.home-stats-premium .home-stats-note {
  border-color: rgba(255, 255, 255, .22);
  color: #fff !important;
  background: rgba(3, 29, 21, .74);
}

/* Insurance is a full-bleed band with a centered, constrained card grid. */
#insurance-partners.ins-premium {
  width: 100%;
  max-width: none;
  margin-inline: 0;
  overflow-x: clip;
}

#insurance-partners.ins-premium > .container {
  width: min(100%, 1240px);
  max-width: 1240px;
  margin-inline: auto;
}

#insurance-partners.ins-premium .insurance-partner-grid {
  width: min(100%, 1080px);
  margin-inline: auto;
  justify-content: center;
}

/* Same photographic footer and booking dialog on all public pages. */
#footer.footer {
  position: relative;
  isolation: isolate;
  width: 100%;
  margin-top: clamp(2rem, 5vw, 4rem);
  padding-top: clamp(2.5rem, 5vw, 4.2rem);
  color: #e4f4eb;
  background: linear-gradient(145deg, #0a3a29, #061e18 72%);
}

#footer.footer::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(110deg, rgba(3, 26, 19, .5), rgba(3, 28, 20, .68));
}

#footer .footer-top {
  width: min(100%, 1500px);
  margin-inline: auto;
  padding: 0 clamp(1rem, 4vw, 3.5rem);
}

#footer .sitename,
#footer h4 { color: #f4fff8 !important; }
#footer p,
#footer .footer-links a { color: rgba(235, 249, 241, .82) !important; }
#footer .footer-links a { display: inline-flex; padding-block: .18rem; text-decoration: none; transition: color .2s ease, transform .2s ease; }
#footer .footer-links a:hover { color: #a7f3d0 !important; transform: translateX(3px); }
#footer .footer-links ul { padding-left: 0; list-style: none; }
#footer .footer-links li { margin-block: .28rem; }
#footer .social-icon { display: inline-grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 1px solid rgba(255,255,255,.17); border-radius: 14px; color: #e7fff1 !important; background: rgba(255,255,255,.09); text-decoration: none; }
#footer .social-icon:hover { color: #073323 !important; background: #a7f3d0; transform: translateY(-3px); }
#footer > .mt-5 { width: min(calc(100% - 2rem), 1420px); margin: clamp(2rem, 4vw, 3.5rem) auto 0 !important; overflow: hidden; border: 1px solid rgba(255,255,255,.18); border-radius: 24px; box-shadow: 0 26px 54px -36px rgba(0,0,0,.9); }
#footer > .mt-5 iframe { display: block; width: 100%; height: clamp(240px, 31vw, 390px); }
#footer > .container { width: min(100% - 2rem, 1420px); color: rgba(235,249,241,.76); border-color: rgba(255,255,255,.18) !important; }
#footer .text-muted { color: rgba(235,249,241,.62) !important; }

.appointment-modal .modal-dialog { width: min(1120px, calc(100vw - 2rem)); max-width: 1120px; }
.appointment-modal .modal-content { overflow: hidden; border: 1px solid rgba(16, 185, 129, .18); border-radius: 24px; box-shadow: 0 30px 90px rgba(2, 34, 22, .28); }
.appointment-modal .modal-header { padding: 1.05rem 1.35rem; border-color: rgba(16, 185, 129, .12); background: linear-gradient(135deg, #f5fff9, #fff); }
.appointment-modal .appointment-modal-kicker { display: block; margin-bottom: .2rem; color: #128452; font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.appointment-modal .modal-title { color: #103d2b; font-size: 1.15rem; font-weight: 800; }
.appointment-modal .modal-body iframe { display: block; width: 100%; height: min(78vh, 850px); border: 0; background: #f7fcf9; }

/* À propos: give the editable clinic imagery and story a more editorial frame. */
#about-page { padding-block: clamp(1.2rem, 4vw, 3rem) !important; }
#about-page .about-page-card { overflow: hidden; border: 1px solid rgba(16, 130, 79, .12) !important; border-radius: clamp(22px, 3vw, 34px) !important; background: #fff !important; box-shadow: 0 28px 80px -48px rgba(4, 51, 32, .46) !important; }
#about-page .about-hero { padding: clamp(1.3rem, 4.4vw, 3.5rem) !important; background: radial-gradient(700px 360px at 100% 0%, rgba(52,211,153,.18), transparent 65%), linear-gradient(135deg, #f4fff8, #fff 55%, #edf9f2) !important; }
#about-page .hero-subtitle { color: #496457 !important; line-height: 1.75; }
#about-page .gradient-heading { color: #0d6845; background: none; -webkit-text-fill-color: #0d6845; animation: none; }
#about-page .hero-brand-card { min-height: 100%; padding: clamp(1rem, 2.5vw, 1.7rem) !important; border-radius: 22px !important; background: linear-gradient(180deg, #fff, #f3fbf6) !important; }
#about-page .about-hero-photo { display: block; width: 100%; height: clamp(150px, 20vw, 230px); border-radius: 16px; object-fit: cover; box-shadow: 0 18px 32px -22px rgba(4, 60, 34, .6); }
#about-page .kpi-card { height: 100%; padding: 1rem .75rem; border-radius: 16px; }
#about-page-story { padding-block: clamp(1.3rem, 3vw, 2.5rem) !important; }
#about-page .section-title { color: #104c34; font-size: clamp(1.2rem, 2.1vw, 1.65rem); }
#about-page .lead,
#about-page .about-body-copy { color: #50675c; font-size: clamp(.94rem, 1.35vw, 1.04rem); line-height: 1.78; }
#about-page .info-card { border-radius: 18px; background: linear-gradient(160deg, #fbfffc, #f4fbf7); }
#about-page .profile-card { position: sticky; top: calc(var(--pm-header-offset, 126px) + 18px); border-radius: 22px; }

@media (max-width: 767.98px) {
  #header .branding > .container { gap: .45rem; }
  #header .brand-text-inline { overflow-wrap: anywhere; }
  #header #appointmentCta { flex-shrink: 0; }
  #stats.home-stats-premium { padding-block: 2.4rem !important; }
  #stats.home-stats-premium .home-stats-heading { border-radius: 19px; }
  #stats.home-stats-premium .home-stats-grid { gap: .65rem; }
  #stats.home-stats-premium .home-stat-card { min-height: 188px; padding: .9rem; border-radius: 18px; }
  #footer > .mt-5 { width: calc(100% - 1.25rem); border-radius: 18px; }
  .appointment-modal .modal-dialog { width: 100%; max-width: none; min-height: 100%; margin: 0; align-items: stretch; }
  .appointment-modal .modal-content { min-height: 100dvh; border: 0; border-radius: 0; }
  .appointment-modal .modal-body iframe { height: calc(100dvh - 78px); }
  #about-page .profile-card { position: static; }
}

@media (prefers-reduced-motion: reduce) {
  #footer .footer-links a,
  #footer .social-icon { transition: none !important; }
}
