/* ============================================================
   Cabinet Dr. Popescu Silvia — single stylesheet
   Palette derived from the logo: magenta, purple, gold, green.
   ============================================================ */

/* ---- Self-hosted Nunito (/fonts/, woff2, latin + latin-ext) ----
   Downloaded from Google Fonts July 2026 so no visitor data goes
   to fonts.googleapis.com / fonts.gstatic.com (GDPR). Variable
   file, covers weights 400–800. */
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/nunito-var-latin.woff2") format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/nunito-var-latin-ext.woff2") format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --magenta: #c6007e;
  --magenta-dark: #9d0064;
  --purple: #7c2e8c;
  --gold: #f5a200;
  --green: #6cb52c;
  --blue: #29a8df;
  --ink: #33222e;
  --muted: #6f5f68;
  --bg: #ffffff;
  --bg-tint: #fdf3f9;
  --bg-dark: #2a1430;
  --card-shadow: 0 6px 24px rgba(51, 34, 46, 0.10);
  --radius: 16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
/* keep anchor targets clear of the sticky header (~82px tall) */
[id] { scroll-margin-top: 98px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  font-family: 'Nunito', 'Segoe UI', system-ui, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  /* sticky footer: fill the viewport and let <main> grow so the footer
     stays at the bottom on short pages (e.g. brief doctor bios) */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1 0 auto; }

img { max-width: 100%; display: block; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* Keyboard skip link — visible only when focused */
.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--magenta);
  color: #fff;
  padding: 10px 16px;
  border-radius: 0 0 10px 10px;
  font-weight: 700;
  text-decoration: none;
  transition: top 0.15s ease;
}
.skip-link:focus { top: 0; }

h1, h2, h3, h4 { line-height: 1.2; font-weight: 800; }

.eyebrow {
  color: var(--purple);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.82rem;
  margin-bottom: 10px;
}

.center { text-align: center; }

