/* ============================================================
   TUTELA INVALIDO – style.css
   Design: Istituzionale, Rassicurante, Accessibile
   Palette: Blu profondo / Oro / Bianco / Grigio caldo
   ============================================================ */

/* ---- CSS Variables ---- */
:root {
  --blue-deep: #2c3e50;
  /* Deep Slate/Navy - Sicurezza */
  --blue-mid: #34495e;
  --blue-light: #5d6d7e;
  --accent: #84a59d;
  /* Sage Green - Calma */
  --accent-light: #96ad90;
  --white: #ffffff;
  --gray-50: #fdfbf9;
  /* Warm White/Cream */
  --gray-100: #f4f1ea;
  /* Soft Beige */
  --gray-200: #e5e0d8;
  --gray-400: #a8a29e;
  --gray-600: #78716c;
  --gray-800: #44403c;
  --text-main: #2c3e50;
  --text-muted: #576574;
  --text-light: #8395a7;

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-xl: 40px;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);

  --transition: .3s cubic-bezier(.4, 0, .2, 1);
  --transition-slow: .5s cubic-bezier(.4, 0, .2, 1);

  --container: 1240px;
  --header-h: 88px;

  --font-display: 'Outfit', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
}

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 8px);
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--text-main);
  background: var(--gray-50);
  line-height: 1.65;
  overflow-x: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--blue-light);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition);
}

a:hover {
  color: var(--blue-deep);
}

a:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 3px;
}

button:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 3px;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-display);
  line-height: 1.2;
  color: var(--blue-deep);
}

/* ---- Accessibility ---- */
.skip-link {
  position: fixed;
  top: -100px;
  left: 12px;
  z-index: 10000;
  padding: 10px 18px;
  background: var(--gold);
  color: var(--blue-deep);
  font-weight: 700;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: top var(--transition);
}

.skip-link:focus {
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- Container ---- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 48px);
}

/* ---- Section ---- */
.section {
  padding-block: clamp(64px, 8vw, 112px);
}

.section-header {
  text-align: center;
  margin-bottom: clamp(40px, 6vw, 72px);
}

.section-label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
  padding: 8px 18px;
  background: rgba(180, 145, 87, .1);
  border-radius: 99px;
  border: 1px solid rgba(180, 145, 87, .2);
}

.section-title {
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 16px;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 620px;
  margin-inline: auto;
}

/* Section Backgrounds */
.servizi {
  background-color: var(--white);
}

.modus {
  background-color: var(--gray-50);
}

.riferimento {
  background-color: var(--white);
}

.contatti {
  background-color: var(--gray-100);
}

.staff {
  background-color: var(--gray-50);
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--blue-deep);
  color: var(--white);
  border-color: var(--blue-deep);
}

.btn--primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(15, 23, 42, .2);
}

.btn--ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, .5);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, .12);
  border-color: var(--white);
  color: var(--white);
}

.btn--outline {
  background: transparent;
  color: var(--blue-light);
  border-color: var(--blue-light);
}

.btn--outline:hover {
  background: var(--blue-pale);
  color: var(--blue-deep);
}

.btn--large {
  padding: 16px 36px;
  font-size: 1rem;
  border-radius: var(--radius-md);
}

.btn--sm {
  padding: 8px 18px;
  font-size: .875rem;
}

.btn--submit {
  width: 100%;
  padding: 16px;
  font-size: 1rem;
  margin-top: 8px;
}

/* ============================================================
   HEADER
============================================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 500;
  height: var(--header-h);
  background: rgba(10, 42, 94, .97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  transition: box-shadow var(--transition);
}

.site-header.scrolled {
  box-shadow: 0 4px 24px rgba(0, 0, 0, .25);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
}

.logo img {
  max-height: 40px;
  width: auto;
  transition: transform var(--transition);
}

.logo-icon {
  font-size: 1.6rem;
  line-height: 1;
  color: var(--accent);
}

.logo-text {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 500;
  letter-spacing: -.02em;
  color: var(--white);
}

.logo-text strong {
  font-weight: 700;
  color: var(--accent);
}

/* Nav */
.main-nav ul {
  display: flex;
  gap: 4px;
  list-style: none;
}

