/* ============================================================
   Website UI kit — layout-only styles (not shipped to consumers).
   All color/type/spacing comes from the design system tokens.
   ============================================================ */
.site { background: var(--surface-page); overflow-x: hidden; }
.wrap { width: min(var(--container), 100% - 2 * var(--gutter)); margin-inline: auto; }
.wrap--narrow { width: min(var(--container-narrow), 100% - 2 * var(--gutter)); margin-inline: auto; }
.section { padding-block: var(--section-y); }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); padding: 18px 0; }
.nav__links { display: flex; gap: var(--space-5); align-items: center; }
.nav__link { font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--ink-200); text-decoration: none; transition: color var(--dur-base) var(--ease-out); }
.nav__link:hover { color: var(--text-on-ink); }
.nav__right { display: flex; align-items: center; gap: var(--space-4); }
.lang { display: inline-flex; gap: 2px; font-family: var(--font-mono); font-size: 12px; align-items: center; }
.lang button { background: none; border: none; cursor: pointer; color: var(--ink-300); padding: 4px 6px; border-radius: 6px; font: inherit; transition: color var(--dur-base) var(--ease-out); }
.lang button[aria-pressed="true"] { color: var(--ink-950); background: var(--volt-500); }
.lang span { color: var(--ink-500); }
@media (max-width: 880px) { .nav__links { display: none; } }

/* ---------- Soglia / hero ---------- */
.soglia { position: relative; min-height: 100svh; display: flex; flex-direction: column; background: var(--grad-horizon); color: var(--text-on-ink); isolation: isolate; }
.soglia::before { content: ""; position: absolute; inset: 0; background: var(--grad-dawn); z-index: -1; }
.soglia__line { position: absolute; left: 0; right: -60px; top: 64%; height: 1.5px; background: linear-gradient(90deg, transparent, var(--ink-400) 30%, var(--volt-500)); z-index: -1; }
.soglia__node { position: absolute; right: -5px; top: calc(64% - 5px); width: 11px; height: 11px; border-radius: 50%; background: var(--volt-500); box-shadow: 0 0 0 6px rgba(200,255,61,.16); z-index: -1; }
.soglia__body { flex: 1; display: flex; flex-direction: column; justify-content: center; padding-block: var(--space-8); }
.quote { font-family: var(--font-display); font-weight: 500; font-size: clamp(2rem, 1rem + 4.4vw, 4.4rem); line-height: 1.12; letter-spacing: -0.02em; max-width: 17ch; margin: 0; color: var(--text-on-ink); text-wrap: balance; }
.quote .q { color: var(--volt-500); }
.quote__by { font-family: var(--font-mono); font-size: var(--fs-sm); letter-spacing: 0.04em; color: var(--ink-300); margin-top: var(--space-5); display: block; }
.opener { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.3rem, 0.9rem + 1.6vw, 2rem); letter-spacing: -0.01em; color: var(--text-on-ink); max-width: 22ch; margin: 0; }
.soglia__foot { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--space-6); padding-bottom: var(--space-7); flex-wrap: wrap; }
.scrollcue { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-300); display: inline-flex; align-items: center; gap: 8px; }
.scrollcue i { animation: nudge 2.2s var(--ease-in-out) infinite; }
@keyframes nudge { 0%,100% { transform: translateY(0); } 50% { transform: translateY(4px); } }

/* ---------- generic dark / light section ---------- */
.sec-ink { background: var(--ink-900); color: var(--text-on-ink); }
.sec-sand { background: var(--paper-100); }
.eyebrow-row { margin-bottom: var(--space-6); }
.h-lead { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-h2); line-height: var(--lh-display); letter-spacing: var(--ls-display); margin: 0 0 var(--space-5); max-width: 18ch; }
.sec-ink .h-lead { color: var(--text-on-ink); }
.lead-p { font-size: var(--fs-lead); line-height: var(--lh-snug); color: var(--text-body); max-width: 40ch; }
.sec-ink .lead-p { color: var(--ink-200); }

/* ---------- Apertura ---------- */
.apertura__grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--space-9); align-items: center; }
.apertura__body p { font-size: var(--fs-lead); line-height: 1.5; color: var(--text-body); max-width: 46ch; }
.apertura__body p + p { margin-top: var(--space-5); }
.portrait { width: 100%; aspect-ratio: 4/5; border-radius: var(--radius-xl); }
.portrait--wide { aspect-ratio: 16/11; }
@media (max-width: 820px) { .apertura__grid { grid-template-columns: 1fr; } .portrait { aspect-ratio: 16/11; } }

