/* =========================================================================
   Mentetecnica - mt-blog.css  (redesign blog chiaro, 2026-10-10)
   Caricato SOLO su indice, categorie, tag, autore e articolo (body.mt-blog),
   dopo mt-v2.css. Riporta i token al contesto CHIARO (carta) su tutto il
   <main>: i componenti condivisi si adattano da soli. Header (pillola) e
   footer restano scuri: il contrasto incornicia la lettura.
   Indice:
     1. Token e base       5. Articolo: testata e layout
     2. Breadcrumb         6. Tipografia del corpo (.mt-prose)
     3. Testata archivio   7. Indice e condivisione
     4. Card e griglia     8. Autore, correlati, paginazione, responsive
   @author Gennaro Canfora
   ========================================================================= */

/* ---------- 1. Token e base ---------- */
body.mt-blog{
  --b-paper:#f7f7f3;          /* sfondo pagina */
  --b-card:#ffffff;
  --b-ink:#0b0e1f;            /* titoli */
  --b-text:#2c3145;           /* testo corrente: contrasto AAA su carta */
  --b-muted:#6b7086;
  --b-line:#e4e4dd;
  --b-line-2:#d4d5cc;
  --b-accent:#3a50e0;         /* blu leggibile su chiaro (AA 5.6:1) */
  --b-accent-soft:rgba(75,99,255,.08);
  --b-radius:18px;
  --b-shadow:0 1px 2px rgba(11,14,31,.04),0 12px 32px -20px rgba(11,14,31,.22);
  --b-shadow-lg:0 2px 4px rgba(11,14,31,.05),0 28px 60px -30px rgba(11,14,31,.35);
  background:var(--b-paper);
}
html:has(body.mt-blog){background:var(--b-paper)}
/* Menu agganciato e barra di lettura: ora globali, vedi mt-v2.css sez. 5b (2026-10-13). */
/* token del sito riportati al chiaro dentro il main */
body.mt-blog #mt-main{
  --mt-ink:var(--b-ink); --mt-body:var(--b-text); --mt-muted:var(--b-muted);
  --mt-line:var(--b-line); --mt-line-2:var(--b-line-2);
  --mt-bg:var(--b-paper); --mt-bg-soft:#efefe9;
  --mt-surface:var(--b-card); --mt-surface-2:#fbfbf8;
  --mt-accent:var(--b-accent);
  --mt-shadow:var(--b-shadow); --mt-shadow-lg:var(--b-shadow-lg);
  color:var(--b-text);
}
/* il primo blocco gestisce da se' lo spazio sotto la pillola: annulla la
   regola di mt-v2 (#mt-main > :first-child:not(...)), classe doppia per
   vincere la specificita' senza !important. Nell'articolo .mt-progress viene
   spostata nel menu da mt-blog.js, quindi .mt-post diventa il primo figlio. */
body.mt-blog #mt-main > .mt-bhead.mt-bhead:first-child,
body.mt-blog #mt-main > .mt-post.mt-post:first-child{margin-top:0}

