/* ========================================================================
   CLINN — Design System
   Aesthetic: clinical, calm, trustworthy. YMYL-safe. NOT "weed lifestyle".
   --------------------------------------------------------------------------
   Type:       Inter (sans, UI/body)  +  Source Serif 4 (serif, editorial H1)
   Palette:    deep teal primary, warm off-white surfaces, sage accent,
               graphite text, soft clinical blue for trust signals.
   Radius:     8 / 12 / 16 — soft, never pill-y for content surfaces
   Shadow:     barely-there, single-layer
   Spacing:    8-pt scale
   ======================================================================== */

:root {
  /* Brand — derivati dal logo CLINN (slate del wordmark + lime della foglia) */
  --teal-900: #1a2528;  /* footer/band scure — più profondo del wordmark */
  --teal-800: #2d3c41;  /* wordmark esatto · bottoni primari · h1 */
  --teal-700: #3d5158;  /* nav active / link */
  --teal-600: #5a7079;  /* slate medio */
  --teal-100: #d7dee0;  /* slate chiaro */
  --teal-50:  #eef1f2;  /* bg tonale */

  /* Lime / sage — colore foglia del logo (#a7c140) */
  --sage-600: #8aa530;  /* lime profondo */
  --sage-400: #a7c140;  /* LOGO leaf · accenti, dot, badge "più scelto" */
  --sage-100: #eef3d4;  /* lime chiaro · badge soft */

  /* Trust blue (used very sparingly — verified badges, info) */
  --blue-700: #2a5d8f;
  --blue-100: #dde9f4;

  /* Neutrals — warm, low chroma */
  --ink-900: #14201f;
  --ink-700: #344241;
  --ink-500: #5b6a69;
  --ink-400: #7c8a89;
  --ink-300: #aab3b2;
  --ink-200: #d4dad9;
  --ink-100: #e9eceb;
  --paper:   #fbfaf6;   /* warm off-white page */
  --paper-2: #f5f3ec;   /* slightly tinted band */
  --white:   #ffffff;

  /* Semantic */
  --rating: #b88b1e;      /* muted gold for stars */
  --price-strike: #94a09e;
  --danger: #b14a3a;

  /* Type */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-serif: "Source Serif 4", "Source Serif Pro", Georgia, serif;

  /* Shadow & radii */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --r-xl: 20px;
  --shadow-1: 0 1px 2px rgba(20, 32, 31, 0.04), 0 0 0 1px rgba(20, 32, 31, 0.06);
  --shadow-2: 0 6px 18px -8px rgba(20, 32, 31, 0.12), 0 0 0 1px rgba(20, 32, 31, 0.06);
}

/* ───── Font Tweak: data-font sull'<html> sovrascrive le variabili type ─────
   "default"  → Inter (sans) + Source Serif 4 (serif) — mockup attuale
   "lexend"   → Lexend ovunque (sans + headings) — allineato a clinn.it
   ───────────────────────────────────────────────────────────────────────── */
:root[data-font="lexend"] {
  --font-sans: "Lexend", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-serif: "Lexend", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}
/* Lexend ha letter-spacing più ampio: rilascio il tracking sui display
   per evitare che gli H1 risultino "tirati" rispetto a Source Serif 4. */
:root[data-font="lexend"] .h-display,
:root[data-font="lexend"] .h1,
:root[data-font="lexend"] .index-title,
:root[data-font="lexend"] .number-figure,
:root[data-font="lexend"] .mega-title {
  letter-spacing: -0.02em;
  font-weight: 500;
}
:root[data-font="lexend"] .h2,
:root[data-font="lexend"] .h3 {
  letter-spacing: -0.01em;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  color: var(--ink-900);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "ss01", "cv11";
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

/* ───── Layout primitives ───── */
.page {
  width: 100%;
  /* Full-width: gli sfondi delle fasce (.band-*, .header, .footer) vanno
     edge-to-edge sul viewport. Il contenuto \u00e8 limitato dal .container (1440). */
  background: var(--paper);
  color: var(--ink-900);
  overflow-x: clip; /* evita scroll orizzontale */
}
.container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 40px;
}
.container-narrow {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 40px;
}

/* ───── Top bar ───── */
.topbar {
  background: var(--teal-900);
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  letter-spacing: 0.01em;
}
.topbar-inner {
  height: 38px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.topbar-spacer { flex: 1; }
.topbar-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.85);
  font-weight: 400;
}
.topbar-link:hover { color: white; }
.topbar-account {
  border-left: 1px solid rgba(255,255,255,0.18);
  padding-left: 18px;
}

/* ───── Header ───── */
.header {
  background: var(--paper);
  border-bottom: 1px solid var(--ink-100);
  /* posizione e livello: più sotto, «Testata che resta in cima» */
}
.header-inner {
  height: 78px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--teal-900);
}
.brand-logo {
  height: 36px;
  width: auto;
  display: block;
}
.brand-logo-footer { height: 32px; }
.brand-mark {
  width: 30px;
  height: 30px;
}
.brand-word {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: 0.06em;
  color: var(--teal-900);
}
.nav {
  display: flex;
  align-items: center;
  gap: 40px;
  font-size: 14.5px;
  color: var(--ink-700);
  font-weight: 500;
}
.nav-item-wrap {
  position: static;
  display: inline-flex;
  align-items: center;
}
.nav .nav-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

/* ───── Megamenu ───── */
.mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity 160ms ease, transform 160ms ease;
}
.nav-item-wrap.has-mega:hover .mega,
.nav-item-wrap.has-mega:focus-within .mega {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.mega::before {
  content: "";
  position: absolute;
  inset: -14px 0 0 0;
  height: 14px;
}
/* Hover-bridge sotto ogni voce con megamenu: copre la "zona morta" tra il
   fondo del link (centrato nei 78px di header) e l'inizio della .mega.
   Senza questo, spostando il mouse verso le sottovoci si perde l'hover
   sul .nav-item-wrap e il menu si chiude. */
.nav .nav-item { position: relative; }
.nav-item-wrap.has-mega .nav-item::after {
  content: "";
  position: absolute;
  left: -16px;
  right: -16px;
  top: 100%;
  height: 26px;
  /* invisibile, ma cattura il puntatore → il :hover sul nav-item-wrap
     resta valido finché il cursore è sopra a questo ponte. */
}
.mega-inner {
  margin: 0 auto;
  max-width: 1440px;
  padding: 32px 40px 28px;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: 0 0 var(--r-lg) var(--r-lg);
  box-shadow: 0 18px 40px -20px rgba(20, 32, 31, 0.18), 0 0 0 1px rgba(20, 32, 31, 0.04);
}
.mega-inner-narrow { max-width: 1080px; }
.mega-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--ink-100);
  margin-bottom: 22px;
}
.mega-title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--ink-900);
  margin: 6px 0 0;
  max-width: 640px;
  line-height: 1.25;
}
.mega-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px 8px;
}
.mega-grid-3 {
  grid-template-columns: repeat(3, 1fr);
  gap: 6px 10px;
}
.mega-card {
  display: block;
  padding: 14px 16px;
  border-radius: var(--r-md);
  border: 1px solid transparent;
  transition: background 120ms, border-color 120ms;
  background: transparent;
}
.mega-card:hover {
  background: var(--paper-2);
  border-color: var(--ink-100);
}
.mega-card strong {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink-900);
  margin-bottom: 4px;
}
.mega-card .small {
  display: block;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink-500);
}
.mega-card.is-featured {
  background: var(--teal-50);
  border-color: var(--teal-100);
}
.mega-card.is-featured strong { color: var(--teal-900); }
.mega-card.is-featured .small { color: var(--ink-700); }
.mega-tag {
  display: inline-block;
  margin-top: 8px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--teal-800);
  color: white;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.mega-card-icon {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
}
.mega-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--teal-50);
  color: var(--teal-700);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.mega-foot {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--ink-100);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.mega-foot-link,
