/* ─── READING PROGRESS BAR ───────────────────────────────────────────────── */
.article-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: var(--green, #3aaa5c);
  z-index: 9999;
  transition: width 0.1s linear;
}

/* ─── COVER IMAGE (full, uncropped) ──────────────────────────────────────── */
.article-cover {
  margin-top: 70px;
  width: 100%;
  background: #f5f5f5;
  line-height: 0;
}

.article-cover__img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 560px;
  object-fit: contain;
  object-position: center top;
}

/* ─── ARTICLE HEADER (below image) ──────────────────────────────────────── */
.article-header {
  background: #fff;
  border-bottom: 1px solid #eef2ef;
  padding: 36px 24px 40px;
}

.article-header__inner {
  max-width: 900px;
  margin: 0 auto;
}

.article-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #666;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3px;
  margin-bottom: 20px;
  transition: color 0.2s;
}
.article-back svg { width: 15px; height: 15px; }
.article-back:hover { color: var(--green, #3aaa5c); }

.article-header__tag {
  display: inline-block;
  background: var(--green, #3aaa5c);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  margin-bottom: 16px;
}

.article-header__title {
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 900;
  color: #111;
  line-height: 1.18;
  margin: 0 0 18px;
  letter-spacing: -0.5px;
}

.article-header__meta {
  color: #888;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.article-header__dot { opacity: 0.4; }

/* ─── ARTICLE BODY ───────────────────────────────────────────────────────── */
.article-wrap {
  background: #fff;
  padding: 64px 24px 80px;
}

.article-body {
  max-width: 900px;
  margin: 0 auto;
  color: #222;
  font-size: 17px;
  line-height: 1.78;
}

.article-lead {
  font-size: 20px;
  line-height: 1.65;
  color: #333;
  font-weight: 500;
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 2px solid #eef2ef;
}

.article-body p { margin: 0 0 20px; }
.article-body p:last-child { margin-bottom: 0; }

/* ─── ERROR BLOCKS — STYLE A (left accent, light green bg) ──────────────── */
.article-error {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  margin: 52px 0;
  padding: 36px 36px 36px 32px;
  background: #f4fdf7;
  border-left: 4px solid var(--green, #3aaa5c);
  border-radius: 0 16px 16px 0;
}

.article-error__num {
  font-size: 64px;
  font-weight: 900;
  color: var(--green, #3aaa5c);
  line-height: 1;
  min-width: 68px;
  opacity: 0.22;
  flex-shrink: 0;
  margin-top: 2px;
  letter-spacing: -2px;
}

.article-error__content { flex: 1; min-width: 0; }

.article-error__content h2 {
  font-size: 22px;
  font-weight: 800;
  color: #111;
  margin: 0 0 14px;
  line-height: 1.3;
}

.article-error__content p { margin: 0 0 16px; }
.article-error__content p:last-child { margin-bottom: 0; }

/* ─── ERROR BLOCKS — STYLE B (card with badge, white bg, border) ─────────── */
.article-error--card {
  flex-direction: column;
  gap: 0;
  background: #fff;
  border-left: none;
  border: 1.5px solid #d4eedd;
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
}

.article-error--card .article-error__num {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--green, #3aaa5c);
  opacity: 1;
  min-width: unset;
  background: #edf9f2;
  padding: 12px 20px;
  border-bottom: 1.5px solid #d4eedd;
  margin: 0;
}

.article-error--card .article-error__num::before {
  content: attr(data-num);
  font-size: 28px;
  font-weight: 900;
  opacity: 0.35;
  letter-spacing: -1px;
}

.article-error--card .article-error__content {
  padding: 24px 28px;
}

.article-error--card .article-error__content h2 {
  font-size: 20px;
}

/* ─── ERROR BLOCKS — STYLE C (inline number, full-width, minimal) ────────── */
.article-error--inline {
  display: block;
  background: none;
  border-left: none;
  border-top: 2px solid #eef2ef;
  border-radius: 0;
  padding: 36px 0;
  margin: 36px 0;
}

.article-error--inline .article-error__num {
  display: inline;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--green, #3aaa5c);
  opacity: 1;
  min-width: unset;
  margin: 0 0 10px;
  line-height: 1;
}

.article-error--inline .article-error__content {
  display: block;
}

.article-error--inline .article-error__content h2 {
  font-size: 24px;
  margin-top: 8px;
}

/* ─── CALLOUT BOXES ──────────────────────────────────────────────────────── */
.article-callout {
  background: #edf9f2;
  border-left: 3px solid var(--green, #3aaa5c);
  border-radius: 0 10px 10px 0;
  padding: 16px 20px;
  margin: 20px 0 0;
  font-size: 15px;
  line-height: 1.65;
  color: #1a3a24;
}

.article-callout--warning {
  background: #fff8e8;
  border-left-color: #e0950a;
  color: #4a3000;
}

/* ─── STAT CALLOUTS (light, no dark bg) ─────────────────────────────────── */
.article-stat {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 28px 32px;
  margin: 28px 0;
  background: #f4fdf7;
  border: 1.5px solid #c6ecd5;
  border-radius: 14px;
}

.article-stat__number {
  font-size: 52px;
  font-weight: 900;
  color: var(--green, #3aaa5c);
  line-height: 1;
  flex-shrink: 0;
  letter-spacing: -1px;
}

.article-stat__label {
  font-size: 15px;
  color: #2a5c3a;
  line-height: 1.5;
  font-weight: 500;
}

/* ─── CONCLUSION ─────────────────────────────────────────────────────────── */
.article-conclusion {
  margin-top: 64px;
  padding-top: 48px;
  border-top: 2px solid #eef2ef;
}

.article-conclusion h2 {
  font-size: 28px;
  font-weight: 900;
  color: #111;
  margin: 0 0 20px;
  letter-spacing: -0.3px;
}

/* ─── POST CTA (card compatta, inline con articolo) ─────────────────────── */
.post-cta-wrap {
  background: #fff;
  padding: 0 24px 56px;
}

.post-cta {
  max-width: 900px;
  margin: 0 auto;
  background: var(--green, #3aaa5c);
  border-radius: 16px;
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.post-cta__text { flex: 1; }

.post-cta__title {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  line-height: 1.3;
}

.post-cta__sub {
  font-size: 13px;
  color: rgba(255,255,255,0.78);
  margin: 0;
  font-weight: 400;
}

.btn-cta {
  display: inline-block;
  background: #fff;
  color: var(--green, #3aaa5c);
  font-weight: 800;
  font-size: 14px;
  padding: 12px 24px;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

@media (max-width: 600px) {
  .post-cta {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 24px 20px;
  }
  .post-cta-wrap { padding-bottom: 40px; }
}

/* ─── ARTICOLI CORRELATI ─────────────────────────────────────────────────── */
.article-related {
  background: #f9fafb;
  padding: 64px 24px 72px;
  border-top: 1px solid #eef2ef;
}

.article-related__inner {
  max-width: 900px;
  margin: 0 auto;
}

.article-related__title {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--green, #3aaa5c);
  margin: 0 0 28px;
}

.article-related__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

@media (max-width: 680px) {
  .article-related { padding: 48px 16px 56px; }
  .article-related__grid { grid-template-columns: 1fr; gap: 14px; }
}
@media (max-width: 900px) and (min-width: 681px) {
  .article-related__grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── MOBILE ─────────────────────────────────────────────────────────────── */
@media (max-width: 680px) {
  .article-cover__img { max-height: 280px; object-fit: cover; object-position: center; }

  .article-header { padding: 28px 16px 32px; }

  .article-error {
    flex-direction: column;
    gap: 12px;
    padding: 24px 20px;
    margin: 36px 0;
  }
  .article-error__num {
    font-size: 40px;
    min-width: unset;
  }

  .article-stat {
    flex-direction: column;
    text-align: center;
    gap: 8px;
    padding: 24px 20px;
  }
  .article-stat__number { font-size: 44px; }

  .article-body { font-size: 16px; }
  .article-wrap { padding: 40px 16px 60px; }
  .article-error--inline { padding: 28px 0; }
}

/* ─── KEYWORD INLINE LINKS ───────────────────────────────────────────────── */
.article-kw-link {
  color: var(--green, #3aaa5c);
  text-decoration: underline;
  text-decoration-color: rgba(58,170,92,0.35);
  text-underline-offset: 2px;
  font-weight: inherit;
  transition: text-decoration-color 0.15s, color 0.15s;
}
.article-kw-link:hover {
  color: #2a8a47;
  text-decoration-color: rgba(58,170,92,0.8);
}

/* ─── GOOGLE AD STYLE INLINE BOX ─────────────────────────────────────────── */
.article-gad {
  margin: 36px 0;
  border: 1px solid #e8eaed;
  border-radius: 8px;
  padding: 18px 20px;
  background: #fff;
  position: relative;
}
.article-gad::before {
  content: 'Sponsorizzato';
  position: absolute;
  top: -1px; left: 16px;
  transform: translateY(-50%);
  background: #fff;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #70757a;
  padding: 0 6px;
  border: 1px solid #e8eaed;
  border-radius: 3px;
}
.article-gad__url {
  font-size: 12px;
  color: #202124;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.article-gad__url-favicon {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--green, #3aaa5c);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.article-gad__url-favicon svg { width: 10px; height: 10px; fill: #fff; }
.article-gad__url-domain { font-weight: 500; }
.article-gad__url-path { color: #70757a; }
.article-gad__title {
  font-size: 18px;
  font-weight: 400;
  color: #1a0dab;
  margin: 2px 0 6px;
  line-height: 1.3;
  text-decoration: none;
  display: block;
}
.article-gad__title:hover { text-decoration: underline; }
.article-gad__desc {
  font-size: 13.5px;
  color: #4d5156;
  line-height: 1.55;
  margin: 0 0 14px;
}
.article-gad__cta {
  display: inline-block;
  background: var(--green, #3aaa5c);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 20px;
  text-decoration: none;
  transition: background 0.15s;
}
.article-gad__cta:hover { background: #2a8a47; }
@media (max-width: 600px) {
  .article-gad { margin: 28px 0; }
  .article-gad__title { font-size: 16px; }
}

/* ─── ARTICLE → SERVICE LINK CARD ────────────────────────────────────────── */
.article-service-link {
  padding: 0 24px 40px;
}
.article-service-link .container {
  max-width: 900px;
}
.asl-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 28px;
  border-radius: 14px;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.asl-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0,0,0,0.18);
}
.asl-card__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.asl-card__eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.65);
}
.asl-card__name {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  line-height: 1.4;
}
.asl-card__btn {
  flex-shrink: 0;
  background: rgba(255,255,255,0.15);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.25);
  white-space: nowrap;
  backdrop-filter: blur(4px);
  transition: background 0.15s;
}
.asl-card:hover .asl-card__btn {
  background: rgba(255,255,255,0.25);
}
@media (max-width: 600px) {
  .asl-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 20px;
  }
  .asl-card__btn { width: 100%; text-align: center; }
  .article-service-link { padding: 0 16px 32px; }
}