.main-nav a {
  display: block;
  padding: 8px 14px;
  color: rgba(255, 255, 255, .85);
  text-decoration: none;
  font-size: .92rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--white);
  background: rgba(255, 255, 255, .1);
}

.nav-cta {
  background: var(--accent) !important;
  color: var(--white) !important;
  font-weight: 600 !important;
  margin-left: 8px;
}

.nav-cta:hover {
  background: var(--accent-light) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(180, 145, 87, .3);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 6px;
  background: transparent;
  border: none;
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.hamburger span {
  display: block;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: all var(--transition);
}

.hamburger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.hamburger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  top: var(--header-h);
  left: 0;
  right: 0;
  background: var(--blue-deep);
  padding: 24px;
  z-index: 499;
  border-bottom: 3px solid var(--gold);
  animation: slideDown .25s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-12px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.mobile-menu ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-link {
  display: block;
  padding: 12px 16px;
  color: rgba(255, 255, 255, .9);
  text-decoration: none;
  font-size: 1.05rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.mobile-link:hover {
  background: rgba(255, 255, 255, .1);
  color: var(--white);
}

/* ============================================================
   HERO
============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--blue-deep) 0%, #0d3578 50%, #1a4490 100%);
  padding-top: var(--header-h);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-shape {
  position: absolute;
  border-radius: 50%;
  opacity: .06;
}

.hero-shape--1 {
  width: 600px;
  height: 600px;
  background: var(--gold);
  top: -200px;
  right: -100px;
}

.hero-shape--2 {
  width: 400px;
  height: 400px;
  background: var(--blue-light);
  bottom: -150px;
  left: -80px;
}

.hero-bg-image {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.4);
  z-index: -2;
}

.hero-bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.8), rgba(15, 23, 42, 0.4));
  z-index: -1;
}

.hero-dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .08) 1px, transparent 1px);
  background-size: 40px 40px;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding-block: 80px 60px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-logo-wrapper {
  margin-bottom: 24px;
}

.hero-logo {
  max-height: 80px;
  width: auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  background: rgba(132, 165, 157, 0.15);
  /* Accent with low opacity */
  border: 1px solid var(--accent);
  border-radius: 99px;
  color: var(--accent);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 28px;
}

.hero-title {
  font-size: clamp(2.6rem, 6vw, 5rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.05;
  margin-bottom: 28px;
  max-width: 900px;
  margin-inline: auto;
}

.hero-title em {
  font-style: italic;
  color: var(--accent);
  font-weight: 600;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255, 255, 255, .8);
  max-width: 580px;
  margin-bottom: 40px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-bottom: 56px;
}

.hero-trust {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  flex-direction: column;
}

.trust-item strong {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.trust-item span {
  font-size: .8rem;
  color: var(--gray-400);
  margin-top: 2px;
}

.trust-divider {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, .2);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, .5), transparent);
  margin-inline: auto;
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {

  0%,
  100% {
    opacity: 1;
    height: 48px;
  }

  50% {
    opacity: .3;
    height: 24px;
  }
}

/* ============================================================
   SERVIZI
============================================================ */
.servizi {
  background: var(--white);
}

.servizi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 480px), 1fr));
  gap: 28px;
}

.servizio-card {
  position: relative;
  background: var(--white);
  border: 1.5px solid var(--gray-100);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  display: flex;
  gap: 28px;
  align-items: flex-start;
  overflow: hidden;
  transition: all var(--transition-slow);
  box-shadow: var(--shadow-sm);
}

.servizio-card:hover {
  border-color: var(--blue-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.servizio-card:hover .card-accent {
  transform: scaleY(1);
}

.card-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--blue-mid), var(--accent));
  transform: scaleY(0);
  transform-origin: top;
  transition: transform var(--transition-slow);
  border-radius: 4px 0 0 4px;
}