.mega-foot-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--teal-800);
}
.mega-foot-link:hover,
.mega-foot-cta:hover { color: var(--teal-900); }
.mega-foot-cta {
  margin-left: auto;
  padding: 10px 16px;
  background: var(--teal-900);
  color: white;
  border-radius: var(--r-md);
}
.mega-foot-cta:hover { color: white; background: var(--ink-900); }

/* Make the header allow megamenu overflow */
.header { overflow: visible; }

/* Testata che resta in cima, sparisce scorrendo in giù e riappare scorrendo
   in su (desktop e telefono). Le classi sull'<html> le mette sv-theme.js;
   senza JavaScript resta semplicemente fissa in cima. La barra scura sopra
   scorre via. Si nasconde spostando `top`, non con `transform`: un transform
   farebbe da riferimento ai figli `position: fixed` (menu mobile e velo). */
.header {
  position: sticky;
  top: 0;
  z-index: 50; /* sopra il contenuto e il bottone «Prenota ora» (40) */
  transition: top 260ms ease, box-shadow 200ms ease;
}
html.svt-testata-staccata .header { box-shadow: 0 6px 18px rgba(20, 32, 31, 0.08); }
html.svt-testata-nascosta .header {
  top: calc(-1 * var(--svt-testata-h, 80px) - 24px); /* anche l'ombra esce dallo schermo */
  box-shadow: none;
}
@media (prefers-reduced-motion: reduce) {
  .header { transition: none; }
}
.header-inner { position: static; }
.nav .nav-item:hover { color: var(--teal-800); }
.nav .nav-item.active { color: var(--teal-900); border-bottom-color: var(--teal-700); }
.nav-spacer { flex: 1; }
.header-cta {
  display: flex;
  align-items: center;
  gap: 18px;
}
.account-link {
  font-size: 14px;
  color: var(--ink-700);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.account-link:hover { color: var(--teal-800); }

/* ───── Buttons ───── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 15px;
  line-height: 1;
  padding: 12px 18px;
  border-radius: var(--r-md);
  transition: background 120ms;
  white-space: nowrap;
}
.btn-primary {
  background: var(--teal-800);
  color: white;
}
.btn-primary:hover { background: var(--teal-900); }

/* ───── CTA Tweaks: cambia stile globalmente con data-cta sull'<html> ───── */
:root[data-cta="lime"] .btn-primary {
  background: var(--sage-400);
  color: var(--teal-900);
}
:root[data-cta="lime"] .btn-primary:hover {
  background: var(--sage-600);
  color: white;
}
:root[data-cta="outline"] .btn-primary {
  background: transparent;
  color: var(--teal-900);
  border: 2px solid var(--sage-400);
  padding: 10px 16px;
}
:root[data-cta="outline"] .btn-primary:hover {
  background: var(--sage-400);
  color: var(--teal-900);
}
:root[data-cta="limeDeep"] .btn-primary {
  background: var(--sage-600);
  color: white;
}
:root[data-cta="limeDeep"] .btn-primary:hover {
  background: var(--sage-400);
  color: var(--teal-900);
}
.btn-secondary {
  background: white;
  color: var(--teal-900);
  border: 1px solid var(--ink-200);
}
.btn-secondary:hover { border-color: var(--teal-700); }
.btn-ghost {
  background: transparent;
  color: var(--teal-800);
  padding: 12px 0;
}
.btn-lg { padding: 15px 22px; font-size: 16px; }
.btn-sm { padding: 8px 12px; font-size: 13.5px; }

/* ───── Type ───── */
.eyebrow {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-700);
}
.h-display {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 60px;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--ink-900);
  margin: 0;
}
.h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 44px;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--ink-900);
  margin: 0;
}
.h2 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--ink-900);
  margin: 0;
}
.h3 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 19px;
  line-height: 1.3;
  color: var(--ink-900);
  margin: 0;
}
.lede {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-700);
  margin: 0;
}
.body {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-700);
}
.small {
  font-size: 13.5px;
  color: var(--ink-500);
}
.mono {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
}

/* ───── Surfaces / Cards ───── */
.card {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1);
}
.tile {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
}
.divider {
  height: 1px;
  background: var(--ink-100);
  border: 0;
  margin: 0;
}

/* ───── Badges & chips ───── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--teal-50);
  color: var(--teal-800);
}
.badge-blue { background: var(--blue-100); color: var(--blue-700); }
.badge-sage { background: var(--sage-100); color: #496334; }
.badge-neutral { background: var(--ink-100); color: var(--ink-700); }
.dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--sage-600);
  display: inline-block;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--ink-200);
  background: white;
  color: var(--ink-700);
  cursor: pointer;
}
.chip:hover { border-color: var(--teal-700); color: var(--teal-800); }
.chip.active {
  background: var(--teal-900);
  color: white;
  border-color: var(--teal-900);
}

/* ───── Footer ───── */
.footer {
  background: var(--teal-900);
  color: rgba(255,255,255,0.78);
  padding: 64px 0 32px;
}
.footer .container { padding: 0 40px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
  gap: 48px;
  align-items: flex-start;
}
.footer h4 {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin: 0 0 18px;
}
.footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.footer ul a { color: rgba(255,255,255,0.85); font-size: 14.5px; }
.footer ul a:hover { color: white; }
.footer-brand .brand-word { color: white; }
.footer-brand p { font-size: 14px; line-height: 1.55; color: rgba(255,255,255,0.7); margin: 16px 0 0; max-width: 320px; }
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 22px;
  font-size: 14px;
}
.footer-contact a {
  color: rgba(255,255,255,0.85);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.footer-fineprint {
  font-size: 12px !important;
  margin-top: 24px !important;
  color: rgba(255,255,255,0.45) !important;
  line-height: 1.6 !important;
}
.footer-partners {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.12);
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 12px 32px;
  align-items: center;
}
.footer-partner-label {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
}
.footer-partner-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-partner-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,0.07);
  font-size: 13px;
  color: rgba(255,255,255,0.78);
  border: 1px solid rgba(255,255,255,0.08);
}
.footer-bottom {
  margin-top: 40px;
  padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,0.12);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  color: rgba(255,255,255,0.55);
  gap: 24px;
}
.footer-bottom a { color: rgba(255,255,255,0.7); border-bottom: 1px solid currentColor; }

/* ───── Breadcrumbs ───── */
.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-500);
}
.crumbs .sep { opacity: 0.5; }
.crumbs a:hover { color: var(--teal-800); }
.crumbs .current { color: var(--ink-700); }

/* ───── Star rating ───── */
.stars { display: inline-flex; gap: 2px; color: var(--rating); }
.stars svg { width: 14px; height: 14px; }

/* ───── Image placeholder ───── */
.imgph {
  background:
    repeating-linear-gradient(135deg,
      rgba(20,32,31,0.04) 0 8px,
      rgba(20,32,31,0.00) 8px 16px),
    var(--paper-2);
  border-radius: var(--r-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-400);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ───── Bar chart for RWE Clinn ───── */
.bar-row { display: grid; grid-template-columns: 220px 1fr 56px; align-items: center; gap: 16px; }
.bar-row + .bar-row { margin-top: 14px; }
.bar-track { height: 10px; background: var(--ink-100); border-radius: 999px; overflow: hidden; }
/* display:block non e' decorativo: .bar-fill e' uno <span> dentro .bar-track,
   che e' un blocco normale, quindi restava inline — e un elemento inline
   IGNORA width e height. Il riquadro misurava 0x0: si vedeva solo la traccia
   grigia e la barra non si riempiva mai, qualunque valore avesse. */
.bar-fill { display: block; height: 100%; background: var(--teal-700); border-radius: 999px; }
.bar-label { font-size: 14px; color: var(--ink-700); }
.bar-value { font-size: 14px; font-weight: 600; color: var(--teal-900); text-align: right; font-variant-numeric: tabular-nums; }

/* ───── Accordion ───── */
.accord-item {
  border-bottom: 1px solid var(--ink-100);
  padding: 22px 0;
}
.accord-item:first-child { padding-top: 0; }
.accord-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 17px;
  font-weight: 500;
  color: var(--ink-900);
}
.accord-a {
  margin-top: 12px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-700);
  max-width: 760px;
}
.accord-icon {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid var(--ink-200);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-left: 16px;
}

