:root {
  --paper: #f7f4ed;
  --paper-deep: #eee9df;
  --ink: #252521;
  --muted: #77736b;
  --line: #d9d2c7;
  --ruby: #b52c40;
  --ruby-dark: #8f1f30;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "IBM Plex Sans Condensed", "DM Sans", Arial, sans-serif;
  --content: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--ruby); }
img { display: block; max-width: 100%; }
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 10;
  background: var(--ink); color: white; padding: 12px 18px;
}
.skip-link:focus { left: 12px; top: 12px; }

/* Contenitore comune: testata, contenuto e footer */
.site-header, .page-shell, .site-footer {
  box-sizing: border-box;
  width: min(var(--content), calc(100% - 64px));
  margin-inline: auto;
}

/* Testata e navigazione */
.header-top {
  display: flex; align-items: end; justify-content: space-between;
  padding: 15px 0 22px 0;
}
.wordmark, .footer-wordmark {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(3.5rem, 7vw, 6.3rem);
  letter-spacing: -.09em; line-height: .9;
}

/* Header logo: "korero" and "it" in ruby, the dot in ink */
.wordmark { color: var(--ruby); }
.wordmark span { color: var(--ink); }
.footer-wordmark span { color: var(--ruby); }

.brand-note {
  color: var(--muted); font-size: .78rem; letter-spacing: .11em;
  text-transform: uppercase; margin: 0 2px -2px 20px;
}

/* Desktop menu links: edit font-size / font-weight / letter-spacing here.
   Taller and narrower letters: condensed face, larger size, tight tracking.
   (Mobile menu overrides size and padding in the @media (max-width: 900px) block.) */
.category-nav {
  display: flex; align-items: center; gap: 0;
  border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink);
  padding: 11px 0; margin-bottom: 15px;
}
.category-nav a {
  font-family: "IBM Plex Sans Condensed", "Arial Narrow", var(--sans);
  font-size: 1.07rem; font-weight: 500; line-height: 1.25;
  letter-spacing: -.053em;
  padding: 4px 4px; border-right: 1px solid var(--line);
  white-space: nowrap;
}
.category-nav a:first-child { padding-left: 0; }
.category-nav a:last-child { border-right: 0; }

/* Alternating menu colors (desktop and mobile): ink | ruby | ink | ruby ...
   Explicit :hover rules are needed because these selectors are more specific
   than the global a:hover rule. */
.category-nav a:nth-child(odd)  { color: var(--ink); }
.category-nav a:nth-child(even) { color: var(--ruby); }
.category-nav a:nth-child(odd):hover  { color: var(--ruby); }
.category-nav a:nth-child(even):hover { color: var(--ruby-dark); }

/* Navigation links wrapper (horizontal row on desktop).
   flex-wrap lets the links flow onto a second line instead of overflowing
   the container (which widened the whole page on phones in "desktop mode").
   min-width: 0 allows the flex item to shrink below its content width. */
.nav-links { display: flex; align-items: center; flex-wrap: wrap; min-width: 0; }

/* Desktop menu (wider than 900px): two rows of five equal columns, so the
   labels do not have to be squeezed on a single line. The mobile menu
   (hamburger) is not affected by this block.
   The grid has 5 columns: if the number of categories changes, update
   repeat(5, ...) and the nth-child values below. */
@media (min-width: 901px) {
  .nav-links {
    display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: stretch; flex: 1 1 auto;
  }
  .category-nav a {
    font-size: clamp(.92rem, 1.45vw, 1.07rem); letter-spacing: -.01em;
    padding: 6px 12px; white-space: normal;
  }
  .category-nav a:nth-child(5n+1) { padding-left: 0; }  /* first column flush with the logo */
  .category-nav a:nth-child(5n) { border-right: 0; }    /* last column: no divider */
  .category-nav a:nth-child(n+6) { border-top: 1px solid var(--line); }  /* hairline between the two rows */
}

