/* ==========================================================================
   Dott. Sebastiano Cattaruzza — Psicologo e Psicoterapeuta
   Ricostruzione fedele del sito originale, con layout robusto mobile-first.
   ========================================================================== */

:root {
  --ink: #1a1a1a;
  --graphite: #565656;
  --paper: #ffffff;
  --wash: #f5f5f3;
  --line: #e2e0db;
  --teal: #1c8a9b;
  --teal-deep: #14707e;
  --amber: #f4b63f;
  --amber-deep: #e0a021;
  --serif: "Frank Ruhl Libre", Georgia, "Times New Roman", serif;
  --sans: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --wrap: 1080px;
  --pad: clamp(1.25rem, 5vw, 3rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Global safety rule: no image can ever overflow or blow up */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

a { color: var(--teal-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: var(--pad); padding-right: var(--pad); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

a:focus-visible, button:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; }

/* ---------------------------------- Header ---------------------------------- */
.site-header {
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.95);
  backdrop-filter: saturate(140%) blur(6px);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding-top: 0.85rem; padding-bottom: 0.85rem;
}
.brand { display: flex; align-items: center; gap: 0.65rem; flex-shrink: 1; min-width: 0; }
.brand img { height: 46px; width: auto; flex-shrink: 0; }
@media (min-width: 821px) {
  .brand img { height: 58px; }
}
.brand span {
  font-family: var(--serif); font-size: 1.02rem; line-height: 1.2; color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.brand span em {
  display: block; font-style: normal; font-family: var(--sans);
  font-size: 0.6rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--graphite); margin-top: 0.15rem;
}

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; flex-shrink: 0;
  border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer;
}
.nav-toggle svg { width: 20px; height: 20px; color: var(--teal); }

.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 1.6rem; }
.main-nav a { color: var(--ink); font-size: 0.9rem; }
.main-nav a[aria-current="page"] { color: var(--teal-deep); font-weight: 600; }
.main-nav .phone { color: var(--teal-deep); font-weight: 600; white-space: nowrap; }

@media (max-width: 820px) {
  .main-nav {
    position: fixed; inset: 71px 0 auto 0;
    background: #fff; border-bottom: 1px solid var(--line);
    max-height: 0; overflow: hidden; transition: max-height 0.25s ease;
  }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: 0; padding: 0.5rem var(--pad) 1rem; }
  .main-nav li { width: 100%; }
  .main-nav a { display: block; padding: 0.8rem 0; font-size: 1.05rem; border-bottom: 1px solid var(--line); width: 100%; }
  body.nav-open .main-nav { max-height: 80vh; }
}
@media (min-width: 821px) {
  .nav-toggle { display: none; }
}

/* ---------------------------------- Generic section ---------------------------------- */
.section { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: clamp(2.5rem, 6vw, 4.5rem); }
.section-tight { padding-top: clamp(1.5rem, 4vw, 2.5rem); padding-bottom: clamp(1.5rem, 4vw, 2.5rem); }

hr.rule { border: none; border-top: 1px solid var(--line); margin: clamp(2rem,5vw,3rem) 0; }

/* ---------------------------------- Hero (home) ---------------------------------- */
.hero {
  position: relative;
  margin: 0;
}
.hero-img {
  width: 100%;
  height: clamp(520px, 88vh, 900px);
  object-fit: cover;
  object-position: center 35%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.5rem;
  /* velatura uniforme e leggera su tutta la foto */
  background: rgba(0,0,0,0.18);
}
.hero-textwrap { display: block; padding: 0; background: none; }
.hero-quote {
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(1.5rem, 4vw, 2.5rem); line-height: 1.35;
  margin: 0 auto; max-width: 24ch; color: #ffffff;
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
}
.hero-cite { margin: 1rem 0 0; font-size: 0.95rem; color: rgba(255,255,255,0.95); text-shadow: 0 1px 8px rgba(0,0,0,0.5); }
.hero-cite cite { font-style: italic; }

/* L'a-capo controllato nella citazione si attiva solo da tablet in su */
.quote-break { display: none; }
@media (min-width: 600px) {
  .quote-break { display: inline; }
  .hero-quote { max-width: none; }
}

.hero-overlay .btn-row { margin-top: 2rem; }