/* ───── Page band variants ───── */
.band-paper2 { background: var(--paper-2); }
.band-teal { background: var(--teal-900); color: white; }
.band-teal .h2, .band-teal .h1, .band-teal .h3 { color: white; }
.band-teal .body, .band-teal .small { color: rgba(255,255,255,0.78); }
.band-teal .eyebrow { color: var(--teal-100); }

/* ───── Misc ───── */
.kbd-link {
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
}
.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 12px; }
.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-40 { margin-top: 40px; }
.mt-64 { margin-top: 64px; }

/* ───── Home — hero ───── */
/* Padding ridotto (5 ott 2026, era 80/96) insieme alla foto quadrata: su un
   monitor 1920×1080 il browser lascia ~930–950 px visibili, e hero + fascia dei
   riconoscimenti devono starci senza scorrere. Sotto ne restano 64: la card della
   recensione sporge di 32 sotto la foto. Misura: run-misura-hero.sh. */
.hero {
  padding: 56px 0 64px;
  background:
    radial-gradient(1200px 600px at -10% -10%, var(--teal-50), transparent 60%),
    radial-gradient(900px 500px at 110% 10%, var(--sage-100), transparent 60%),
    var(--paper);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 72px;
  align-items: center;
}

/* Hero visual: contenitore relativo per immagine + overlay recensioni */
.hero-visual {
  position: relative;
  isolation: isolate; /* nuovo stacking context, z-index locali */
}
.hero-visual image-slot {
  position: relative;
  z-index: 1;
  box-shadow: var(--shadow-2);
  border-radius: var(--r-lg);
  overflow: hidden;
}

/* Chip aggregato in alto a destra */
.hero-rating-chip {
  position: absolute;
  top: 20px;
  right: -16px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-2);
}
.hero-rating-chip strong {
  display: block;
  font-size: 15px;
  color: var(--ink-900);
  font-weight: 600;
}
.hero-rating-chip .small {
  display: block;
  font-size: 12px;
  color: var(--ink-500);
  margin-top: 1px;
}
/* Una riga per piattaforma (MioDottore, Google — 29 set 2026): marchio, voto e
   stelle sulla stessa riga, la dicitura sotto. */
.hero-rating-chip { flex-direction: column; align-items: stretch; gap: 10px; max-width: 300px; }
.hero-rating-row { display: flex; align-items: flex-start; gap: 10px; }
.hero-rating-row > .agr-source-icon { flex: none; margin-top: 2px; }
.hero-rating-row strong { display: inline-block; margin-right: 6px; vertical-align: middle; }
.hero-rating-row .stars { vertical-align: middle; }
.hero-rating-chip--multi .hero-rating-row + .hero-rating-row { padding-top: 10px; border-top: 1px solid var(--ink-100); }

/* Senza foto: chip e card in colonna, invece che sovrapposti al vuoto. */
.hero-visual--senza-foto {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}
.hero-visual--senza-foto .hero-rating-chip,
.hero-visual--senza-foto .hero-review {
  position: static;
}
.hero-visual--senza-foto .hero-review { width: 100%; }

/* Card recensione hero — sovrapposta in basso */
.hero-review {
  position: absolute;
  left: -36px;
  right: 32px;
  bottom: -32px;
  z-index: 3;
  padding: 22px 24px;
  margin: 0;
  background: white;
  box-shadow: var(--shadow-2);
}
/* Sotto i 960 il margine laterale della pagina è 28 px (20 sotto i 640): la card,
   spostata di 36 px a sinistra, usciva dallo schermo, mentre il chip del voto
   (-16 px a destra) restava intero. Stesso sporgere del chip, dall'altro lato.
   ⚠️ Queste due regole devono stare DOPO quella sopra: stessa specificità. */
@media (max-width: 960px) {
  .hero-review { left: -16px; right: 16px; }
}
/* Su telefono la card della singola recensione non si mostra (5 ott 2026,
   scelta dell'utente: «carica un po' troppo»). Resta nel markup: per rimetterla
   basta togliere questa regola. */
@media (max-width: 640px) {
  .hero-review { display: none; }
  /* Senza la card, il chip dei voti va in basso, a filo della foto (5 ott 2026). */
  .hero-rating-chip { top: auto; bottom: 0; }
}
.hero-review-head {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 12px;
  align-items: center;
}
.hero-review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--teal-50);
  color: var(--teal-800);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.hero-review-head strong {
  display: block;
  font-size: 14.5px;
  color: var(--ink-900);
  font-weight: 600;
}
.hero-review-head .small {
  display: block;
  font-size: 12.5px;
  color: var(--ink-500);
  margin-top: 2px;
}
.hero-review-quote {
  margin: 16px 0 12px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-700);
  font-style: normal;
  text-wrap: pretty;
}
.hero-review-source {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--teal-700);
  font-weight: 500;
}
.hero-review-source::before {
  content: "✓";
  display: inline-block;
  width: 14px;
  height: 14px;
  line-height: 14px;
  text-align: center;
  border-radius: 50%;
  background: var(--sage-100);
  color: var(--sage-600);
  font-size: 10px;
  font-weight: 700;
}

/* ───── Home — awards ───── */
.awards-strip {
  border-top: 1px solid var(--ink-100);
  border-bottom: 1px solid var(--ink-100);
  background: var(--paper);
  padding: 28px 0;
}
.awards-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.award-item {
  display: flex;
  align-items: center;
  gap: 16px;
}
.award-mark {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--teal-50);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal-700);
  flex-shrink: 0;
}
.award-item strong {
  display: block;
  font-size: 14.5px;
  color: var(--ink-900);
  font-weight: 600;
  margin-bottom: 2px;
}
.award-item .small { font-size: 12.5px; }

/* ───── Home — 3 step ───── */
.step-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 56px;
}
.step-tile {
  padding: 28px;
  position: relative;
}
/* Verdi come .badge-sage (4 ott 2026, prima teal): in tutto il sito, non solo
   negli ambiti clinici. */
.step-num {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  color: #496334;
  font-size: 13px;
  letter-spacing: 0.06em;
  display: inline-block;
  margin-bottom: 16px;
  padding: 4px 10px;
  background: var(--sage-100);
  border-radius: 999px;
}

/* ───── Home — Feature pair (Card / Welcome kit) ───── */
.feature-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.feature-card {
  display: grid;
  grid-template-columns: 280px 1fr;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: border-color 120ms;
}
.feature-card:hover { border-color: var(--teal-700); }
.feature-img {
  height: 100%;
  min-height: 260px;
  border-radius: 0;
  font-size: 10px;
}
.feature-body {
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ───── Home — Numeri di Clinn ───── */
.numbers-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(6, 1fr);
  gap: 16px;
  margin-top: 56px;
}
.number-tile {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 24px;
}
.number-figure {
  font-family: var(--font-serif);
  font-size: 44px;
  line-height: 1;
  color: var(--teal-800);
  margin-bottom: 12px;
}
.numbers-grid .number-tile:first-child {
  background: var(--teal-900);
  color: white;
  border-color: var(--teal-900);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.numbers-grid .number-tile:first-child .number-figure { color: white; font-size: 28px; }
.numbers-grid .number-tile:first-child .small { color: rgba(255,255,255,0.78); font-size: 14px; }

/* ───── Home — Rating badges + testimonial grid ───── */
.rating-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--ink-100);
  background: white;
  border-radius: var(--r-md);
}
.rating-badge strong { display: block; font-size: 14px; color: var(--ink-900); }
.rating-badge .small { font-size: 11.5px; }

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 48px;
}
.testimonial { padding: 24px; display: flex; flex-direction: column; }
.testimonial-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--ink-100);
}
.testimonial-foot strong { display: block; }
.testimonial-foot .small { display: block; }