/* Hamburger toggle: hidden on desktop, enabled in the responsive blocks below */
.nav-toggle {
  display: none; align-items: center; justify-content: space-between;
  width: 100%; min-height: 48px; padding: 0;
  background: none; border: 0; color: var(--ink); cursor: pointer;
  font: inherit; font-size: .8rem; font-weight: 700;
  letter-spacing: .11em; text-transform: uppercase;
}
.nav-toggle:hover { color: var(--ruby); }
.nav-toggle:focus-visible { outline: 2px solid var(--ruby); outline-offset: 2px; }
.nav-toggle-bars { position: relative; display: block; width: 24px; height: 18px; }
.nav-toggle-bars span {
  position: absolute; left: 0; width: 100%; height: 2px;
  background: currentColor;
  transition: transform .25s ease, top .25s ease, opacity .2s ease;
}
.nav-toggle-bars span:nth-child(1) { top: 0; }
.nav-toggle-bars span:nth-child(2) { top: 8px; }
.nav-toggle-bars span:nth-child(3) { top: 16px; }
/* Open state: the three bars become an X */
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(1) { top: 8px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(3) { top: 8px; transform: rotate(-45deg); }

/* Home page */
.intro-line {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 20px; border-bottom: 1px solid var(--line); padding: 0 0 14px;
  margin-bottom: 28px;
}
.eyebrow {
  color: var(--ruby); font-size: .68rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
}
.intro-line p { margin: 0; color: var(--muted); font-size: .9rem; }
.lead-story {
  display: grid; grid-template-columns: 1fr 1.06fr; gap: clamp(28px, 5vw, 70px);
  align-items: start; padding: 0 0 30px;
  border-bottom: 1px solid var(--ink);
}
.lead-copy { padding: 10px 0; }
.story-category {
  display: inline-block; color: var(--ruby); font-size: .69rem;
  font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
}
/* All the categories of an article (cards and article header): cat1 | cat2 */
.story-categories { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.category-sep { color: var(--muted); font-size: .69rem; font-weight: 400; }
/* Article header: categories 2px lower, the title stays where it is */
.article-header .story-categories { position: relative; top: 0; }  /* Spazio sopra le categorie, nell'articolo */
.lead-copy h1 {  /* Lead Story: prima notizia in home */
  font: 600 clamp(2.1rem, 4.1vw, 3.7rem)/1.06 var(--serif);  /* [600: peso grassetto] [clamp(2.0rem, 4vw, 3.5rem): dimensione minima, dinamica e massima del testo] [/1.06: interlinea] [var(--serif): famiglia di caratteri] */
  letter-spacing: -.045em;
  margin: 15px 0;
}
.story-summary {
  max-width: 500px; color: #5c5952; font-size: 1.04rem; line-height: 1.75;
}
.story-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; color: var(--muted); font-size: .73rem; }
.meta-dot { color: var(--ruby); }
.read-link {
  display: inline-flex; align-items: center; gap: 12px; margin-top: 23px;
  padding-bottom: 5px; border-bottom: 1px solid var(--ruby);
  color: var(--ruby); font-size: .8rem; font-weight: 700;
}
.read-link:hover { color: var(--ruby-dark); }
.lead-image {
  display: block;
  overflow: hidden;
  background: var(--paper-deep);
  aspect-ratio: 1.16 / 1;
  margin: 22px 0 8px 0;
}
.lead-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.lead-image:hover img, .card-image:hover img { transform: scale(1.035); }
.lead-art {
  aspect-ratio: 1.16 / 1; background: var(--ruby); color: var(--paper);
  display: grid; place-items: center; font: 700 9rem var(--serif);
}
.story-section { padding: 20px 0 42px; border-bottom: 1px solid var(--line); }
.section-title-row { display: flex; align-items: center; gap: 22px; margin-bottom: 25px; }
.section-title-row h2 {  /* Da non perdere */
  font: 600 1.8rem/1.2 var(--serif); letter-spacing: -.035em; margin: 0;
  color: var(--ruby);
  margin-top: -2px;
}
.story-section:last-of-type {
  border-bottom: none;
}
.section-rule { height: 1px; background: var(--line); flex: 1; }
.story-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 26px; }
.story-card { min-width: 0; }
.card-image { display: block; overflow: hidden; aspect-ratio: 16 / 9; background: var(--paper-deep); margin-bottom: 17px; }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card-copy h2, .card-copy h3 {
  font: 600 clamp(1.35rem, 2vw, 1.8rem)/1.2 var(--serif);
  letter-spacing: -.025em; margin: 8px 0 10px;
}
.card-copy p, .latest-item p { color: var(--muted); font-size: .86rem; margin: 0 0 13px; }
.card-copy time { color: var(--muted); font-size: .7rem; }

