/* Shared colors/fonts/ease/mx come from /tokens.css. Only this
   page's own overrides live here. */
:root {
  --sp: clamp(48px, 8vw, 96px);
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
html {
  height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  background: var(--ombra);
  color: var(--luce);
  font-family: var(--text);
  -webkit-font-smoothing: antialiased;
}
.wrap {
  max-width: 1400px;
  margin: 0 auto;
}
a {
  color: inherit;
}
main.wrap {
  flex: 1 0 auto;
  padding: var(--sp) var(--mx);
}
.eyebrow {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--oro);
}
h1.page-title {
  font-family: var(--display-xl);
  text-transform: uppercase;
  overflow-wrap: anywhere;
  hyphens: auto;
  font-weight: 700;
  font-size: clamp(21.6px, 3.6vw, 38.4px);
  letter-spacing: -0.015em;
  margin-top: 12px;
}
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: clamp(32px, 5vw, 56px);
}
@media (max-width: 900px) {
  .news-grid {
    grid-template-columns: 1fr;
  }
}
.news-card {
  display: block;
  background: var(--notte);
  border: 1px solid var(--grafite);
  text-decoration: none;
  transition: border-color 200ms var(--ease);
}
@media (hover: hover) {
  .news-card:hover {
    border-color: var(--nebbia);
  }
}
.news-card-img {
  position: relative;
  background: #0d0d0d;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}
.news-card-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.news-card-body {
  padding: 20px 22px 26px;
}
.news-card-meta {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cenere);
}
.news-card-title {
  font-family: var(--display);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.25;
  margin-top: 10px;
}
.news-card-teaser {
  font-size: 14px;
  line-height: 1.55;
  color: var(--nebbia);
  margin-top: 10px;
}
/* body is a flex column; keep the shared footer from being squashed */
footer {
  flex-shrink: 0;
}

/* Big titles are wide capitals: on phones keep them to ~8% of the
   screen width so long words (MONTERIGGIONI, COLLABORAZIONI) still fit. */
@media (max-width: 600px) {
  h1.page-title {
    font-size: min(21.6px, 4.8vw);
  }
}

/* 2026-10-29: room for the fixed main site header */
body {
  padding-top: 80px;
}

/* News / Press buttons */
.news-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: clamp(20px, 3vw, 32px);
}
.news-filter-btn {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--nebbia);
  background: transparent;
  border: 1px solid var(--grafite);
  border-radius: 999px;
  padding: 10px 20px;
  cursor: pointer;
  transition: border-color 200ms var(--ease), color 200ms var(--ease), background 200ms var(--ease);
}
.news-filter-btn:hover {
  border-color: var(--nebbia);
  color: var(--luce);
}
.news-filter-btn.is-active {
  background: var(--oro);
  border-color: var(--oro);
  color: #000;
}
.news-grid[data-filter="news"] .news-card[data-type="press"],
.news-grid[data-filter="press"] .news-card:not([data-type="press"]) {
  display: none;
}
.news-grid + .news-empty {
  margin-top: 24px;
  color: var(--cenere);
  font-size: 15px;
}

/* buttons moved into the fixed top bar (wide screens) */
.news-filter.in-header {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  z-index: 2;
}
.news-filter.in-header .news-filter-btn {
  padding: 8px 18px;
  background: rgba(0, 0, 0, 0.55);
}
.news-filter.in-header .news-filter-btn.is-active {
  background: var(--oro);
}
