/* Stile condiviso di /consulenza.html e /prenota.html (sito statico). */
:root {
  --accent: #d97757;
  --accent-dark: #c2603f;
  --accent-soft: #fbeee8;
  --ink: #1f1e1d;
  --muted: #5f5b57;
  --line: #e9e4dd;
  --bg: #faf9f5;
  --card: #ffffff;
  --nav-bg: rgba(250, 249, 245, 0.85);
  --inverse-bg: #1f1e1d;
  --inverse-ink: #ffffff;
  --nav-h: 64px;
  color-scheme: light;
}
/* Scuro: data-theme lo risolve theme.js (anche per "system"), quindi un blocco solo. */
:root[data-theme="dark"] {
  --accent-dark: #e48d6f;
  --accent-soft: rgba(217, 119, 87, 0.14);
  --ink: #f3f1ec;
  --muted: #a8a29e;
  --line: #34322e;
  --bg: #1a1917;
  --card: #242320;
  --nav-bg: rgba(26, 25, 23, 0.85);
  --inverse-bg: #0f0e0d;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
body {
  margin: 0;
  font-family: "Inter Tight", system-ui, sans-serif;
  letter-spacing: -0.01em;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.modal-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select { font: inherit; letter-spacing: inherit; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }

/* ── Navbar ───────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  height: var(--nav-h);
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { font-weight: 800; font-size: 18px; text-decoration: none; letter-spacing: -0.03em; }
.brand span { color: var(--accent); }
.nav-links { display: flex; gap: 20px; margin-left: auto; list-style: none; padding: 0; }
.nav-links a { white-space: nowrap; text-decoration: none; font-size: 14px; font-weight: 500; color: var(--muted); }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav .cta { white-space: nowrap; padding: 10px 18px; font-size: 14px; margin-left: 8px; }
.theme-toggle {
  flex: none; width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--muted); cursor: pointer;
}
.theme-toggle:hover { color: var(--ink); border-color: var(--muted); }
.theme-toggle svg { width: 18px; height: 18px; display: none; }
:root[data-theme-pref="system"] .theme-toggle .i-system,
:root[data-theme-pref="light"] .theme-toggle .i-light,
:root[data-theme-pref="dark"] .theme-toggle .i-dark { display: block; }
.nav-toggle { display: none; margin-left: auto; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; }
@media (max-width: 1180px) {
  .nav-toggle { display: block; }
  .nav .cta { margin-left: 0; padding: 9px 14px; font-size: 13px; }
  .nav-links {
    display: none; position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; gap: 0; margin: 0; background: var(--bg); border-bottom: 1px solid var(--line);
  }
  .nav-links.open { display: flex; }
  .nav-links a { display: block; padding: 14px 20px; font-size: 16px; }
}

/* ── Elementi ─────────────────────────────────── */
.cta {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  background: var(--accent); color: #fff; text-decoration: none; border: 0; cursor: pointer;
  font-weight: 700; font-size: 17px; padding: 18px 32px; border-radius: 12px;
  box-shadow: 0 10px 30px -10px rgba(217, 119, 87, 0.7);
  transition: background .15s, transform .15s;
}
.cta:hover { background: var(--accent-dark); transform: translateY(-1px); }
.cta:focus-visible, input:focus-visible, select:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.cta-wrap { text-align: center; margin-top: 40px; }
.eyebrow { color: var(--accent); font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: 0.04em; margin: 0 0 12px; }
h1, h2, h3 { line-height: 1.12; letter-spacing: -0.03em; margin: 0 0 16px; }
h1 { font-size: clamp(32px, 5.5vw, 56px); font-weight: 800; }
h2 { font-size: clamp(26px, 4vw, 40px); font-weight: 800; }
h3 { font-size: 21px; font-weight: 700; }
.accent { color: var(--accent); }
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 680px; margin: 0 auto; }
.prose p { color: var(--muted); font-size: 18px; margin: 0 0 16px; }

section { padding: 88px 0; }
section + section { border-top: 1px solid var(--line); }
.center { text-align: center; }

/* ── Hero + video ─────────────────────────────── */
.hero { padding-top: 56px; text-align: center; }
.video-box {
  position: relative; margin: 36px auto 0; max-width: 880px; aspect-ratio: 16 / 9;
  border-radius: 18px; overflow: hidden; background: #111;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.45);
}
.video-trigger { position: absolute; inset: 0; border: 0; padding: 0; cursor: pointer; background: #111; }
.video-trigger img { width: 100%; height: 100%; object-fit: cover; opacity: .85; }
.play-badge {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  color: #fff; font-weight: 700; font-size: 18px; text-shadow: 0 2px 12px rgba(0,0,0,.5);
}
.play-badge i, .vsl-paused i {
  width: 84px; height: 84px; border-radius: 50%; background: var(--accent);
  display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 10px rgba(217,119,87,.25);
}
.play-badge i::before, .vsl-paused i::before {
  content: ""; margin-left: 6px; border-style: solid; border-width: 14px 0 14px 22px; border-color: transparent transparent transparent #fff;
}
/* L'iframe sborda sopra e sotto: il box (overflow hidden) taglia titolo e loghi che YouTube mostra anche con controls=0. */
#vsl-player { position: absolute; left: 0; width: 100%; top: -64px; height: calc(100% + 128px); }
/* Il velo intercetta ogni click: l'utente non tocca mai l'interfaccia di YouTube. */
.vsl-tap { position: absolute; inset: 0; border: 0; background: transparent; cursor: pointer; }
.vsl-paused { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(0,0,0,.35); pointer-events: none; }
.video-box.is-paused .vsl-paused { display: flex; }
.vsl-controls { display: flex; justify-content: center; margin-top: 14px; }
.vsl-restart {
  display: inline-flex; gap: 8px; align-items: center; border: 1px solid var(--line); background: var(--card);
  padding: 10px 18px; border-radius: 999px; cursor: pointer; font-weight: 600; font-size: 14px; color: var(--ink);
}
.vsl-restart:hover { border-color: var(--accent); color: var(--accent); }

.bullets { list-style: none; padding: 0; margin: 32px auto 0; max-width: 680px; text-align: left; display: grid; gap: 12px; }
.bullets li { display: flex; gap: 12px; font-size: 17px; }
.bullets li::before {
  content: "✓"; flex: none; width: 24px; height: 24px; border-radius: 50%; background: var(--accent-soft); color: var(--accent);
  display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; margin-top: 2px;
}
.strap { background: var(--inverse-bg); color: var(--inverse-ink); text-align: center; padding: 22px 20px; font-weight: 700; font-size: clamp(17px, 2.2vw, 22px); letter-spacing: -0.02em; }
.strap span { color: var(--accent); }

/* ── Griglie ──────────────────────────────────── */
.grid { display: grid; gap: 20px; margin-top: 40px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 28px; }
.card p { color: var(--muted); margin: 0; }
.num { font-size: 14px; font-weight: 800; color: var(--accent); margin-bottom: 10px; }
.fit ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.fit li { display: flex; gap: 10px; color: var(--muted); }
.fit .yes { border-color: var(--accent); background: var(--accent-soft); }
.fit .yes li::before { content: "✓"; color: var(--accent); font-weight: 800; }
.fit .no li::before { content: "✕"; color: #a8a29e; font-weight: 800; }

.about { display: grid; grid-template-columns: 320px 1fr; gap: 48px; align-items: center; }
.about-photo { aspect-ratio: 4/5; border-radius: 18px; background: var(--accent-soft) center/cover; }
@media (max-width: 800px) { .about { grid-template-columns: 1fr; } .about-photo { max-width: 320px; } }

.testimonial-video { position: relative; aspect-ratio: 16/9; border: 0; padding: 0; border-radius: 12px; overflow: hidden; cursor: pointer; background: #111; width: 100%; margin-bottom: 18px; }
.testimonial-video img { width: 100%; height: 100%; object-fit: cover; }
.testimonial-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.quote { font-weight: 700; color: var(--ink) !important; margin: 6px 0 8px !important; }

.final { background: var(--inverse-bg); color: var(--inverse-ink); text-align: center; }
.final .lead { color: #d6d3d1; }

footer { padding: 32px 0; text-align: center; font-size: 13px; color: var(--muted); }
footer a { color: var(--muted); margin: 0 6px; }

/* ── Modal lead ───────────────────────────────── */
dialog { background: var(--card); color: var(--ink); border: 0; padding: 0; border-radius: 20px; width: min(480px, calc(100% - 32px)); max-height: calc(100dvh - 32px); }
dialog::backdrop { background: rgba(20, 18, 16, 0.6); backdrop-filter: blur(4px); }
.modal-card { position: relative; padding: 32px 28px 28px; }
.modal-card h2 { font-size: 26px; margin-bottom: 6px; }
.modal-card > p { color: var(--muted); margin: 0 0 20px; }
.close { position: absolute; right: 14px; top: 12px; border: 0; background: none; font-size: 28px; line-height: 1; cursor: pointer; color: var(--muted); }
.form { display: grid; gap: 12px; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; }
.form input, .form select { width: 100%; padding: 13px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink); font-size: 16px; }
.consent { display: flex !important; grid-template-columns: none; gap: 8px !important; align-items: flex-start; font-weight: 400 !important; color: var(--muted); }
.consent input { width: auto; margin-top: 4px; }
.form .cta { width: 100%; margin-top: 6px; }
.form .cta:disabled { opacity: .6; cursor: wait; }

@media (max-width: 900px) { .hide-sm { display: none; } }