/* ---------- 2. Breadcrumb (chiaro, compatto, dentro la testata) ---------- */
.mt-blog .mt-crumb{background:none;border:0;font:500 .78rem var(--v-mono);margin-bottom:clamp(1.25rem,3vw,2rem)}
.mt-blog .mt-crumb .mt-wrap{width:auto;margin:0}
.mt-blog .mt-crumb ol{padding:0;gap:.35rem}
.mt-blog .mt-crumb li{color:var(--b-muted)}
.mt-blog .mt-crumb li+li::before{content:"/";color:var(--b-line-2)}
.mt-blog .mt-crumb a{color:var(--b-muted)}
.mt-blog .mt-crumb a:hover{color:var(--b-accent);text-decoration:none}
.mt-blog .mt-crumb [aria-current]{color:var(--b-ink);max-width:40ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* ---------- 3. Testata archivio ---------- */
.mt-bhead{padding:calc(var(--v-pill-h) + 12px + clamp(2rem,5vw,3.5rem)) 0 clamp(1.5rem,3vw,2.25rem);border-bottom:1px solid var(--b-line);
  background:radial-gradient(40rem 18rem at 0% 0%,rgba(75,99,255,.07),transparent 70%),radial-gradient(30rem 16rem at 100% 0%,rgba(255,226,31,.10),transparent 70%)}
.mt-bhead__eyebrow{display:inline-flex;align-items:center;gap:.55rem;font:600 .74rem var(--v-mono);letter-spacing:.08em;text-transform:uppercase;color:var(--b-accent);margin-bottom:1rem}
.mt-bhead__eyebrow::before{content:"";width:18px;height:2px;background:var(--v-yellow);border-radius:2px}
.mt-bhead h1{font-family:var(--v-display);font-weight:700;color:var(--b-ink);font-size:clamp(2rem,1.4rem + 2.6vw,3.4rem);line-height:1.06;letter-spacing:-.025em;max-width:20ch;margin:0 0 .9rem}
.mt-bhead h1 .mt-s{font-family:var(--v-serif);font-style:italic;font-weight:400;color:var(--b-accent)}
.mt-bhead__lead{font-size:clamp(1rem,.95rem + .3vw,1.15rem);color:var(--b-muted);max-width:58ch;line-height:1.6;margin:0}
/* chip categorie */
.mt-chips{display:flex;flex-wrap:wrap;gap:.5rem;margin-top:clamp(1.5rem,3vw,2rem)}
.mt-chips a{display:inline-flex;align-items:center;gap:.45rem;padding:.5rem .95rem;border-radius:999px;border:1px solid var(--b-line-2);background:var(--b-card);
  color:var(--b-text);font-size:.9rem;font-weight:550;text-decoration:none;transition:border-color .2s,background .2s,color .2s}
.mt-chips a small{font:500 .7rem var(--v-mono);color:var(--b-muted)}
.mt-chips a:hover{border-color:var(--b-ink);color:var(--b-ink)}
.mt-chips a.is-active{background:var(--b-ink);border-color:var(--b-ink);color:#fff}
.mt-chips a.is-active small{color:rgba(255,255,255,.6)}
@media (max-width:640px){
  .mt-chips{flex-wrap:nowrap;overflow-x:auto;margin-inline:-1.25rem;padding:0 1.25rem .25rem;scrollbar-width:none;-webkit-overflow-scrolling:touch}
  .mt-chips::-webkit-scrollbar{display:none}
  .mt-chips a{flex:none}
}

/* ---------- 4. Card e griglia ---------- */
.mt-bsec{padding-block:clamp(2.25rem,5vw,3.5rem) clamp(3rem,6vw,4.5rem)}
.mt-bsec-title{font-family:var(--v-display);font-size:1.05rem;font-weight:650;color:var(--b-ink);letter-spacing:-.01em;
  margin:clamp(2.5rem,5vw,3.5rem) 0 1.25rem;padding-bottom:.85rem;border-bottom:1px solid var(--b-line)}
.mt-bsec-title--big{font-size:clamp(1.5rem,1.2rem + 1.2vw,2rem);border:0;padding:0;margin:0 0 1.5rem}
/* auto-FILL: con pochi articoli le card mantengono la loro larghezza */
.mt-bgrid{display:grid;gap:clamp(1rem,2vw,1.5rem);grid-template-columns:repeat(auto-fill,minmax(min(100%,18.5rem),1fr))}
.mt-bcard{position:relative;display:flex;flex-direction:column;background:var(--b-card);border:1px solid var(--b-line);border-radius:var(--b-radius);
  overflow:hidden;transition:transform .25s var(--v-ease),box-shadow .25s var(--v-ease),border-color .25s}
.mt-bcard:hover{transform:translateY(-3px);box-shadow:var(--b-shadow-lg);border-color:transparent}
.mt-bcard__media{display:block;aspect-ratio:16/10;background:#ecece6;overflow:hidden}
.mt-bcard__media img{width:100%;height:100%;object-fit:cover;display:block;transition:transform .6s var(--v-ease)}
.mt-bcard:hover .mt-bcard__media img{transform:scale(1.035)}
.mt-bcard__ph{width:100%;height:100%;display:grid;place-items:center;color:#c9cbd6;background:linear-gradient(135deg,#eef0ff,#f7f7f3)}
.mt-bcard__ph svg{width:2.2rem;height:2.2rem}
.mt-bcard__body{display:flex;flex-direction:column;flex:1;padding:1.2rem 1.3rem 1.35rem}
.mt-bcard__top{display:flex;flex-wrap:wrap;align-items:center;gap:.4rem .7rem;margin-bottom:.7rem}
.mt-bcard__cat{position:relative;z-index:2;font:600 .68rem var(--v-mono);letter-spacing:.06em;text-transform:uppercase;color:var(--b-accent);
  background:var(--b-accent-soft);padding:.28rem .55rem;border-radius:6px;text-decoration:none}
.mt-bcard__cat:hover{background:var(--b-accent);color:#fff}
.mt-bcard__meta{font:500 .74rem var(--v-mono);color:var(--b-muted)}
.mt-bcard__title{font-family:var(--v-display);font-size:1.12rem;line-height:1.3;font-weight:650;letter-spacing:-.01em;margin:0 0 .55rem;color:var(--b-ink);
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.mt-bcard__title a{color:inherit;text-decoration:none}
/* tutta la card cliccabile senza annidare link (accessibile) */
.mt-bcard__title a::after{content:"";position:absolute;inset:0;z-index:1}
.mt-bcard__excerpt{font-size:.93rem;line-height:1.6;color:var(--b-muted);margin:0 0 1rem;flex:1;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.mt-bcard__more{display:inline-flex;align-items:center;gap:.4rem;font-size:.86rem;font-weight:650;color:var(--b-ink)}
.mt-bcard__more svg{width:.95rem;height:.95rem;transition:transform .25s var(--v-ease)}
.mt-bcard:hover .mt-bcard__more{color:var(--b-accent)}
.mt-bcard:hover .mt-bcard__more svg{transform:translateX(3px)}
.mt-bcard__title a:focus-visible{outline:none}
.mt-bcard:has(.mt-bcard__title a:focus-visible){outline:2px solid var(--b-accent);outline-offset:3px}
/* in evidenza: orizzontale su desktop */
@media (min-width:860px){
  .mt-bcard--featured{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr)}
  .mt-bcard--featured .mt-bcard__media{aspect-ratio:auto;min-height:100%}
  .mt-bcard--featured .mt-bcard__body{padding:clamp(1.75rem,3vw,2.75rem);justify-content:center}
}
.mt-bcard--featured .mt-bcard__title{font-size:clamp(1.4rem,1.1rem + 1.2vw,2.05rem);line-height:1.15;letter-spacing:-.02em;-webkit-line-clamp:4}
.mt-bcard--featured .mt-bcard__excerpt{font-size:1rem;-webkit-line-clamp:4;flex:none;margin-bottom:1.5rem}
.mt-blog-empty{color:var(--b-muted);padding:3rem 0;font-size:1.02rem}

/* ---------- 5. Articolo: testata e layout ---------- */
.mt-post__head{padding:calc(var(--v-pill-h) + 12px + clamp(2rem,5vw,3.5rem)) 0 clamp(1.75rem,3.5vw,2.5rem)}
.mt-post__cat{display:inline-block;font:600 .72rem var(--v-mono);letter-spacing:.08em;text-transform:uppercase;color:var(--b-accent);
  background:var(--b-accent-soft);padding:.35rem .65rem;border-radius:6px;text-decoration:none;margin-bottom:1.1rem}
.mt-post__cat:hover{background:var(--b-accent);color:#fff}
.mt-post__title{font-family:var(--v-display);font-weight:700;color:var(--b-ink);font-size:clamp(1.9rem,1.3rem + 2.4vw,3.1rem);
  line-height:1.08;letter-spacing:-.028em;max-width:28ch;margin:0 0 1.1rem;text-wrap:balance}
.mt-post__dek{font-size:clamp(1.05rem,1rem + .35vw,1.25rem);line-height:1.55;color:var(--b-muted);max-width:none;margin:0 0 1.6rem;text-wrap:pretty}
.mt-post__byline{display:flex;align-items:center;gap:.8rem;padding-top:1.25rem;border-top:1px solid var(--b-line)}
.mt-post__avatar{border-radius:50%;flex:none;width:44px;height:44px}
.mt-post__author{display:block;font-weight:650;color:var(--b-ink);text-decoration:none;font-size:.95rem}
.mt-post__author:hover{color:var(--b-accent)}
.mt-post__meta{font:500 .76rem var(--v-mono);color:var(--b-muted)}
.mt-post__hero{margin:0 0 clamp(2rem,4vw,3rem)}
.mt-post__hero img{width:100%;height:auto;max-height:560px;object-fit:cover;border-radius:var(--b-radius);display:block;box-shadow:var(--b-shadow)}
/* colonna unica; con indice (has-toc) sidebar destra da 1100px in su */
.mt-post__grid{padding-bottom:clamp(3rem,6vw,4.5rem)}
.mt-post__main{min-width:0}

/* ---------- 5b. Indice sticky (2026-11-17) ----------
   Un solo pannello .mt-tocs: sidebar fissa su desktop, bottom-sheet sotto
   1100px aperto dalla barra .mt-tocbar. Solo transform/opacity animati
   (compositor), nessun layout shift: la barra e' fixed, fuori dal flusso. */
.mt-tocs{position:relative;background:var(--b-card);border:1px solid var(--b-line);border-radius:18px;box-shadow:var(--b-shadow-lg);
  display:flex;flex-direction:column;overflow:hidden}
.mt-tocs::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--v-yellow);z-index:1}
.mt-tocs__grab{display:none}
.mt-tocs__head{display:flex;align-items:center;gap:.75rem;padding:1rem 1.1rem .9rem 1.25rem;border-bottom:1px solid var(--b-line)}
.mt-tocs__icon{flex:none;width:2.25rem;height:2.25rem;display:grid;place-items:center;border-radius:10px;background:var(--v-ink-2);color:var(--v-yellow)}
.mt-tocs__icon svg{width:1.1rem;height:1.1rem}
.mt-tocs__title{flex:1;min-width:0;display:flex;flex-direction:column;gap:.1rem}
.mt-tocs__title strong{font-family:var(--v-display);font-size:1rem;font-weight:650;color:var(--b-ink)}
.mt-tocs__title small{font:500 .7rem var(--v-mono);color:var(--b-muted)}
.mt-tocs__x{display:none;flex:none;width:2.2rem;height:2.2rem;border-radius:50%;border:1px solid var(--b-line-2);background:#fff;color:var(--b-ink);place-items:center;cursor:pointer}
.mt-tocs__x svg{width:1rem;height:1rem}
/* anello di lettura */
.mt-ringwrap{position:relative;flex:none;width:2.4rem;height:2.4rem;display:grid;place-items:center}
.mt-ring{position:absolute;inset:0;width:100%;height:100%;transform:rotate(-90deg)}
.mt-ring circle{fill:none;stroke-width:4}
.mt-ring__bg{stroke:#ecede6}
.mt-ring__fg{stroke:var(--v-yellow);stroke-linecap:round;transition:stroke-dashoffset .15s linear}
.mt-ring__pc{position:relative;font:700 .62rem var(--v-mono);color:var(--b-ink)}
/* lista: riusa il markup di mt_toc_list(), colonna singola */
.mt-tocs__body{overflow-y:auto;overscroll-behavior:contain;padding:.6rem .7rem .8rem .85rem;scrollbar-width:thin;scrollbar-color:var(--b-line-2) transparent}
.mt-tocs .mt-toc__list{columns:auto}
.mt-tocs .mt-toc__item{grid-template-columns:1.9rem 1fr;padding:0;border-radius:10px;transition:background .25s}
.mt-tocs .mt-toc__n{padding:.55rem 0 0 .45rem;transition:color .25s}
.mt-tocs .mt-toc__list a{display:block;padding:.45rem .5rem .45rem 0;font-size:.9rem;line-height:1.38;color:var(--b-ink);background:none;transition:color .25s}
.mt-tocs .mt-toc__list a:hover{color:var(--b-accent)}
.mt-tocs .mt-toc__list a:focus-visible{outline:2px solid var(--b-accent);outline-offset:1px;border-radius:6px}
.mt-tocs .mt-toc__sub{margin:-.1rem 0 .4rem;padding-left:.75rem}
.mt-tocs .mt-toc__sub li{padding:0}
.mt-tocs .mt-toc__sub a{font-size:.82rem;font-weight:450;color:var(--b-muted);padding:.28rem .4rem .28rem 0}
/* stati impostati da mt-blog.js */
.mt-tocs .is-done > a,.mt-tocs .mt-toc__item.is-done > .mt-toc__n{color:#9ea3b8}
.mt-tocs .mt-toc__item.is-current{background:linear-gradient(90deg,rgba(255,226,31,.22),rgba(255,226,31,.03));box-shadow:inset 3px 0 0 var(--v-yellow)}
.mt-tocs .mt-toc__item.is-current > .mt-toc__n{color:#8a6d00}
.mt-tocs .mt-toc__item.is-current > a{color:var(--b-ink);font-weight:650}
.mt-tocs .mt-toc__sub li.is-active{border-left:2px solid var(--v-yellow);margin-left:-.8rem;padding-left:.7rem}
.mt-tocs .mt-toc__sub li.is-active > a{color:var(--b-ink);font-weight:600}
.mt-tocs__foot{display:flex;justify-content:space-between;align-items:center;border-top:1px solid var(--b-line);padding:.7rem 1.1rem .75rem 1.25rem;font:500 .72rem var(--v-mono);color:var(--b-muted)}
.mt-tocs__top{color:var(--b-accent);font-weight:600;text-decoration:none}
.mt-tocs__top:hover{text-decoration:underline}
.mt-post__sideshare{margin-top:1rem}

/* DESKTOP: sidebar fissa allo scroll */
@media (min-width:1100px){
  .mt-post__grid.has-toc{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:clamp(2.5rem,4vw,3.5rem);align-items:start}
  .mt-post__side{align-self:stretch} /* alta quanto l'articolo: lo sticky segue tutta la lettura */
  .mt-post__stick{position:sticky;top:calc(var(--v-pill-h) + 28px)}
  body.admin-bar .mt-post__stick{top:calc(var(--v-pill-h) + 60px)}
  .mt-tocs{max-height:calc(100vh - var(--v-pill-h) - 120px)} /* mai oltre lo schermo: scroll interno */
  .mt-tocbar,.mt-tocs__backdrop{display:none!important}
}

/* MOBILE / TABLET: barra compatta fissa + bottom-sheet */
@media (max-width:1099.98px){
  .mt-post__sideshare{display:none} /* resta la riga di condivisione in fondo */
  .mt-tocbar{position:fixed;z-index:50;left:max(.75rem,env(safe-area-inset-left));right:max(.75rem,env(safe-area-inset-right));
    top:calc(var(--v-pill-h) + 10px);display:flex;align-items:center;gap:.65rem;padding:.5rem .55rem .5rem .6rem;
    background:rgba(255,255,255,.9);-webkit-backdrop-filter:blur(14px) saturate(1.4);backdrop-filter:blur(14px) saturate(1.4);
    border:1px solid var(--b-line);border-radius:14px;box-shadow:0 12px 28px -16px rgba(11,14,31,.4);
    font:inherit;text-align:left;color:var(--b-ink);cursor:pointer;
    opacity:0;transform:translateY(-10px);pointer-events:none;transition:opacity .25s var(--v-ease),transform .25s var(--v-ease)}
  .mt-tocbar[hidden]{display:none}
  .mt-tocbar.is-on{opacity:1;transform:none;pointer-events:auto}
  body:not(.mt-docked) .mt-tocbar{top:calc(var(--v-pill-h) + 22px)}
  body.admin-bar .mt-tocbar{top:calc(var(--v-pill-h) + 56px)}
  .mt-tocbar:focus-visible{outline:2px solid var(--b-accent);outline-offset:2px}
  .mt-tocbar .mt-tocs__icon{width:1.9rem;height:1.9rem;border-radius:8px}
  .mt-tocbar .mt-tocs__icon svg{width:.95rem;height:.95rem}
  .mt-tocbar__txt{flex:1;min-width:0;display:flex;flex-direction:column}
  .mt-tocbar__txt small{font:500 .64rem var(--v-mono);color:var(--b-muted);text-transform:uppercase;letter-spacing:.04em}
  .mt-tocbar__txt strong{font-size:.86rem;font-weight:650;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .mt-tocbar .mt-ringwrap{width:2.1rem;height:2.1rem}

  .mt-tocs__backdrop{position:fixed;inset:0;z-index:70;background:rgba(8,10,25,.5);opacity:0;transition:opacity .3s;touch-action:none}
  .mt-tocs__backdrop.is-on{opacity:1}
  .mt-tocs{position:fixed;z-index:71;left:0;right:0;bottom:0;max-height:min(80vh,640px);max-height:min(80dvh,640px);
    border-radius:22px 22px 0 0;border-bottom:0;padding-bottom:env(safe-area-inset-bottom);
    transform:translateY(105%);visibility:hidden;transition:transform .35s var(--v-ease),visibility 0s .35s}
  .mt-tocs::before{display:none}
  .mt-tocs.is-open{transform:none;visibility:visible;transition:transform .35s var(--v-ease)}
  .mt-tocs__grab{display:block;width:42px;height:5px;border-radius:3px;background:var(--b-line-2);margin:.55rem auto .1rem}
  .mt-tocs__head{border-bottom:0;padding:.5rem 1rem .6rem 1.25rem}
  .mt-tocs__head .mt-ringwrap{display:none}
  .mt-tocs__x{display:grid}
  .mt-tocs .mt-toc__list a{padding:.7rem .5rem .7rem 0;font-size:.98rem} /* target touch >= 44px */
  .mt-tocs .mt-toc__n{padding-top:.85rem}
  .mt-tocs .mt-toc__sub a{padding:.5rem .4rem .5rem 0;font-size:.9rem}
  .mt-tocs__foot{display:none}
  html.mt-toc-lock{overflow:hidden}
}
@media (prefers-reduced-motion:reduce){.mt-tocbar,.mt-tocs,.mt-tocs__backdrop,.mt-ring__fg,.mt-tocs .mt-toc__item{transition:none!important}}

/* ---------- 6. Tipografia del corpo ---------- */
.mt-prose{font-size:clamp(1.0625rem,.98rem + .3vw,1.22rem);line-height:1.82;color:var(--b-text);text-align:left;margin:0;hyphens:manual}
.mt-prose > *{margin-top:0;margin-bottom:1.35em}
.mt-prose > p:first-child{font-size:1.12em;line-height:1.7;color:var(--b-ink)}
.mt-prose h2,.mt-prose h3,.mt-prose h4{font-family:var(--v-display);color:var(--b-ink);letter-spacing:-.018em;scroll-margin-top:calc(var(--v-pill-h) + 32px);text-wrap:balance}
.mt-prose h2{font-size:clamp(1.45rem,1.2rem + 1vw,1.85rem);line-height:1.2;font-weight:700;margin:2.4em 0 .7em;padding-top:.2em}
.mt-prose h3{font-size:clamp(1.18rem,1.08rem + .4vw,1.35rem);line-height:1.3;font-weight:650;margin:1.9em 0 .55em}
.mt-prose h4{font-size:1.05rem;font-weight:650;margin:1.6em 0 .5em}
.mt-prose h2 + *,.mt-prose h3 + *,.mt-prose h4 + *{margin-top:0}
.mt-prose a{color:var(--b-accent);text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:.18em;text-decoration-color:rgba(58,80,224,.35);transition:text-decoration-color .2s}
.mt-prose a:hover{text-decoration-color:currentColor}
.mt-prose strong,.mt-prose b{color:var(--b-ink);font-weight:650}
.mt-prose ul,.mt-prose ol{padding-left:1.35em}
.mt-prose li{margin-bottom:.55em;padding-left:.25em}
.mt-prose li::marker{color:var(--b-accent);font-weight:650}
.mt-prose ul li::marker{content:"▪  ";font-size:.85em}
.mt-prose li > ul,.mt-prose li > ol{margin:.55em 0 0}
.mt-prose blockquote,.mt-prose .wp-block-quote{margin:2em 0;padding:.25em 0 .25em 1.4em;border-left:3px solid var(--v-yellow);
  font-family:var(--v-serif);font-style:italic;font-size:1.4em;line-height:1.45;color:var(--b-ink)}
.mt-prose blockquote p{margin:0 0 .4em}
.mt-prose blockquote cite{display:block;font:500 .78rem var(--v-mono);font-style:normal;color:var(--b-muted);margin-top:.6em}
.mt-prose figure{margin:2.2em 0}
.mt-prose img{max-width:100%;height:auto;border-radius:14px;display:block}
.mt-prose figcaption,.mt-prose .wp-element-caption{margin-top:.7em;font-size:.84rem;line-height:1.5;color:var(--b-muted);text-align:left}
.mt-prose .aligncenter{margin-inline:auto}
.mt-prose hr{border:0;height:1px;background:var(--b-line-2);margin:2.75em 0}
.mt-prose code{font-family:var(--v-mono);font-size:.86em;background:#efeff7;color:#2b2f6b;padding:.15em .4em;border-radius:5px}
.mt-prose pre{background:var(--v-ink-2);color:#e3e7fb;padding:1.25em 1.4em;border-radius:14px;overflow-x:auto;font-size:.88em;line-height:1.6}
.mt-prose pre code{background:none;color:inherit;padding:0;font-size:inherit}
/* tabelle: scroll orizzontale su mobile senza rompere il layout */
.mt-prose .wp-block-table{overflow-x:auto;-webkit-overflow-scrolling:touch}
.mt-prose table{width:100%;border-collapse:collapse;font-size:.92em;background:var(--b-card);border:1px solid var(--b-line);border-radius:12px;overflow:hidden}
.mt-prose th{background:#f1f1ec;color:var(--b-ink);font-weight:650;text-align:left}
.mt-prose th,.mt-prose td{padding:.7em .9em;border-bottom:1px solid var(--b-line);vertical-align:top}
.mt-prose tr:last-child td{border-bottom:0}
/* box evidenziato: in editor aggiungere la classe CSS "mt-note" a un gruppo/paragrafo */
.mt-prose .mt-note{background:var(--b-card);border:1px solid var(--b-line);border-left:3px solid var(--b-accent);border-radius:12px;padding:1.1em 1.3em;font-size:.97em}
.mt-prose .wp-block-buttons{display:flex;flex-wrap:wrap;gap:.6rem}
.mt-prose .wp-block-button__link{background:var(--b-ink);color:#fff;text-decoration:none;border-radius:10px;padding:.7em 1.2em;font-size:.95rem;font-weight:600}

/* ---------- Indice dei contenuti (automatico, sopra il testo) ----------
   Card bianca con testata (icona, titolo, sezioni/minuti, freccia), voci H2
   numerate in mono e H3 raggruppati sotto il loro H2; 2 colonne da 900px.
   Aperto di default, richiudibile; la freccia ruota. */
.mt-toc{position:relative;background:var(--b-card);border:1px solid var(--b-line);border-radius:18px;margin:0 0 clamp(2rem,4vw,2.75rem);
  box-shadow:var(--b-shadow);overflow:hidden}
.mt-toc::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--v-yellow)}
.mt-toc summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:.9rem;padding:1.1rem 1.35rem 1.1rem 1.5rem;user-select:none}
.mt-toc summary::-webkit-details-marker{display:none}
.mt-toc summary:focus-visible{outline:2px solid var(--b-accent);outline-offset:-4px;border-radius:16px}
.mt-toc__icon{flex:none;width:2.4rem;height:2.4rem;display:grid;place-items:center;border-radius:10px;background:var(--v-ink-2);color:var(--v-yellow)}
.mt-toc__icon svg{width:1.15rem;height:1.15rem}
.mt-toc__head{flex:1;min-width:0;display:flex;flex-direction:column;gap:.15rem}
.mt-toc__head strong{font-family:var(--v-display);font-size:1.02rem;font-weight:650;color:var(--b-ink);letter-spacing:-.01em}
.mt-toc__head small{font:500 .72rem var(--v-mono);color:var(--b-muted)}
.mt-toc__chev{flex:none;width:2rem;height:2rem;display:grid;place-items:center;border-radius:50%;border:1px solid var(--b-line-2);color:var(--b-ink);transition:transform .3s var(--v-ease),background .2s}
.mt-toc__chev svg{width:1rem;height:1rem}
.mt-toc summary:hover .mt-toc__chev{background:#f1f1ec}
.mt-toc[open] .mt-toc__chev{transform:rotate(180deg)}
.mt-toc__body{border-top:1px solid var(--b-line);padding:1.1rem 1.35rem 1.35rem 1.5rem}
.mt-toc__list{list-style:none;margin:0;padding:0}
@media (min-width:900px){.mt-toc__list{columns:2;column-gap:2.5rem}}
.mt-toc__item{break-inside:avoid;display:grid;grid-template-columns:2rem 1fr;align-items:baseline;padding:.15rem 0}
.mt-toc__n{font:600 .74rem var(--v-mono);color:var(--b-accent);letter-spacing:.02em}
.mt-toc__list a{display:inline;color:var(--b-ink);font-size:.95rem;font-weight:550;line-height:1.45;text-decoration:none;
  background:linear-gradient(var(--v-yellow),var(--v-yellow)) 0 100%/0 2px no-repeat;transition:background-size .3s var(--v-ease),color .2s}
.mt-toc__list a:hover{background-size:100% 2px}
.mt-toc__item > a{padding:.4rem 0;display:inline-block}
.mt-toc__sub{grid-column:2;list-style:none;margin:0 0 .35rem;padding:0 0 0 .9rem;border-left:1px solid var(--b-line-2)}
.mt-toc__sub li{padding:.22rem 0}
.mt-toc__sub a{font-size:.87rem;font-weight:450;color:var(--b-muted)}
.mt-toc__sub a:hover{color:var(--b-ink)}
@media (prefers-reduced-motion:reduce){.mt-toc__chev,.mt-toc__list a{transition:none}}

/* ---------- 7. Condivisione ---------- */
.mt-share{display:flex;gap:.45rem}
.mt-share a,.mt-share button{position:relative;width:2.4rem;height:2.4rem;display:grid;place-items:center;border-radius:10px;border:1px solid var(--b-line-2);background:var(--b-card);
  color:var(--b-text);cursor:pointer;transition:border-color .2s,color .2s,background .2s;padding:0}
.mt-share svg{width:1.05rem;height:1.05rem}
.mt-share a:hover,.mt-share button:hover{border-color:var(--b-ink);color:var(--b-ink)}
.mt-share button.is-done{background:var(--b-ink);color:#fff;border-color:var(--b-ink)}
.mt-share__ok{position:absolute;bottom:calc(100% + 6px);left:50%;transform:translateX(-50%);white-space:nowrap;font:500 .7rem var(--v-mono);color:var(--b-ink)}

/* ---------- 8. Autore, correlati, paginazione ---------- */
.mt-post__foot{margin-top:clamp(2.5rem,5vw,3.5rem)}
.mt-post__tags{list-style:none;display:flex;flex-wrap:wrap;gap:.45rem;padding:0;margin:0 0 1.75rem}
.mt-post__tags a{font:500 .78rem var(--v-mono);color:var(--b-muted);text-decoration:none;padding:.3rem .6rem;border:1px solid var(--b-line-2);border-radius:6px;background:var(--b-card)}
.mt-post__tags a:hover{color:var(--b-ink);border-color:var(--b-ink)}
.mt-post__sharerow{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:1rem;padding:1.15rem 0;border-block:1px solid var(--b-line)}
.mt-post__sharerow > span{font-weight:650;color:var(--b-ink);font-size:.95rem}
.mt-blog .mt-authorbox{max-width:none;margin:1.75rem 0 0;padding:1.4rem;border:1px solid var(--b-line);border-radius:16px;background:var(--b-card)}
.mt-blog .mt-authorbox--big{border:0;background:none;padding:0}
.mt-blog .mt-authorbox__label{font:600 .68rem var(--v-mono);letter-spacing:.08em;color:var(--b-muted)}
.mt-blog .mt-authorbox__name{color:var(--b-ink)}
.mt-bsec--related{background:#efefe9;border-top:1px solid var(--b-line)}
.mt-blog .mt-pagination a.page-numbers,.mt-blog .mt-pagination span.page-numbers{background:var(--b-card);border-color:var(--b-line-2);color:var(--b-ink)}
.mt-blog .mt-pagination a.page-numbers:hover{border-color:var(--b-ink)}
.mt-blog .mt-pagination span.page-numbers.current{background:var(--b-ink);border-color:var(--b-ink);color:#fff}
/* la CTA scura a fondo pagina resta scura: stacca bene sulla carta */
.mt-blog .mt-cta{box-shadow:var(--b-shadow-lg)}

@media (prefers-reduced-motion:reduce){
  .mt-bcard,.mt-bcard__media img,.mt-bcard__more svg{transition:none}
  .mt-progress span{transition:none}
}
@media print{
  .mt-progress,.mt-toc,.mt-post__side,.mt-tocbar,.mt-post__sharerow,.mt-header,.mt-footer,.mt-cta{display:none!important}
  body.mt-blog{background:#fff}
}

/* Testo descrittivo categoria (14/11/2026) */
.mt-cat-about .mt-wrap{max-width:72ch}
.mt-cat-about h2{font-size:clamp(1.2rem,1.1rem + .5vw,1.5rem);margin:0 0 .75rem}
.mt-cat-about p{color:var(--b-muted);line-height:1.7;margin:0 0 1rem}
