/* ═══════════════════════════════════════════════════════════════════
   DEAS MAG — Blocchi editoriali v4 nel corpo articolo (pubblico).
   Caricato da includes/article-extras.php DOPO main.css: a parità di
   specificità vince questo. Scope: .article-body (il contenitore del
   corpo, anche in variante --gated). I blocchi nascono nell'editor v4
   (13-EDITOR); gli articoli vecchi non li contengono e non cambiano.
   ═══════════════════════════════════════════════════════════════════ */

/* attacco grande */
.article-body p.lead {
  font-size: 1.22em;
  line-height: 1.55;
  letter-spacing: -0.005em;
}

/* capolettera */
.article-body p.dropcap::first-letter {
  float: left;
  font-size: 3.4em;
  line-height: 0.82;
  font-weight: 500;
  padding: 0.06em 0.12em 0 0;
}

/* evidenziatore editoriale: nero pieno, testo bianco (decisione 12.08) */
.article-body mark {
  background: #0a0a0a;
  color: #fff;
  padding: 0 0.18em;
}

/* pull quote con attribuzione */
.article-body .pullquote {
  border-left: 2px solid #0a0a0a;
  padding: 0.2em 0 0.2em 1.2em;
  margin: 2em 0;
}
.article-body .pullquote p:first-child {
  font-size: 1.35em;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin-bottom: 0.55em;
}
.article-body .pullquote p:nth-child(2) {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.62em;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #8a8a85;
  margin: 0;
}

/* blocco immagine: didascalia + credit; larghezze wide e full-bleed */
.article-body figure.imgblock {
  margin: 2em 0;
}
.article-body figure.imgblock img {
  width: 100%;
  height: auto;
  display: block;
  margin: 0;
}
.article-body figure.imgblock figcaption,
.article-body figure.duo figcaption {
  display: flex;
  justify-content: space-between;
  gap: 1em;
  align-items: baseline;
  margin-top: 0.7em;
}
.article-body figure.imgblock figcaption .cap,
.article-body figure.duo figcaption .cap {
  font-size: 0.78em;
  color: #5c5c58;
  line-height: 1.45;
}
.article-body figure.imgblock figcaption .credit,
.article-body figure.duo figcaption .credit {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.58em;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #8a8a85;
  white-space: nowrap;
}
/* breakout indipendenti dal contenitore (tecnica 50% − 50vw) */
.article-body figure.imgblock.imgblock--wide {
  width: min(100vw - 3rem, 960px);
  margin-left: calc(50% - min(100vw - 3rem, 960px) / 2);
}
.article-body figure.imgblock.imgblock--full {
  width: 100vw;
  margin-left: calc(50% - 50vw);
}
.article-body figure.imgblock.imgblock--full figcaption {
  padding: 0 1.5rem;
}

/* dittico */
.article-body figure.duo {
  margin: 2em 0;
}
.article-body figure.duo {
  display: block;
}
.article-body figure.duo img {
  width: calc(50% - 0.3em);
  height: auto;
  display: inline-block;
  vertical-align: top;
  margin: 0;
}
.article-body figure.duo img + img {
  margin-left: 0.6em;
}

/* blocco crediti di fine articolo */
.article-body .credits {
  border-top: 1px solid #0a0a0a;
  margin-top: 3em;
  padding-top: 1.1em;
}
.article-body .credits__row {
  display: grid;
  grid-template-columns: 9em 1fr;
  gap: 0.9em;
  padding: 0.3em 0;
}
.article-body .credits__k {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.58em;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6e6e6a;
  padding-top: 0.35em;
}
.article-body .credits__v {
  font-size: 0.82em;
}

@media (max-width: 640px) {
  .article-body figure.imgblock.imgblock--wide {
    width: 100vw;
    margin-left: calc(50% - 50vw);
  }
  .article-body .credits__row {
    grid-template-columns: 7em 1fr;
  }
}

/* ─────────────────────────────────────────────────────────────────────
   HTML embed interattivo (53-EMBED-HTML): figure.embedblock > iframe
   same-origin verso /uploads/embeds/*.html. Trattamento "filetto
   editoriale" come il blocco credits: filo nero sopra con etichetta
   mono INTERACTIVE, didascalia/fonte in figcaption come le immagini.
   L'altezza dell'iframe la imposta lo script in article.php.
   Regole APPESE in coda di proposito: i selettori esistenti sopra non
   si toccano (file vivo condiviso). */