/* ───── Home — Patologie grid ───── */
.patologie-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 48px;
}
.patologia-card {
  display: block;
  padding: 28px;
  transition: border-color 120ms;
}
.patologia-card:hover { border-color: var(--teal-700); }

/* ───── Home — Professionisti pills ───── */
.prof-pill {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  background: var(--paper-2);
  border-radius: var(--r-md);
  min-width: 180px;
  color: var(--teal-800);
}
.prof-pill strong { display: block; font-size: 14px; color: var(--ink-900); margin-bottom: 2px; }
.prof-pill .small { font-size: 12.5px; color: var(--ink-500); }

/* ───── Home — Callback (band-teal CTA) ───── */
.callback-list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: rgba(255,255,255,0.85);
  font-size: 15px;
}
.callback-list li {
  display: flex;
  align-items: center;
  gap: 10px;
}
/* Testo a sinistra, modulo a destra. Il modulo aveva una larghezza fissa di
   380px e, con nome, cognome, cellulare, email e due consensi, risultava stretto:
   ora prende poco più di metà della riga (29 set 2026). */
.callback-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 56px;
  align-items: center;
}
.callback-form {
  padding: 32px;
  background: white;
  color: var(--ink-900);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.band-teal .callback-form-title { color: var(--ink-900); margin: 0 0 4px; }
.callback-field { display: flex; flex-direction: column; gap: 6px; }
.callback-field span { font-size: 12px; font-weight: 600; color: var(--ink-500); letter-spacing: 0.04em; text-transform: uppercase; }
.callback-field input {
  padding: 12px 14px;
  border: 1px solid var(--ink-200);
  border-radius: 8px;
  font-family: inherit;
  font-size: 14.5px;
  color: var(--ink-900);
  outline: none;
}
.callback-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--ink-700);
  margin: 6px 0;
}

/* ───── Subpage hero (Come funziona) ───── */
.subpage-hero {
  padding: 56px 0 64px;
  background:
    radial-gradient(900px 480px at 100% 0%, var(--teal-50), transparent 60%),
    var(--paper);
}

/* ───── Compare table (Basic / Plus; chiave dei dati: standard) ───── */
.compare-row {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.2fr;
  align-items: center;
  padding: 18px 28px;
  border-bottom: 1px solid var(--ink-100);
  font-size: 15.5px;
  color: var(--ink-900);
}
.compare-row.is-last { border-bottom: 0; }
.compare-row.compare-head {
  background: var(--paper-2);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-500);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.compare-plus { color: var(--teal-800); font-weight: 600; }
.compare-row.compare-head .compare-plus { color: var(--teal-700); }

/* ───── Patology — Percorso terapeutico ───── */
.path-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 40px;
}
.path-tile {
  padding: 24px;
}
.preliminary-cta {
  margin-top: 32px;
  padding: 36px 40px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: center;
  background: var(--teal-50);
  border-color: var(--teal-100);
}

/* ───── Article — cross-link to patology & doctors ───── */
.cross-link-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.cross-link {
  display: block;
  padding: 24px 26px;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  background: white;
  transition: border-color 120ms, transform 120ms;
}
.cross-link:hover {
  border-color: var(--teal-700);
  transform: translateY(-2px);
}
.cross-link-eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal-700);
}
.cross-link-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--teal-800);
}
.cross-link-pathology { background: var(--paper-2); border-color: var(--ink-100); }
.cross-link-doctors { background: var(--teal-900); border-color: var(--teal-900); color: white; }
.cross-link-doctors .cross-link-eyebrow { color: var(--teal-100); }
.cross-link-doctors .h3 { color: white; }
.cross-link-doctors .small { color: rgba(255,255,255,0.78); }
.cross-link-doctors .cross-link-cta { color: white; }

/* ──────────────────────────────────────────────────────────────────────────
   PREZZI — apertura della pagina e «Come si paga».
   Il calcolatore a slider e «Cosa è incluso» sono stati tolti il 1 ott 2026:
   la tabella dei costi che li sostituisce sta in pages/prezzi.css.
   ────────────────────────────────────────────────────────────────────────── */
.estim-hero {
  padding: 56px 0 32px;
  background:
    radial-gradient(800px 320px at 50% 0%, var(--teal-50), transparent 70%),
    var(--paper);
  text-align: center;
}

/* Come si paga — 3 step orizzontali con linea */
.payment-flow {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin-top: 40px;
  position: relative;
}
.payment-step {
  padding: 28px 28px 28px 0;
  position: relative;
}
.payment-step + .payment-step {
  padding-left: 28px;
  border-left: 1px solid var(--ink-100);
}
.payment-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--teal-900);
  color: white;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 13px;
  margin-bottom: 16px;
}
.payment-step strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-900);
  margin-bottom: 8px;
}
.payment-step p {
  margin: 0;
  font-size: 14px;
  color: var(--ink-500);
  line-height: 1.55;
}

/* ──────────────────────────────────────────────────────────────────────────
   PROFESSIONISTI — Medici / Farmacie
   ────────────────────────────────────────────────────────────────────────── */

/* Big segmented control sopra l'hero */
.role-switch {
  display: inline-flex;
  gap: 4px;
  padding: 6px;
  background: var(--paper-2);
  border: 1px solid var(--ink-100);
  border-radius: 999px;
  box-shadow: var(--shadow-1);
}
.role-switch-btn {
  background: transparent;
  border: none;
  padding: 12px 26px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-500);
  transition: background 140ms, color 140ms, box-shadow 140ms;
}
.role-switch-btn:hover { color: var(--ink-900); }
.role-switch-btn.is-active {
  background: var(--teal-900);
  color: white;
  box-shadow: 0 2px 6px rgba(20,32,31,0.18);
}
.role-switch-icon {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--teal-50);
  color: var(--teal-700);
  border-radius: 50%;
}
.role-switch-btn.is-active .role-switch-icon {
  background: rgba(255,255,255,0.16);
  color: white;
}

/* Pilastri — layout asimmetrico card grande con aside */
.pillar-stack {
  display: grid;
  gap: 32px;
  margin-top: 44px;
}
.pillar {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 48px;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-xl);
  padding: 44px;
  box-shadow: var(--shadow-1);
}
.pillar:nth-child(even) {
  grid-template-columns: 1fr 320px;
}
.pillar:nth-child(even) .pillar-aside { order: 2; }
.pillar:nth-child(even) .pillar-blocks { order: 1; }
.pillar-aside {
  padding-right: 8px;
}
.pillar-tag {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-700);
  background: var(--teal-50);
  padding: 5px 10px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 22px;
}
.pillar-icon {
  display: inline-flex;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--teal-900);
  color: white;
  align-items: center;
  justify-content: center;
}
/* Percorsi dei medici: la foglia del fonendoscopio nel lime del logo. */
.pillar-icon .icon-foglia { fill: var(--sage-400); }
.pillar-icon .icon-foglia path[stroke] { stroke: var(--sage-400); }
.pillar-blocks {
  display: grid;
  gap: 24px;
}
.pillar-block {
  padding: 22px 0;
  border-top: 1px solid var(--ink-100);
}
.pillar-block:first-child { padding-top: 0; border-top: none; }
.pillar-block h4 {
  font-size: 18px;
  font-weight: 600;
  color: var(--ink-900);
  letter-spacing: -0.01em;
}

/* Benefits grid 3×2 */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
}
.benefit-tile {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 26px;
}
.benefit-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--sage-100);
  color: var(--sage-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

/* Form partnership */
.partner-form {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-xl);
  padding: 32px;
  box-shadow: var(--shadow-2);
}
.partner-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.field-full { grid-column: 1 / -1; }
.field > span {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-700);
}
.field input,
.field select,
.field textarea {
  font-family: var(--font-sans);
  font-size: 14.5px;
  color: var(--ink-900);
  background: var(--paper);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-md);
  padding: 11px 14px;
  outline: none;
  transition: border-color 120ms, background 120ms;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--teal-700);
  background: white;
}
.field textarea { resize: vertical; min-height: 96px; }
.field-checkbox {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--ink-500);
  line-height: 1.5;
  padding-top: 4px;
}
.field-checkbox input {
  margin-top: 3px;
  accent-color: var(--teal-700);
}

