/* ==========================================================================
   Dr Viviane Soravia-Dunand: practice website
   Single light theme, "soft navy" palette. Change colours in :root only.
   ========================================================================== */

@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --navy: #2f4a6d;
  --navy-deep: #213650;
  --navy-soft: #5d7696;
  --tint: #f3f6fa;
  --tint-strong: #e6ecf4;
  --line: #dde4ec;
  --ink: #1b2633;
  --muted: #586576;
  --white: #ffffff;

  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(27, 38, 51, 0.04), 0 12px 32px -12px rgba(27, 38, 51, 0.14);
  --header-h: 68px;
  --wrap: 1120px;
  --gutter: clamp(20px, 5vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--navy); text-underline-offset: 3px; }
h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; border-radius: 6px; }
.icon { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 9vw, 112px); }
.section--tint { background: var(--tint); }
.eyebrow { font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--navy-soft); }
.h2 { font-weight: 600; font-size: clamp(1.75rem, 3.4vw, 2.4rem); line-height: 1.15; letter-spacing: -0.022em; color: var(--navy-deep); text-wrap: balance; }
.section-head { margin-bottom: clamp(28px, 4vw, 48px); }
.section-head .h2 { margin-top: 8px; }
.section-head--center { text-align: center; }
.lead { color: var(--muted); max-width: 60ch; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header .wrap { height: 100%; display: flex; align-items: center; gap: 20px; }
.brand { font-weight: 600; font-size: 1.05rem; letter-spacing: -0.01em; line-height: 1; color: var(--navy-deep); text-decoration: none; white-space: nowrap; margin-right: auto; }
.nav { display: flex; gap: 26px; }
.nav a { font-size: 0.9375rem; font-weight: 500; color: var(--ink); text-decoration: none; padding: 6px 0; border-bottom: 1.5px solid transparent; transition: border-color 0.15s, color 0.15s; }
.nav a:hover, .nav a[aria-current="true"] { color: var(--navy); border-bottom-color: var(--navy); }
.lang { display: flex; align-items: center; gap: 2px; font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.04em; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang a, .lang span { padding: 3px 9px; border-radius: 999px; text-decoration: none; color: var(--muted); }
.lang [aria-current="true"] { background: var(--navy); color: #fff; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 20px;
  border-radius: 999px; border: 1.5px solid var(--navy);
  background: var(--navy); color: #fff;
  font-weight: 600; font-size: 0.9375rem; text-decoration: none; white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.btn:hover { background: var(--navy-deep); border-color: var(--navy-deep); }
.btn--ghost { background: transparent; color: var(--navy); }
.btn--ghost:hover { background: var(--tint); border-color: var(--navy); }
.burger { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; border-radius: 10px; }
.burger .icon { width: 26px; height: 26px; }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(180deg, var(--white) 0%, var(--tint) 100%); padding-block: clamp(28px, 4vw, 48px) clamp(48px, 6vw, 72px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero h1 { font-weight: 600; font-size: clamp(2.1rem, 4.6vw, 3.3rem); line-height: 1.08; letter-spacing: -0.028em; color: var(--navy-deep); margin-top: 14px; text-wrap: balance; }
.hero h1 small { display: block; font-size: 0.42em; font-weight: 500; color: var(--navy-soft); margin-bottom: 6px; letter-spacing: -0.01em; }
.titles { margin-top: 24px; display: grid; gap: 8px; }
.titles li { display: flex; gap: 12px; align-items: baseline; color: var(--ink); }
.titles li::before { content: ""; flex: none; width: 18px; height: 1.5px; background: var(--navy-soft); transform: translateY(-5px); }
.hero-photo { position: relative; }
.hero-photo img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: 50% 50%; border-radius: 28px; box-shadow: var(--shadow); background: var(--tint-strong); }

.actions { margin-top: clamp(28px, 4vw, 44px); display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 14px; align-items: stretch; }
.action {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center;
  padding: 20px 16px; min-height: 124px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--ink); text-decoration: none;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.action:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--navy-soft); }
.action > span:not(.onedoc-chip) { display: flex; flex-direction: column; gap: 3px; }
.action .icon { width: 26px; height: 26px; color: var(--navy); }
.action-label { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--navy-soft); }
.action-value { font-weight: 600; line-height: 1.35; }
.action--book { background: var(--navy); border-color: var(--navy); color: #fff; box-shadow: var(--shadow); }
.action--book:hover { background: var(--navy-deep); border-color: var(--navy-deep); }
.action--book .action-value { font-weight: 600; font-size: 1.3rem; letter-spacing: -0.015em; line-height: 1.2; }
.onedoc-chip { white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; margin-top: 6px; padding: 7px 14px; background: #fff; border-radius: 999px; color: var(--muted); font-size: 0.8125rem; font-weight: 500; }
.onedoc-chip img { height: 20px; width: auto; }

/* ---------- Présentation ---------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.about-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 30%; border-radius: 28px; background: var(--tint-strong); }
.prose p + p { margin-top: 1.1em; }
.prose { color: #2b3847; }

/* ---------- Spécialités ---------- */
.spec-hint { text-align: center; color: var(--muted); margin-top: 12px; }
.spec-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 420px)); justify-content: center; gap: 24px; align-items: start; }
.spec { background: var(--white); border: 1px solid var(--line); border-radius: 24px; transition: box-shadow 0.2s, border-color 0.2s; }
.spec-head { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; padding: 36px 28px 30px; border-radius: 24px; }
.spec-icon { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; background: var(--tint); color: var(--navy); }
.spec-icon .icon { width: 28px; height: 28px; }
.spec-title { font-weight: 600; font-size: clamp(1.3rem, 2.3vw, 1.55rem); letter-spacing: -0.018em; line-height: 1.2; color: var(--navy-deep); }
.spec-more { display: inline-flex; align-items: center; gap: 6px; font-size: 0.875rem; font-weight: 600; color: var(--navy); }
.spec-more .icon { width: 16px; height: 16px; transition: transform 0.2s; }
.spec-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.45s ease; }
.spec-body > div { overflow: hidden; }
.spec-list { padding: 0 28px 28px; }
.spec-list li { border-top: 1px solid var(--line); }
.exp { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; text-align: left; padding: 13px 2px; font-weight: 500; font-size: 0.98rem; line-height: 1.4; }
.exp .icon { width: 18px; height: 18px; color: var(--navy-soft); transition: transform 0.25s; display: none; }
.exp-desc { display: none; padding: 0 2px 16px; color: var(--muted); font-size: 0.95rem; max-width: 62ch; }
.spec-back { display: none; margin: 0 auto 24px; }

