/* ============================================================
   SCUOLASTICO – Landing Page One-Page 2026
   CSS custom, mobile-first, senza framework.
   Brand originale: viola #9b2b87 / #782b9b, font Poppins.
   ============================================================ */

/* ---------- Variabili di brand ---------- */
:root {
  --c-primary: #9b2b87;        /* viola istituzionale (logo e pulsanti) */
  --c-primary-dark: #7a2168;   /* variante scura per hover/gradiente */
  --c-secondary: #782b9b;      /* viola secondario del sito originale */
  --c-ink: #2b2b2b;            /* colore testo originale */
  --c-muted: #6d5f6a;
  --c-paper: #ffffff;
  --c-soft: #f8f3f7;           /* fondo sezioni alternate, tinto di viola */
  --c-line: #eadfe7;
  --grad-brand: linear-gradient(135deg, #9b2b87 0%, #782b9b 100%);
  --font-brand: 'Poppins', Arial, Helvetica, sans-serif;
  --radius: 10px;              /* raggio pulsanti/eventuali del sito originale */
  --radius-lg: 16px;
  --shadow: 0 10px 30px rgba(122, 33, 104, 0.10);
  --header-h: 72px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-brand);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--c-ink);
  background: var(--c-paper);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

a {
  color: var(--c-primary);
  text-decoration: none;
}

/* ---------- Utilità ---------- */
.container {
  width: min(100% - 2.5rem, 1140px);
  margin-inline: auto;
}

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

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 200;
  padding: 0.6rem 1rem;
  background: var(--c-primary);
  color: #fff;
  border-radius: 0 0 var(--radius) var(--radius);
}

.skip-link:focus {
  top: 0;
}

/* ============================================================
   HEADER + NAVIGAZIONE AD ANCORE (CSS-only)
   ============================================================ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--c-paper);
  border-bottom: 1px solid var(--c-line);
  box-shadow: 0 2px 14px rgba(43, 43, 43, 0.06);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}

.header__logo {
  width: auto;
  height: 44px;
}

/* Burger (solo mobile) */
.nav-toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.header__burger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  cursor: pointer;
  border-radius: var(--radius);
}

.header__burger-bar {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--c-primary);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle:checked ~ .header__burger .header__burger-bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle:checked ~ .header__burger .header__burger-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle:checked ~ .header__burger .header__burger-bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.nav-toggle:focus-visible ~ .header__burger {
  outline: 2px solid var(--c-primary);
  outline-offset: 2px;
}

/* Pannello nav: mobile a scomparsa */
.nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--c-paper);
  border-bottom: 1px solid var(--c-line);
  box-shadow: var(--shadow);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.nav-toggle:checked ~ .nav {
  max-height: 26rem;
}

.nav__list {
  display: flex;
  flex-direction: column;
  padding: 0.5rem 1.25rem 1rem;
}

.nav__link,
.nav__sublink {
  display: block;
  padding: 0.7rem 0.25rem;
  font-weight: 500;
  color: var(--c-ink);
  border-bottom: 1px solid var(--c-line);
  transition: color 0.2s ease;
  cursor: pointer;
}

.nav__link:hover,
.nav__sublink:hover,
.nav__link:focus-visible,
.nav__sublink:focus-visible {
  color: var(--c-primary);
}