.section { padding: 72px 0; }
.section-tint { background: var(--bg-tint); }
.section-title { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin-bottom: 14px; }
.section-lead { color: var(--muted); max-width: 640px; margin: 0 auto 20px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--magenta); color: #fff; box-shadow: 0 4px 14px rgba(198, 0, 126, 0.35); }
.btn-primary:hover { background: var(--magenta-dark); }
.btn-whatsapp { background: #25d366; color: #fff; box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35); }
.btn-whatsapp:hover { background: #1eb857; }
.btn-outline { border: 2px solid var(--magenta); color: var(--magenta); }
.btn-outline:hover { background: var(--magenta); color: #fff; }

/* ---------- Header ---------- */
/* Reserve the header's height while include.js fetches the partial, so content
   below doesn't jump when the chrome lands (≈ 8px×2 padding + 65px logo + 1px border). */
[data-include$="header.html"] { min-height: 82px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #f0e4ec;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 8px;
  padding-bottom: 8px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand img { width: 88px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 1.05rem; color: var(--magenta); }
.brand-text small { color: var(--muted); font-size: 0.78rem; }

.site-nav { display: flex; align-items: center; gap: 22px; }
.site-nav a { text-decoration: none; color: var(--ink); font-weight: 700; }
.site-nav a:hover { color: var(--magenta); }
.site-nav .nav-cta { color: #fff; }
.site-nav .nav-cta:hover { color: #fff; }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 3px; background: var(--ink); margin: 5px 0; border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(245, 162, 0, 0.14), transparent 60%),
    radial-gradient(900px 420px at -10% 110%, rgba(124, 46, 140, 0.12), transparent 60%),
    linear-gradient(180deg, #fef7fb 0%, #ffffff 100%);
  padding: 72px 0;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 48px;
  align-items: center;
}
.hero h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); margin-bottom: 16px; }
.hero .lead { font-size: 1.12rem; color: var(--muted); margin-bottom: 26px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-actions.center { justify-content: center; }
.hero-media img {
  border-radius: 24px;
  box-shadow: var(--card-shadow);
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}

/* Subtle entrance for the hero — opacity + transform only (no layout props,
   so zero CLS). The h1 and the hero image are deliberately excluded so they
   paint immediately and never delay LCP; only the supporting elements
   fade/rise. A tiny stagger keeps it tasteful. Auto-disabled by the
   reduced-motion rule above. */
@keyframes hero-rise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-copy > .eyebrow,
.hero-copy > .lead,
.hero-copy > .hero-actions {
  animation: hero-rise 0.45s ease-out both;
}
.hero-copy > .lead { animation-delay: 0.06s; }
.hero-copy > .hero-actions { animation-delay: 0.12s; }

/* ---------- Despre (split) ---------- */
.split {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
  align-items: center;
}
.split-media {
  width: min(360px, 100%);
  aspect-ratio: 1 / 1;
  margin: 0 auto;
  border-radius: 50%;
  overflow: hidden;               /* clip the zoomed photo to the circle */
  border: 6px solid #fff;
  outline: 4px solid rgba(198, 0, 126, 0.55);   /* magenta ring */
  box-shadow: var(--card-shadow);
}
.split-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* zoom in a touch so the white wedge at the photo's bottom is pushed
     out of the circle and the subject fills the frame */
  transform: scale(1.14);
  transform-origin: center 26%;
}
.split-copy h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: 14px; }
.split-copy p { margin-bottom: 14px; color: var(--muted); }
.split-copy .btn { margin-top: 6px; }

/* ---------- Servicii ---------- */
.card-grid {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;   /* centers orphan cards on the last row */
  gap: 24px;
}
.svc-card {
  flex: 0 1 330px;   /* fixed width so the last row centers instead of stretching */
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease;
}
.svc-card:hover { transform: translateY(-4px); }
.svc-card > img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; }
/* focal points for the portrait-orientation photos */
#adhd > img { object-position: center 22%; }
#logopedie > img { object-position: center 30%; }
#psihoterapie > img { object-position: center 85%; }
#consultatie-psihiatrica-pediatrica > img { object-position: center 20%; }
.svc-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.svc-body h3 { font-size: 1.08rem; margin-bottom: 10px; color: var(--purple); }
.svc-body p { color: var(--muted); font-size: 0.95rem; flex: 1; }
.svc-note {
  flex: 0 !important;
  margin-top: 12px;
  padding: 10px 12px;
  background: rgba(108, 181, 44, 0.12);
  border-left: 3px solid var(--green);
  border-radius: 8px;
  color: #3f6b18 !important;
  font-size: 0.88rem !important;
  font-weight: 600;
}
.svc-link {
  margin-top: 14px;
  color: var(--magenta);
  font-weight: 800;
  text-decoration: none;
}
.svc-link:hover { text-decoration: underline; }

/* ---------- Echipa ---------- */
.team-group {
  margin: 44px 0 20px;
  font-size: 1.25rem;
  color: var(--purple);
  border-left: 5px solid var(--gold);
  padding-left: 12px;
}
.team-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;   /* centers orphan cards on the last row */
  gap: 22px;
}
.team-card {
  flex: 0 1 232px;           /* ~4 per row on desktop; last row stays centered */
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  text-align: center;
}
.team-card img { aspect-ratio: 1 / 1; object-fit: cover; object-position: center top; width: 100%; }
/* figcaption is a column so the link pins to the card bottom regardless of
   how many lines the role label wraps to — keeps links aligned across a row */
.team-card { display: flex; flex-direction: column; }
.team-card figcaption {
  padding: 14px 12px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.team-card strong { display: block; font-size: 1rem; }
/* reserve 2 lines for every role label so single- and two-line roles align across a row */
.team-card span { color: var(--muted); font-size: 0.85rem; line-height: 1.3; min-height: 2.6em; }
/* whole-card link to the bio page (cards without .team-more stay static) */
.team-card { position: relative; transition: transform 0.2s ease; }
.team-card:has(.team-more):hover { transform: translateY(-4px); }
.team-card:has(.team-more):hover .team-more { text-decoration: underline; }
.team-more {
  margin-top: auto;
  padding-top: 10px;
  color: var(--magenta);
  font-weight: 800;
  font-size: 0.85rem;
  text-decoration: none;
}
.team-more::after { content: ""; position: absolute; inset: 0; }

/* ---------- Doctor bio pages ---------- */
.back-link { color: var(--purple); text-decoration: none; font-weight: 700; }
.back-link:hover { color: var(--magenta); }

/* ---- Legal pages (/confidentialitate/) ---- */
.legal-content { max-width: 760px; margin: 0 auto; }
.legal-content h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin: 14px 0 4px; }
.legal-updated { color: var(--muted); font-size: 0.88rem; margin-bottom: 28px; }
.legal-content h2 { font-size: 1.25rem; margin: 30px 0 8px; }
.legal-content ul { padding-left: 1.3em; margin: 6px 0 14px; }
.legal-content li { margin-bottom: 6px; }
.legal-content a { color: var(--magenta); }
.doctor-hero {
  display: flex;
  align-items: center;
  gap: 36px;
  flex-wrap: wrap;
  margin: 18px 0 34px;
}
.doctor-photo {
  width: 220px;
  height: 220px;
  object-fit: cover;
  object-position: center top;
  border-radius: 50%;
  border: 5px solid #fff;
  outline: 4px solid rgba(198, 0, 126, 0.55);
  box-shadow: var(--card-shadow);
}
.doctor-hero h1 { font-size: clamp(1.7rem, 3.2vw, 2.3rem); margin-bottom: 6px; }
.doctor-role { color: var(--purple); font-weight: 700; margin-bottom: 18px; }
.doctor-bio { max-width: 780px; }
.doctor-bio p { margin-bottom: 14px; }
.doctor-bio h2 { font-size: 1.15rem; color: var(--purple); margin: 24px 0 10px; }
.doctor-bio ul, .doctor-bio ol { margin: 0 0 16px 22px; }
.doctor-bio li { margin-bottom: 6px; }
.mini-footer {
  background: var(--bg-dark);
  color: #e9d9e4;
  text-align: center;
  padding: 24px 20px;
  font-size: 0.9rem;
  margin-top: 40px;
}
.mini-footer a { color: #fff; text-decoration: none; }
.mini-footer a:hover { color: var(--gold); }

/* ---------- CTA band ---------- */
.cta-band {
  background:
    radial-gradient(800px 300px at 90% 0%, rgba(245, 162, 0, 0.18), transparent 60%),
    radial-gradient(700px 300px at 5% 100%, rgba(198, 0, 126, 0.25), transparent 60%),
    var(--bg-dark);
  color: #fff;
  padding: 72px 0;
  text-align: center;
}
.cta-inner h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); margin-bottom: 14px; }
.cta-inner p { max-width: 620px; margin: 0 auto 26px; color: #e9d9e4; }

/* ---------- Contact & locații ---------- */
.contact-methods {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 26px 0 40px;
}
.contact-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 2px solid #f0dcea;
  border-radius: 999px;
  padding: 10px 20px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.contact-chip:hover { border-color: var(--magenta); transform: translateY(-2px); }
.fb-icon, .wa-icon { display: block; flex-shrink: 0; }

.locations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 1120px;
}
.location-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--card-shadow);
  padding: 20px;
  /* column so the map pins to the card bottom no matter how many lines the
     heading/address wrap to — keeps maps aligned across a row (~954–1087px) */
  display: flex;
  flex-direction: column;
}
.location-card h3 { color: var(--purple); margin-bottom: 4px; font-size: 1.1rem; }
.location-card p { color: var(--muted); font-size: 0.92rem; margin-bottom: 14px; }
.map-wrap {
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  margin-top: auto;
  flex-shrink: 0;
}
.map-wrap iframe { width: 100%; height: 100%; border: 0; }