/* ──────────────────────────────────────────────────────────────────────────
   DESIGN SYSTEM — schermata documentazione (pages/design-system.jsx)
   ────────────────────────────────────────────────────────────────────────── */

.ds-section-head { max-width: 760px; margin-bottom: 36px; }

/* Type ─ font families */
.ds-font-single { margin-bottom: 48px; }
.ds-fonts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 48px;
}
.ds-font-card {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 32px;
  box-shadow: var(--shadow-1);
}
.ds-font-tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-700);
  background: var(--teal-50);
  padding: 5px 10px;
  border-radius: 4px;
  margin-bottom: 24px;
}

/* Type scale */
.ds-type-table {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-1);
}
.ds-type-row {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 32px;
  padding: 26px 32px;
  border-bottom: 1px solid var(--ink-100);
  align-items: center;
}
.ds-type-row:last-child { border-bottom: none; }
.ds-type-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ds-type-label {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal-700);
}
.ds-type-cls {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 13px;
  color: var(--ink-900);
  background: var(--paper-2);
  padding: 3px 8px;
  border-radius: 4px;
  align-self: flex-start;
}
.ds-type-spec {
  font-size: 12px;
  color: var(--ink-500);
  line-height: 1.5;
}
.ds-type-sample {
  min-width: 0;
}

/* Color ─ swatches */
.ds-color-stack { display: grid; gap: 36px; }
.ds-color-group-head {
  margin-bottom: 18px;
}
.ds-swatch-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}
.ds-swatch {
  border-radius: var(--r-md);
  padding: 18px;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(0,0,0,0.05);
  font-family: var(--font-sans);
}
.ds-swatch-name {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 11px;
  opacity: 0.85;
  font-weight: 500;
}
.ds-swatch-hex {
  display: block;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.ds-swatch-role {
  display: block;
  font-size: 11.5px;
  margin-top: 4px;
  opacity: 0.78;
  line-height: 1.45;
}

/* Radii + Shadows twin */
.ds-twin {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
}
.ds-radius-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.ds-radius-cell {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.ds-radius-shape {
  width: 80px;
  height: 80px;
  background: var(--teal-50);
  border: 1px solid var(--teal-100);
}
.ds-radius-name {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 12px;
  color: var(--ink-900);
  background: var(--paper-2);
  padding: 2px 6px;
  border-radius: 4px;
}
.ds-shadow-list {
  display: grid;
  gap: 18px;
}
.ds-shadow-card {
  background: white;
  border-radius: var(--r-lg);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
}

/* Spacing */
.ds-spacing-row {
  display: flex;
  align-items: flex-end;
  gap: 32px;
  flex-wrap: wrap;
  background: white;
  padding: 36px;
  border-radius: var(--r-xl);
  border: 1px solid var(--ink-100);
  box-shadow: var(--shadow-1);
}
.ds-spacing-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 60px;
}
.ds-spacing-bar {
  background: var(--teal-800);
  border-radius: 2px;
  flex-shrink: 0;
}

/* Components grid */
.ds-component-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.ds-comp-card {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 28px;
  box-shadow: var(--shadow-1);
}
.ds-comp-tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-700);
}

/* Rules */
.ds-rules-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.ds-rule {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 22px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.ds-rule-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--sage-100);
  color: var(--sage-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Versione DOC standalone (design-system-doc) — look da documento, niente chrome.
   La prima sezione (hero) ha più aria sopra visto che manca l'header. */
.ds-doc { padding-top: 24px; }
.ds-doc > section:first-child { padding-top: 48px; }

/* ──────────────────────────────────────────────────────────────────────────
   STRUTTURE — listing + dettaglio
   ────────────────────────────────────────────────────────────────────────── */

/* Listing grid */
.strutture-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.struttura-card {
  display: flex;
  flex-direction: column;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-1);
  transition: box-shadow 160ms ease, transform 160ms ease;
}
.struttura-card:hover {
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}
.struttura-photo {
  height: 190px;
  border-radius: 0;
  font-size: 11px;
}
.struttura-body {
  padding: 22px 24px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.struttura-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.struttura-cta {
  margin-top: 20px;
  align-self: flex-start;
}

/* Dettaglio — hero */
.struttura-hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: stretch;
}
.struttura-hero-photo {
  min-height: 320px;
  border-radius: var(--r-xl);
  font-size: 12px;
}
.struttura-hero-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Dettaglio — info sede */
.struttura-info-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 56px;
  align-items: start;
}
.struttura-features {
  display: grid;
  gap: 22px;
  margin-top: 28px;
}
.struttura-feature {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.struttura-feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--teal-50);
  color: var(--teal-700);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.struttura-contact-card {
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-xl);
  padding: 28px;
  box-shadow: var(--shadow-2);
  position: sticky;
  /* --svt-testata: altezza della testata quando è visibile in cima, 0 se nascosta */
  top: calc(var(--svt-testata, 0px) + 20px);
  transition: top 260ms ease;
}
.struttura-contact-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.struttura-contact-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--ink-700);
  line-height: 1.5;
}
.struttura-contact-list a { color: var(--teal-700); }
.struttura-contact-icon {
  color: var(--ink-400);
  flex-shrink: 0;
  margin-top: 2px;
}
.struttura-hours {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.struttura-hours li {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--ink-700);
}
.struttura-hours .is-closed { color: var(--ink-400); }

/* Dettaglio — medici associati */
.struttura-doctors-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 36px;
}
.struttura-doctor-card {
  display: flex;
  flex-direction: column;
  background: white;
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  padding: 20px;
  box-shadow: var(--shadow-1);
  transition: box-shadow 160ms ease, transform 160ms ease, border-color 160ms ease;
}
.struttura-doctor-card:hover {
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
  border-color: var(--teal-100);
}
.struttura-doctor-photo {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  font-size: 9px;
  margin-bottom: 14px;
}
.struttura-doctor-link {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--teal-700);
}

/* ════════════════════════════════════════════════════════════════════════
   RESPONSIVE — breakpoint UIkit: 1200 (desktop) · 960 (tablet) · 640 (mobile)
   Mobile-first non applicabile (base = desktop 1440), quindi usiamo max-width.
   ════════════════════════════════════════════════════════════════════════ */

/* ───── Hamburger + drawer: nascosti di default (desktop) ───── */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  margin-left: 4px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink-900);
  border-radius: 2px;
  transition: transform 200ms ease, opacity 160ms ease;
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(360px, 86vw);
  height: 100dvh;
  background: var(--paper);
  transform: translateX(100%);
  /* Da chiuso è fuori schermo ma esiste: senza visibility i suoi link restavano
     raggiungibili col Tab. visibility scatta a fine transizione, così l'uscita
     si vede ancora. */
  visibility: hidden;
  transition: transform 280ms cubic-bezier(0.4,0,0.2,1), visibility 0s linear 280ms;
  z-index: 60;
  overflow-y: auto;
  display: none;
}
/* L'ombra solo da aperto: da chiuso cadeva verso sinistra e restava sul bordo
   destro di ogni pagina, su telefono, come una striscia grigia (1 ott 2026). */