.hero-actions { padding-top: clamp(1.5rem,4vw,2.5rem); padding-bottom: clamp(1rem,3vw,2rem); }

.btn-row { display: flex; flex-wrap: wrap; gap: 0.8rem; justify-content: center; margin-top: 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.8rem 1.5rem; font-size: 0.92rem; font-weight: 600;
  border: 1px solid var(--ink); background: var(--ink); color: #fff;
  border-radius: 2px; cursor: pointer; text-align: center;
}
.btn:hover { background: var(--teal-deep); border-color: var(--teal-deep); text-decoration: none; color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: transparent; color: var(--teal-deep); border-color: var(--teal-deep); }
.btn-ghost-light { background: rgba(255,255,255,0.12); color: #fff; border-color: rgba(255,255,255,0.85); backdrop-filter: blur(2px); }
.btn-ghost-light:hover { background: #fff; color: var(--ink); border-color: #fff; text-decoration: none; }
.btn-amber-outline { background: transparent; color: var(--amber-deep); border-color: var(--amber); }
.btn-amber-outline:hover { background: var(--amber); color: var(--ink); border-color: var(--amber); text-decoration: none; }
.btn-bonus { background: var(--teal); border-color: var(--teal); color: #fff; }
.btn-bonus:hover { background: var(--teal-deep); border-color: var(--teal-deep); color: #fff; text-decoration: none; }
.btn-teal { background: var(--amber); border-color: var(--amber); color: var(--ink); }
.btn-teal:hover { background: var(--amber-deep); border-color: var(--amber-deep); color: var(--ink); }

/* ---------------------------------- Page title (info / bonus) ---------------------------------- */
.page-title {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.9rem, 5vw, 2.8rem); line-height: 1.15;
  margin: 0 0 1.5rem;
}

/* ---------------------------------- Quote block ---------------------------------- */
.quote {
  margin: 0 0 clamp(2rem,5vw,3rem);
  padding: 1.5rem 1.8rem;
  background: var(--wash);
  border-left: 3px solid var(--teal);
}
.quote p { margin: 0; font-family: var(--serif); font-style: italic; font-size: clamp(1.15rem,2.5vw,1.4rem); line-height: 1.4; }
.quote cite { display: block; margin-top: 0.8rem; font-family: var(--sans); font-style: normal; font-size: 0.85rem; color: var(--graphite); }

/* ---------------------------------- Info: portrait + intro ---------------------------------- */
.portrait {
  width: 100%;
  max-width: 300px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
  margin: 0 auto clamp(1.5rem,4vw,2rem);
  filter: grayscale(1);
}
.intro-text { font-size: 1.08rem; max-width: 62ch; }
@media (min-width: 760px) {
  .info-lead { display: grid; grid-template-columns: 300px 1fr; gap: clamp(2rem,4vw,3.5rem); align-items: center; }
  .portrait { margin: 0; }
}
.services-block { margin-top: clamp(2rem, 5vw, 3rem); }
.cta-hero { margin-top: clamp(5rem, 11vw, 7.5rem); }

/* ---------------------------------- Services / problems ---------------------------------- */
.subhead {
  font-family: var(--serif); font-weight: 600;
  font-size: 1.5rem; margin: 0 0 1rem;
}
.stack-list { list-style: none; margin: 0; padding: 0; }
.stack-list li {
  padding: 0.7rem 0; border-bottom: 1px solid var(--line);
  font-size: 1.08rem;
}
.stack-list li:first-child { border-top: 1px solid var(--line); }

/* Su mobile i due blocchi (Servizi / Problematiche) sono impilati: serve respiro tra loro */
.two-col > div + div { margin-top: clamp(2rem, 7vw, 2.8rem); }

@media (min-width: 720px) {
  .two-col { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem,5vw,4rem); }
  .two-col > div + div { margin-top: 0; }
}

/* ---------------------------------- Highlight (practical info) ---------------------------------- */
.highlight {
  background: var(--wash); border-radius: 4px;
  padding: clamp(1.3rem,4vw,2rem);
  font-size: 1.1rem; text-align: center;
}
.highlight p { margin: 0.3rem 0; }

/* ---------------------------------- Bonus: two-column layout ---------------------------------- */
.bonus-layout { display: block; }
.bonus-aside { margin-bottom: 2rem; }
.link-col { display: flex; flex-direction: column; gap: 0.7rem; margin-top: 1.4rem; }
.link-col .btn { width: 100%; }

@media (min-width: 860px) {
  .bonus-layout {
    display: grid;
    grid-template-columns: minmax(300px, 380px) 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: start;
  }
  .bonus-aside { margin-bottom: 0; position: sticky; top: 90px; }
  .bonus-main p:first-child { margin-top: 0; }
}

/* ---------------------------------- CTA hero (info: appuntamento su foto) ---------------------------------- */
.cta-hero { position: relative; margin-left: 0; margin-right: 0; margin-bottom: 0; border-radius: 4px; overflow: hidden; }
.cta-img {
  width: 100%;
  height: clamp(320px, 42vh, 460px);
  object-fit: cover;
  object-position: center 40%;
}
.cta-overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 1.5rem;
  background: rgba(0,0,0,0.20);
}
.cta-textwrap {
  display: block; padding: 0; background: none;
  margin: 0 0 2.8rem; max-width: 30ch;
  font-size: clamp(1.1rem, 2.4vw, 1.35rem); color: #fff;
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
}
@media (min-width: 760px) {
  .cta-textwrap { max-width: 40ch; }
}
.cta-break { display: none; }
@media (min-width: 620px) { .cta-break { display: inline; } }
.cta-overlay strong { color: #fff; }

/* ---------------------------------- Bonus image ---------------------------------- */
.bonus-figure { margin: 0 0 clamp(1rem,3vw,1.5rem); }
.bonus-figure img { width: 100%; border-radius: 4px; }

.body-copy p { font-size: 1.08rem; }
.body-copy strong { color: var(--ink); }

.link-row { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1.8rem; }

/* ---------------------------------- Partner logos (bonus) ---------------------------------- */
.partners {
  margin-top: clamp(1.8rem,4vw,2.5rem);
  padding-top: clamp(1.5rem,3vw,2rem);
  border-top: 1px solid var(--line);
}
.partners h2 {
  font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--graphite); margin: 0 0 1.2rem; font-weight: 600;
}
.partner-row {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: clamp(1.2rem, 4vw, 2rem);
}
.partner-row a { display: inline-flex; align-items: center; }
.partner-row img { width: auto; }
.partner-row .p-regione { height: 42px; }
.partner-row .p-ardis { height: 54px; }
@media (max-width: 480px) {
  .partner-row .p-regione { height: 36px; }
  .partner-row .p-ardis { height: 46px; }
}

/* ---------------------------------- Breather image ---------------------------------- */
.breather { margin: 0; }
.breather img { width: 100%; max-height: 52vh; object-fit: cover; filter: grayscale(1); }

/* ---------------------------------- Footer ---------------------------------- */
.site-footer { border-top: 1px solid var(--line); background: var(--wash); }
.footer-inner {
  padding-top: clamp(2.5rem,6vw,3.5rem); padding-bottom: clamp(2.5rem,6vw,3.5rem);
  display: grid; grid-template-columns: 1fr; gap: 2rem;
}
@media (min-width: 760px) {
  .footer-inner { grid-template-columns: 1.4fr 1fr 1fr; gap: 2.5rem; }
}
.footer-brand img { height: 34px; width: auto; margin-bottom: 1rem; }
.footer-brand p { font-size: 0.9rem; color: var(--graphite); margin: 0; max-width: 32ch; }
.footer-col h3 { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--graphite); margin: 0 0 0.9rem; }
.footer-col a, .footer-col p { display: block; font-size: 0.95rem; color: var(--ink); margin: 0 0 0.5rem; }
.footer-col a:hover { color: var(--teal-deep); }
.social { display: flex; gap: 0.7rem; margin-top: 0.4rem; }
.social a {
  width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; background: #fff;
}
.social a:hover { border-color: var(--teal); }
.social svg { width: 17px; height: 17px; }
.footer-legal {
  border-top: 1px solid var(--line);
  padding: 1.2rem var(--pad);
  text-align: center; font-size: 0.82rem; color: var(--graphite);
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
/* build 20260703-1711 */