.card-icon {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--blue-pale);
  border-radius: var(--radius-md);
  color: var(--blue-light);
}

.card-icon svg {
  width: 28px;
  height: 28px;
}

.card-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 12px;
}

.card-text {
  color: var(--text-muted);
  font-size: .95rem;
  line-height: 1.7;
  margin-bottom: 18px;
}

.card-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .9rem;
  color: var(--text-muted);
}

.card-list li::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ============================================================
   CHI SIAMO
============================================================ */
.chi-siamo {
  background: var(--gray-50);
}

.chi-siamo-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.chi-siamo-content .section-label {
  margin-bottom: 16px;
}

.chi-siamo-content h2 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 24px;
  line-height: 1.2;
}

.chi-siamo-content p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.chi-siamo-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.chi-siamo-image::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.05);
  pointer-events: none;
}

.chi-siamo-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.chi-siamo-image:hover img {
  transform: scale(1.05);
}

@media (max-width: 900px) {
  .chi-siamo-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* ============================================================
   MODUS OPERANDI
============================================================ */
.modus {
  position: relative;
}

.modus-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, var(--gray-100) 0%, var(--gray-50) 60%);
  pointer-events: none;
}

.modus .container {
  position: relative;
  z-index: 1;
}

.fasi-container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* Fase block */
.fase {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow-md);
  border: 1.5px solid var(--gray-100);
}

.fase-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 36px;
  padding-bottom: 24px;
  border-bottom: 1.5px solid var(--gray-100);
}

.fase-number {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--blue-pale);
  line-height: 1;
  flex-shrink: 0;
  margin-top: -8px;
}

.fase-label {
  display: block;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 6px;
}

.fase-title {
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 700;
  color: var(--blue-deep);
}

/* Steps */
.fase-steps {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.fase-step {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.step-marker {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--blue-light), var(--blue-deep));
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: .9rem;
  box-shadow: 0 4px 12px rgba(41, 96, 200, .3);
}

.step-marker--sm {
  width: 32px;
  height: 32px;
  font-size: .8rem;
}

.step-content h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 8px;
}

.step-content p {
  color: var(--text-muted);
  font-size: .92rem;
  line-height: 1.7;
}

/* Fase 2 grid */
.fase--giudiziaria .fase-header {
  border-bottom-color: rgba(41, 96, 200, .15);
}

.fase-steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.fase-step--compact {
  background: var(--gray-50);
  border-radius: var(--radius-md);
  padding: 18px;
  border: 1px solid var(--gray-100);
  transition: all var(--transition);
}

.fase-step--compact:hover {
  border-color: var(--blue-pale);
  box-shadow: var(--shadow-sm);
}

/* Valutazione clinica box */
.valutazione-box {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: linear-gradient(135deg, #fff8ee, #fff3e0);
  border: 2px solid rgba(201, 151, 58, .25);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
}

.vbox-icon {
  font-size: 2rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.vbox-content h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 8px;
}

.vbox-content p {
  color: var(--text-muted);
  font-size: .93rem;
  line-height: 1.7;
}

/* Messaggio chiave */
.messaggio-chiave {
  margin-top: 40px;
  display: flex;
  gap: 20px;
  align-items: center;
  background: linear-gradient(135deg, var(--blue-deep), var(--blue-mid));
  border-radius: var(--radius-lg);
  padding: 28px 36px;
  color: var(--white);
}

.mchiave-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, .15);
  border-radius: 50%;
  color: var(--gold-light);
}

.mchiave-icon svg {
  width: 28px;
  height: 28px;
}

.messaggio-chiave p {
  font-size: 1rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, .9);
}

.messaggio-chiave strong {
  color: var(--gold-light);
}

/* ============================================================
   STAFF
============================================================ */
.staff-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
}

.staff-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition);
}

.staff-card:hover {
  transform: translateY(-8px);
}

.staff-img {
  aspect-ratio: 4/5;
  background: var(--gray-200);
}

.staff-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.staff-info {
  padding: 24px;
  text-align: center;
}