.latest-section { border-bottom: 0; }

/* Make the divider above "Le ultime storie" as bold as the one above "Da non perdere" */
.story-section:has(+ .latest-section) { border-bottom: 1px solid var(--ink); padding-bottom: 30px; }

/* Hide the line next to the "Le ultime storie" title */
.latest-section .section-rule { display: none; }

.latest-list { border-top: 1px solid var(--line); }
.latest-item {
  display: grid; grid-template-columns: 130px minmax(0, 1fr) 28px;
  gap: 24px; padding: 23px 0; border-bottom: 1px solid var(--line); align-items: start;
}
.latest-date { font-size: .72rem; color: var(--muted); padding-top: 5px; }
.latest-item h3 { font: 600 1.45rem/1.25 var(--serif); margin: 4px 0 8px; }
.latest-item p { margin-bottom: 0; }
.latest-arrow { color: var(--ruby); font-size: 1.3rem; }
.latest-item:last-child { border-bottom: 0; margin-bottom: -50px; }

/* Archivi e categorie */
.section-heading { padding: 10px 0 30px; border-bottom: 1px solid var(--ink); }

.section-heading h1 { font: 600 clamp(2.1rem, 4.2vw, 3.4rem)/1.1 var(--serif); letter-spacing: -.045em; margin: 10px 0; }

.section-heading p { margin: 0; color: var(--muted); }
.category-heading { margin-top: -6px; }  /* Spazio sopra le categorie, nelle pagine di categoria */
.archive-section { padding-top: 30px; }
.empty-category {
  padding: 80px 20px;
  text-align: center;
  border-bottom: none;
}
.empty-mark, .end-mark { color: var(--ruby); font: 700 3rem var(--serif); }
.empty-category h2 { font: 600 2rem var(--serif); margin: 10px 0; }
.empty-category p { color: var(--muted); }

