/* ============================================================
   SMC — Download (Area Download) page sections
   ============================================================ */

/* ---------- Hero (text only, on white) ---------- */
.dl-hero {
  padding-block: clamp(2.5rem, 5vw, 4.5rem) clamp(1.5rem, 3vw, 2.25rem);
}

.dl-hero__inner {
  display: flex;
  flex-direction: column;
  gap: clamp(1.25rem, 0.9rem + 1.4vw, 2.25rem);
}

.dl-hero__title {
  font-size: var(--fs-display); /* 32 -> 48, livello display */
  font-weight: var(--fw-semibold);
  line-height: 1.1;
  color: var(--text-heading);
}

.dl-hero__subtitle {
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.25rem); /* 18 -> 20, riga di supporto */
  font-weight: var(--fw-regular);
  line-height: 1.4;
  color: var(--text-heading);
}

.dl-hero__text {
  max-width: 72ch;
  font-size: var(--fs-body); /* 18, coerente col body del sito */
  color: var(--text-body);
  line-height: 1.5;
}

.dl-hero__text a {
  color: var(--navy-primary);
  font-weight: var(--fw-medium);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Downloads grid ---------- */
.downloads {
  padding-block: clamp(1rem, 2vw, 2rem) clamp(3rem, 7vw, 6rem);
}

/* Section heading above each group of cards (Cataloghi, Schede prodotto) */
.downloads__title {
  font-size: var(--fs-h2);
  font-weight: var(--fw-semibold);
  line-height: var(--lh-heading);
  color: var(--text-heading);
  margin-bottom: var(--space-6);
}

/* Space between consecutive card groups */
.downloads__group + .downloads__group {
  margin-top: clamp(2rem, 4vw, 3.5rem);
}

.downloads__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}

.dl-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  background: var(--surface-white);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: var(--space-6);
  transition: transform var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.dl-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px -12px rgba(18, 41, 96, 0.22);
  border-color: #d4dae6;
}

.dl-card__head {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dl-card__eyebrow {
  font-size: 0.75rem;
  font-weight: var(--fw-semibold);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.dl-card__brand {
  font-size: var(--fs-h3);
  font-weight: var(--fw-semibold);
  line-height: 1.3;
  color: var(--text-heading);
}

.dl-card__divider {
  border: 0;
  height: 1px;
  width: 100%;
  background: var(--border-subtle);
  margin-block: var(--space-2);
}

.dl-card__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.dl-card__link-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.dl-card__link {
  color: var(--navy-dark);
  font-weight: var(--fw-medium);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.dl-card__link:hover {
  text-decoration: none;
  color: var(--navy-primary);
}

/* Small language tag next to each catalogue link */
.dl-lang {
  font-size: 0.6875rem;
  font-weight: var(--fw-semibold);
  letter-spacing: 0.03em;
  color: var(--navy-primary);
  background: var(--surface-tint);
  border-radius: var(--radius-pill);
  padding: 2px 8px;
  line-height: 1.4;
  white-space: nowrap;
}

/* "Ultima modifica" pinned to the bottom so cards line up */
.dl-card__meta {
  margin-top: auto;
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  padding-top: var(--space-4);
}

.dl-card__meta-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.dl-card__meta-date {
  font-size: 0.875rem;
  font-weight: var(--fw-medium);
  color: var(--text-heading);
}

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .downloads__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .downloads__grid {
    grid-template-columns: 1fr;
  }
}