.staff-info h3 {
  font-size: 1.2rem;
  margin-bottom: 4px;
}

.staff-info p {
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ============================================================
   RIFERIMENTO
============================================================ */
.riferimento {
  background: var(--white);
}

/* City selector */
.city-selector {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.city-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 32px;
  background: var(--gray-50);
  border: 2px solid var(--gray-200);
  border-radius: 99px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition);
}

.city-btn:hover {
  border-color: var(--blue-light);
  color: var(--blue-light);
}

.city-btn.active {
  background: var(--blue-deep);
  border-color: var(--blue-deep);
  color: var(--white);
  box-shadow: 0 4px 16px rgba(15, 23, 42, .3);
}

.city-btn__icon {
  font-size: 1.1rem;
}

#sede-info {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* Sede cards */
.sede-card {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 0;
  background: var(--white);
  border: 1.5px solid var(--gray-100);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  animation: fadeIn .35s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.sede-map {
  background: linear-gradient(135deg, var(--blue-deep), var(--blue-mid));
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
}

.map-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  color: rgba(255, 255, 255, .7);
}

.map-placeholder svg {
  width: 80px;
  height: 80px;
  color: var(--gold-light);
}

.map-placeholder span {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: .05em;
}

.sede-details {
  padding: clamp(28px, 4vw, 48px);
}

.sede-city-name {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--blue-deep);
  margin-bottom: 24px;
}

.sede-info-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.info-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.info-row dt {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--blue-light);
  margin-top: 1px;
}

.info-row dt svg {
  width: 20px;
  height: 20px;
}

.info-row dd {
  font-size: .95rem;
  color: var(--text-muted);
}

.info-row dd a {
  color: var(--blue-light);
}

/* ============================================================
   CONTATTI
============================================================ */
.contatti {
  position: relative;
  background-color: var(--gray-100);
  overflow: hidden;
}

.contatti-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.contatti-bg-image {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(12px) brightness(1.05);
  transform: scale(1.1);
  opacity: 0.4;
}

.contatti-bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--gray-100) 0%, rgba(244, 241, 234, 0.7) 100%);
}

.contatti .container {
  position: relative;
  z-index: 1;
}

.contatti-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
}

.contatti-intro .section-title {
  text-align: left;
}

.contatti-intro p {
  color: var(--text-muted);
  margin-top: 16px;
  margin-bottom: 32px;
  font-size: 1rem;
  line-height: 1.7;
}

.contatti-direct {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.direct-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--blue-deep);
  text-decoration: none;
  font-size: .95rem;
  font-weight: 500;
  transition: color var(--transition);
}

.direct-link em {
  font-style: normal;
  color: var(--text-light);
  font-size: .85rem;
}

.direct-item {
  display: flex;
  align-items: center;
  gap: 15px;
}

.map-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--white);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.85rem;
  color: var(--accent);
  text-decoration: none;
  border: 1px solid var(--gray-200);
  transition: all var(--transition);
}

.map-link:hover {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.direct-link:hover {
  color: var(--blue-light);
}

/* Form */
.form-wrapper {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow-lg);
  border: 1.5px solid var(--gray-100);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.form-group label {
  font-size: .87rem;
  font-weight: 600;
  color: var(--gray-800);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: .95rem;
  color: var(--text-main);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--blue-light);
  box-shadow: 0 0 0 3px rgba(41, 96, 200, .12);
}

.form-group input:invalid:not(:placeholder-shown),
.form-group textarea:invalid:not(:placeholder-shown) {
  border-color: #e53e3e;
}

.form-group textarea {
  resize: vertical;
  min-height: 110px;
}

.select-wrapper {
  position: relative;
}

.select-wrapper::after {
  content: '';
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--gray-400);
  pointer-events: none;
}

.field-error {
  font-size: .8rem;
  color: #c53030;
  min-height: 18px;
}

/* Honeypot */
.ohnohoney {
  display: none !important;
}