/* Articoli */
.article-layout { display: grid; grid-template-columns: minmax(0, 820px) minmax(0, 1fr); gap: 48px; }
.article { min-width: 0; }
.article-header { max-width: 820px; margin: 10px auto 32px; }
.article-header h1 {
  font: 600 clamp(2.1rem, 4.1vw, 3.7rem)/1.06 var(--serif);
  letter-spacing: -.045em;
  margin: 15px 0 20px;
}
.article-deck { font-size: 1.15rem; line-height: 1.7; color: #5c5952; }
.article-figure { aspect-ratio: 16 / 9; overflow: hidden; margin: 0 0 23px; background: var(--paper-deep); }  /* Spazio sotto la foto */
.article-figure img { width: 100%; height: 100%; object-fit: cover; }
.article-figure figcaption { font-size: .72rem; color: var(--muted); padding-top: 8px; }
.article-body {
  max-width: 820px; margin: 0 auto; font-family: Georgia, serif;
  font-size: 1.14rem; line-height: 1.95;
}
.article-body h2, .article-body h3 {
  font-family: var(--serif); line-height: 1.5; letter-spacing: -.025em;
}
.article-body h2 { font-size: 2rem; margin: 2em 0 .65em; }
.article-body h3 { font-size: 1.45rem; margin: 1.2em 0 .5em; color: var(--ruby); }

/* TOC list (the TOC heading is the only h3 without an id): above / below */
.article-body h3:not([id]) + ul { margin: 0.5em 0 1.0em; }
.article-body h3:not([id]) + ul + h3 { margin-top: .6em; }  /* First title after the TOC: the bigger margin wins */

.article-body p { margin: 0 0 -0.5em 0; }  /* Spazio tra paragrafi */
.article-body a { color: var(--ruby); text-decoration: underline; text-underline-offset: 3px; }
.article-body blockquote { margin: 2em 0; padding: 5px 0 5px 24px; border-left: 3px solid var(--ruby); font: italic 1.4rem/1.6 var(--serif); }

.article-end { max-width: 820px; margin: 55px auto 0; padding: 28px 0 42px; border-top: 1px solid var(--ink); }
.article-end p { color: var(--muted); }
.sidebar-reserve { min-height: 180px; }
.article-sidebar { border-left: 1px solid var(--line); padding-top: 10px; }  /* Sidebar destra */
.pagination {
  display: flex; justify-content: space-between; align-items: center; gap: 15px;
  padding: 25px 0; font-size: .8rem; border-top: 1px solid var(--line);
}
.pagination a { color: var(--ruby); font-weight: 700; }

/* Pagine (cookie, privacy): singola colonna centrata, nessuna barra laterale */
.page-layout { grid-template-columns: minmax(0, 1fr); font-family: var(--serif); }
.page-layout .article-header, .page-layout .article-body { max-width: none; }
.page-layout .article-body { font-family: inherit; font-size: 1rem; line-height: 1.7; }
.page-layout .article-header h1 { font-size: 2.5rem; margin: 0; }
.page-layout .article-deck { margin: 0.4em 0 -0.8em 0; }
.page-layout .article-body h2 { font-size: 1.45rem; margin: 0.5em 0 .5em; }
.page-layout .article-body h3 { font-size: 1.15rem; margin: 1.2em 0 .4em; color: #000; }
.page-layout .article-body p { margin: 0 0 0.5em 0; }
.page-layout .article-body ul { margin: 0 0 1em 0; padding-left: 1.4em; }
.page-layout .article-body li { margin: 0 0 .4em 0; }
.page-layout .article-body li ul { margin-top: .4em; }

/* Footer editoriale Korero.it */
.site-footer {
  margin-top: 1.2rem;
  padding: 2rem 0 1.25rem;
  color: #252522;
  background: #f7f4ed;
  border-top: 1px solid var(--ink);
  font-size: .94rem;
  line-height: 1.7;
}
.site-footer .footer-inner {
  display: block;
  width: 100%;
  max-width: none;
  margin: 0;
}
.footer-wordmark { font-size: 2.8rem; }
.site-footer p { margin: 0 0 1rem; color: var(--muted); font-size: .8rem; }

.site-footer .footer-grid {
  display: grid;
  width: 100%;
  max-width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: clamp(1rem, 2.5vw, 2rem);
  row-gap: 2rem;
  align-items: start;
}
.site-footer .footer-column { min-width: 0; }
.site-footer .footer-heading {
  margin: 0;
  color: #252522;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.4;
}
.site-footer .footer-rule {
  width: 48px;
  height: 3px;
  margin: .9rem 0 1.2rem;
  background: #a52235;
}
.site-footer a {
  color: #252522;
  text-decoration: none;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}
.site-footer a:hover,
.site-footer a:focus-visible {
  color: #252522;
  text-decoration: underline;
}
.site-footer .footer-links,
.site-footer .social-links {
  margin: 0 0 1.25rem;
  padding: 0;
  list-style: none;
}
.site-footer .footer-links li,
.site-footer .social-links li { margin: 0 0 .6rem; }

.site-footer .footer-link-icon,
.site-footer .social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 1.15rem;
  width: 1.15rem;
  height: 1.15rem;
  color: #a52235;
}
.site-footer .footer-link-icon {
  margin-right: .5rem;
  vertical-align: -.22rem;
}
.site-footer .footer-link-icon svg,
.site-footer .social-icon svg {
  display: block;
  width: 100%;
  height: 100%;
}
/* Colore uniforme per tutte le icone social, come Instagram */
.site-footer .social-icon,
.site-footer .social-links svg {
  color: #a52235;
  fill: #a52235;
  stroke: #a52235;
}
.site-footer .social-links a {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
}
.site-footer .footer-disclaimer {
  margin-top: -0.5rem;
  color: #5c5952;
  font-size: .69rem;
  line-height: 1.65;
}
.site-footer .newsletter-form {
  display: grid;
  gap: .55rem;
  margin-top: 1rem;
}
.site-footer .newsletter-form label {
  color: #252522;
  font-size: .85rem;
  font-weight: 600;
  margin-top: -12px;
}
.site-footer .newsletter-form input {
  box-sizing: border-box;
  width: 100%;
  min-height: 32px;
  padding: .35rem .65rem;
  border: 1px solid #d8d2c7;
  border-radius: 3px;
  color: #252522;
  background: #fffdf8;
  font: inherit;
}
.site-footer .newsletter-form input:disabled {
  opacity: .75;
  cursor: not-allowed;
}
.site-footer .newsletter-form button {
  min-height: 32px;
  margin-top: .2rem;
  padding: .35rem .8rem;
  border: 0;
  border-radius: 3px;
  color: var(--paper); /* Testo giallino/crema dello sfondo */
  background: var(--ruby); /* Sfondo rosso rubino del sito (#b52c40 o #a52235) */
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s ease, opacity 0.2s ease;
}
.site-footer .newsletter-form button:hover {
  background: var(--ruby-dark); /* Rosso più scuro al passaggio del mouse */
}
.site-footer .newsletter-note {
  margin-top: .70rem;
}
.site-footer .footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 2rem;
  margin-top: 0.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid #d8d2c7;
  color: #5c5952;
  font-size: .82rem;
}
.site-footer .footer-bottom p { margin: 0; }
.site-footer .footer-bottom a { text-decoration: underline; text-underline-offset: 3px; }