.nav__link--parent {
  color: var(--c-muted);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.nav__sub {
  padding-left: 0.9rem;
}

/* Nav desktop */
@media (min-width: 900px) {
  .header__burger {
    display: none;
  }

  .nav {
    position: static;
    max-height: none;
    overflow: visible;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .nav__list {
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
    padding: 0;
  }

  .nav__link {
    padding: 0.5rem 0.9rem;
    border-bottom: 0;
    border-radius: var(--radius);
  }

  .nav__link:hover,
  .nav__link:focus-visible {
    background: var(--c-soft);
    color: var(--c-primary);
  }

  .nav__link--parent {
    color: var(--c-ink);
    font-weight: 500;
    font-size: 1rem;
    text-transform: none;
    letter-spacing: normal;
  }

  .nav__link--parent::after {
    content: "▾";
    margin-left: 0.35rem;
    font-size: 0.75em;
    color: var(--c-primary);
  }

  .nav__item--dropdown {
    position: relative;
  }

  .nav__sub {
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0;
    min-width: 11rem;
    padding: 0.4rem;
    background: var(--c-paper);
    border: 1px solid var(--c-line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }

  .nav__item--dropdown:hover .nav__sub,
  .nav__item--dropdown:focus-within .nav__sub {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav__sublink {
    padding: 0.55rem 0.8rem;
    border-bottom: 0;
    border-radius: calc(var(--radius) - 4px);
  }

  .nav__sublink:hover,
  .nav__sublink:focus-visible {
    background: var(--c-soft);
  }
}

/* ============================================================
   SEZIONI GENERICHE
   ============================================================ */
section[id] {
  scroll-margin-top: calc(var(--header-h) + 8px);
}

.section {
  padding: 3.5rem 0;
}

.section--soft {
  background: var(--c-soft);
}

.section__head {
  max-width: 46rem;
  margin: 0 auto 2.25rem;
  text-align: center;
}

.section__title {
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  font-weight: 600;
  line-height: 1.25;
  color: var(--c-ink);
}

.section__title::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin: 0.8rem auto 0;
  border-radius: 2px;
  background: var(--grad-brand);
}

.section__lead {
  margin-top: 1rem;
  color: var(--c-muted);
}

.section__lead--strong {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--c-primary);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  background: var(--grad-brand);
  color: #fff;
  padding: 3.5rem 0;
}

.hero__inner {
  display: grid;
  gap: 2.25rem;
  align-items: center;
}

.hero__eyebrow {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  opacity: 0.9;
  margin-bottom: 0.9rem;
}

.hero__title {
  font-size: clamp(1.7rem, 4.2vw, 2.6rem);
  font-weight: 700;
  line-height: 1.2;
}

.hero__subtitle {
  margin-top: 1.1rem;
  font-size: 1.05rem;
  opacity: 0.94;
  max-width: 34rem;
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.6rem;
}

.hero__badge {
  padding: 0.4rem 0.9rem;
  font-size: 0.83rem;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

.hero__media img {
  margin-inline: auto;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.25));
}

@media (min-width: 900px) {
  .hero {
    padding: 4.5rem 0;
  }

  .hero__inner {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

/* ============================================================
   GRIGLIE E CARD
   ============================================================ */
.grid {
  display: grid;
  gap: 1.4rem;
}

@media (min-width: 640px) {
  .grid--2,
  .grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 980px) {
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--c-paper);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.4rem;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(122, 33, 104, 0.16);
}

.card__icon {
  width: 48px;
  height: 48px;
  object-fit: contain;
  margin-bottom: 1rem;
}

.card__title {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.card__text {
  font-size: 0.95rem;
  color: var(--c-muted);
}

.card--value {
  text-align: center;
  border-top: 4px solid var(--c-primary);
}

/* ============================================================
   SCUOLE: BLOCCO COMUNE + DIFFERENZE
   ============================================================ */
.common {
  background: var(--c-paper);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 1.8rem 1.5rem;
}

.common__title,
.panel__title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--c-primary);
  margin-bottom: 1rem;
}

.checklist {
  display: grid;
  gap: 0.65rem;
}

@media (min-width: 900px) {
  .common .checklist {
    grid-template-columns: repeat(2, 1fr);
    column-gap: 2rem;
  }
}

.checklist__item {
  position: relative;
  padding-left: 1.7rem;
  font-size: 0.95rem;
}

.checklist__item::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0.05rem;
  width: 1.15rem;
  height: 1.15rem;
  display: grid;
  place-items: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  background: var(--grad-brand);
  border-radius: 50%;
}

.scuole-diff {
  margin-top: 1.4rem;
}