/* Checkbox */
.form-group--check {
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  font-size: .88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.checkbox-custom {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border: 2px solid var(--gray-200);
  border-radius: 4px;
  background: var(--white);
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

.checkbox-label input[type="checkbox"]:checked+.checkbox-custom {
  background: var(--blue-light);
  border-color: var(--blue-light);
}

.checkbox-label input[type="checkbox"]:checked+.checkbox-custom::after {
  content: '';
  display: block;
  width: 5px;
  height: 9px;
  border: 2px solid white;
  border-top: none;
  border-left: none;
  transform: rotate(45deg) translate(-1px, -1px);
}

.checkbox-label input[type="checkbox"]:focus-visible+.checkbox-custom {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

/* Form status */
#form-status {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 500;
  display: none;
}

#form-status.success {
  display: block;
  background: #f0fdf4;
  border: 1.5px solid #86efac;
  color: #15803d;
}

#form-status.error {
  display: block;
  background: #fef2f2;
  border: 1.5px solid #fca5a5;
  color: #dc2626;
}

/* ============================================================
   FOOTER
============================================================ */
.site-footer {
  background: var(--blue-deep);
  color: rgba(255, 255, 255, .8);
  padding-top: 64px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.footer-brand .logo--light {
  color: var(--white);
  margin-bottom: 16px;
}

.footer-brand p {
  font-size: .88rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, .6);
}

.footer-links h3,
.footer-sedi h3 {
  font-family: var(--font-body);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 16px;
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a {
  color: rgba(255, 255, 255, .7);
  text-decoration: none;
  font-size: .9rem;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--white);
}

.footer-sedi address {
  font-style: normal;
  font-size: .88rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, .65);
  margin-bottom: 20px;
}

.footer-sedi address strong {
  color: var(--white);
  display: block;
}

.footer-sedi address a {
  color: var(--gold-light);
  text-decoration: none;
}

.footer-sedi address a:hover {
  color: var(--gold);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-block: 20px;
  font-size: .82rem;
  color: rgba(255, 255, 255, .45);
  flex-wrap: wrap;
  gap: 12px;
}

.cookie-reopen-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, .2);
  color: rgba(255, 255, 255, .6);
  padding: 6px 14px;
  border-radius: 99px;
  font-size: .8rem;
  cursor: pointer;
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}

.cookie-reopen-btn:hover {
  border-color: rgba(255, 255, 255, .5);
  color: var(--white);
}

/* ============================================================
   GEO POPUP
============================================================ */
.geo-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 42, 94, .65);
  backdrop-filter: blur(4px);
  z-index: 800;
}

.geo-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 801;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: clamp(32px, 5vw, 56px);
  max-width: 420px;
  width: calc(100% - 32px);
  text-align: center;
  box-shadow: 0 32px 80px rgba(10, 42, 94, .3);
  animation: popupIn .3s cubic-bezier(.34, 1.56, .64, 1);
}

@keyframes popupIn {
  from {
    opacity: 0;
    transform: translate(-50%, -60%) scale(.9);
  }

  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.geo-popup__icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.geo-popup h2 {
  font-size: 1.5rem;
  color: var(--blue-deep);
  margin-bottom: 10px;
}

.geo-popup p {
  color: var(--text-muted);
  font-size: .95rem;
  margin-bottom: 28px;
  line-height: 1.6;
}

.geo-popup__buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-bottom: 16px;
}

.geo-popup__close {
  background: transparent;
  border: none;
  font-size: .83rem;
  color: var(--text-light);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition);
}

.geo-popup__close:hover {
  color: var(--text-muted);
}

/* ============================================================
   COOKIE BANNER
============================================================ */
.cookie-banner {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 900;
  width: min(720px, calc(100vw - 48px));
  background: var(--blue-deep);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, .35);
  display: none;
  animation: slideUp .4s cubic-bezier(.4, 0, .2, 1);
  border: 1px solid rgba(255, 255, 255, .1);
}