/* YouTube facade (the iframe loads only after the click) */
.yt-facade {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 2.2em 0 1.5em 0;  /* Spazio sopra e sotto al video */
  background: #000;
  overflow: hidden;
  border-radius: 4px;
}
.yt-facade img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0.92;
}

.yt-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);   /* cerchio centrato */
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
  transition: background-color 0.2s ease, transform 0.2s ease;
}
.yt-play svg {
  width: 48px;
  height: 48px;
  /* Sposta la freccia a sinistra dentro il cerchio
     (era 5px, ora 0: compensazione ottica ridotta) */
  margin-left: 0;
}
.yt-play:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: translate(-50%, -50%) scale(1.08);
}
.yt-play:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px #fff, 0 4px 24px rgba(0, 0, 0, 0.35);
}

.yt-notice {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 0;
  padding: 6px 12px;
  display: flex;
  align-items: center;
  min-height: 32px;
  box-sizing: border-box;
  background: rgba(0, 0, 0, 0.72);
  color: #fff;
  font-size: 0.8rem;
  line-height: 1.35;
  pointer-events: none;  /* la barra non attiva il video */
}
.yt-notice > span {
  flex: 1;
  transform: translateY(-4px);   /* alza la scritta di 4px */
}
.yt-notice a {
  color: #fff;
  text-decoration: underline;
  pointer-events: auto;  /* solo il link è cliccabile */
}
.yt-notice a:hover {
  text-decoration: none;
}

/* Responsive */
@media (min-width: 901px) {
  .archive-section .story-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

  /* Colonne del Footer */
  .site-footer .footer-grid {
    grid-template-columns: 1fr 1fr auto;
    column-gap: 5rem;
  }

  .site-footer .footer-column:last-child { text-align: left; }
  .site-footer .footer-column:last-child .footer-rule { margin-left: 0; }
  .site-footer .footer-column:last-child .social-links a { justify-content: flex-start; }
}