/* Click-to-load map placeholder (GDPR) — shows a locally hosted
   screenshot of the map (inline background-image, images/maps/);
   the inline script swaps it for the live Google iframe when pressed. */
.map-load {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background-color: var(--bg-tint);
  background-size: cover;
  /* bottom-pinned so Google's attribution line survives any vertical crop */
  background-position: center bottom;
  cursor: pointer;
  overflow: hidden;
}
.map-load:focus-visible {
  outline: 3px solid var(--magenta);
  outline-offset: 2px;
}
.map-load .map-load-note {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  max-width: calc(100% - 24px);
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(42, 20, 48, 0.85);
  color: #f3e8f0;
  font-size: 0.74rem;
  line-height: 1.4;
  transition: background 0.2s;
}
.map-load:hover .map-load-note,
.map-load:focus-visible .map-load-note { background: var(--bg-dark); }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-dark); color: #e9d9e4; padding: 56px 0 0; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 1.1fr 1fr;
  gap: 40px;
  padding-bottom: 36px;
}
.footer-social a { display: inline-flex; align-items: center; gap: 8px; color: #e9d9e4; }
.footer-social a:hover { color: var(--gold); }
.footer-social svg { flex-shrink: 0; }
.footer-logo { width: 132px; height: auto; margin-bottom: 14px; }
.site-footer p { font-size: 0.92rem; }
.site-footer h4 { color: var(--gold); margin-bottom: 12px; font-size: 1rem; }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 8px; font-size: 0.92rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 18px;
  padding-bottom: 18px;
  text-align: center;
}
.footer-bottom p { font-size: 0.85rem; color: #bfa3b6; }
.footer-bottom .footer-credit { margin-top: 4px; font-size: 0.76rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-inner, .split { grid-template-columns: 1fr; gap: 32px; }
  .hero-media { order: -1; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .site-nav .nav-cta { margin-top: 4px; }

  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    align-items: flex-start;
    padding: 18px 20px;
    gap: 14px;
    border-bottom: 1px solid #f0e4ec;
    box-shadow: 0 12px 24px rgba(51, 34, 46, 0.12);
  }
  .site-nav.open { display: flex; }
}

@media (max-width: 480px) {
  .section { padding: 52px 0; }
  .brand img { width: 64px; }
  .brand-text strong { font-size: 0.95rem; }
}
