/* Blog di Lavoretto. Intestazione, footer, bottoni, badge e variabili di colore vengono
   da /site-assets/site.css (caricato prima di questo file): qui c'è solo ciò che è
   proprio del blog, cioè indice e pagina articolo. I nomi delle classi sono quelli già
   presenti nei file HTML degli articoli. */

body { display: flex; flex-direction: column; min-height: 100vh; }
main { flex: 1; }
.container { width: 100%; max-width: calc(72rem + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- indice ---------- */
/* l'apertura dell'indice è la stessa fascia coral delle pagine statiche (.sp-hero in site.css) */
.blog-tools { display: grid; gap: .5rem; max-width: 36rem; margin: var(--head-gap) 0 2rem; }
.search-label { font-size: .9rem; font-weight: 600; }
.blog-tools input { padding: .9rem 1.2rem; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); font: inherit; }
.blog-tools input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(204, 65, 39, .14); }
.results-info { font-size: .9rem; color: var(--ink-soft); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; }
.card { display: flex; flex-direction: column; padding: 1rem 1rem 1.4rem; border-radius: 1.5rem; background: var(--tint); }
.card img { display: block; width: 100%; height: 11rem; margin-bottom: 1rem; border-radius: 1rem; object-fit: cover; }
.chip { align-self: flex-start; margin: 0 .4rem .7rem; padding: .3rem .75rem; border-radius: 999px; background: #fff; color: var(--deep); font-size: .78rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.card h2 { margin: 0 .4rem .5rem; font-size: var(--fs-card); font-weight: 600; line-height: 1.3; }
.card p { margin: 0 .4rem 1rem; font-size: var(--fs-small); line-height: 1.55; color: var(--ink-soft); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.read { margin: auto .4rem -.6rem; padding: .6rem 0; color: var(--deep); font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }

.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .6rem; margin: 2.5rem 0 1rem; }
.page-numbers { display: inline-flex; flex-wrap: wrap; gap: .5rem; }
.page-btn, .page-num { min-width: 2.75rem; min-height: 2.75rem; padding: .65rem 1rem; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); font: 600 .95rem/1 'Poppins', system-ui, sans-serif; cursor: pointer; }
.page-btn:hover:not(:disabled), .page-num:hover { border-color: var(--brand); color: var(--deep); }
.page-btn:disabled { opacity: .45; cursor: not-allowed; }
.page-num.active { border-color: var(--brand); background: var(--brand); color: #fff; }

.blog-app { margin: clamp(2.5rem, 6vh, 4rem) 0 clamp(3rem, 8vh, 5rem); padding: clamp(1.75rem, 4vw, 3rem); border-radius: 2rem; background: var(--peach); text-align: center; }
.blog-app .sp-stores { justify-content: center; }
.blog-app h2 { margin-bottom: 1.25rem; font-family: 'Tanker', sans-serif; font-weight: 400; font-size: var(--fs-h2); line-height: .98; text-transform: uppercase; color: var(--brand); }

/* ---------- articolo ---------- */
.article { padding: clamp(2rem, 5vh, 3.5rem) var(--gutter) clamp(3.5rem, 9vh, 6rem); }
.article .box { max-width: 46rem; margin: 0 auto; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.25rem; font-size: .88rem; color: var(--ink-soft); }
.breadcrumbs a { color: var(--deep); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.breadcrumbs span[aria-hidden] { opacity: .55; }
.article h1 { font-family: 'Tanker', 'Poppins', sans-serif; font-weight: 400; font-size: clamp(2.3rem, 5.6vw, 4rem); line-height: .97; text-transform: uppercase; text-wrap: balance; color: var(--brand); }
.meta { margin: 1.1rem 0 1.75rem; font-size: .9rem; color: var(--ink-soft); }
.article-hero { display: block; width: 100%; height: clamp(12rem, 34vw, 21rem); margin-bottom: 1.75rem; border-radius: 1.5rem; object-fit: cover; }
.article .article-lead { font-size: var(--fs-title); line-height: 1.65; color: var(--ink); }
.article h2 { margin: 2.5rem 0 .8rem; font-size: clamp(1.35rem, 2.4vw, 1.65rem); font-weight: 600; line-height: 1.25; }
.article h3 { margin: 1.6rem 0 .5rem; font-size: 1.12rem; font-weight: 600; line-height: 1.3; }
.article p, .article li { font-size: 1.0625rem; line-height: 1.75; color: var(--ink-soft); }
.article p + p { margin-top: 1rem; }
.article .box > ul { display: grid; gap: .55rem; margin-top: .25rem; padding-left: 1.3rem; list-style: disc; }
.article .box > ul li::marker { color: var(--brand); }
.article p a { color: var(--deep); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

.article-cta { display: grid; justify-items: start; gap: 1.1rem; margin-top: 2.75rem; padding: clamp(1.5rem, 3vw, 2.25rem); border-radius: 1.5rem; background: var(--peach); }
.article-cta p { font-size: 1.1rem; font-weight: 500; color: var(--ink); }

.related-posts { margin-top: 2.75rem; padding-top: 1.75rem; border-top: 1.5px solid var(--line); }
.related-posts h2 { margin: 0 0 1rem; font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--brand); }
.related-posts ul { display: grid; gap: .7rem; }
.related-posts a { color: var(--ink); font-weight: 600; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--peach-2); }
.related-posts a:hover { color: var(--brand); text-decoration-color: var(--brand); }

/* su telefono i bottoni principali sono a tutta larghezza, come nelle pagine statiche */
@media (max-width: 560px) {
  .article-cta, .article-cta .sp-btn { width: 100%; }
}