/* Mobile (Tablet: dai 900px in giù) */
@media (max-width: 900px) {
  .site-header, .page-shell, .site-footer { width: min(100% - 36px, var(--content)); }  /* Mobile menu: hamburger bar + collapsible vertical list */

  .header-top { padding: 18px 0 17px 0; align-items: start; flex-direction: column; gap: 12px; }  /* Spazio sopra e sotto il logo korero.it + CAPIRE, NON SOLO SAPERE. */

  .lead-story { gap: 25px; }
  .lead-copy h1 {
    font-size: 2.0rem !important;
    margin-top: 10px;
  }

  .lead-image {
    margin: 23px 0 -8px 0;
  }

  .read-link { display: none; }  /* Leggi la storia */

  .article-header h1, .article h1 {  /* Mobile: Titolo articolo */
    font-size: 2.0rem !important;
    line-height: 1.15;
    margin-top: 10px;
  }

  .article-figure {  /* Mobile: immagine */
    margin: -5px 0 20px 0;
  }

  .article-body p { margin: 0 0 -0.7em 0; }  /* Mobile: Spazio tra paragrafi */

  .section-heading p { margin-bottom: -10px; }  /* Mobile: Idee, notizie e approfondimenti: una prospettiva in più sul mondo. */

  .category-nav { display: block; padding: 0;  margin-bottom: 0px; }  /* Mobile: spazio tra menu e immagine */
  .nav-toggle { display: flex; }
  .nav-links {
    display: none; flex-direction: column; align-items: stretch;
    border-top: 1px solid var(--line);
  }
  .category-nav.is-open .nav-links { display: flex; }
  .category-nav .nav-links a {
    padding: 13px 0; border-right: 0; border-bottom: 1px solid var(--line);
    font-size: .95rem; white-space: normal;
  }
  .category-nav .nav-links a:last-child { border-bottom: 0; }
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .article-sidebar { display: none; }

  .site-footer {
    margin-top: 0.7rem !important;
  }

   /* Footer: 1a colonna normale, 2a e 3a affiancate */
  .site-footer .footer-grid {
    grid-template-columns: 1.45fr 1fr;
    column-gap: 2rem;
  }
  .site-footer .footer-column:nth-child(1) {
    grid-column: 1 / -1;
    margin: -1.1rem 0 -2rem 0;
  }
  .site-footer .footer-column:nth-child(2),
  .site-footer .footer-column:nth-child(3) {
    grid-column: span 1;
  }

  .site-footer .footer-disclaimer {
    margin-bottom: 1.4rem; /* Aumenta lo spazio sotto il disclaimer su mobile (Korero.it è un sito indipendente...) */
  }

  /* YouTube facade (the iframe loads only after the click) */
  .yt-facade {
    margin: 2.5em 0 0em 0;  /* Spazio sopra e sotto al video */
  }

  .yt-play { width: 56px; height: 56px; }  /* Dimesioni freccia Play */
}