.nav-drawer.is-open {
  transform: translateX(0);
  visibility: visible;
  box-shadow: -16px 0 40px -20px rgba(20,32,31,0.3);
  transition: transform 280ms cubic-bezier(0.4,0,0.2,1), visibility 0s;
}
.nav-drawer-inner {
  display: flex;
  flex-direction: column;
  padding: 88px 24px 32px;
  gap: 4px;
}
.nav-drawer-link {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 500;
  color: var(--ink-900);
  padding: 16px 12px;
  border-bottom: 1px solid var(--ink-100);
}
.nav-drawer-link.active { color: var(--teal-700); }
.nav-drawer-cta {
  margin-top: 24px;
  justify-content: center;
  width: 100%;
}
.nav-scrim {
  position: fixed;
  inset: 0;
  background: rgba(20,32,31,0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms ease;
  z-index: 55;
  display: none;
}
.nav-scrim.is-open { opacity: 1; pointer-events: auto; }

/* ───────────────────────── 1200 · DESKTOP COMPATTO ───────────────────────── */
@media (max-width: 1200px) {
  .container { padding: 0 32px; }
  .container-narrow { padding: 0 32px; }
  .nav { gap: 28px; }
  .nav .nav-item { font-size: 14.5px; }
  .hero-grid { gap: 48px; }
  .numbers-grid { grid-template-columns: 1fr repeat(3, 1fr); }
  .testimonial-grid { grid-template-columns: repeat(2, 1fr); }
  .ds-swatch-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ───────────────────────── 960 · TABLET ───────────────────────── */
@media (max-width: 960px) {
  .container, .container-narrow { padding: 0 28px; }

  /* Header → hamburger */
  .nav,
  .header-cta { display: none; }
  .nav-toggle { display: flex; }
  .nav-drawer, .nav-scrim { display: block; }
  .header-inner { height: 64px; justify-content: space-between; }
  .nav-spacer { display: none; }
  .brand-logo { height: 30px; }

  /* Sezioni a 2 colonne o impilate */
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-media { order: -1; }
  .awards-row { grid-template-columns: 1fr; gap: 16px; }
  .step-grid { grid-template-columns: 1fr; gap: 16px; margin-top: 36px; }
  .feature-pair { grid-template-columns: 1fr; }
  .feature-card { grid-template-columns: 1fr; }
  .numbers-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 36px; }
  .testimonial-grid { grid-template-columns: repeat(2, 1fr); }
  .patologie-grid { grid-template-columns: repeat(2, 1fr); }
  .path-grid { grid-template-columns: repeat(2, 1fr); }
  .cross-link-grid { grid-template-columns: 1fr; }
  .cross-link-row { grid-template-columns: 1fr; gap: 24px; padding: 28px; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
  .footer-contact { grid-template-columns: 1fr; gap: 8px; }

  /* Prezzi */
  .payment-flow { grid-template-columns: 1fr; }
  .payment-step + .payment-step { border-left: none; border-top: 1px solid var(--ink-100); padding-left: 0; }

  /* Professionisti */
  .pillar,
  .pillar:nth-child(even) { grid-template-columns: 1fr; gap: 28px; padding: 32px; }
  .pillar:nth-child(even) .pillar-aside { order: 0; }
  .pillar:nth-child(even) .pillar-blocks { order: 0; }
  .benefits-grid { grid-template-columns: 1fr 1fr; }
  #partner-form .container { grid-template-columns: 1fr !important; gap: 36px !important; }

  /* Strutture */
  .strutture-grid { grid-template-columns: repeat(2, 1fr); }
  .struttura-hero { grid-template-columns: 1fr; gap: 28px; }
  .struttura-hero-photo { min-height: 240px; }
  .struttura-info-grid { grid-template-columns: 1fr; gap: 36px; }
  .struttura-contact-card { position: static; }
  .struttura-doctors-grid { grid-template-columns: repeat(2, 1fr); }

  /* Design system */
  .ds-fonts-grid { grid-template-columns: 1fr; }
  .ds-twin { grid-template-columns: 1fr; gap: 40px; }
  .ds-component-row { grid-template-columns: 1fr; }
  .ds-rules-grid { grid-template-columns: 1fr 1fr; }
  .ds-swatch-grid { grid-template-columns: repeat(3, 1fr); }

  /* Type scale leggermente ridotta */
  .h-display { font-size: 44px !important; }
}

/* ───────────────────────── 640 · MOBILE ───────────────────────── */
@media (max-width: 640px) {
  .container, .container-narrow { padding: 0 20px; }

  /* Top bar mobile: il link professionisti resta per esteso (è la voce che
     porta traffico B2B), mentre Area Personale e Ricerca si riducono alla sola
     icona. Così lo spazio è bilanciato: un testo a sinistra, due icone a destra. */
  .topbar-inner { height: 34px; gap: 14px; font-size: 12px; justify-content: space-between; }
  .topbar-spacer { display: none; }
  .topbar-account-label { display: none; }
  .topbar-account { border-left: 0; padding-left: 0; margin-left: auto; }

  /* Tipografia ridotta */
  .h-display { font-size: 34px !important; line-height: 1.1; }
  .h1 { font-size: 28px !important; }
  .h2 { font-size: 23px !important; }
  .lede { font-size: 16px !important; }
  section { padding-top: 44px !important; padding-bottom: 44px !important; }

  /* Tutto a 1 colonna */
  .numbers-grid,
  .testimonial-grid,
  .patologie-grid,
  .path-grid,
  .awards-row,
  .benefits-grid,
  .ds-rules-grid { grid-template-columns: 1fr; }
  .ds-swatch-grid { grid-template-columns: repeat(2, 1fr); }
  .ds-radius-grid { grid-template-columns: repeat(2, 1fr); }

  /* Strutture → 1 colonna */
  .strutture-grid { grid-template-columns: 1fr; }
  .struttura-doctors-grid { grid-template-columns: 1fr; }

  /* Footer impilato */
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }

  /* Buttons full-width nelle CTA principali */
  .btn-lg { width: 100%; justify-content: center; }
  .band-teal .container { grid-template-columns: 1fr !important; gap: 28px !important; }

  /* Tabella confronto → impilata in righe leggibili */
  .compare-row { grid-template-columns: 1fr; gap: 4px; padding: 16px 20px; }
  .compare-row.compare-head { display: none; }
  .compare-row > span { display: flex; justify-content: space-between; gap: 16px; }
  .compare-row > span:first-child { font-weight: 600; color: var(--ink-900); margin-bottom: 4px; }
  /* Etichetta di ogni valore = intestazione di colonna del back-end (data-etichetta) */
  .compare-row > span[data-etichetta]::before { content: attr(data-etichetta); color: var(--ink-400); font-size: 13px; font-weight: 400; white-space: nowrap; flex-shrink: 0; }
  .compare-row > span[data-etichetta] { text-align: right; }

  /* Form partner 1 colonna */
  .partner-form-grid { grid-template-columns: 1fr; }
  .partner-form { padding: 24px; }

  /* Design system type row impilata */
  .ds-type-row { grid-template-columns: 1fr; gap: 14px; padding: 22px 20px; }

  /* Spacing scale: consenti wrap */
  .ds-spacing-row { gap: 20px; padding: 24px; }
}


/* ===== Aggiunte sv-theme (non nel mockup): accordion interattivo ===== */
.accord-q { cursor: pointer; user-select: none; }
.accord-item:not(.is-open) .accord-a { display: none; }
.accord-item .accord-icon .icon-dash { display: none; }
.accord-item.is-open .accord-icon .icon-dash { display: inline-flex; }
.accord-item.is-open .accord-icon .icon-plus { display: none; }

/* ===== Shim modale prenotazione (plugin clinn-medici, senza UIkit) ===== */
.clinn-booking-modal { display: none; }
.clinn-booking-modal.svtheme-modal-open {
  display: flex;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(20, 32, 31, 0.55);
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.clinn-booking-modal .uk-modal-dialog {
  position: relative;
  background: var(--white);
  box-shadow: var(--shadow-2);
  max-height: calc(100vh - 32px);
  overflow: auto;
}
.clinn-booking-modal .uk-modal-header { padding: 18px 24px; }
.clinn-booking-modal .uk-modal-close-default {
  position: absolute;
  top: 12px; right: 12px;
  width: 32px; height: 32px;
  border: 0; border-radius: 50%;
  background: var(--paper-2);
  color: var(--ink-700);
  cursor: pointer;
  font-size: 0;
}
.clinn-booking-modal .uk-modal-close-default::before {
  content: "\00d7";
  font-size: 20px; line-height: 1;
}

/* Passo «Sede» della modale (medici con più sedi, 2 ott 2026): poi parte il widget. */
.clinn-sede { padding: 28px 24px 32px; }
.clinn-sede-titolo {
  margin: 0 0 16px;
  font-size: 20px; font-weight: 600;
  color: var(--ink-900);
}
.clinn-sede-lista {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.clinn-sede-voce {
  display: flex; flex-direction: column; gap: 6px;
  min-width: 0;
  padding: 18px 20px;
  text-align: left;
  font: inherit;
  color: var(--ink-700);
  background: var(--white);
  border: 1px solid var(--ink-100);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.clinn-sede-voce strong { font-size: 16px; color: var(--teal-900); }
.clinn-sede-voce span { font-size: 14px; line-height: 1.4; }
.clinn-sede-voce:hover { border-color: var(--sage-600); box-shadow: var(--shadow-1); }
.clinn-sede-voce:focus-visible { outline: 2px solid var(--sage-600); outline-offset: 2px; }
.clinn-sede-indietro {
  display: inline-flex; align-items: center; gap: 6px;
  margin: 12px 24px;
  padding: 6px 0;
  font: inherit; font-size: 14px; font-weight: 500;
  color: var(--teal-700);
  background: none; border: 0;
  cursor: pointer;
}
.clinn-sede-indietro:hover { text-decoration: underline; }

/* Checkbox filtri archivio medici */
.svtheme-filter-check input[type="checkbox"] { accent-color: var(--teal-800); width: 16px; height: 16px; }
.medici-pagination ul.page-numbers { display: flex; gap: 6px; list-style: none; padding: 0; margin: 0; }
.medici-pagination .page-numbers a, .medici-pagination .page-numbers span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; padding: 8px 10px; border-radius: 999px;
  border: 1px solid var(--ink-200); background: var(--white);
  color: var(--ink-700); font-size: 13.5px; text-decoration: none;
}
.medici-pagination .page-numbers span.current {
  background: var(--teal-900); color: white; border-color: var(--teal-900);
}

/* ===== Drawer mobile: sottolivello (mega menu su mobile) ===== */
.nav-drawer-group { display: flex; flex-direction: column; }
.nav-drawer-row {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--ink-100);
}
.nav-drawer-row .nav-drawer-link { flex: 1; border-bottom: 0; }
/* Le voci con figli sono <button>: azzeriamo l'aspetto nativo così restano
   identiche agli <a> accanto. text-align/width servono perché un button
   centra il testo e non si allarga da solo. */
.nav-drawer-toggle-label {
  appearance: none;
  background: transparent;
  border: 0;
  width: 100%;
  text-align: left;
  cursor: pointer;
  line-height: inherit;
}
/* Prima voce del sottomenu: è la pagina genitore, quindi la stacchiamo appena. */
.nav-drawer-sublink.is-parent {
  font-weight: 500;
  color: var(--ink-900);
}
.nav-drawer-toggle {
  flex-shrink: 0;
  width: 52px;
  border: 0;
  background: transparent;
  color: var(--ink-500);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform .18s ease, color .18s ease;
}
.nav-drawer-toggle[aria-expanded="true"] {
  transform: rotate(180deg);
  color: var(--teal-700);
}
.nav-drawer-sub {
  display: none;
  flex-direction: column;
  padding: 4px 0 10px 12px;
  border-bottom: 1px solid var(--ink-100);
}
.nav-drawer-sub.is-open { display: flex; }
.nav-drawer-sublink {
  font-family: var(--font-sans);
  font-size: 15px;
  color: var(--ink-700);
  padding: 11px 12px;
  border-left: 2px solid var(--ink-100);
}
.nav-drawer-sublink:hover,
.nav-drawer-sublink.active {
  color: var(--teal-800);
  border-left-color: var(--sage-400);
}
.nav-drawer-sublink.is-foot {
  color: var(--teal-700);
  font-weight: 500;
  margin-top: 6px;
  border-left-color: transparent;
}

/* ===== Card medico archivio: intro biografia ===== */
.medici-card-intro {
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-500);
  max-width: 62ch;
}

/* ===== Mega menu: stato ATTIVO reale (pagina corrente) ===== */
.mega-card.is-active {
  background: var(--teal-50);
  border-color: var(--teal-700);
  box-shadow: inset 3px 0 0 var(--sage-400);
}
.mega-card.is-active strong { color: var(--teal-900); }
.mega-card.is-active .small { color: var(--ink-700); }
.mega-card.is-active .mega-icon { background: var(--white); color: var(--teal-800); }

/* ===== Archivio approfondimenti (home.php) ===== */
.ar-archive-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.ar-archive-card { padding: 0; overflow: hidden; display: block; }
.ar-archive-thumb { height: 180px; border-radius: 0; }
.ar-archive-body { padding: 22px; }
.ar-archive-meta { margin-top: 14px; color: var(--ink-500); }

@media (max-width: 960px) {
  .ar-archive-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .ar-archive-grid { grid-template-columns: 1fr; }
  .ar-reviewer-card { grid-template-columns: 1fr !important; gap: 16px !important; }
}

/* ===== Articolo: revisione medica, autore, data (17 set 2026) =====
   Solo testo: niente avatar né icone. Nomi con link alla scheda del medico o,
   per il Comitato scientifico, alla pagina Chi siamo. */
.ar-firme {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 40px;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--ink-100);
}
.ar-firma { min-width: 0; }
.ar-firma-nomi {
  margin-top: 2px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink-900);
}
.ar-firma-nomi a { color: var(--teal-800); border-bottom: 1px solid var(--teal-100); }
.ar-firma-nomi a:hover { border-bottom-color: currentColor; }