/* overview: hover / keyboard focus lets the list trickle down */
@media (hover: hover) {
  .spec-grid:not([data-active]) .spec:hover .spec-body,
  .spec-grid:not([data-active]) .spec:focus-within .spec-body { grid-template-rows: 1fr; }
  .spec-grid:not([data-active]) .spec:hover { box-shadow: var(--shadow); border-color: var(--navy-soft); }
}
.spec-grid:not([data-active]) .spec { cursor: pointer; }
.spec-grid:not([data-active]) .exp { pointer-events: none; }

/* detail: one specialty selected */
.spec-grid[data-active] { grid-template-columns: minmax(0, 720px); }
.spec-grid[data-active] .spec:not(.is-active) { display: none; }
.spec.is-active { box-shadow: var(--shadow); animation: spec-in 0.4s ease both; }
.spec.is-active .spec-body { grid-template-rows: 1fr; }
.spec.is-active .spec-more { display: none; }
.spec.is-active .exp .icon { display: block; }
.spec.is-active .exp:hover { color: var(--navy); }
.exp[aria-expanded="true"] .icon { transform: rotate(45deg); }
.exp[aria-expanded="true"] + .exp-desc { display: block; animation: fade-in 0.3s ease both; }
.spec-grid[data-active] ~ .spec-back, .spec-back.is-visible { display: flex; }
@keyframes spec-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes fade-in { from { opacity: 0; } }