.cookie-banner.visible {
  display: block;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cookie-banner__content {
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.cookie-banner__text {
  flex: 1;
}

.cookie-banner__text strong {
  display: block;
  color: var(--white);
  margin-bottom: 4px;
  font-size: .95rem;
}

.cookie-banner__text p {
  font-size: .83rem;
  color: rgba(255, 255, 255, .7);
  line-height: 1.5;
}

.cookie-banner__text a {
  color: var(--gold-light);
}

.cookie-banner__actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

/* Floating cookie */
/* Floating cookie */
.cookie-float {
  position: fixed;
  bottom: 28px;
  left: 28px;
  z-index: 800;
  width: 44px;
  height: 44px;
  background: var(--blue-deep);
  border: 2px solid rgba(255, 255, 255, .15);
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.cookie-float:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-lg);
}

/* Adjust positioning on small screens to avoid overlap with footer credits */
@media (max-width: 600px) {
  .cookie-float {
    bottom: 20px;
    /* close to bottom but not overlapping */
    right: 90px;
    /* move to right side */
    left: auto;
  }

  .footer-bottom {
    padding-right: 60px;
    /* ensure space for float button on right */
  }
}

/* ============================================================
   ANIMATIONS
============================================================ */
.animate-fade-up {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp .7s ease forwards;
}

.animate-slide-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .6s ease, transform .6s ease;
}

.animate-slide-up.in-view {
  opacity: 1;
  transform: none;
}

/* Hero stagger */
.hero-badge.animate-fade-up {
  animation-delay: .1s;
}

.hero-title.animate-fade-up {
  animation-delay: .25s;
}

.hero-subtitle.animate-fade-up {
  animation-delay: .4s;
}

.hero-actions.animate-fade-up {
  animation-delay: .55s;
}

.hero-trust.animate-fade-up {
  animation-delay: .7s;
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: none;
  }
}

/* Slide-up stagger via --delay */
.animate-slide-up {
  transition-delay: var(--delay, 0s);
}

/* ============================================================
   BACK TO TOP
============================================================ */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 52px;
  height: 52px;
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition);
  box-shadow: var(--shadow-md);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--blue-deep);
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.back-to-top svg {
  width: 24px;
  height: 24px;
}

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .contatti-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  .main-nav {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .hero-title {
    font-size: clamp(2rem, 8vw, 3.2rem);
  }

  .servizio-card {
    flex-direction: column;
    gap: 20px;
    padding: 28px 24px;
  }

  .sede-card {
    grid-template-columns: 1fr;
  }

  .sede-map {
    min-height: 160px;
  }

  #sede-info {
    gap: 40px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .fase-steps-grid {
    grid-template-columns: 1fr;
  }

  .geo-popup__buttons {
    flex-direction: column;
  }

  .cookie-banner {
    bottom: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    width: 100%;
    left: 0;
    transform: none;
    padding: 20px;
  }

  .cookie-banner__content {
    flex-direction: column;
    text-align: center;
    gap: 16px;
  }

  .cookie-banner__actions {
    justify-content: center;
    width: 100%;
  }

  .cookie-banner.visible {
    animation-name: slideUpMobile;
  }

  @keyframes slideUpMobile {
    from {
      opacity: 0;
      transform: translateY(20px);
    }

    to {
      opacity: 1;
      transform: none;
    }
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
    text-align: center;
  }

  .messaggio-chiave {
    flex-direction: column;
    text-align: center;
  }

  .valutazione-box {
    flex-direction: column;
  }

  .fase-header {
    flex-direction: column;
    gap: 12px;
  }

  .fase-number {
    font-size: 2.5rem;
  }
}

/* ============================================================
   HIGH CONTRAST / REDUCED MOTION
============================================================ */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}

@media (prefers-contrast: more) {
  :root {
    --blue-light: #003db3;
    --text-muted: #333;
    --gray-200: #999;
  }

  .card-list li::before {
    background: #003db3;
  }
}

/* Print */
@media print {

  .site-header,
  .cookie-banner,
  .cookie-float,
  .geo-popup,
  .geo-overlay {
    display: none !important;
  }

  .hero {
    min-height: auto;
    padding-top: 0;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: .8em;
    color: #666;
  }
}