.panel {
  background: var(--c-paper);
  border: 1px solid var(--c-line);
  border-left: 5px solid var(--c-primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 1.6rem 1.4rem;
}

.panel + .panel,
.panel:last-child {
  border-left-color: var(--c-secondary);
}

/* ============================================================
   CHI SIAMO
   ============================================================ */
.about__text {
  max-width: 46rem;
  margin: 0 auto 2rem;
  text-align: center;
  display: grid;
  gap: 0.9rem;
}

/* ============================================================
   EXPERIENCE / PORTFOLIO
   ============================================================ */
.shot {
  background: var(--c-paper);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.shot:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(122, 33, 104, 0.16);
}

.shot__img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  object-position: top;
}

.shot__caption {
  padding: 0.9rem 1.1rem 1.1rem;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.4;
}

.shot__place {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.83rem;
  font-weight: 400;
  color: var(--c-muted);
}

/* ============================================================
   SUPPORTO ANIMATORI DIGITALI
   ============================================================ */
.support {
  display: grid;
  gap: 2rem;
  align-items: center;
}

.support__media img {
  max-width: 380px;
  margin-inline: auto;
}

.support__text .section__title {
  text-align: left;
}

.support__text .section__title::after {
  margin-left: 0;
}

.support__text p {
  margin-top: 1rem;
  color: var(--c-muted);
}

@media (min-width: 900px) {
  .support {
    grid-template-columns: 0.85fr 1.15fr;
  }
}

/* ============================================================
   CONTATTI
   ============================================================ */
.section--contatti {
  background: var(--grad-brand);
  color: #fff;
}

.section__title--light {
  color: #fff;
}

.section__title--light::after {
  background: rgba(255, 255, 255, 0.85);
}

.section__lead--light {
  color: rgba(255, 255, 255, 0.92);
}

.contacts {
  max-width: 60rem;
  margin-inline: auto;
}

.contacts__block {
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.4rem;
  text-align: center;
}

.contacts__label {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 0.7rem;
  color: rgba(255, 255, 255, 0.85);
}

.contacts__value {
  font-size: 1rem;
  line-height: 1.7;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: #241023;
  color: rgba(255, 255, 255, 0.85);
  padding: 2.5rem 0 2rem;
}

.footer__accreditations {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 2.5rem;
  margin-bottom: 2rem;
}

.footer__accr {
  display: grid;
  justify-items: center;
  gap: 0.6rem;
  text-align: center;
  font-size: 0.78rem;
  line-height: 1.4;
}

.footer__accr img {
  height: 56px;
  width: auto;
  background: #fff;
  border-radius: 8px;
  padding: 6px 10px;
}

.footer__legal {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 1.4rem;
  text-align: center;
  display: grid;
  gap: 0.4rem;
}

.footer__privacy {
  color: #fff;
  font-size: 0.9rem;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer__privacy:hover {
  color: #e9c7e2;
}

.footer__copy {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
}

/* ============================================================
   PAGINA LEGALE (privacy-e-note-legali.html)
   ============================================================ */
.legal-hero {
  background: var(--grad-brand);
  color: #fff;
  padding: 2.6rem 0;
  text-align: center;
}

.legal-hero__title {
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  font-weight: 600;
}

.legal-hero__breadcrumb {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.legal-hero__breadcrumb a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal {
  max-width: 50rem;
  margin-inline: auto;
  padding: 2.8rem 0 3.5rem;
}

.legal h2 {
  font-size: 1.45rem;
  font-weight: 600;
  color: var(--c-primary);
  margin: 2.2rem 0 0.9rem;
}

.legal h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.8rem 0 0.7rem;
}

.legal h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--c-primary);
  margin: 1.4rem 0 0.5rem;
}

.legal p {
  margin-bottom: 0.9rem;
}

.legal ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-bottom: 0.9rem;
}

.legal li {
  margin-bottom: 0.3rem;
}

/* ---------- Accessibilità: riduzione movimento ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .card,
  .shot,
  .nav,
  .header__burger-bar,
  .nav__sub {
    transition: none;
  }
}