.ar-reviewer-card {
  padding: 24px 28px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 20px;
  align-items: center;
}
.ar-reviewer-card.senza-foto { grid-template-columns: 1fr auto; }
.ar-reviewer-foto { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
@media (max-width: 640px) {
  .ar-firme { gap: 14px 28px; }
  .ar-reviewer-card,
  .ar-reviewer-card.senza-foto { grid-template-columns: 1fr; gap: 14px; justify-items: start; }
}

/* ===== Slot disponibilità: giorno esteso + orari ===== */
.clinn-availability .clinn-slot {
  display: flex;
  flex-direction: column;
  gap: 3px;
  width: 100%;
  padding: 9px 12px;
  line-height: 1.35;
}
.clinn-availability .clinn-slot strong {
  font-size: 13.5px;
  color: var(--ink-900);
  font-weight: 600;
}
.clinn-availability .clinn-slot-times {
  font-size: 12.5px;
  color: var(--teal-700);
}
.clinn-availability .clinn-slot.is-muted { display: inline-flex; width: auto; }

/* ===== Aggiunte sv-theme (non nel mockup): ricerca ===== */

/* Trigger nella topbar, accanto ad Area Personale */
.topbar-search {
  background: none;
  border: 0;
  font: inherit;
  cursor: pointer;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
  padding: 0 0 0 18px;
  gap: 8px;
}
.topbar-search:hover { color: var(--white); }
.topbar-search:focus-visible {
  outline: 2px solid var(--sage-400);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Overlay a tutto schermo */
.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 2100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(20, 32, 31, 0.72);
  backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}
.search-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.search-overlay-inner {
  width: 100%;
  max-width: 760px;
  transform: translateY(14px) scale(0.98);
  transition: transform 0.26s cubic-bezier(0.2, 0.7, 0.3, 1);
}
.search-overlay.is-open .search-overlay-inner { transform: none; }

.search-close {
  position: absolute;
  top: 22px;
  right: 26px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.18s ease;
}
.search-close:hover { background: rgba(255, 255, 255, 0.22); }

.search-form {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--white);
  border-radius: 16px;
  padding: 14px 14px 14px 22px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
}
.search-form-icon {
  display: inline-flex;
  color: var(--teal-700);
  flex-shrink: 0;
}
.search-form-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: none;
  font-family: inherit;
  font-size: 22px;
  color: var(--ink-900);
  padding: 10px 0;
}
.search-form-input::placeholder { color: var(--ink-400); }
.search-form-input::-webkit-search-cancel-button { display: none; }
.search-form-submit { flex-shrink: 0; }