/* ---------- Percorso (timeline on ink) ---------- */
.percorso__steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5); margin-top: var(--space-8); position: relative; }
.percorso__line { position: absolute; top: 7px; left: 8px; right: 8px; height: 1.5px; background: linear-gradient(90deg, var(--ink-500), var(--volt-500)); opacity: .5; }
.step { position: relative; padding-top: var(--space-6); }
.step__dot { position: absolute; top: 1px; left: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--ink-700); border: 2px solid var(--ink-500); }
.step:last-child .step__dot { background: var(--volt-500); border-color: var(--volt-500); box-shadow: 0 0 0 5px rgba(200,255,61,.16); }
.step__k { font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-300); }
.step__t { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-h4); color: var(--text-on-ink); margin: 8px 0 8px; }
.step__d { font-size: var(--fs-sm); line-height: 1.5; color: var(--ink-200); }
.step__d b { color: var(--volt-500); font-weight: 600; }
@media (max-width: 820px) { .percorso__steps { grid-template-columns: 1fr 1fr; } .percorso__line { display: none; } }
@media (max-width: 520px) { .percorso__steps { grid-template-columns: 1fr; } }

/* ---------- Cosa faccio (3 pillars) ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); margin-top: var(--space-7); }
.pillar h3 { font-size: var(--fs-h3); margin: var(--space-4) 0 var(--space-3); }
.pillar p { font-size: var(--fs-body); color: var(--text-muted); margin: 0 0 var(--space-5); }
.pillar__ic { width: 46px; height: 46px; border-radius: 12px; background: var(--ink-900); color: var(--volt-500); display: flex; align-items: center; justify-content: center; }
.pillar__ic i { width: 22px; height: 22px; }
@media (max-width: 820px) { .pillars { grid-template-columns: 1fr; } }

/* ---------- Progetti ---------- */
.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-5); margin-top: var(--space-7); }
.project { display: flex; flex-direction: column; gap: var(--space-3); }
.project__top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-3); }
.project__yr { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-300); }
.project h3 { font-size: var(--fs-h4); color: var(--text-on-ink); margin: 0; }
.project p { font-size: var(--fs-sm); line-height: 1.55; color: var(--ink-200); margin: 0; }
.project__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: var(--space-3); }
@media (max-width: 760px) { .projects { grid-template-columns: 1fr; } }

/* ---------- Canali / podcast ---------- */
.canali__grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: var(--space-7); align-items: start; margin-top: var(--space-7); }
.stats-row { display: flex; gap: var(--space-8); margin: var(--space-6) 0; flex-wrap: wrap; }
.podcast { background: var(--ink-800); border: 1px solid var(--ink-600); border-radius: var(--radius-lg); padding: var(--space-5); display: flex; gap: var(--space-4); align-items: center; }
.podcast__art { width: 84px; height: 84px; border-radius: 12px; background: linear-gradient(145deg, var(--ink-600), var(--ink-900)); display: flex; align-items: center; justify-content: center; flex: none; position: relative; overflow: hidden; }
.podcast__art::after { content:""; position:absolute; inset:0; background: var(--grad-dawn); }
.podcast__meta { flex: 1; min-width: 0; }
.podcast__k { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--volt-500); }
.podcast__t { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-h4); color: var(--text-on-ink); margin: 4px 0 2px; }
.podcast__sub { font-size: var(--fs-sm); color: var(--ink-300); }
.playbtn { width: 46px; height: 46px; border-radius: 50%; border: none; cursor: pointer; background: var(--volt-500); color: var(--ink-950); display: flex; align-items: center; justify-content: center; flex: none; transition: transform var(--dur-fast) var(--ease-out); }
.playbtn:hover { transform: scale(1.06); }
.channels { display: flex; flex-direction: column; gap: var(--space-3); }
.channel { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3) 0; border-bottom: 1px solid var(--ink-700); text-decoration: none; color: var(--text-on-ink); transition: padding-left var(--dur-base) var(--ease-out); }
.channel:hover { padding-left: 6px; }
.channel i { width: 18px; height: 18px; color: var(--ink-300); }
.channel__name { font-weight: var(--fw-semibold); font-size: var(--fs-body); flex: 1; }
.channel__h { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-300); }
@media (max-width: 880px) { .canali__grid { grid-template-columns: 1fr; } }

/* ---------- Contatto ---------- */
.contatto { text-align: center; }
.contatto h2 { font-size: var(--fs-h1); margin: 0 auto var(--space-4); max-width: 16ch; }
.contatto p { font-size: var(--fs-lead); color: var(--text-muted); max-width: 44ch; margin: 0 auto var(--space-6); }

/* ---------- Footer ---------- */
.footer { background: var(--ink-950); color: var(--ink-200); padding-block: var(--space-8) var(--space-6); }
.footer__top { display: flex; justify-content: space-between; gap: var(--space-7); flex-wrap: wrap; padding-bottom: var(--space-7); border-bottom: 1px solid var(--ink-700); }
.footer__col h4 { font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-400); margin: 0 0 var(--space-4); font-weight: 400; }
.footer__col a { display: block; color: var(--ink-200); text-decoration: none; font-size: var(--fs-sm); padding: 5px 0; transition: color var(--dur-base) var(--ease-out); }
.footer__col a:hover { color: var(--volt-500); }
.footer__bottom { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); padding-top: var(--space-5); flex-wrap: wrap; }
.footer__bottom small { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }

/* ============================================================
   Canonical-copy layout (v2): Apertura headline, Percorso road,
   sober Progetti list, Racconto, quiet Contatto.
   ============================================================ */
.sec-sand { background: var(--paper-100); }

/* Apertura — long first-person headline */
.apertura__h { max-width: 16ch; }
.apertura__body p { font-size: var(--fs-lead); line-height: 1.5; color: var(--text-body); max-width: 46ch; margin-top: var(--space-5); }

/* Percorso — the vertical "road": four beats, connector turns Volt into Oggi */
.road { margin-top: var(--space-7); }
.beat { position: relative; padding-left: 48px; padding-bottom: var(--space-8); }
.beat:last-child { padding-bottom: 0; }
.beat__node { position: absolute; left: 6px; top: 8px; width: 16px; height: 16px; border-radius: 50%; background: var(--ink-700); border: 2px solid var(--ink-500); z-index: 1; }
.beat::before { content: ""; position: absolute; left: 13px; top: 18px; bottom: -8px; width: 2px; background: var(--ink-600); }
.beat:last-child::before { display: none; }
.beat:nth-last-child(2)::before { background: linear-gradient(180deg, var(--ink-600), var(--volt-500)); }
.beat:last-child .beat__node { background: var(--volt-500); border-color: var(--volt-500); box-shadow: 0 0 0 6px rgba(200,255,61,.14); }
.beat__h { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-h3); color: var(--text-on-ink); letter-spacing: var(--ls-snug); margin: 0 0 12px; }
.beat__body { font-size: var(--fs-body-lg); line-height: 1.6; color: var(--ink-200); margin: 0; max-width: 54ch; }
.beat__body b { color: var(--volt-500); font-weight: 600; }
.road__more { margin-top: var(--space-7); padding-left: 48px; }

/* Progetti — sober list */
.projlead { font-size: var(--fs-lead); line-height: var(--lh-snug); color: var(--text-body); max-width: 40ch; margin: 0 0 var(--space-7); }
.projlist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--border); }
.projitem { border-bottom: 1px solid var(--border); }
.projitem__link { display: flex; align-items: baseline; gap: var(--space-4); padding: var(--space-5) 0; text-decoration: none; color: var(--text-strong); transition: padding-left var(--dur-base) var(--ease-out); }
.projitem__link:hover { padding-left: 10px; }
.projitem__name { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.5rem, 1rem + 1.8vw, 2.4rem); letter-spacing: var(--ls-display); flex: none; }
.projitem__meta { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--text-faint); flex: 1; }
.projitem__link i { width: 20px; height: 20px; color: var(--text-faint); transition: transform var(--dur-base) var(--ease-out), color var(--dur-base) var(--ease-out); }
.projitem__link:hover i { transform: translate(3px, -3px); color: var(--volt-700); }
.projlist__more { margin-top: var(--space-6); }

/* Racconto */
.racconto__lead { max-width: 34ch; margin-bottom: var(--space-4); }
.proofline { font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: 0.04em; color: var(--ink-300); margin: 0 0 var(--space-6); }
.podcast__link { margin-top: var(--space-5); }
.channels__title { display: block; margin-bottom: var(--space-2); }

/* Contatto — quiet */
.contatto__sub { display: block; margin-top: var(--space-5); font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: 0.04em; color: var(--text-faint); }

/* Keep hub out-links + their arrow on one line */
.mm-outlink { white-space: nowrap; }

/* ============================================================
   Production additions (static site)
   ============================================================ */
/* Portrait placeholder — warm slot until a real photo of Mario is added.
   Replace with: <img class="portrait" src="assets/mario.jpg" alt="..."> */
.portrait-slot {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-xl);
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(200,255,61,0.10), transparent 60%),
    linear-gradient(160deg, var(--paper-200), var(--paper-100));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  display: flex; align-items: flex-end;
  overflow: hidden;
}
.portrait-slot::before {
  content: "⚡";
  position: absolute; top: 18px; left: 20px;
  font-size: 22px; color: var(--volt-700); opacity: .8;
}
.portrait-slot::after {
  content: attr(aria-label);
  display: block; width: 100%;
  padding: 16px 18px;
  font-family: var(--font-mono); font-size: var(--fs-xs);
  letter-spacing: .02em; color: var(--warm-500);
  background: linear-gradient(0deg, rgba(245,241,232,.9), transparent);
}
@media (max-width: 820px) { .portrait-slot { aspect-ratio: 16 / 11; } }
img.portrait { object-fit: cover; display: block; }

/* Podcast inline embed container */
.podcast__embed:not([hidden]) { display: block; }