/* Smartphone: dai 600px in giù */
@media (max-width: 600px) {
  .site-header, .page-shell, .site-footer { width: calc(100% - 32px); }
  .wordmark { font-size: 4.2rem; }
  .brand-note { margin: 0; font-size: .65rem; }
  .intro-line { display: block; }
  .intro-line p { margin-top: 6px; }
  .lead-story { grid-template-columns: 1fr; gap: 22px; padding-bottom: 30px; }
  .lead-copy { padding: 0; }
  .lead-copy h1 { font-size: 3rem; }
  .lead-image, .lead-art { grid-row: 1; aspect-ratio: 1.35 / 1; }
  .story-grid { grid-template-columns: 1fr; gap: 28px; }
  .section-title-row h2 { font-size: 1.55rem; }
  .latest-item { grid-template-columns: 1fr 24px; gap: 8px 12px; }
  .latest-date { grid-column: 1 / -1; }
  .latest-item h3 { font-size: 1.35rem; }
  .latest-arrow { grid-column: 2; grid-row: 2; }
  .article-header h1 { font-size: 2.7rem; }
  .article-deck { font-size: 1rem; }
  .article-body { font-size: 1.05rem; }
  .article-body h2 { font-size: 1.7rem; }
  .pagination { font-size: .72rem; }
  .site-footer { margin-top: 2.5rem; padding: 2.5rem 0 1.1rem; }
  .site-footer .footer-bottom { flex-direction: column; gap: .65rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

.article-related {
  max-width: 820px;
  margin: 40px auto 20px;
  padding-top: 35px;
  border-top: 1px solid var(--ink);
}

.article-related .section-title-row {  /* Dalla stessa categoria */
  margin: -15px 0 25px 0;
}

.article-related .story-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 30px 24px;
}

/* "Leggi anche" box inside the article text (after the 2nd paragraph):
   image on the left, text on the right; stacked on small screens.
   Selectors start with .article-body to win over .article-body a / p rules. */
.article-body .read-also {
  margin: 2.0em 0 1.5em;  /* Space above/below the box */
  font-family: var(--sans);
  line-height: 1.4;
}
.read-also-label {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 14px;
  color: var(--ruby); font-size: .72rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
}
.read-also-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }  /* Hairline after the label */
.article-body a.read-also-card {
  display: grid; grid-template-columns: minmax(0, 38%) minmax(0, 1fr);
  overflow: hidden;
  background: #fffdf8;
  border: 1px solid var(--line);
  color: var(--ink); text-decoration: none;
  box-shadow: 0 1px 0 rgba(37, 37, 33, .04);
  transition: box-shadow .3s ease, transform .3s ease;
}
.article-body a.read-also-card:hover {
  color: var(--ink);
  box-shadow: 0 12px 30px rgba(37, 37, 33, .12);
  transform: translateY(-2px);
}
.read-also-image { position: relative; display: block; min-height: 180px; overflow: hidden; background: var(--paper-deep); }
.read-also-image img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; transition: transform .5s ease;
}
.read-also-card:hover .read-also-image img { transform: scale(1.045); }
.read-also-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 22px 26px 20px; min-width: 0; }
.read-also-category { color: var(--ruby); font-size: .66rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.read-also-title {
  font: 600 clamp(1.2rem, 2.1vw, 1.5rem)/1.22 var(--serif);
  letter-spacing: -.025em; transition: color .2s ease;
}
.read-also-card:hover .read-also-title { color: var(--ruby); }
.read-also-desc {
  color: var(--muted); font-size: .86rem; line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;  /* Max 2 lines */
}
.read-also-cta {
  margin-top: auto; padding-bottom: 4px;
  border-bottom: 1px solid var(--ruby);
  color: var(--ruby); font-size: .78rem; font-weight: 700;
}

/* Smartphone: image on top, text below */
@media (max-width: 600px) {
  .article-body a.read-also-card { grid-template-columns: minmax(0, 1fr); }
  .read-also-image { min-height: 0; aspect-ratio: 16 / 9; }
  .read-also-copy { padding: 18px 18px 18px; }
}

/* Toast di successo con sfondo verde */
.newsletter-toast {
  position: fixed;
  top: 20px;
  left: 50%;
  /* Size to the text, but never wider than the viewport (avoids tall wrapped box on mobile) */
  width: max-content;
  max-width: calc(100% - 32px);
  /* Hidden by default: moved off-screen AND invisible, whatever its height */
  transform: translate(-50%, -200%);
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  z-index: 9999;
  background-color: #0ea900;
  color: #f7f4ed;
  padding: 12px 24px;
  border-radius: 4px;
  font-size: 0.9rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  text-align: center;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease, visibility 0s linear 0.4s;
}

/* Quando il body ha la classe 'subbed' (attivata dal parametro URL), il toast scende in cima */
body.subbed .newsletter-toast {
  transform: translate(-50%, 0);
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition-delay: 0s;
}