/* ---------- Cabinet ---------- */
.cabinet-text { max-width: 80ch; margin-inline: auto; text-align: center; text-wrap: pretty; }
.strip-wrap { position: relative; margin-top: clamp(32px, 5vw, 56px); }
.strip { display: flex; gap: 16px; overflow-x: auto; scrollbar-width: none; padding-inline: var(--gutter); -webkit-overflow-scrolling: touch; }
.strip::-webkit-scrollbar { display: none; }
.strip li { flex: none; }
.strip img { height: clamp(240px, 42vw, 440px); width: auto; max-width: none; border-radius: var(--radius); background: var(--tint-strong); }
.strip-toggle { position: absolute; right: var(--gutter); bottom: 14px; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, 0.92); color: var(--navy-deep); box-shadow: var(--shadow); margin-right: 14px; }
.strip-toggle .icon { width: 18px; height: 18px; fill: currentColor; stroke: none; }
.strip-toggle .i-play, .strip-toggle[aria-pressed="true"] .i-pause { display: none; }
.strip-toggle[aria-pressed="true"] .i-play { display: block; }

.partners { margin-top: clamp(48px, 7vw, 80px); }
.partners-title { text-align: center; }
.partners-grid { margin-top: 24px; display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.partners-grid a { flex: 0 1 240px; display: grid; place-items: center; height: 108px; padding: 20px 26px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); transition: border-color 0.18s, box-shadow 0.18s, transform 0.18s; }
.partners-grid a:hover { border-color: var(--navy-soft); box-shadow: var(--shadow); transform: translateY(-2px); }
.partners-grid img { max-height: 46px; max-width: 100%; width: auto; height: auto; object-fit: contain; }
.partners-grid img.tall { max-height: 66px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 48px); align-items: stretch; }
.contact-name { font-weight: 600; font-size: 1.2rem; letter-spacing: -0.012em; line-height: 1.35; color: var(--navy-deep); }
.info { margin-top: 24px; display: grid; gap: 0; }
.info > div { display: grid; grid-template-columns: 28px 1fr; gap: 14px; padding: 18px 0; border-top: 1px solid var(--line); }
.info .icon { width: 24px; height: 24px; color: var(--navy); margin-top: 2px; }
.info h3 { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--navy-soft); margin-bottom: 4px; }
.info p { line-height: 1.55; }
.info a { font-weight: 600; text-decoration: none; }
.info a:hover { text-decoration: underline; }
.info .tpg-logo { height: 16px; width: auto; display: inline-block; vertical-align: -2px; margin-left: 6px; }
.stops { display: grid; gap: 6px; margin-top: 2px; }
.stops li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.line { display: inline-grid; place-items: center; min-width: 30px; height: 22px; padding: 0 7px; border-radius: 11px; font-size: 0.8125rem; font-weight: 700; color: #fff; line-height: 1; }
.line-3 { background: #b82f89; }
.line-8 { background: #84471c; }
.line-11 { background: #82419e; }
.line-20 { background: #00a828; }
.contact-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.map-card { position: relative; min-height: 460px; border-radius: 24px; overflow: hidden; border: 1px solid var(--line); background: var(--tint-strong); isolation: isolate; }
#map { position: absolute; inset: 0; }
.map-legend { position: absolute; left: 12px; bottom: 12px; z-index: 500; display: flex; flex-wrap: wrap; gap: 6px 14px; max-width: calc(100% - 24px); padding: 8px 12px; background: rgba(255, 255, 255, 0.94); border-radius: 10px; font-size: 0.78rem; font-weight: 500; box-shadow: var(--shadow); }
.map-legend span { display: inline-flex; align-items: center; gap: 6px; }
.leaflet-container { font-family: var(--sans); }
.leaflet-tile-pane { filter: saturate(0.55) contrast(1.02); }
.leaflet-popup-content-wrapper { border-radius: 12px; box-shadow: var(--shadow); }
.leaflet-popup-content { margin: 12px 14px; font-size: 0.875rem; line-height: 1.45; }
.leaflet-popup-content strong { display: block; color: var(--navy-deep); }
.leaflet-popup-content .line { margin: 6px 4px 0 0; }
.pin { display: grid; place-items: center; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(27, 38, 51, 0.35); color: #fff; font-weight: 700; font-size: 12px; line-height: 1; }
.pin--cabinet { background: var(--navy); width: 38px; height: 38px; }
.pin--cabinet svg { width: 20px; height: 20px; }
.pin--clinic { background: #fff; color: var(--navy); border-color: var(--navy); width: 28px; height: 28px; font-size: 14px; }
.pin--parking { background: #2c6fbb; width: 24px; height: 24px; border-radius: 6px; }
.pin--stop { background: #e9530e; width: 22px; height: 22px; }
.pin--stop svg { width: 12px; height: 12px; }
.map-legend .pin { display: inline-grid; place-items: center; gap: 0; box-shadow: none; transform: scale(0.75); margin: -4px; }
.cabinet-label { background: var(--navy-deep); color: #fff; border: 0; border-radius: 8px; padding: 4px 9px; font-weight: 600; font-size: 0.8rem; box-shadow: var(--shadow); }
.cabinet-label::before { display: none; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: #d5deea; padding-block: 48px 28px; font-size: 0.9375rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.footer-name { font-weight: 600; font-size: 1.1rem; letter-spacing: -0.01em; line-height: 1.4; color: #fff; max-width: 30ch; }
.site-footer h3 { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: #9fb1c8; margin-bottom: 8px; }
.footer-bottom { margin-top: 36px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, 0.14); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; font-size: 0.8125rem; color: #9fb1c8; }
.to-top { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- Mobile action bar ---------- */
.mobile-bar { display: none; }

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .nav { gap: 18px; }
}
@media (max-width: 900px) {
  .burger { display: inline-flex; }
  .header-cta { display: none; }
  .nav {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; gap: 0; padding: 8px var(--gutter) 20px;
    background: var(--white); border-bottom: 1px solid var(--line); box-shadow: 0 24px 32px -24px rgba(27, 38, 51, 0.25);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 14px 0; font-size: 1.0625rem; border-bottom: 1px solid var(--line); }
  .nav a:last-child { border-bottom: 0; }
  .hero-grid, .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .hero-photo { order: -1; max-width: 420px; margin-inline: auto; width: 100%; }
  .hero-text { text-align: center; }
  .titles { justify-items: center; }
  .titles li::before { display: none; }
  .about-photo { max-width: 420px; margin-inline: auto; width: 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .map-card { min-height: 400px; }

  .mobile-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    display: grid; grid-template-columns: 1fr 1.4fr; gap: 10px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, 0.96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
  }
  .mobile-bar .btn { min-height: 48px; }
  body { padding-bottom: calc(70px + env(safe-area-inset-bottom)); }
}
@media (max-width: 680px) {
  body { font-size: 1rem; }
  .brand { font-size: 0.98rem; }
  .actions { grid-template-columns: 1fr; }
  .action { min-height: 0; flex-direction: row; justify-content: flex-start; text-align: left; gap: 14px; padding: 16px 18px; }
  .action--book { order: -1; flex-direction: column; text-align: center; padding: 22px 18px; }
  .spec-grid { grid-template-columns: 1fr; }
  .spec-head { padding: 28px 20px 24px; }
  .spec-list { padding: 0 20px 20px; }
  .partners-grid { gap: 10px; }
  .partners-grid a { flex: 1 1 calc(50% - 5px); height: 92px; padding: 16px 18px; }
  .cabinet-text { text-align: left; }
}
@media (max-width: 380px) {
  .brand { font-size: 0.9rem; }
  .site-header .wrap { gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