/* Label solo per screen reader */
.search-form-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.search-hint {
  margin: 18px 4px 0;
  text-align: center;
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.7);
}

/* Campo di ricerca nella pagina dei risultati */
.search-inline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  max-width: 640px;
  background: var(--white);
  border: 1px solid var(--ink-200);
  border-radius: 12px;
  padding: 8px 8px 8px 16px;
}
.search-inline-icon { display: inline-flex; color: var(--teal-700); flex-shrink: 0; }
.search-inline-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: none;
  font-family: inherit;
  font-size: 15.5px;
  color: var(--ink-900);
  padding: 9px 0;
}
.search-inline-input::placeholder { color: var(--ink-400); }

/* Gruppi di risultati: titolo di sezione + divisorio */
.search-group { margin-top: 44px; }
.search-group:first-child { margin-top: 16px; }
.search-group-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}
.search-group-title {
  font-size: 20px;
  margin: 0;
  flex-shrink: 0;
}
.search-group-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--sage-100);
  color: var(--sage-600);
  font-size: 12.5px;
  font-weight: 600;
  flex-shrink: 0;
}
.search-group-rule {
  flex: 1;
  height: 1px;
  background: var(--ink-200);
}

/* ⚠️ NON chiamare questa classe .search-results: WordPress mette "search-results"
   come classe sul <body> nelle pagine di ricerca, e la regola colpirebbe il body,
   trasformando l'intera pagina in una griglia a 3 colonne. */
/* minmax(0, 1fr), non 1fr: con "1fr" il minimo della traccia è il min-content,
   e l'eyebrow su riga singola (nowrap, sotto) allargherebbe la sua colonna al
   doppio delle altre. Con minmax(0,…) la colonna resta a 1/3 e l'ellissi lavora. */
.search-hits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.search-hit {
  display: block;
  min-width: 0;
  padding: 28px;
  transition: border-color 120ms;
}
.search-hit:hover { border-color: var(--teal-700); }
/* La qualifica del medico può essere lunghissima: una riga sola, poi ellissi,
   altrimenti spinge il titolo a metà card e la griglia perde allineamento. */
.search-hit .eyebrow {
  display: block;
  margin-bottom: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-hit-text {
  margin-top: 10px;
  font-size: 14.5px;
}

.search-empty {
  padding: 40px 0;
  border-top: 1px solid var(--ink-200);
}

/* ===== Aggiunte sv-theme (non nel mockup): segnaposto form ===== */
.form-placeholder {
  border: 1.5px dashed var(--ink-300);
  border-radius: 16px;
  background: var(--paper-2);
  padding: 44px 28px;
  text-align: center;
}
.form-placeholder-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--ink-200);
  color: var(--teal-700);
  margin-bottom: 16px;
}
.form-placeholder-title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-900);
}
.form-placeholder-label {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--teal-700);
}
.form-placeholder-note {
  margin: 8px auto 0;
  max-width: 380px;
  font-size: 13.5px;
  color: var(--ink-500);
}
/* Dentro le card che già hanno padding proprio, il segnaposto sta più stretto. */
.callback-form > .form-placeholder,
.partner-form > .form-placeholder { padding: 30px 16px; }

@media (max-width: 960px) {
  .search-hits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .topbar-search-label { display: none; }
  .topbar-search { border-left: 0; padding-left: 0; }
  .search-overlay { padding: 16px 16px 16px; align-items: flex-start; padding-top: 84px; }
  .search-form { flex-wrap: wrap; padding: 12px 14px; gap: 10px; }
  .search-form-input { font-size: 18px; }
  .search-form-submit { width: 100%; justify-content: center; }
  .search-hits { grid-template-columns: 1fr; }
  .search-hit { padding: 22px; }
  .search-inline { flex-wrap: wrap; }
  .search-group-title { font-size: 18px; }
}

/* Tabella dei dati RWE a valori liberi (alternativa alle barre, finché i dati
   non sono omogenei). Sta nella stessa card delle barre. */
.rwe-tabella {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
}

/* Se nella stessa card ci sono sia le barre sia la tabella, l'intestazione
   della tabella finirebbe appiccicata all'ultima barra e i due blocchi si
   leggerebbero come uno solo. */
.bar-row + .rwe-tabella {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--ink-100);
}

.rwe-tabella th,
.rwe-tabella td {
  padding: 12px 0;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--ink-100);
}

.rwe-tabella thead th {
  padding-top: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-500);
}

.rwe-tabella tbody th {
  font-weight: 400;
  color: var(--ink-700);
  padding-right: 24px;
}

/* I valori: nel verde dei bottoni e alla misura dei titoli .h3, perché si vedano
   (4 ott 2026; prima 14,5 px in teal scuro). */
.rwe-tabella tbody td {
  font-size: 19px;
  font-weight: 600;
  color: var(--sage-600);
  text-align: right;
  white-space: nowrap;
}

.rwe-tabella tbody tr:last-child th,
.rwe-tabella tbody tr:last-child td { border-bottom: 0; }

.rwe-tabella-nota { margin-top: 16px; color: var(--ink-500); }

/* Sotto i 640 il valore a destra su una riga sola stringe troppo la voce:
   meglio impilare voce e valore. */
@media (max-width: 640px) {
  .rwe-tabella tbody th,
  .rwe-tabella tbody td {
    display: block;
    text-align: left;
    white-space: normal;
    border-bottom: 0;
    padding: 0;
  }
  .rwe-tabella tbody th { padding-top: 14px; }
  .rwe-tabella tbody td { padding-bottom: 14px; border-bottom: 1px solid var(--ink-100); }
}

/* Occhiello degli articoli: "Approfondimento · Categoria".
   Sta nel CSS di base e non in pages/approfondimenti.css perché serve anche
   sulla scheda del singolo articolo e nelle card "Continua a leggere", dove
   quel foglio non viene caricato. */
.ar-archive-eyebrow {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ar-eyebrow a {
  color: var(--teal-700);
  border-bottom: 1px solid currentColor;
  text-decoration: none;
}

.ar-eyebrow a:hover { color: var(--ink-900); }

/* Etichetta leggibile solo dagli screen reader. Serve quando il campo si
   capisce a occhio da un'icona ma resterebbe senza nome per chi non la vede.
   Con clip e non display:none: un elemento nascosto davvero non viene letto. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ───── Clinn Plus: disclaimer sotto la tabella (29 set 2026) ───── */
.care-disclaimer {
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-500);
}
.care-disclaimer p { margin: 0 0 8px; }
.care-disclaimer p:last-child { margin-bottom: 0; }
.care-disclaimer a { color: var(--teal-700); text-decoration: underline; }

/* ───── Professionisti: fascia «L'Academy per professionisti» (29 set 2026) ───── */
.academy-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 56px;
  align-items: center;
}
.academy-text { max-width: 680px; margin-top: 18px; }
.academy-text .lede { color: rgba(255, 255, 255, 0.78); margin: 0 0 12px; }
.academy-text .lede:last-child { margin-bottom: 0; }

/* ───── Approfondimento: link nel corpo dell'articolo (29 set 2026) ─────
   Erano indistinguibili dal testo (al più in grassetto): sottolineati e nel
   verde dei bottoni primari (--sage-600, data-cta="limeDeep"). */
.ar-corpo a:not(.btn) {
  color: var(--sage-600);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.ar-corpo a:not(.btn):hover { color: var(--teal-800); }

/* Ambito clinico — icona del riquadro «Studio osservazionale interno».
   flex: none perché dentro la card inline-flex una nota lunga schiacciava
   l'SVG (18px di partenza) fino a 10px su desktop e 6px su telefono. */
.pt-rwe-badge-icon {
  flex: none;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--teal-50);
  color: var(--teal-700);
  border-radius: 50%;
}
.pt-rwe-badge-icon svg { flex: none; }