.article-body figure.embedblock {
  margin: 2.4em 0;
  border-top: 1px solid #0a0a0a;
}
.article-body figure.embedblock::before {
  content: "■ INTERACTIVE";
  display: block;
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.58em;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1em 0 1.1em;
}
.article-body figure.embedblock iframe {
  display: block;
  width: 100%;
  border: 0;
  border-left: 1px solid rgba(10, 10, 10, 0.18);
  border-right: 1px solid rgba(10, 10, 10, 0.18);
  min-height: 320px;
}
.article-body figure.embedblock figcaption {
  display: flex;
  justify-content: space-between;
  gap: 1em;
  align-items: baseline;
  margin-top: 0.7em;
  border-top: 1px solid #0a0a0a;
  padding-top: 0.7em;
}
.article-body figure.embedblock figcaption .cap {
  font-size: 0.78em;
  color: #5c5c58;
  line-height: 1.45;
}
.article-body figure.embedblock figcaption .credit {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.58em;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #8a8a85;
  white-space: nowrap;
}
.article-body figure.embedblock.embedblock--wide {
  width: min(100vw - 3rem, 960px);
  margin-left: calc(50% - min(100vw - 3rem, 960px) / 2);
}
.article-body figure.embedblock.embedblock--full {
  width: 100vw;
  margin-left: calc(50% - 50vw);
}
.article-body figure.embedblock.embedblock--full iframe {
  border-left: 0;
  border-right: 0;
}
.article-body figure.embedblock.embedblock--full::before,
.article-body figure.embedblock.embedblock--full figcaption {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
@media (max-width: 640px) {
  .article-body figure.embedblock.embedblock--wide {
    width: 100vw;
    margin-left: calc(50% - 50vw);
  }
  .article-body figure.embedblock iframe,
  .article-body figure.embedblock.embedblock--wide iframe {
    border-left: 0;
    border-right: 0;
  }
}

/* ── LOTTO 56 (16.09.2026): byline cliccabili → /author/slug/ ────────────
   Il link eredita colore e peso del nome (header meta, blocco «By»,
   box ABOUT THE AUTHOR) e si rivela solo al passaggio: la firma resta
   tipograficamente identica a prima. */
.article-header__meta-item a,
.article-author__name a,
.author-box__name a {
  color: inherit;
  text-decoration: none;
}
.article-header__meta-item a:hover,
.article-author__name a:hover,
.author-box__name a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── LOTTO 57 (23.09.2026): collection boards in sidebar + visore ─────────
   Il modulo usa il titolo mono dei moduli sidebar (.sidebar-highlights__title
   del CSS legacy, caricato su ogni articolo); qui solo lista e visore. */
.sidebar-boards { padding-bottom: 1.5rem; border-bottom: 1px solid var(--c-border); }
.sidebar-boards__meta { font-family: var(--f-ui); font-size: .55rem; letter-spacing: .14em; text-transform: uppercase; color: var(--c-text-dim); margin: -.4rem 0 .7rem; }
.sidebar-boards__meta span { color: #d5ff32; }
.sidebar-boards__list { display: grid; gap: 6px; }
.sidebar-boards__item { display: block; border: 1px solid var(--c-border); background: #f2f2f0; transition: border-color .2s; }
.sidebar-boards__item:hover, .sidebar-boards__item:focus-visible { border-color: var(--c-black); }
.sidebar-boards__item img { width: 100%; height: auto; display: block; }
.crlb { position: fixed; inset: 0; z-index: 600; background: rgba(0, 0, 0, .92); overflow: auto; -webkit-overflow-scrolling: touch; padding: 64px 24px 24px; cursor: zoom-out; }
.crlb[hidden] { display: none; }
.crlb:focus { outline: none; }
.crlb__stage { min-height: 100%; display: flex; align-items: flex-start; justify-content: center; }
/* FIT: adattata alla larghezza (max 1100px), si scorre in verticale */
.crlb img { display: block; width: min(1100px, 100%); height: auto; max-width: none; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); cursor: zoom-in; }
/* ZOOM: larghezza naturale × livello (impostata dallo script), scorre in entrambe le direzioni */
.crlb--zoom .crlb__stage { justify-content: flex-start; width: max-content; min-width: 100%; }
.crlb--zoom img { cursor: zoom-out; }
.crlb__bar { position: fixed; left: 0; right: 0; top: 0; z-index: 2; display: flex; align-items: center; gap: 1.5rem; padding: 18px 24px; background: rgba(0, 0, 0, .75); font-family: var(--f-ui); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase; color: #fff; cursor: default; }
.crlb__bar .crlb__t { margin-right: auto; }
.crlb__zoom { display: inline-flex; border: 1px solid rgba(255,255,255,.35); }
.crlb__zb { background: none; border: 0; color: #fff; cursor: pointer; font: inherit; padding: 6px 12px; line-height: 1; }
.crlb__zb + .crlb__zb { border-left: 1px solid rgba(255,255,255,.35); }
.crlb__zb--lvl { min-width: 54px; text-align: center; }
.crlb__zb:hover, .crlb__x:hover, .crlb__nav:hover { background: rgba(255,255,255,.14); }
.crlb__x { background: none; border: 0; color: #fff; cursor: pointer; font: inherit; letter-spacing: .16em; padding: 6px 8px; }
.crlb__nav { position: fixed; top: 50%; transform: translateY(-50%); z-index: 2; background: rgba(0,0,0,.55); border: 0; color: #fff; cursor: pointer; font: inherit; font-size: 28px; line-height: 1; padding: 20px 14px; font-weight: 300; }
.crlb__nav--l { left: 0; } .crlb__nav--r { right: 0; }
@media (max-width: 640px) {
  .crlb { padding: 56px 0 16px; }
  .crlb__bar { padding: 14px 10px; gap: .8rem; font-size: .56rem; }
  .crlb__bar .crlb__t { display: none; }
  .crlb__nav { top: auto; bottom: 14px; transform: none; padding: 10px 16px; font-size: 22px; }
  .crlb__nav--l { left: 10px; } .crlb__nav--r { right: 10px; }
}
@media (prefers-reduced-motion: reduce) { .sidebar-boards__item { transition: none; } }

/* ═══ 65-EMBED-CONSENT — segnaposto per video bloccati dal consenso (65, 3.10.2026) ═══
   Va in coda ad assets/css/article-blocks.css. Compare SOLO quando iubenda
   ha svuotato l'iframe (data-suppressedsrc); con consenso dato non esiste. */
.article-body .video-wrapper { position: relative; }
.article-body .embed-consent {
  position: absolute; inset: 0; z-index: 2;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  gap: 0.75em; padding: clamp(1rem, 4vw, 2rem);
  background: #f5f5f5; border: 1px solid #0a0a0a; color: #0a0a0a;
}
.article-body .embed-consent__k {
  font-family: "Geist Mono", ui-monospace, Menlo, monospace;
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: #666;
}
.article-body .embed-consent__t { font-size: 1em; line-height: 1.45; max-width: 36ch; margin: 0; }
.article-body .embed-consent__b {
  font-family: "Geist Mono", ui-monospace, Menlo, monospace;
  font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase;
  background: #0a0a0a; color: #fff; border: 0; padding: 0.7em 1.1em; cursor: pointer;
}
.article-body .embed-consent__b:hover { opacity: 0.9; }
@media (max-width: 480px) { .article-body .embed-consent__t { font-size: 0.92em; } }

/* ─── 73-GALLERY (9.10.2026): carosello di immagini negli articoli ───────
   figure.gallery > .gallery__frame > .gallery__track > img… + figcaption.
   Scroll-snap nativo; frecce e contatore (.count) li inserisce lo script
   in article-extras.php. Credit unico, altezza uguale, larghezza fissa. */
.article-body figure.gallery { margin: 2em 0; }
.article-body figure.gallery .gallery__frame { position: relative; }
.article-body figure.gallery .gallery__track {
  display: flex; gap: 0.5rem; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; -webkit-overflow-scrolling: touch; margin: 0; padding: 0;
}
.article-body figure.gallery .gallery__track::-webkit-scrollbar { display: none; }
.article-body figure.gallery .gallery__track img {
  flex: 0 0 auto; scroll-snap-align: start; margin: 0; display: block;
  height: min(72vh, 640px); width: auto; aspect-ratio: 4 / 5; object-fit: cover;
}
.article-body figure.gallery.gallery--landscape .gallery__track img {
  aspect-ratio: 3 / 2; height: min(60vh, 520px);
}
.article-body figure.gallery .gallery__nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 40px; height: 40px; border: 0; background: #0A0A0A; color: #FFF; cursor: pointer;
  display: flex; align-items: center; justify-content: center; padding: 0;
}
.article-body figure.gallery .gallery__nav:hover { background: #D5FF32; color: #0A0A0A; }
.article-body figure.gallery .gallery__nav--prev { left: 0; }
.article-body figure.gallery .gallery__nav--next { right: 0; }
.article-body figure.gallery .gallery__nav[disabled] { opacity: 0.25; cursor: default; }
.article-body figure.gallery figcaption {
  display: flex; justify-content: space-between; gap: 1em; align-items: baseline; margin-top: 0.7em;
}
.article-body figure.gallery figcaption .cap { font-size: 0.78em; color: #5c5c58; line-height: 1.45; }
.article-body figure.gallery figcaption .credit,
.article-body figure.gallery figcaption .count {
  font-family: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.58em; letter-spacing: 0.07em; text-transform: uppercase; color: #8a8a85; white-space: nowrap;
}
.article-body figure.gallery figcaption .count { margin-left: auto; padding-right: 1em; }
@media (hover: none) { .article-body figure.gallery .gallery__nav { display: none; } }

/* ─── 75-IG-FALLBACK (10.10.2026): post Instagram non incorporabile ──────
   Quando l'account del post ha spento «consenti di incorporare», Instagram
   restituisce un iframe vuoto di 2px. Lo script in article-extras.php lo
   sostituisce con la card del 65 (stesse classi) in versione statica. */
.article-body .embed-wrapper .embed-consent--static {
  position: static; inset: auto; width: 100%; max-width: 540px; box-sizing: border-box;
}
.article-body .embed-consent--static .embed-consent__b { text-decoration: none; display: inline-block; }
.article-body .embed-wrapper .ig-hidden { display: none !important; }
