/* TurinLex — foglio di stile */
:root {
  --ink: #0e1a36;
  --ink-2: #1b2b56;
  --ink-3: #2c3f74;
  --paper: #f7f3ea;
  --paper-2: #efe8d8;
  --surface: #ffffff;
  --gold: #b8924a;
  --gold-2: #d6b878;
  --gold-soft: #f1e6cc;
  --text: #1d2433;
  --muted: #5b6476;
  --line: #e3dccb;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(14, 26, 54, .06), 0 12px 32px -12px rgba(14, 26, 54, .18);
  --shadow-lg: 0 30px 60px -20px rgba(14, 26, 54, .35);
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 17px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--ink-3); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--gold); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; color: var(--ink); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); font-weight: 400; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); font-weight: 400; }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1em; }
em.accent { font-style: italic; color: var(--gold); }

.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section--tight { padding: clamp(48px, 6vw, 80px) 0; }
.section--white { background: var(--surface); }
.section--ink { background: var(--ink); color: #d9deeb; }
.section--ink h2, .section--ink h3 { color: #fff; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 700 .75rem/1 var(--sans); letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.section-head { max-width: 760px; margin-bottom: 48px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow::after { content: ""; width: 28px; height: 1px; background: currentColor; }
.section-head.center .lead { margin-inline: auto; }

/* Pulsanti */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 26px; border-radius: 999px;
  font: 700 .95rem/1 var(--sans); text-decoration: none;
  transition: transform .25s ease, background .25s ease, color .25s ease, box-shadow .25s ease;
  border: 1px solid transparent; cursor: pointer;
}
.btn svg { width: 18px; height: 18px; transition: transform .25s ease; }
.btn:hover svg { transform: translateX(4px); }
.btn--gold { background: var(--gold); color: #fff; box-shadow: 0 10px 24px -10px rgba(184, 146, 74, .8); }
.btn--gold:hover { background: #a37f3c; color: #fff; transform: translateY(-2px); }
.btn--ghost { border-color: rgba(255, 255, 255, .35); color: #fff; }
.btn--ghost:hover { background: #fff; color: var(--ink); }
.btn--ink { background: var(--ink); color: #fff; }
.btn--ink:hover { background: var(--ink-3); color: #fff; transform: translateY(-2px); }
.btn--line { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn--line:hover { border-color: var(--gold); color: var(--ink); }

/* Header */
.topbar { background: var(--ink); color: #aeb8d3; font-size: .82rem; }
.topbar .wrap { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; }
.topbar a { color: #dfe4f0; text-decoration: none; }
.topbar a:hover { color: var(--gold-2); }
.topbar .tb-links { display: flex; gap: 22px; }
@media (max-width: 720px) { .topbar .tb-hide { display: none; } }

.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 243, 234, .86);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, box-shadow .3s ease;
}
.header.is-scrolled { border-color: var(--line); box-shadow: 0 8px 30px -18px rgba(14, 26, 54, .35); }
.header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 78px; }

.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink); color: var(--gold-2);
  font: 500 1.15rem/1 var(--serif); letter-spacing: -.02em;
  box-shadow: inset 0 0 0 2px var(--ink), inset 0 0 0 3px var(--gold);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font: 500 1.45rem/1 var(--serif); letter-spacing: -.01em; }
.brand-name b { font-weight: 500; color: var(--gold); }
.brand-sub { font: 700 .62rem/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: 5px; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  position: relative; padding: 10px 13px; border-radius: 10px;
  font-weight: 600; font-size: .92rem; color: var(--text); text-decoration: none;
}
.nav a::after {
  content: ""; position: absolute; left: 13px; right: 13px; bottom: 5px; height: 2px;
  background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .3s ease;
}
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav .btn { margin-left: 10px; padding: 12px 20px; }
.nav .btn--ink, .nav .btn--ink[aria-current="page"] { color: #fff; }
.nav .btn--ink:hover { color: #fff; }
.nav .btn::after { display: none; }

.nav-toggle {
  display: none; width: 46px; height: 46px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); cursor: pointer;
  align-items: center; justify-content: center;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px;
  position: relative; transition: transform .3s ease, background .3s ease;
}
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; }
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle span::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1040px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    position: fixed; inset: 78px 0 auto 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); padding: 12px 16px 24px; border-bottom: 1px solid var(--line);
    box-shadow: 0 30px 40px -30px rgba(14, 26, 54, .4);
    transform: translateY(-12px); opacity: 0; visibility: hidden;
    transition: transform .3s ease, opacity .3s ease, visibility .3s;
    max-height: calc(100vh - 78px); overflow-y: auto;
  }
  .nav-open .nav { transform: none; opacity: 1; visibility: visible; }
  .nav a { padding: 14px 6px; font-size: 1.05rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav a::after { display: none; }
  .nav a[aria-current="page"] { color: var(--gold); }
  .nav .btn { margin: 18px 0 0; justify-content: center; border-bottom: 0; border-radius: 999px; }
}

/* Hero home */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--ink); color: #dce2f0;
  padding: clamp(80px, 12vw, 150px) 0 clamp(120px, 14vw, 180px);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background: url("../img/torino.jpg") center 35% / cover no-repeat;
  opacity: .28; filter: grayscale(.4) contrast(1.1);
  transform: scale(1.06); animation: heroZoom 18s ease-out forwards;
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(900px 500px at 85% 10%, rgba(184, 146, 74, .28), transparent 60%),
    linear-gradient(180deg, rgba(14, 26, 54, .35) 0%, rgba(14, 26, 54, .92) 75%, var(--ink) 100%);
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero h1 { color: #fff; max-width: 15ch; }
.hero .lead { color: #c3cbe0; font-size: clamp(1.05rem, 1.6vw, 1.25rem); }
.hero-badge {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px;
  padding: 8px 16px 8px 8px; border-radius: 999px;
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14);
  font-size: .85rem; color: #e8ecf5;
}
.hero-badge i {
  font-style: normal; font-weight: 800; font-size: .7rem; letter-spacing: .12em;
  background: var(--gold); color: #fff; padding: 5px 10px; border-radius: 999px;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 56px; align-items: end; }
.hero-card {
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12);
  border-radius: var(--radius); padding: 28px; backdrop-filter: blur(8px);
}
.hero-card h3 { color: #fff; font-size: 1.15rem; margin-bottom: 16px; }
.hero-card ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.hero-card li { display: grid; grid-template-columns: 28px 1fr; gap: 10px; font-size: .95rem; color: #cfd6e8; }
.hero-card li svg { width: 22px; height: 22px; color: var(--gold-2); margin-top: 2px; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } }

/* Hero pagine interne */
.page-hero {
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--ink); color: #c9d0e3; padding: clamp(64px, 9vw, 110px) 0 clamp(70px, 9vw, 110px);
}
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background: var(--hero-img, none) center / cover no-repeat; opacity: .22; filter: grayscale(.5);
}
.page-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(700px 380px at 90% 0%, rgba(184, 146, 74, .3), transparent 60%),
              linear-gradient(180deg, rgba(14, 26, 54, .4), var(--ink));
}
.page-hero h1 { color: #fff; font-size: clamp(2.2rem, 4.6vw, 3.6rem); max-width: 18ch; }
.page-hero .lead { color: #bfc8de; }
.crumbs { font-size: .85rem; margin-bottom: 20px; color: #8e9abb; }
.crumbs a { color: #c9d0e3; text-decoration: none; }
.crumbs a:hover { color: var(--gold-2); }
.crumbs span { margin: 0 8px; opacity: .6; }

/* Statistiche */
.stats {
  position: relative; z-index: 2; margin-top: -80px;
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--surface); border-radius: calc(var(--radius) + 4px); box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.stat { padding: 30px 28px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat b { display: block; font: 400 clamp(2.2rem, 3.6vw, 3rem)/1 var(--serif); color: var(--ink); margin-bottom: 10px; }
.stat b sup { font-size: .45em; color: var(--gold); margin-left: 2px; }
.stat > span { font-size: .92rem; color: var(--muted); line-height: 1.45; display: block; }
@media (max-width: 860px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 420px) { .stat { padding: 22px 18px; } }

/* Griglie e card */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 680px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  position: relative; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow);
  transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--gold-soft); }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.card .icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: var(--gold-soft); color: var(--gold); margin-bottom: 20px;
}
.card .icon svg { width: 26px; height: 26px; }
.card .tag {
  display: inline-block; font: 700 .7rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); background: var(--gold-soft); padding: 7px 11px; border-radius: 999px; margin-bottom: 16px;
}
.card .more {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 18px;
  font-weight: 700; font-size: .92rem; text-decoration: none; color: var(--ink);
}
.card .more svg { width: 16px; height: 16px; transition: transform .25s ease; }
.card:hover .more svg { transform: translateX(4px); }
.card--link { text-decoration: none; color: inherit; display: block; }
.card--ink { background: var(--ink); border-color: var(--ink); color: #c9d0e3; }
.card--ink h3 { color: #fff; }
.card--ink .icon { background: rgba(214, 184, 120, .14); color: var(--gold-2); }
.card--ink .more { color: var(--gold-2); }

/* Due colonne testo/immagine */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.split--top { align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }
.photo { position: relative; }
.photo img { border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 100%; aspect-ratio: 4 / 3.4; object-fit: cover; }
.photo::before {
  content: ""; position: absolute; inset: 24px -24px -24px 24px; z-index: -1;
  border: 1px solid var(--gold); border-radius: var(--radius);
}
.photo-note {
  position: absolute; left: -20px; bottom: 30px; max-width: 250px;
  background: var(--surface); border-radius: 14px; padding: 18px 20px; box-shadow: var(--shadow-lg);
  font-family: var(--serif); font-size: 1.05rem; line-height: 1.35; color: var(--ink);
}
.photo-note small { display: block; font: 600 .75rem/1.3 var(--sans); color: var(--muted); margin-top: 8px; letter-spacing: .04em; }
@media (max-width: 900px) { .photo::before { inset: 16px -10px -16px 16px; } .photo-note { left: 12px; } }

/* Liste con spunta */
.checks { list-style: none; padding: 0; margin: 24px 0; display: grid; gap: 14px; }
.checks li { display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: start; }
.checks li::before {
  content: ""; width: 26px; height: 26px; border-radius: 50%; margin-top: 2px;
  background: var(--gold-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b8924a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.section--ink .checks li::before, .card--ink .checks li::before { background-color: rgba(214, 184, 120, .15); }

/* Passaggi numerati */
.steps { counter-reset: s; display: grid; gap: 0; }
.step {
  counter-increment: s; position: relative;
  display: grid; grid-template-columns: 76px 1fr; gap: 22px; padding: 26px 0;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step::before {
  content: counter(s, decimal-leading-zero);
  font: 400 2.4rem/1 var(--serif); color: var(--gold);
}
.step h3 { font-size: 1.2rem; margin-bottom: .3em; }
.step p { margin: 0; color: var(--muted); }
.section--ink .step { border-color: rgba(255, 255, 255, .12); }
.section--ink .step p { color: #aab4cf; }
@media (max-width: 560px) { .step { grid-template-columns: 52px 1fr; gap: 14px; } .step::before { font-size: 1.9rem; } }

/* Box fatti */
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.fact { background: var(--surface); padding: 28px; }
.fact .k { font: 700 .72rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.fact .v { font: 400 1.5rem/1.2 var(--serif); color: var(--ink); margin-bottom: 8px; }
.fact p { font-size: .93rem; color: var(--muted); margin: 0; }
@media (max-width: 900px) { .facts { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .facts { grid-template-columns: 1fr; } }

/* Accordion */
.accordion { display: grid; gap: 12px; }
.accordion details {
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  transition: border-color .3s ease, box-shadow .3s ease;
}
.accordion details[open] { border-color: var(--gold-2); box-shadow: var(--shadow); }
.accordion summary {
  list-style: none; cursor: pointer; padding: 20px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  font: 500 1.12rem/1.3 var(--serif); color: var(--ink);
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary .count { font: 600 .78rem/1 var(--sans); color: var(--muted); margin-left: auto; white-space: nowrap; }
.accordion summary .plus {
  flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--gold-soft); position: relative;
}
.accordion summary .plus::before, .accordion summary .plus::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; background: var(--gold);
  transform: translate(-50%, -50%); transition: transform .3s ease;
}
.accordion summary .plus::after { transform: translate(-50%, -50%) rotate(90deg); }
.accordion details[open] .plus::after { transform: translate(-50%, -50%) rotate(0deg); }
.accordion .body { padding: 0 24px 22px; color: var(--muted); }
.accordion .body ol { margin: 0; padding-left: 1.3em; display: grid; gap: 6px; }
.accordion .body ol li::marker { color: var(--gold); font-weight: 700; }

/* Corsi */
.course { display: flex; flex-direction: column; }
.course .meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 18px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 600;
  padding: 6px 11px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); color: var(--ink-2);
}
.chip svg { width: 14px; height: 14px; color: var(--gold); }
.course .price { margin-top: auto; padding-top: 20px; border-top: 1px dashed var(--line); display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.course .price b { font: 400 1.8rem/1 var(--serif); color: var(--ink); }
.course .price small { color: var(--muted); font-size: .8rem; }
.course details { margin-top: 4px; }
.course details summary { cursor: pointer; font-weight: 700; font-size: .9rem; color: var(--gold); list-style: none; display: inline-flex; gap: 6px; align-items: center; }
.course details summary::-webkit-details-marker { display: none; }
.course details summary::after { content: "+"; font-size: 1.1rem; line-height: 1; }
.course details[open] summary::after { content: "–"; }
.course details ul { margin: 14px 0 0; padding-left: 1.1em; color: var(--muted); font-size: .94rem; display: grid; gap: 6px; }
.course details ul li::marker { color: var(--gold); }

/* Tabs filtro corsi */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.filters button {
  font: 700 .88rem/1 var(--sans); padding: 12px 18px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); transition: all .25s ease;
}
.filters button:hover { border-color: var(--gold); }
.filters button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.course[hidden] { display: none; }

/* Docenti */
.teacher { display: flex; flex-direction: column; }
.teacher .avatar {
  width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 20px;
  background: linear-gradient(135deg, var(--ink), var(--ink-3)); color: var(--gold-2);
  font: 400 1.9rem/1 var(--serif); box-shadow: 0 0 0 4px var(--surface), 0 0 0 5px var(--gold-soft);
}
.teacher .role { font-weight: 700; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }
.teacher .areas { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 18px; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 20px; border-left: 2px solid var(--gold-soft); display: grid; gap: 14px; font-size: .94rem; color: var(--muted); }
.timeline li { position: relative; }
.timeline li::before { content: ""; position: absolute; left: -27px; top: 8px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 2px solid var(--gold); }
.timeline b { color: var(--ink); font-weight: 700; margin-right: 6px; }

/* Prezzi */
.price-card { text-align: left; display: flex; flex-direction: column; }
.price-card.featured { background: var(--ink); color: #c9d0e3; border-color: var(--ink); }
.price-card.featured h3 { color: #fff; }
.price-card .amount { font: 400 3.2rem/1 var(--serif); color: var(--ink); margin: 14px 0 6px; }
.price-card.featured .amount { color: #fff; }
.price-card .amount small { font: 600 .9rem/1 var(--sans); color: var(--muted); margin-left: 6px; }
.price-card.featured .amount small { color: #9eaacb; }
.price-card .btn { margin-top: auto; align-self: flex-start; }
.price-table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.price-table th, .price-table td { text-align: left; padding: 20px 24px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.price-table tr:last-child td { border-bottom: 0; }
.price-table thead th { background: var(--paper-2); font: 700 .75rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.price-table td:first-child { font: 500 1.08rem/1.3 var(--serif); color: var(--ink); }
.price-table td.amt { font: 400 1.4rem/1 var(--serif); color: var(--ink); white-space: nowrap; text-align: right; }
.price-table tbody tr { transition: background .2s ease; }
.price-table tbody tr:hover { background: #fbf8f1; }
@media (max-width: 640px) {
  .price-table thead { display: none; }
  .price-table, .price-table tbody, .price-table tr, .price-table td { display: block; width: 100%; }
  .price-table tr { padding: 18px 20px; border-bottom: 1px solid var(--line); }
  .price-table td { padding: 2px 0; border: 0; }
  .price-table td.amt { text-align: left; margin-top: 8px; }
}

/* Testimonianze */
.wall { columns: 4 220px; column-gap: 20px; }
.note {
  break-inside: avoid; margin: 0 0 20px; display: block; width: 100%; padding: 0; border: 0; cursor: zoom-in;
  background: var(--surface); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow);
  transition: transform .35s ease, box-shadow .35s ease;
}
.note:nth-child(3n+1) { transform: rotate(-1deg); }
.note:nth-child(3n+2) { transform: rotate(.8deg); }
.note:hover { transform: rotate(0) scale(1.03); box-shadow: var(--shadow-lg); }
.note img { width: 100%; height: auto; }
.wall--teaser { columns: 3 200px; }
.quote {
  font: 400 clamp(1.5rem, 2.6vw, 2.1rem)/1.35 var(--serif); color: #fff; font-style: italic; max-width: 26ch;
}
.quote::before { content: "“"; display: block; font-size: 4rem; line-height: .6; color: var(--gold); margin-bottom: 14px; font-style: normal; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 100; background: rgba(8, 14, 30, .92);
  display: grid; place-items: center; padding: 24px; opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility .3s;
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox img { max-height: 86vh; width: auto; border-radius: 10px; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }
.lightbox button {
  position: absolute; width: 50px; height: 50px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .25);
  background: rgba(255, 255, 255, .08); color: #fff; font-size: 1.5rem; cursor: pointer; display: grid; place-items: center;
}
.lightbox button:hover { background: var(--gold); border-color: var(--gold); }
.lb-close { top: 20px; right: 20px; }
.lb-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 20px; top: 50%; transform: translateY(-50%); }
@media (max-width: 600px) { .lb-prev, .lb-next { top: auto; bottom: 20px; transform: none; } }

/* Contatti */
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.contact-list li { display: grid; grid-template-columns: 48px 1fr; gap: 16px; align-items: start; }
.contact-list .ic { width: 48px; height: 48px; border-radius: 14px; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; }
.contact-list .ic svg { width: 22px; height: 22px; }
.contact-list small { display: block; font-weight: 700; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.contact-list a, .contact-list span { font: 500 1.12rem/1.4 var(--serif); color: var(--ink); text-decoration: none; }
.contact-list a:hover { color: var(--gold); }
.map { border: 0; width: 100%; height: 100%; min-height: 420px; border-radius: var(--radius); box-shadow: var(--shadow-lg); filter: grayscale(.35) sepia(.12); }

/* CTA */
.cta {
  position: relative; overflow: hidden; border-radius: 28px; padding: clamp(40px, 6vw, 72px);
  background: linear-gradient(135deg, var(--ink) 0%, var(--ink-3) 100%); color: #c9d0e3;
  display: grid; grid-template-columns: 1.4fr auto; gap: 32px; align-items: center;
}
.cta::after {
  content: ""; position: absolute; width: 420px; height: 420px; right: -120px; top: -160px; border-radius: 50%;
  border: 1px solid rgba(214, 184, 120, .35); box-shadow: 0 0 0 40px rgba(214, 184, 120, .05), 0 0 0 80px rgba(214, 184, 120, .04);
}
.cta h2 { color: #fff; margin-bottom: .3em; }
.cta p { margin: 0; max-width: 52ch; }
.cta .actions { display: flex; flex-wrap: wrap; gap: 12px; position: relative; z-index: 1; }
@media (max-width: 820px) { .cta { grid-template-columns: 1fr; } }

/* Callout */
.callout {
  display: grid; grid-template-columns: auto 1fr; gap: 18px; align-items: start;
  background: var(--gold-soft); border-radius: var(--radius); padding: 24px 26px; color: #5a4520;
}
.callout svg { width: 28px; height: 28px; color: var(--gold); }
.callout b { color: var(--ink); }
.callout p:last-child { margin: 0; }

.prose p { color: var(--muted); }
.prose p strong { color: var(--ink); }

/* Footer */
.footer { background: #0a1329; color: #8f9abb; padding: 80px 0 30px; font-size: .94rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; }
.footer h4 { font: 700 .75rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold-2); margin-bottom: 18px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer a { color: #c7cee2; text-decoration: none; }
.footer a:hover { color: var(--gold-2); }
.footer .brand { color: #fff; margin-bottom: 18px; }
.footer .brand-sub { color: #8f9abb; }
.footer-bottom { margin-top: 56px; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .08); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .84rem; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* Animazioni in entrata */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s ease, transform .8s cubic-bezier(.2, .7, .2, 1); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: .08s; } .reveal-d2 { transition-delay: .16s; } .reveal-d3 { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero::before { animation: none; }
  * { transition-duration: .01ms !important; }
}

.mt-0 { margin-top: 0; } .mt-l { margin-top: 48px; } .center { text-align: center; }
.skip { position: absolute; left: -999px; top: 0; background: var(--gold); color: #fff; padding: 10px 16px; z-index: 200; }
.skip:focus { left: 16px; top: 16px; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

/* ============================================================
   Colore — palette vivace sopra la base blu/oro
   ============================================================ */
:root {
  --coral: #e8624a;   --coral-soft: #fde6e0;
  --teal: #13a39a;    --teal-soft: #d8f3f0;
  --violet: #7258d6;  --violet-soft: #ebe6fb;
  --sky: #2f86e0;     --sky-soft: #dfeefc;
  --sun: #f2b234;     --sun-soft: #fdf1d6;
  --rainbow: linear-gradient(90deg, var(--coral), var(--sun), var(--teal), var(--sky), var(--violet));
}

/* Striscia colorata sopra la barra in alto */
.topbar { position: relative; }
.topbar::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--rainbow); }

/* Hero: luci colorate */
.hero::after {
  background:
    radial-gradient(700px 420px at 88% 8%, rgba(232, 98, 74, .35), transparent 60%),
    radial-gradient(600px 400px at 8% 90%, rgba(19, 163, 154, .30), transparent 60%),
    radial-gradient(500px 300px at 55% 0%, rgba(114, 88, 214, .30), transparent 65%),
    linear-gradient(180deg, rgba(14, 26, 54, .35) 0%, rgba(14, 26, 54, .9) 78%, var(--ink) 100%);
}
.page-hero::after {
  background:
    radial-gradient(640px 360px at 92% 0%, rgba(232, 98, 74, .32), transparent 60%),
    radial-gradient(520px 320px at 0% 100%, rgba(47, 134, 224, .30), transparent 60%),
    linear-gradient(180deg, rgba(14, 26, 54, .4), var(--ink));
}
.hero h1 em.accent, .page-hero h1 em.accent {
  background: linear-gradient(90deg, var(--sun), var(--coral)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-badge i { background: linear-gradient(90deg, var(--coral), var(--sun)); }
.hero-card { border-top: 3px solid transparent; border-image: var(--rainbow) 1; border-radius: 0 0 var(--radius) var(--radius); }
.hero-card li:nth-child(1) svg { color: var(--sun); }
.hero-card li:nth-child(2) svg { color: #4fd1c5; }
.hero-card li:nth-child(3) svg { color: #ff8a73; }
.hero-card li:nth-child(4) svg { color: #a594f0; }

/* Pulsanti */
.btn--gold { background: linear-gradient(135deg, var(--coral), #f08a3c); box-shadow: 0 12px 26px -10px rgba(232, 98, 74, .75); }
.btn--gold:hover { background: linear-gradient(135deg, #d4523b, #e07a2c); }
.btn--ink { background: linear-gradient(135deg, var(--ink-2), var(--violet)); }
.btn--ink:hover { background: linear-gradient(135deg, var(--ink-3), #8670e6); }

/* Statistiche: ogni numero il suo colore */
.stats { border-top: 4px solid transparent; border-image: var(--rainbow) 1; }
.stat:nth-child(1) b, .stat:nth-child(1) b sup { color: var(--coral); }
.stat:nth-child(2) b, .stat:nth-child(2) b sup { color: var(--teal); }
.stat:nth-child(3) b, .stat:nth-child(3) b sup { color: var(--sky); }
.stat:nth-child(4) b, .stat:nth-child(4) b sup { color: var(--violet); }

/* Card: icone, tag e bordo superiore a colori ciclici */
.grid > .card:not(.card--ink):not(.featured) { border-top: 4px solid var(--c, var(--gold)); }
.grid > .card:nth-child(5n+1) { --c: var(--coral);  --cs: var(--coral-soft); }
.grid > .card:nth-child(5n+2) { --c: var(--teal);   --cs: var(--teal-soft); }
.grid > .card:nth-child(5n+3) { --c: var(--violet); --cs: var(--violet-soft); }
.grid > .card:nth-child(5n+4) { --c: var(--sky);    --cs: var(--sky-soft); }
.grid > .card:nth-child(5n+5) { --c: var(--sun);    --cs: var(--sun-soft); }
.grid > .card .icon { background: var(--cs, var(--gold-soft)); color: var(--c, var(--gold)); }
.grid > .card .tag { background: var(--cs, var(--gold-soft)); color: var(--c, var(--gold)); }
.grid > .card .chip svg { color: var(--c, var(--gold)); }
.grid > .card .more { color: var(--c, var(--ink)); }
.grid > .card:hover { border-color: var(--line); border-top-color: var(--c, var(--gold)); box-shadow: 0 30px 60px -24px color-mix(in srgb, var(--c, #0e1a36) 45%, transparent); }
.course .price b { color: var(--c, var(--ink)); }
.course details summary { color: var(--c, var(--gold)); }
.course details ul li::marker { color: var(--c, var(--gold)); }

/* Card scure: sfumatura colorata */
.card--ink { background: linear-gradient(145deg, var(--ink) 0%, #2a2470 100%); }
.card--ink .tag { background: rgba(242, 178, 52, .18); color: var(--sun); }
.section--ink .grid > .card--ink:nth-child(1) .icon { background: rgba(232, 98, 74, .2); color: #ff9a85; }
.section--ink .grid > .card--ink:nth-child(2) .icon { background: rgba(19, 163, 154, .22); color: #5fe0d4; }
.section--ink .grid > .card--ink:nth-child(3) .icon { background: rgba(114, 88, 214, .25); color: #b3a5f5; }

/* Sezioni: fondi tinti */
.section--white { background: linear-gradient(180deg, #ffffff 0%, #f4fbfa 100%); }
.section--ink {
  background:
    radial-gradient(600px 360px at 100% 0%, rgba(232, 98, 74, .22), transparent 60%),
    radial-gradient(600px 360px at 0% 100%, rgba(19, 163, 154, .2), transparent 60%),
    var(--ink);
}
.eyebrow { color: var(--coral); }
.section--ink .eyebrow { color: var(--sun); }

/* Passaggi numerati a colori */
.step:nth-child(5n+1)::before { color: var(--coral); }
.step:nth-child(5n+2)::before { color: var(--teal); }
.step:nth-child(5n+3)::before { color: var(--violet); }
.step:nth-child(5n+4)::before { color: var(--sky); }
.step:nth-child(5n+5)::before { color: var(--sun); }

/* Liste con spunta: verde acqua */
.checks li::before {
  background-color: var(--teal-soft);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2313a39a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E");
}
.card--ink .checks li::before, .featured .checks li::before, .section--ink .checks li::before { background-color: rgba(19, 163, 154, .22); }

/* Fatti Scuola Forense */
.fact:nth-child(6n+1) .k { color: var(--coral); }
.fact:nth-child(6n+2) .k { color: var(--teal); }
.fact:nth-child(6n+3) .k { color: var(--violet); }
.fact:nth-child(6n+4) .k { color: var(--sky); }
.fact:nth-child(6n+5) .k { color: #d1931a; }
.fact:nth-child(6n+6) .k { color: var(--coral); }
.fact { transition: background .3s ease; }
.fact:hover { background: #fffaf4; }

/* Accordion programma */
.accordion details:nth-child(5n+1) { --c: var(--coral);  --cs: var(--coral-soft); }
.accordion details:nth-child(5n+2) { --c: var(--teal);   --cs: var(--teal-soft); }
.accordion details:nth-child(5n+3) { --c: var(--violet); --cs: var(--violet-soft); }
.accordion details:nth-child(5n+4) { --c: var(--sky);    --cs: var(--sky-soft); }
.accordion details:nth-child(5n+5) { --c: #d1931a;       --cs: var(--sun-soft); }
.accordion details { border-left: 4px solid var(--c); }
.accordion details[open] { border-color: var(--line); border-left-color: var(--c); }
.accordion summary .plus { background: var(--cs); }
.accordion summary .plus::before, .accordion summary .plus::after { background: var(--c); }
.accordion .body ol li::marker { color: var(--c); }

/* Docenti: avatar con sfumature diverse */
.grid > .teacher:nth-child(1) .avatar { background: linear-gradient(135deg, var(--coral), #f2a13a); color: #fff; }
.grid > .teacher:nth-child(2) .avatar { background: linear-gradient(135deg, var(--teal), #2f86e0); color: #fff; }
.grid > .teacher:nth-child(3) .avatar { background: linear-gradient(135deg, var(--violet), #c05bd6); color: #fff; }
.grid > .teacher:nth-child(4) .avatar { background: linear-gradient(135deg, var(--sky), var(--violet)); color: #fff; }
.teacher .role { color: var(--c); }
.teacher .avatar { box-shadow: 0 0 0 4px var(--surface), 0 0 0 6px var(--cs); }
.timeline { border-left-color: var(--cs); }
.timeline li::before { border-color: var(--c); }

/* Prezzi */
.price-card.featured { background: linear-gradient(150deg, var(--ink) 0%, #3a2a85 60%, #7a3f8f 100%); }
.price-card.featured .tag { background: rgba(242, 178, 52, .2); color: var(--sun); }
.price-table thead th { background: linear-gradient(90deg, var(--coral-soft), var(--sun-soft), var(--teal-soft), var(--sky-soft)); color: var(--ink-2); }
.price-table tbody tr:nth-child(5n+1) td.amt { color: var(--coral); }
.price-table tbody tr:nth-child(5n+2) td.amt { color: var(--teal); }
.price-table tbody tr:nth-child(5n+3) td.amt { color: var(--violet); }
.price-table tbody tr:nth-child(5n+4) td.amt { color: var(--sky); }
.price-table tbody tr:nth-child(5n+5) td.amt { color: #d1931a; }
.price-table tbody tr:hover { background: #fff8f2; }

/* Filtri corsi */
.filters button[aria-pressed="true"] { background: linear-gradient(135deg, var(--coral), var(--violet)); border-color: transparent; }

/* Callout */
.callout { background: linear-gradient(135deg, var(--sky-soft), var(--violet-soft)); color: #2b3a66; }
.callout svg { color: var(--sky); }

/* Contatti: icone colorate */
.contact-list li:nth-child(5n+1) .ic { background: var(--coral-soft); color: var(--coral); }
.contact-list li:nth-child(5n+2) .ic { background: var(--violet-soft); color: var(--violet); }
.contact-list li:nth-child(5n+3) .ic { background: var(--teal-soft); color: var(--teal); }
.contact-list li:nth-child(5n+4) .ic { background: var(--sky-soft); color: var(--sky); }
.contact-list li:nth-child(5n+5) .ic { background: var(--sun-soft); color: #d1931a; }

/* Biglietti: cornice colorata */
.note { border-bottom: 5px solid var(--c, var(--gold)); }
.note:nth-child(5n+1) { --c: var(--coral); }
.note:nth-child(5n+2) { --c: var(--teal); }
.note:nth-child(5n+3) { --c: var(--violet); }
.note:nth-child(5n+4) { --c: var(--sky); }
.note:nth-child(5n+5) { --c: var(--sun); }

/* Foto */
.photo::before { border-color: var(--coral); }
.photo::after {
  content: ""; position: absolute; width: 120px; height: 120px; right: -30px; top: -30px; z-index: -1; border-radius: 50%;
  background: radial-gradient(circle, var(--sun) 0 30%, transparent 31%) 0 0 / 20px 20px; opacity: .55;
}

/* CTA */
.cta { background: linear-gradient(120deg, var(--ink) 0%, #3a2a85 50%, #b24a63 100%); }
.cta::after { border-color: rgba(242, 178, 52, .45); }

/* Navigazione */
.nav a::after { background: var(--rainbow); }
.nav a:hover { color: var(--coral); }
.brand-name b { color: var(--coral); }
.brand-mark { box-shadow: inset 0 0 0 2px var(--ink), inset 0 0 0 3px var(--coral); }

/* Footer */
.footer { position: relative; }
.footer::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--rainbow); }
.footer h4 { color: var(--sun); }
.footer a:hover { color: #ff9a85; }

/* ============================================================
   Docenti — schede e pagine profilo
   ============================================================ */
.teacher.card--link { color: inherit; }
.teacher.card--link p { color: var(--muted); }
.teacher .more { margin-top: auto; padding-top: 18px; }
.teacher-hl {
  display: grid; gap: 2px; margin-top: 6px; padding: 14px 16px; border-radius: 12px;
  background: var(--cs, var(--gold-soft)); font-size: .9rem; color: var(--text);
}
.teacher-hl b { font: 500 1.05rem/1.2 var(--serif); color: var(--c, var(--ink)); }

.profile-hero { padding-bottom: clamp(56px, 7vw, 90px); }
.profile-head { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.profile-head h1 { margin-bottom: 16px; }
.profile-head .eyebrow { margin-bottom: 12px; }
.profile-head .chip { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .18); color: #e3e8f4; }
.avatar--xl {
  flex: none; width: 132px; height: 132px; border-radius: 50%; display: grid; place-items: center;
  color: #fff; font: 400 3rem/1 var(--serif);
  box-shadow: 0 0 0 6px rgba(255, 255, 255, .08), 0 24px 50px -16px rgba(0, 0, 0, .6);
}
@media (max-width: 560px) { .avatar--xl { width: 96px; height: 96px; font-size: 2.2rem; } }

.profile { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(32px, 5vw, 64px); align-items: start; }
@media (max-width: 960px) { .profile { grid-template-columns: 1fr; } }
.profile-main { display: grid; gap: 56px; }
.profile-block h2 {
  font-size: clamp(1.6rem, 2.6vw, 2.1rem); padding-bottom: 14px; margin-bottom: 24px;
  border-bottom: 1px solid var(--line); position: relative;
}
.profile-block h2::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 64px; height: 3px; background: var(--c); border-radius: 3px; }
.prose--lg p { font-size: 1.08rem; }

.timeline--lg { gap: 22px; padding-left: 28px; border-left-width: 3px; font-size: 1rem; }
.timeline--lg li { display: grid; gap: 2px; }
.timeline--lg li::before { left: -37px; top: 6px; width: 16px; height: 16px; border-width: 3px; }
.timeline--lg b { font: 600 .78rem/1.2 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--c); }
.timeline--lg span { color: var(--text); }

.pubs { list-style: none; margin: 0; padding: 0; counter-reset: p; display: grid; gap: 14px; }
.pubs li {
  counter-increment: p; display: grid; grid-template-columns: 44px 1fr; gap: 4px 14px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px;
}
.pubs li::before { content: counter(p, decimal-leading-zero); grid-row: span 2; font: 400 1.6rem/1 var(--serif); color: var(--c); }
.pubs span { font: 500 1.02rem/1.45 var(--serif); color: var(--ink); }
.pubs small { color: var(--muted); font-size: .88rem; }

.profile-side { position: sticky; top: 100px; display: grid; gap: 20px; }
@media (max-width: 960px) { .profile-side { position: static; } }
.side-card { border-top: 4px solid var(--c); }
.side-card:hover { transform: none; }
.side-hl { background: var(--cs); border-radius: 12px; padding: 18px; margin-bottom: 22px; }
.side-hl small, .side-title { display: block; font: 700 .7rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--c); margin-bottom: 8px; }
.side-hl b { font: 500 1.3rem/1.2 var(--serif); color: var(--ink); display: block; margin-bottom: 6px; }
.side-hl p { margin: 0; font-size: .92rem; color: var(--text); }
.contact-list--sm { gap: 14px; margin-bottom: 22px; }
.contact-list--sm li { grid-template-columns: 40px 1fr; gap: 12px; }
.contact-list--sm .ic { width: 40px; height: 40px; border-radius: 12px; }
.contact-list--sm .ic svg { width: 18px; height: 18px; }
.contact-list--sm a, .contact-list--sm span { font-size: 1rem; }
.side-card .btn { width: 100%; justify-content: center; }
.side-title { color: var(--muted); margin-bottom: 14px; }
.minis { display: grid; gap: 6px; }
.mini { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 12px; text-decoration: none; color: var(--ink); font-weight: 600; transition: background .2s ease; }
.mini:hover { background: var(--paper); color: var(--c); }
.avatar--sm { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--grad); color: #fff; font: 400 .95rem/1 var(--serif); flex: none; }

.profile-nav { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: center; margin-top: 72px; padding-top: 28px; border-top: 1px solid var(--line); }
.profile-nav a { text-decoration: none; color: var(--ink); display: grid; gap: 4px; }
.profile-nav a small { font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.profile-nav a span { font: 500 1.15rem/1.2 var(--serif); }
.profile-nav a:hover span { color: var(--c); }
.profile-nav .next { text-align: right; }
.profile-nav .all { padding: 12px 20px; border: 1px solid var(--line); border-radius: 999px; font-weight: 700; font-size: .9rem; background: var(--surface); }
.profile-nav .all:hover { border-color: var(--c); color: var(--c); }
@media (max-width: 640px) {
  .profile-nav { grid-template-columns: 1fr 1fr; }
  .profile-nav .all { grid-column: 1 / -1; grid-row: 2; justify-self: center; }
}

/* Logo TurinLex (SVG: versione scura nell'header, bianca nel footer) */
.brand-logo { height: 50px; width: auto; display: block; }
@media (max-width: 560px) { .brand-logo { height: 40px; } }
.footer .brand { display: inline-flex; }
.footer .brand-logo { height: 46px; }

/* Contatori — schede separate */
.stats {
  margin-top: -84px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px;
  background: none; box-shadow: none; border: 0; border-image: none; border-radius: 0; overflow: visible;
}
.stats .stat {
  position: relative; overflow: hidden; border: 0; padding: 26px 26px 24px;
  background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-lg);
  display: grid; grid-template-columns: auto 1fr; grid-template-areas: "ic num" "label label"; align-items: center; gap: 14px 16px;
  transition: transform .35s ease, box-shadow .35s ease;
}
.stats .stat::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--c); }
.stats .stat:hover { transform: translateY(-4px); }
.stat-ic { grid-area: ic; width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; background: var(--cs); color: var(--c); }
.stat-ic svg { width: 24px; height: 24px; }
.stat-num { grid-area: num; display: flex; align-items: baseline; gap: 6px; font: 400 2.7rem/1 var(--serif); color: var(--ink); letter-spacing: -.02em; }
.stat-num small { font: 700 .78rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--c); }
.stat-label { grid-area: label; font-size: .92rem; line-height: 1.45; color: var(--muted); }
@media (max-width: 980px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats .stat:nth-child(n) { border: 0; }
}
@media (max-width: 480px) {
  .stats { gap: 12px; margin-top: -70px; }
  .stats .stat { padding: 18px 16px; grid-template-columns: 1fr; grid-template-areas: "ic" "num" "label"; gap: 10px; }
  .stat-ic { width: 40px; height: 40px; border-radius: 12px; }
  .stat-ic svg { width: 20px; height: 20px; }
  .stat-num { font-size: 2.1rem; }
}

/* Contatori — senza icone, sfondo sfumato */
.stats .stat {
  grid-template-columns: 1fr; grid-template-areas: "num" "label"; gap: 10px;
  padding: 30px 28px 28px; isolation: isolate;
  background:
    radial-gradient(160px 160px at 100% 0%, color-mix(in srgb, var(--c) 22%, transparent), transparent 70%),
    linear-gradient(160deg, #ffffff 0%, var(--cs) 140%);
  border: 1px solid color-mix(in srgb, var(--c) 18%, transparent);
}
.stats .stat::before {
  content: ""; position: absolute; z-index: -1; right: -38px; top: -38px; width: 120px; height: 120px; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--c) 35%, transparent);
  box-shadow: 0 0 0 18px color-mix(in srgb, var(--c) 6%, transparent), 0 0 0 36px color-mix(in srgb, var(--c) 4%, transparent);
}
.stats .stat::after { height: 3px; left: 28px; right: auto; width: 44px; bottom: 22px; border-radius: 3px; }
.stats .stat { padding-bottom: 42px; }
.stat-num { font-size: 3rem; color: var(--c); }
.stat-num small { color: var(--ink-2); opacity: .7; }
.stat-label { color: var(--text); opacity: .75; }
@media (max-width: 480px) {
  .stats .stat { grid-template-areas: "num" "label"; padding: 20px 16px 34px; }
  .stats .stat::after { left: 16px; bottom: 16px; }
  .stat-num { font-size: 2.3rem; }
}

/* Header senza striscia sfumata */
.topbar::before { display: none; }

/* Google Maps a colori pieni */
.map { filter: none; }

/* ============================================================
   Font — Plus Jakarta Sans per tutto il sito
   ============================================================ */
:root {
  --serif: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
body { font-size: 16.5px; }
h1, h2, h3, h4 { font-weight: 700; letter-spacing: -.025em; }
h1 { font-weight: 800; letter-spacing: -.035em; line-height: 1.05; }
h2 { font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
h3 { font-size: 1.25rem; }
.page-hero h1 { font-weight: 800; }
.hero h1 em.accent { font-style: italic; font-weight: 800; padding-right: .08em; }

/* Elementi che usavano il serif sottile */
.stat-num { font-weight: 800; letter-spacing: -.04em; }
.step::before { font-weight: 800; font-size: 2rem; letter-spacing: -.04em; }
.fact .v { font-weight: 700; font-size: 1.35rem; letter-spacing: -.02em; }
.accordion summary { font-weight: 700; font-size: 1.02rem; }
.course .price b { font-weight: 800; font-size: 1.6rem; letter-spacing: -.03em; }
.price-card .amount { font-weight: 800; letter-spacing: -.04em; }
.price-table td:first-child { font-weight: 700; font-size: 1rem; }
.price-table td.amt { font-weight: 800; font-size: 1.2rem; }
.quote { font-weight: 600; font-style: normal; letter-spacing: -.02em; line-height: 1.3; }
.photo-note { font-weight: 700; font-size: 1rem; }
.contact-list a, .contact-list span { font-weight: 600; font-size: 1.05rem; }
.contact-list--sm a, .contact-list--sm span { font-size: .95rem; }
.teacher .avatar, .avatar--xl, .avatar--sm { font-weight: 700; letter-spacing: -.02em; }
.teacher-hl b, .side-hl b { font-weight: 700; }
.pubs span { font-weight: 600; font-size: .98rem; }
.pubs li::before { font-weight: 800; }
.profile-nav a span { font-weight: 700; font-size: 1.05rem; }
.profile-block h2 { font-weight: 800; }
.stats .stat .stat-num small { font-weight: 700; }
.hero h1 em.accent { padding-right: .08em; margin-right: -.08em; }

/* ============================================================
   Accessibilità
   ============================================================ */
:root {
  /* Varianti scure dei colori, per il testo: contrasto ≥ 4,5:1 */
  --coral-ink: #b5402b; --teal-ink: #0b6f68; --violet-ink: #5639b8; --sky-ink: #1a5fae; --sun-ink: #7f5600;
  --focus: #1a5fae;
}
.grid > .card:nth-child(5n+1), .accordion details:nth-child(5n+1) { --ci: var(--coral-ink); }
.grid > .card:nth-child(5n+2), .accordion details:nth-child(5n+2) { --ci: var(--teal-ink); }
.grid > .card:nth-child(5n+3), .accordion details:nth-child(5n+3) { --ci: var(--violet-ink); }
.grid > .card:nth-child(5n+4), .accordion details:nth-child(5n+4) { --ci: var(--sky-ink); }
.grid > .card:nth-child(5n+5), .accordion details:nth-child(5n+5) { --ci: var(--sun-ink); }
.stats .stat:nth-child(1) { --ci: var(--coral-ink); }
.stats .stat:nth-child(2) { --ci: var(--teal-ink); }
.stats .stat:nth-child(3) { --ci: var(--violet-ink); }
.stats .stat:nth-child(4) { --ci: var(--sky-ink); }

/* Testi colorati: sempre nella variante scura */
.eyebrow { color: var(--coral-ink); }
.card .tag { color: var(--sun-ink); }
.grid > .card .tag, .grid > .card .more, .teacher .role, .course details summary,
.course .price b, .teacher-hl b, .stat-num { color: var(--ci, var(--ink)); }
.grid > .card .icon, .grid > .card .chip svg { color: var(--ci, var(--sun-ink)); }
.card .icon { color: var(--sun-ink); }
.step:nth-child(5n+1)::before { color: var(--coral-ink); }
.step:nth-child(5n+2)::before { color: var(--teal-ink); }
.step:nth-child(5n+3)::before { color: var(--violet-ink); }
.step:nth-child(5n+4)::before { color: var(--sky-ink); }
.step:nth-child(5n+5)::before { color: var(--sun-ink); }
.section--ink .step::before { color: var(--sun) !important; }
.fact:nth-child(6n+1) .k, .fact:nth-child(6n+6) .k { color: var(--coral-ink); }
.fact:nth-child(6n+2) .k { color: var(--teal-ink); }
.fact:nth-child(6n+3) .k { color: var(--violet-ink); }
.fact:nth-child(6n+4) .k { color: var(--sky-ink); }
.fact:nth-child(6n+5) .k { color: var(--sun-ink); }
.accordion .body ol li::marker { color: var(--ci); }
.price-table tbody tr td.amt { color: var(--ink); }
.contact-list li:nth-child(5n+1) .ic { color: var(--coral-ink); }
.contact-list li:nth-child(5n+2) .ic { color: var(--violet-ink); }
.contact-list li:nth-child(5n+3) .ic { color: var(--teal-ink); }
.contact-list li:nth-child(5n+4) .ic { color: var(--sky-ink); }
.contact-list li:nth-child(5n+5) .ic { color: var(--sun-ink); }
.nav a:hover { color: var(--coral-ink); }
.callout svg { color: var(--sky-ink); }
.checks li::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b6f68' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E");
}
.card--ink .checks li::before, .featured .checks li::before, .section--ink .checks li::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235fe0d4' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E");
}

/* Pulsanti con testo bianco: fondo abbastanza scuro (≥ 5:1) */
.btn--gold { background: linear-gradient(135deg, #b5402b, #b04a16); }
.btn--gold:hover { background: linear-gradient(135deg, #9c3523, #973f12); }
.filters button[aria-pressed="true"] { background: linear-gradient(135deg, var(--coral-ink), var(--violet-ink)); }
.hero-badge i { background: linear-gradient(90deg, var(--coral-ink), #b04a16); }

/* Profili docenti: colori testo scuri */
.profile-block h2::after { background: var(--c); }
.timeline--lg b, .side-hl small, .pubs li::before, .profile-nav a:hover span, .mini:hover { color: var(--ci, var(--ink)); }

/* Focus ben visibile su chiaro e su scuro */
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.topbar :focus-visible, .hero :focus-visible, .page-hero :focus-visible, .section--ink :focus-visible,
.footer :focus-visible, .cta :focus-visible, .card--ink:focus-visible, .card--ink :focus-visible, .featured :focus-visible, .lightbox :focus-visible { outline-color: #ffd166; }
.note:focus-visible { outline-offset: 5px; }
main:focus { outline: none; }

/* Link "Vai al contenuto" */
.skip { background: var(--ink); color: #fff; font-weight: 700; border-radius: 10px; }

/* Solo per lettori di schermo */
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Senza JavaScript i contenuti restano visibili */
html:not(.js) .reveal { opacity: 1; transform: none; }

/* Struttura titoli */
.hero-card h2 { color: #fff; font-size: 1.15rem; margin-bottom: 16px; }
.footer .f-title { font: 700 .75rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--sun); margin: 0 0 18px; }
.footer address { font-style: normal; }
.side-title { font-size: .7rem; }
.h3 { font-size: 1.25rem; }
.small-note { margin-top: 24px; font-size: .88rem; color: var(--muted); }
.price-table tbody th { text-align: left; padding: 20px 24px; border-bottom: 1px solid var(--line); font-weight: 700; font-size: 1rem; color: var(--ink); }
.price-table tr:last-child th { border-bottom: 0; }
@media (max-width: 640px) { .price-table tbody th { display: block; padding: 0; border: 0; } }
.faq summary { font-size: 1rem; }
.faq .body p { margin: 0; }
.crumbs a { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(255,255,255,.35); }
.crumbs [aria-current] { color: #fff; }

/* Bersagli più comodi da toccare */
.topbar .tb-links { align-items: center; }
.topbar .tb-links a { padding: 6px 0; }

/* ---------- Pannello Accessibilità ---------- */
.a11y { position: relative; }
.a11y-toggle {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  font: 700 .8rem/1 var(--sans); color: #fff; background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.28); border-radius: 999px; padding: 7px 13px;
}
.a11y-toggle:hover, .a11y-toggle[aria-expanded="true"] { background: #fff; color: var(--ink); }
.a11y-toggle svg { width: 16px; height: 16px; }
.a11y-panel {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 120; width: min(320px, calc(100vw - 32px));
  background: var(--surface); color: var(--text); border-radius: 18px; padding: 18px;
  box-shadow: 0 30px 60px -15px rgba(14,26,54,.45); border: 1px solid var(--line);
}
.a11y-panel[hidden] { display: none; }
.a11y-title { font-weight: 800; font-size: 1rem; color: var(--ink); margin: 0 0 12px; }
.a11y-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.a11y-opts button {
  display: grid; gap: 6px; justify-items: start; text-align: left; cursor: pointer;
  padding: 12px; border-radius: 12px; border: 2px solid var(--line); background: var(--paper);
  font: 600 .84rem/1.25 var(--sans); color: var(--ink);
}
.a11y-opts button b { font-size: 1.1rem; line-height: 1; }
.a11y-opts button:hover { border-color: var(--sky-ink); }
.a11y-opts button[aria-pressed="true"] { border-color: var(--sky-ink); background: #e5effa; }
.a11y-opts button[aria-pressed="true"]::after { content: "Attivo"; font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--sky-ink); }
.a11y-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 14px; font-size: .82rem; }
.a11y-foot a { color: var(--sky-ink); font-weight: 700; }
.a11y-reset { background: none; border: 0; padding: 6px 0; font: 700 .82rem var(--sans); color: var(--muted); cursor: pointer; text-decoration: underline; }
@media (max-width: 720px) { .topbar .wrap { justify-content: flex-end; } .topbar .tb-links a[href^="mailto"] { display: none; } }

/* Modalità: testo grande */
html.a11y-text { font-size: 118.75%; }
html.a11y-text body { font-size: 19.5px; }

/* Modalità: link sottolineati */
html.a11y-links a:not(.btn):not(.brand):not(.card--link) { text-decoration: underline !important; text-decoration-thickness: 2px !important; text-underline-offset: 3px; }
html.a11y-links .card--link h3, html.a11y-links .card--link .more { text-decoration: underline; }

/* Modalità: niente animazioni */
html.a11y-motion { scroll-behavior: auto; }
html.a11y-motion *, html.a11y-motion *::before, html.a11y-motion *::after { animation: none !important; transition: none !important; }
html.a11y-motion .reveal { opacity: 1; transform: none; }
html.a11y-motion .note { transform: none !important; }

/* Modalità: alto contrasto */
html.a11y-contrast {
  --paper: #ffffff; --paper-2: #f0f0f0; --text: #000000; --muted: #1f2430; --line: #4b5263;
  --coral-ink: #8a2a19; --teal-ink: #064d48; --violet-ink: #3d2491; --sky-ink: #0d4381; --sun-ink: #5c3d00;
}
html.a11y-contrast .hero::before, html.a11y-contrast .page-hero::before { opacity: .06; }
html.a11y-contrast .hero::after, html.a11y-contrast .page-hero::after, html.a11y-contrast .section--ink { background: #0a1329; }
html.a11y-contrast .hero .lead, html.a11y-contrast .page-hero .lead, html.a11y-contrast .hero-card li, html.a11y-contrast .section--ink, html.a11y-contrast .footer { color: #fff; }
html.a11y-contrast .card, html.a11y-contrast .stats .stat { background: #fff; border: 2px solid #000; box-shadow: none; }
html.a11y-contrast .card--ink, html.a11y-contrast .price-card.featured, html.a11y-contrast .cta { background: #0a1329; border-color: #0a1329; color: #fff; }
html.a11y-contrast .card--ink p, html.a11y-contrast .price-card.featured p, html.a11y-contrast .price-card.featured li { color: #fff; }
html.a11y-contrast .section--white { background: #fff; }
html.a11y-contrast .hero-card, html.a11y-contrast .hero-badge { background: #0a1329; border-color: #fff; }
html.a11y-contrast a:not(.btn) { text-decoration: underline; }
html.a11y-contrast .btn--line { border: 2px solid #000; }
.lightbox[hidden] { display: none; }

/* ============================================================
   Font ospitato in locale (nessuna richiesta a Google Fonts)
   ============================================================ */
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-display: swap; font-weight: 200 800;
  src: url("../fonts/plus-jakarta-sans-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-display: swap; font-weight: 200 800;
  src: url("../fonts/plus-jakarta-sans-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: italic; font-display: swap; font-weight: 200 800;
  src: url("../fonts/plus-jakarta-sans-latin-wght-italic.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: italic; font-display: swap; font-weight: 200 800;
  src: url("../fonts/plus-jakarta-sans-latin-ext-wght-italic.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ============================================================
   Banner cookie (vanilla-cookieconsent) con i colori del sito
   ============================================================ */
#cc-main {
  --cc-font-family: var(--sans);
  --cc-modal-border-radius: var(--radius);
  --cc-btn-border-radius: 999px;
  --cc-bg: var(--surface);
  --cc-primary-color: var(--ink);
  --cc-secondary-color: var(--muted);
  --cc-btn-primary-bg: var(--ink);
  --cc-btn-primary-color: #fff;
  --cc-btn-primary-border-color: var(--ink);
  --cc-btn-primary-hover-bg: var(--ink-3);
  --cc-btn-primary-hover-color: #fff;
  --cc-btn-primary-hover-border-color: var(--ink-3);
  --cc-btn-secondary-bg: var(--paper);
  --cc-btn-secondary-color: var(--ink);
  --cc-btn-secondary-border-color: var(--line);
  --cc-btn-secondary-hover-bg: var(--paper-2);
  --cc-btn-secondary-hover-color: var(--ink);
  --cc-btn-secondary-hover-border-color: var(--gold);
  --cc-separator-border-color: var(--line);
  --cc-toggle-on-bg: var(--ink);
  --cc-toggle-readonly-bg: var(--line);
  --cc-section-category-border: var(--line);
  --cc-cookie-category-block-bg: var(--paper);
  --cc-cookie-category-block-border: var(--line);
  --cc-cookie-category-block-hover-bg: var(--paper-2);
  --cc-cookie-category-block-hover-border: var(--gold-soft);
  --cc-footer-bg: var(--paper);
  --cc-footer-border-color: var(--line);
  --cc-link-color: var(--ink);
}
#cc-main .cm__title, #cc-main .pm__title { font-weight: 800; }
#cc-main .cm__desc a, #cc-main .pm__section-desc a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
#cc-main :focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* Link "Preferenze cookie" nel footer: è un pulsante con l'aspetto di un link */
.cc-link { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.cc-link:hover { color: var(--gold-2); }

/* Mappa bloccata finché non c'è il consenso */
.map-blocked { display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); padding: 32px; text-align: center; }
.map-consent { max-width: 360px; }
.map-consent .ic { width: 52px; height: 52px; border-radius: 14px; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; margin: 0 auto 14px; }
.map-consent .ic svg { width: 24px; height: 24px; }
.map-consent p { color: var(--muted); font-size: .95rem; }
.map-consent .btn { margin: 6px 0 14px; }
.map-consent a:not(.btn) { display: block; font-size: .9rem; color: var(--ink); }

/* Pagine Privacy e Cookie */
.legal { max-width: 820px; }
.legal h2 { font-size: 1.45rem; margin-top: 1.8em; }
.legal h2:first-child { margin-top: 0; }
.legal h3 { font-size: 1.05rem; margin: 1.2em 0 .3em; }
.legal ul.checks li { color: var(--muted); }
.table-scroll { overflow-x: auto; margin: 1em 0 1.4em; }
.legal-table { width: 100%; border-collapse: collapse; font-size: .93rem; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.legal-table th, .legal-table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal-table th { color: var(--ink); font-weight: 700; background: var(--paper); }
.legal-table tr:last-child td { border-bottom: 0; }
