:root {
  /* Palette enti Casa Zanussi (non Federsanità) */
  --cz-ink: #212121;
  --cz-muted: #666666;
  --cz-paper: #ffffff;
  --cz-surface: #ffffff;
  --cz-accent: #4C4C49;
  --cz-accent-deep: #21211F;
  --cz-accent-soft: #E9E9E9;
  --cz-accent-mid: #888;
  --cz-line: #dddddd;
  --cz-header: #4C4C49;
  --cz-header-deep: #21211F;
  --cz-serif: "Source Serif 4", Georgia, serif;
  --cz-sans: "Source Sans 3", system-ui, sans-serif;
  --cz-prose: var(--cz-sans);
  --cz-prose-plex: "IBM Plex Sans", var(--cz-sans);
  --cz-prose-franklin: "Libre Franklin", var(--cz-sans);
  --cz-prose-literata: "Literata", var(--cz-serif);
  --cz-prose-lora: "Lora", var(--cz-serif);
}

body.section-casa-zanussi {
  --cz-accent: #4C4C49;
  --cz-accent-deep: #21211F;
  --cz-accent-soft: #E9E9E9;
  --cz-header: #4C4C49;
  --cz-header-deep: #21211F;
}
body.section-cicp {
  --cz-accent: #C41C01;
  --cz-accent-deep: #891501;
  --cz-accent-soft: #FFEEEA;
  --cz-header: #C41C01;
  --cz-header-deep: #891501;
}
body.section-irse {
  --cz-accent: #699D3B;
  --cz-accent-deep: #3a5621;
  --cz-accent-soft: #E7EFDF;
  --cz-header: #699D3B;
  --cz-header-deep: #3a5621;
}
body.section-pec {
  --cz-accent: #DF9D09;
  --cz-accent-deep: #a27306;
  --cz-accent-soft: #FEF4DE;
  --cz-header: #DF9D09;
  --cz-header-deep: #a27306;
}
body.section-ute {
  --cz-accent: #B51E7D;
  --cz-accent-deep: #751351;
  --cz-accent-soft: #FCEBF5;
  --cz-header: #B51E7D;
  --cz-header-deep: #751351;
}
body.section-civitas {
  --cz-accent: #e94e1d;
  --cz-accent-deep: #b33814;
  --cz-accent-soft: #FFEEEA;
  --cz-header: #e94e1d;
  --cz-header-deep: #b33814;
}
body.section-fc7 {
  --cz-accent: #0166B0;
  --cz-accent-deep: #014a80;
  --cz-accent-soft: #E6F2FA;
  --cz-header: #0166B0;
  --cz-header-deep: #014a80;
}

.enti-bar {
  background: #fff;
  border-bottom: 1px solid var(--cz-line);
}
.enti-bar-inner {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: space-between;
  gap: 0.35rem;
  overflow-x: auto;
}
.enti-link {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 0.35rem 0.55rem;
  text-decoration: none;
  color: var(--cz-ink);
  border-bottom: 4px solid transparent;
}
.enti-link img {
  height: 96px;
  width: auto;
  max-width: 124px;
  object-fit: contain;
}
@media (min-width: 1200px) {
  .enti-bar .container {
    max-width: 1200px;
  }
  .enti-link {
    padding: 0.35rem 0.25rem 0.25rem;
  }
  .enti-link img {
    height: 125px;
    max-width: none;
  }
}
.enti-link-name {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cz-muted);
}
.enti-link.is-active,
.enti-link:hover,
.enti-link:focus-visible {
  border-bottom-color: var(--enti-color, var(--cz-accent));
}
.org-chip {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: var(--org-soft, var(--cz-accent-soft));
  color: var(--org-accent, var(--cz-accent-deep));
}
.event-card-org { margin-bottom: 0.35rem; }
.home-upcoming-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.home-event-card {
  display: block;
  background: #fff;
  border: 1px solid var(--cz-line);
  border-left: 4px solid var(--org-accent, var(--cz-accent));
  padding: 1rem 1.1rem;
  text-decoration: none;
  color: inherit;
  height: 100%;
}
.home-event-card:hover { box-shadow: 0 6px 18px rgba(0,0,0,0.08); color: inherit; }


html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--cz-sans);
  color: var(--cz-ink);
  background: var(--cz-paper);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1 0 auto;
}

h1, h2, h3, .brand-mark, .hero-title {
  font-family: var(--cz-serif);
  letter-spacing: -0.02em;
  color: var(--cz-accent-deep);
}

a {
  color: var(--cz-accent);
}

a:hover {
  color: var(--cz-accent-deep);
}

.site-header {
  background: linear-gradient(180deg, var(--cz-header) 0%, var(--cz-header-deep) 100%);
  color: #fff;
  position: relative;
  z-index: 1030;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
}

.site-header .navbar {
  --bs-navbar-color: rgba(255, 255, 255, 0.92);
  --bs-navbar-hover-color: #fff;
  --bs-navbar-active-color: #fff;
  --bs-navbar-brand-color: #fff;
  --bs-navbar-brand-hover-color: #fff;
  padding-block: 0.75rem;
}

@media (max-width: 991.98px) {
  .site-header .navbar > .container {
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.35rem;
  }

  .site-header .navbar {
    padding-block: 0.55rem;
  }

  .site-header .navbar-toggler {
    margin-left: auto;
  }

  .site-header .brand-mobile {
    max-width: calc(100% - 3.25rem);
  }
}

.navbar-brand {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.85rem;
  line-height: 1.1;
  min-width: 0;
}

.brand-logo {
  height: 3.5rem;
  width: auto;
  display: block;
  flex-shrink: 0;
  border-radius: 0.35rem;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.85), 0 2px 10px rgba(0, 0, 0, 0.2);
  background: #fff;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.brand-mark {
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
}

.brand-sub {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.85;
  font-family: var(--cz-sans);
  color: #fff;
}

.brand-mobile {
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  flex: 1 1 auto;
  margin-right: 0.5rem;
}

.brand-mobile-home {
  display: flex;
  align-items: center;
  min-width: 0;
  flex: 1 1 auto;
  text-decoration: none;
  color: #fff;
}

.brand-mobile-logo-btn {
  position: relative;
  flex: 0 0 auto;
  width: 2.85rem;
  height: 2.85rem;
  padding: 0;
  border: 0;
  border-radius: 0.55rem;
  background: #fff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.95);
  cursor: pointer;
  overflow: hidden;
}

.brand-mobile-logo-btn:hover,
.brand-mobile-logo-btn:focus-visible {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px rgba(255, 255, 255, 0.35);
}

.brand-mobile-logo-btn .brand-mobile-logo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  padding: 0.28rem;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

.brand-mobile-logo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #21211F;
  font-family: var(--cz-sans);
}

.brand-mobile-logo-caret {
  position: absolute;
  right: 0.12rem;
  top: 50%;
  width: 0;
  height: 0;
  border-left: 0.28rem solid transparent;
  border-right: 0.28rem solid transparent;
  border-top: 0.34rem solid #21211F;
  transform: translateY(-50%);
  filter: drop-shadow(0 0 1px #fff) drop-shadow(0 0 1px #fff);
}

.brand-mobile-logo {
  width: 2.75rem;
  height: 2.75rem;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 0.55rem;
  background: #fff;
  padding: 0.2rem;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.9);
}

.brand-mobile-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.brand-mobile-name {
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.brand-mobile-sub {
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.8;
  font-family: var(--cz-sans);
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.enti-picker {
  --bs-offcanvas-height: min(88vh, 40rem);
  --bs-offcanvas-bg: #fff;
  --bs-offcanvas-color: var(--cz-ink);
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
}

.enti-picker-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.enti-picker-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1rem;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--cz-line);
  border-radius: 0.75rem;
  border-left: 5px solid var(--enti-color, var(--cz-accent));
  background: #fff;
  min-height: 5.5rem;
}

.enti-picker-item:hover,
.enti-picker-item:focus-visible {
  background: color-mix(in srgb, var(--enti-color, var(--cz-accent)) 8%, #fff);
  color: inherit;
}

.enti-picker-item.is-active {
  background: color-mix(in srgb, var(--enti-color, var(--cz-accent)) 12%, #fff);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--enti-color, var(--cz-accent)) 35%, transparent);
}

.enti-picker-logo {
  flex: 0 0 auto;
  width: 5.5rem;
  height: 5.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 0.5rem;
  border: 1px solid var(--cz-line);
  padding: 0.35rem;
}

.enti-picker-logo img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}

.enti-picker-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.enti-picker-name {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--cz-ink);
}

.enti-picker-short {
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cz-muted);
  font-family: var(--cz-sans);
}

.navbar-toggler {
  border-color: rgba(255, 255, 255, 0.55);
  flex-shrink: 0;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.offcanvas,
.offcanvas-sm,
.offcanvas-md,
.offcanvas-lg,
.offcanvas-xl,
.offcanvas-xxl {
  --bs-offcanvas-bg: var(--cz-header-deep);
  --bs-offcanvas-color: #fff;
}

.offcanvas.enti-picker {
  --bs-offcanvas-bg: #fff;
  --bs-offcanvas-color: var(--cz-ink);
}

#navOffcanvas .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
  opacity: 1;
}

.enti-picker .btn-close {
  filter: none;
  opacity: 0.7;
}

@media (max-width: 991.98px) {
  #navOffcanvas {
    background-color: var(--cz-header-deep);
    color: #fff;
  }

  #navOffcanvas .nav-link {
    color: rgba(255, 255, 255, 0.92);
  }

  #navOffcanvas .nav-link:hover,
  #navOffcanvas .nav-link:focus,
  #navOffcanvas .nav-link.active {
    color: #fff;
  }

  #navOffcanvas .offcanvas-title {
    color: #fff;
  }
}

.nav-link.active {
  text-decoration: underline;
  text-underline-offset: 0.35em;
}

.site-header .navbar-nav > .nav-item.dropdown > .dropdown-toggle {
  border: 0;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.site-header .navbar-nav > .nav-item.dropdown > .dropdown-toggle::after {
  margin-left: 0.15rem;
  transition: transform 0.15s ease;
}

.site-header .dropdown-menu {
  --bs-dropdown-bg: var(--cz-header-deep);
  --bs-dropdown-link-color: rgba(255, 255, 255, 0.92);
  --bs-dropdown-link-hover-bg: color-mix(in srgb, var(--cz-header) 70%, #000);
  --bs-dropdown-link-hover-color: #fff;
  --bs-dropdown-link-active-bg: color-mix(in srgb, var(--cz-header) 55%, #000);
  --bs-dropdown-link-active-color: #fff;
  --bs-dropdown-border-color: rgba(255, 255, 255, 0.12);
  min-width: 14rem;
  padding: 0.4rem 0;
  margin-top: 0;
  border-radius: 0.35rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.site-header .dropdown-item {
  padding: 0.45rem 1rem;
  font-size: 0.95rem;
  white-space: normal;
}

.site-header .dropdown-item.active {
  font-weight: 600;
}

@media (min-width: 992px) {
  .site-header .navbar .dropdown:hover > .dropdown-menu {
    display: block;
  }

  .site-header .navbar .dropdown:hover > .dropdown-toggle {
    color: #fff;
  }
}

@media (max-width: 991.98px) {
  .site-header .navbar-nav {
    align-items: stretch;
    width: 100%;
    gap: 0;
  }

  .site-header .navbar-nav > .nav-item {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .site-header .navbar-nav > .nav-item.dropdown {
    width: 100%;
    flex-wrap: wrap;
  }

  .site-header .navbar-nav > .nav-item.dropdown > .dropdown-toggle {
    width: 100%;
    justify-content: space-between;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
    text-align: left;
  }

  .site-header .navbar-nav > .nav-item.dropdown > .dropdown-toggle[aria-expanded="true"]::after {
    transform: rotate(180deg);
  }

  .site-header .navbar-nav > .nav-item > .nav-link {
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
  }

  .site-header .dropdown-menu {
    position: static !important;
    transform: none !important;
    float: none;
    width: 100%;
    margin: 0;
    padding: 0.15rem 0 0.5rem;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: color-mix(in srgb, var(--cz-header-deep) 88%, #000);
  }

  .site-header .dropdown-item {
    padding: 0.65rem 1rem 0.65rem 1.5rem;
  }

  .site-header .navbar-nav > .nav-item:last-child {
    border-bottom: 0;
    margin-top: 0.75rem;
  }
}

.hero-eyebrow {
  letter-spacing: 0.14em;
}

.hero {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(120deg, color-mix(in srgb, var(--cz-header-deep) 92%, #000) 0%, var(--cz-header) 55%, var(--cz-accent-mid) 100%),
    url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.08'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  color: #fff;
  padding: clamp(3rem, 8vw, 5.5rem) 0;
}

.hero .hero-title,
.hero .hero-subtitle,
.hero .hero-eyebrow {
  color: #fff;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 700;
  max-width: 18ch;
  margin-bottom: 0.75rem;
  animation: rise-in 0.7s ease-out both;
}

.hero-subtitle {
  font-size: 1.15rem;
  opacity: 0.95;
  max-width: 36ch;
  animation: rise-in 0.7s ease-out 0.12s both;
}

.hero-cta {
  animation: rise-in 0.7s ease-out 0.24s both;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.section {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
}

.home-quicklinks {
  background: var(--cz-accent-soft);
  border-bottom: 1px solid var(--cz-line);
  padding: 2rem 0 1.5rem;
}
.home-quicklinks-intro {
  font-family: var(--cz-serif);
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-style: italic;
  line-height: 1.45;
  color: var(--cz-ink);
  max-width: 40rem;
  margin: 0 auto 1.5rem;
  text-align: center;
}
.home-quicklinks-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}
@media (min-width: 768px) {
  .home-quicklinks-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 1.5rem;
  }
}
.home-quicklinks-list li {
  border-top: 1px solid color-mix(in srgb, var(--cz-accent) 28%, var(--cz-line));
}
.home-quicklinks-list a {
  display: block;
  padding: 0.95rem 0.15rem;
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-weight: 600;
  color: var(--cz-accent);
  text-decoration: none;
  text-align: center;
}
.home-quicklinks-list a:hover,
.home-quicklinks-list a:focus-visible {
  color: var(--cz-accent-deep);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.home-evidenza {
  padding-top: 1.75rem;
  padding-bottom: 1.75rem;
}
.home-evidenza-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem 1.25rem;
}
.home-evidenza-item {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}
.home-evidenza-item:hover .home-evidenza-title {
  color: var(--cz-accent-deep);
}
.home-evidenza-thumb {
  width: 100%;
}
.home-evidenza-thumb img,
.home-evidenza-thumb-ph {
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  object-fit: cover;
  background: var(--cz-accent-soft);
  display: block;
}
.home-evidenza-title {
  font-family: var(--cz-sans);
  font-size: clamp(0.72rem, 1.5vw, 0.95rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cz-accent);
  margin: 0 0 0.25rem;
  line-height: 1.25;
}
.home-evidenza-text {
  margin: 0;
  font-size: clamp(0.75rem, 1.4vw, 0.9rem);
  line-height: 1.4;
  color: var(--cz-ink);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (min-width: 992px) {
  .home-evidenza-item {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 0.75rem 0.9rem;
    align-items: center;
  }
  .home-evidenza-thumb,
  .home-evidenza-thumb img,
  .home-evidenza-thumb-ph {
    width: 96px;
    height: 96px;
    aspect-ratio: auto;
  }
  .home-evidenza-title {
    margin: 0;
  }
}

.section-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 0.35rem;
}

.section-lead {
  color: var(--cz-muted);
  max-width: 50ch;
  margin-bottom: 1.75rem;
}

.news-item {
  border-bottom: 1px solid var(--cz-line);
  padding: 1rem 0;
  transition: transform 0.2s ease;
}

.news-item:hover {
  transform: translateX(4px);
}

.news-item time {
  color: var(--cz-muted);
  font-size: 0.875rem;
}

.news-item a {
  text-decoration: none;
  color: inherit;
  font-weight: 600;
}

.news-item a:hover {
  color: var(--cz-accent);
}

.home-agenda-list {
  padding: 2rem 0 2.5rem;
  background: #fff;
  border-top: 1px solid var(--cz-line);
}
.home-agenda-list-title {
  font-family: var(--cz-serif);
  font-size: clamp(1.2rem, 2.2vw, 1.5rem);
  font-weight: 700;
  color: var(--cz-accent);
  margin: 0 0 1rem;
}
.home-agenda-list-items {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.35rem;
}
@media (min-width: 768px) {
  .home-agenda-list-items {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
}
@media (min-width: 992px) {
  .home-agenda-list-items {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.6rem;
  }
}
@media (min-width: 1200px) {
  .home-agenda-list-items {
    grid-template-columns: repeat(4, 1fr);
  }
}
.home-agenda-list-items li {
  min-width: 0;
}
.home-agenda-list-items a {
  display: block;
  height: 100%;
  text-decoration: none;
  padding: 0.85rem 1rem 0.95rem;
  background: color-mix(in srgb, var(--cz-accent-soft) 70%, #fff);
  color: inherit;
}
.home-agenda-list-items a:hover h3 {
  color: var(--cz-accent-deep);
}
.home-agenda-list-items h3 {
  font-family: var(--cz-sans);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--cz-accent);
  margin: 0 0 0.2rem;
  line-height: 1.3;
}
.home-agenda-list-items time {
  display: block;
  font-size: 0.9rem;
  color: var(--cz-muted);
}

.home-agenda-curated {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.6rem;
}
@media (min-width: 768px) {
  .home-agenda-curated {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1200px) {
  .home-agenda-curated {
    grid-template-columns: repeat(3, 1fr);
  }
}
.home-agenda-curated-item {
  margin: 0;
  padding: 0.95rem 1rem 1.05rem;
  background: color-mix(in srgb, var(--cz-accent-soft) 70%, #fff);
}
.home-agenda-curated p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--cz-ink);
}
.home-agenda-curated p + p {
  margin-top: 0.4rem;
}
.home-agenda-curated a {
  color: var(--cz-accent);
  font-weight: 700;
  text-decoration: none;
}
.home-agenda-curated a:hover {
  color: var(--cz-accent-deep);
  text-decoration: underline;
}

/* Elenco cronologico (notizie / convegni) */
.news-archive {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.55rem;
}

.news-archive-link {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--cz-accent-deep);
  border: 1px solid var(--cz-line);
  background: var(--cz-surface);
}

.news-archive-link:hover {
  border-color: var(--cz-accent);
  color: var(--cz-accent-deep);
}

.news-archive-link.is-active {
  background: var(--cz-accent-deep);
  border-color: var(--cz-accent-deep);
  color: #fff;
}

.news-listing {
  max-width: 42rem;
}

.news-listing-item {
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--cz-line);
}

.news-listing-item:first-child {
  padding-top: 0.25rem;
}

.news-listing-date {
  display: block;
  font-size: 0.875rem;
  color: var(--cz-muted);
  text-transform: lowercase;
  margin-bottom: 0.35rem;
}

.news-listing-title {
  font-family: var(--cz-serif);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
  overflow-wrap: anywhere;
}

.news-listing-title a {
  text-decoration: none;
  color: var(--cz-ink);
}

.news-listing-title a:hover {
  color: var(--cz-accent-deep);
}

.news-listing-excerpt {
  margin: 0.45rem 0 0;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--cz-muted);
}

/* Ricerca */
.search-summary {
  margin: 0 0 1.75rem;
  padding: 0.85rem 1rem;
  background: var(--cz-accent-soft);
  border-left: 4px solid var(--cz-accent);
  color: var(--cz-ink);
  font-size: 1rem;
}

.search-summary a {
  font-weight: 600;
  text-decoration: none;
}

.search-summary a:hover {
  text-decoration: underline;
}

.search-section {
  margin-bottom: 2.5rem;
}

.search-section-title {
  font-family: var(--cz-sans);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--cz-accent-deep);
  margin: 0 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--cz-accent);
}

.search-section-count {
  font-weight: 600;
  color: var(--cz-muted);
  font-size: 0.95rem;
}

.search-result-item {
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--cz-line);
}

.search-result-title {
  font-family: var(--cz-sans);
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
  line-height: 1.35;
}

.search-result-title a {
  text-decoration: none;
  color: var(--cz-ink);
}

.search-result-title a:hover {
  color: var(--cz-accent-deep);
}

.search-result-meta {
  display: block;
  margin: 0;
  font-size: 0.85rem;
  color: var(--cz-muted);
}

.search-result-excerpt {
  margin: 0.35rem 0 0;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--cz-muted);
}

.search-doc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

@media (min-width: 768px) {
  .search-doc-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .search-doc-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
  }
}

.search-doc-card {
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  padding: 0.9rem 1rem;
  min-height: 100%;
}

.search-doc-card .search-result-title {
  font-size: 0.98rem;
}

.search-doc-link {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  text-decoration: none;
  color: var(--cz-ink);
}

.search-doc-link:hover {
  color: var(--cz-accent-deep);
}

.search-doc-icon {
  flex: 0 0 auto;
  margin-top: -0.1rem;
  color: var(--cz-accent);
}

.search-doc-name {
  flex: 1 1 auto;
  min-width: 0;
}

.search-doc-card .search-result-meta {
  margin-top: 0.4rem;
}

.search-doc-card .search-result-meta a {
  color: var(--cz-muted);
  text-decoration: none;
}

.search-doc-card .search-result-meta a:hover {
  color: var(--cz-accent-deep);
  text-decoration: underline;
}

.search-pager {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
  margin-top: 1rem;
  font-size: 0.9rem;
}

.search-pager a {
  font-weight: 600;
  text-decoration: none;
}

/* Griglia card (atti e convegni) */
.event-card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 768px) {
  .event-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .event-card-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

.event-card {
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  height: 100%;
}

.event-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.event-card-link:hover .event-card-title {
  color: var(--cz-accent-deep);
}

.event-card-date {
  display: block;
  margin: 0;
  padding: 0.75rem 1rem;
  background: var(--cz-accent);
  color: #fff;
  font-family: var(--cz-sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.3;
}

.event-card-date--empty {
  background: var(--cz-muted);
}

.event-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  flex: 1;
  padding: 1.1rem 1.15rem 1.25rem;
  background: var(--cz-surface);
}

.event-card-title {
  font-family: var(--cz-sans);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  margin: 0;
  color: var(--cz-ink);
  overflow-wrap: anywhere;
}

.event-card-excerpt {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.45;
  color: var(--cz-muted);
}

.project-link {
  display: block;
  padding: 1rem 0;
  border-bottom: 1px solid var(--cz-line);
  text-decoration: none;
  color: inherit;
  font-weight: 600;
}

.project-link:hover {
  color: var(--cz-accent);
}

.project-link .summary {
  display: block;
  font-weight: 400;
  color: var(--cz-muted);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

.calendar-table th,
.calendar-table td {
  width: 14.28%;
  vertical-align: top;
  height: 4.5rem;
  font-size: 0.85rem;
}

.calendar-table .has-event {
  background: var(--cz-accent-soft);
}

.calendar-table .day-num {
  font-weight: 700;
  color: var(--cz-accent-deep);
}

.event-chip {
  display: block;
  font-size: 0.7rem;
  line-height: 1.2;
  color: var(--cz-accent-deep);
  text-decoration: none;
  margin-top: 0.2rem;
}

/* —— Calendario agenda (pagina /agenda/) —— */
.agenda-page-header {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0.5rem;
}

.cal-month-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

.cal-month-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  text-decoration: none;
  color: var(--cz-accent-deep);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--cz-line);
  background: var(--cz-surface);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.cal-month-nav-btn:hover {
  border-color: var(--cz-accent);
  background: var(--cz-accent-soft);
  color: var(--cz-accent-deep);
}

.cal-month-nav-btn span[aria-hidden] {
  font-size: 1.35rem;
  line-height: 1;
  font-weight: 400;
}

.cal-month-current {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-width: 10rem;
}

.cal-month-name {
  font-family: var(--cz-serif);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  color: var(--cz-accent-deep);
  text-transform: capitalize;
  line-height: 1.1;
}

.cal-month-year {
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  color: var(--cz-muted);
  font-weight: 600;
}

.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.1rem;
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
  font-size: 0.85rem;
}
.cal-legend li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--cz-muted);
}
.cal-legend-dot {
  display: inline-block;
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  flex-shrink: 0;
}

.cal {
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  overflow: hidden;
}

.cal-weekdays,
.cal-week {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.cal-weekdays {
  background: linear-gradient(180deg, var(--cz-accent-deep) 0%, var(--cz-header) 100%);
  color: #fff;
}

.cal-weekdays > div {
  padding: 0.75rem 0.5rem;
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
}

.cal-week + .cal-week {
  border-top: 1px solid var(--cz-line);
}

.cal-day {
  min-height: 8.5rem;
  padding: 0.55rem 0.45rem 0.65rem;
  border-right: 1px solid var(--cz-line);
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.cal-day:last-child {
  border-right: none;
}

.cal-day--empty {
  background:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 4px,
      rgba(0, 0, 0, 0.02) 4px,
      rgba(0, 0, 0, 0.02) 5px
    );
  min-height: 8.5rem;
}

.cal-day--has-events {
  background: linear-gradient(180deg, var(--cz-accent-soft) 0%, #fff 55%);
}

.cal-day--today {
  box-shadow: inset 0 0 0 2px var(--cz-accent);
}

.cal-day--today .cal-day-num {
  background: var(--cz-accent);
  color: #fff;
}

.cal-day-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
}

.cal-day-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--cz-accent-deep);
}

.cal-day-events {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
  min-height: 0;
}

.cal-event {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  text-decoration: none;
  color: var(--cz-ink);
  background: #fff;
  border: 1px solid var(--cz-line);
  border-left: 3px solid var(--org-accent, var(--cz-accent));
  padding: 0.4rem 0.45rem;
  font-size: 0.72rem;
  line-height: 1.3;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.cal-event:hover {
  border-color: var(--cz-accent);
  background: var(--cz-accent-soft);
  color: var(--cz-accent-deep);
  transform: translateY(-1px);
}

.cal-event-dot {
  flex: 0 0 auto;
  width: 0.4rem;
  height: 0.4rem;
  margin-top: 0.28rem;
  border-radius: 50%;
  background: var(--org-accent, var(--cz-accent));
}

.cal-event-title {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-weight: 600;
}

.agenda-month-list {
  margin-top: 2.75rem;
  padding-top: 2rem;
  border-top: 1px solid var(--cz-line);
}

.agenda-month-list-title {
  font-size: 1.25rem;
  margin: 0 0 1.5rem;
}

.agenda-timeline-day {
  display: grid;
  grid-template-columns: 4.25rem 1fr;
  gap: 1.25rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--cz-line);
}

.agenda-timeline-day:first-child {
  padding-top: 0;
}

.agenda-timeline-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 0.15rem;
}

.agenda-timeline-daynum {
  font-family: var(--cz-serif);
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--cz-accent-deep);
  line-height: 1;
}

.agenda-timeline-month {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cz-muted);
  font-weight: 700;
  margin-top: 0.2rem;
}

.agenda-timeline-events {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.agenda-timeline-link {
  display: block;
  text-decoration: none;
  color: var(--cz-ink);
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.35;
  padding: 0.75rem 1rem;
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  border-left: 4px solid var(--org-accent, var(--cz-accent));
  transition: border-color 0.15s ease, background 0.15s ease;
}

.agenda-timeline-link:hover {
  color: var(--cz-accent-deep);
  border-color: var(--org-accent, var(--cz-accent));
  background: var(--org-soft, var(--cz-accent-soft));
}

@media (max-width: 991.98px) {
  .cal-day {
    min-height: 6.5rem;
    padding: 0.4rem 0.3rem 0.5rem;
  }

  .cal-event-title {
    -webkit-line-clamp: 2;
    font-size: 0.65rem;
  }

  .cal-month-nav-label {
    display: none;
  }
}

@media (max-width: 575.98px) {
  .cal-weekdays > div {
    font-size: 0.62rem;
    padding: 0.5rem 0.15rem;
  }

  .cal-day {
    min-height: 4.75rem;
  }

  .cal-event-title {
    -webkit-line-clamp: 1;
  }

  .agenda-timeline-day {
    grid-template-columns: 3.25rem 1fr;
    gap: 0.85rem;
  }
}

.page-header {
  padding: 2rem 0 1rem;
  border-bottom: 1px solid var(--cz-line);
  margin-bottom: 2rem;
}

.page-header h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

.prose {
  max-width: 68ch;
  font-family: var(--cz-prose);
  font-optical-sizing: auto;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.75;
}

body.prose-font-source {
  --cz-prose: var(--cz-sans);
}

body.prose-font-plex {
  --cz-prose: var(--cz-prose-plex);
}

body.prose-font-franklin {
  --cz-prose: var(--cz-prose-franklin);
}

body.prose-font-literata {
  --cz-prose: var(--cz-prose-literata);
}

body.prose-font-lora {
  --cz-prose: var(--cz-prose-lora);
}

.prose img {
  max-width: 100%;
  height: auto;
}

/* Allineamento immagini Plone (class left/right) → format Wagtail */
.prose .richtext-image.left,
.prose img.left,
.legacy-html img.left {
  float: left;
  max-width: 50%;
  height: auto;
  margin: 0.35em 1em 0.75em 0;
}

.prose .richtext-image.right,
.prose img.right,
.legacy-html img.right {
  float: right;
  max-width: 50%;
  height: auto;
  margin: 0.35em 0 0.75em 1em;
}

.prose .richtext-image.full-width,
.prose .richtext-image.fullwidth {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 1rem 0;
}

.prose::after {
  content: "";
  display: table;
  clear: both;
}

@media (max-width: 767.98px) {
  .prose .richtext-image.left,
  .prose .richtext-image.right,
  .prose img.left,
  .prose img.right,
  .legacy-html img.left,
  .legacy-html img.right {
    float: none;
    display: block;
    max-width: 100%;
    margin: 1rem 0;
  }
}

.site-footer {
  background: #21211F;
  color: rgba(255, 255, 255, 0.9);
}

.site-footer a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.site-footer a:hover {
  color: #fff;
  opacity: 0.85;
}

.footer-brand {
  font-family: var(--cz-serif);
  font-size: 1.15rem;
  color: #fff;
}

.footer-meta {
  font-size: 0.95rem;
}

.btn-accent {
  --bs-btn-bg: var(--cz-accent);
  --bs-btn-border-color: var(--cz-accent);
  --bs-btn-hover-bg: var(--cz-accent-deep);
  --bs-btn-hover-border-color: var(--cz-accent-deep);
  --bs-btn-color: #fff;
  --bs-btn-hover-color: #fff;
  --bs-btn-active-bg: var(--cz-accent-deep);
  --bs-btn-active-border-color: var(--cz-accent-deep);
  --bs-btn-active-color: #fff;
}

.list-plain > li {
  margin-bottom: 0.5rem;
}

/* Sezioni istituzionali (Chi siamo, Documenti, …) */
.section-band {
  background: linear-gradient(180deg, color-mix(in srgb, var(--cz-accent) 12%, transparent) 0%, color-mix(in srgb, var(--cz-accent) 4%, transparent) 100%);
  border-bottom: 1px solid var(--cz-line);
  padding: 1.25rem 0 0;
}

.section-band--thin .page-header--band {
  padding-bottom: 1.25rem;
}

.page-header--band {
  border-bottom: none;
  margin-bottom: 0;
  padding-top: 0.5rem;
  padding-bottom: 1.75rem;
}

.breadcrumb-nav {
  margin-bottom: 0.5rem;
}

.breadcrumb-nav .breadcrumb {
  background: transparent;
  padding: 0;
  font-size: 0.875rem;
}

.breadcrumb-nav .breadcrumb-item a {
  color: var(--cz-accent-deep);
  text-decoration: none;
}

.breadcrumb-nav .breadcrumb-item a:hover {
  text-decoration: underline;
}

.breadcrumb-nav .breadcrumb-item.active {
  color: var(--cz-muted);
}

.section-index-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 0;
  border-bottom: 1px solid var(--cz-line);
  text-decoration: none;
  color: var(--cz-ink);
  font-weight: 600;
  font-size: 1.1rem;
  transition: color 0.15s ease, padding-left 0.15s ease;
}

.section-index-item:hover {
  color: var(--cz-accent);
  padding-left: 0.35rem;
}

.section-index-arrow {
  color: var(--cz-accent);
  font-weight: 400;
}

.aside-card,
.section-nav {
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  border-left: 4px solid var(--cz-accent);
  padding: 1.25rem 1.35rem;
  position: sticky;
  top: 1rem;
}

.aside-card-label,
.section-nav-title {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cz-muted);
  margin-bottom: 0.85rem;
  font-weight: 600;
}

.section-nav-title a {
  color: var(--cz-accent-deep);
  text-decoration: none;
}

.aside-card a,
.section-nav-link {
  display: block;
  padding: 0.4rem 0;
  color: var(--cz-ink);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  font-size: 0.95rem;
}

.aside-card a:hover,
.section-nav-link:hover {
  color: var(--cz-accent);
}

.section-nav-link.is-active {
  color: var(--cz-accent);
  font-weight: 700;
}

.prose--page {
  max-width: none;
}

.prose--page h2 {
  font-size: 1.35rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid var(--cz-accent-soft);
}

.prose--page p {
  margin-bottom: 1rem;
}

.prose--page ul {
  padding-left: 1.2rem;
  margin-bottom: 1.25rem;
}

.section--tight {
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
}

.section--alt {
  background: color-mix(in srgb, var(--cz-accent) 6%, var(--cz-paper));
}

/* Carosello home: stessa altezza per tutte le slide, locandina intera */
.home-carousel {
  background: var(--cz-header-deep);
}

.home-carousel .carousel-item {
  min-height: 0;
}

.carousel-slide-link {
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}

.carousel-visual {
  position: relative;
  height: clamp(15rem, 42vw, 22rem);
  background: var(--cz-header-deep);
}

.carousel-img {
  position: absolute;
  inset: 0.75rem 3.75rem;
  width: calc(100% - 7.5rem);
  height: calc(100% - 1.5rem);
  object-fit: contain;
  object-position: center;
}

.home-carousel .carousel-item img.carousel-img {
  width: calc(100% - 7.5rem);
  height: calc(100% - 1.5rem);
  max-width: none;
  max-height: none;
}

.carousel-img--placeholder {
  background: linear-gradient(120deg, var(--cz-accent-deep), var(--cz-accent) 55%, var(--cz-accent-soft));
}

.home-carousel .carousel-caption {
  position: static;
  left: auto;
  right: auto;
  bottom: auto;
  min-height: 5.75rem;
  padding: 0.5rem 1.25rem 0.25rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  background: var(--cz-header-deep);
}

.home-carousel .carousel-indicators {
  position: static;
  inset: auto;
  z-index: 1;
  margin: 0;
  padding: 0.15rem 0 0.85rem;
}

.carousel-title {
  font-family: var(--cz-serif);
  font-size: clamp(1.05rem, 2.2vw, 1.45rem);
  font-weight: 700;
  margin: 0 auto 0.2rem;
  max-width: 40ch;
  color: #fff;
}

.carousel-text {
  margin: 0 auto;
  max-width: 52ch;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-carousel .carousel-control-prev,
.home-carousel .carousel-control-next {
  width: 3.5rem;
}

.agenda-nav {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.95rem;
}

.agenda-nav a {
  text-decoration: none;
  font-size: 1.25rem;
  line-height: 1;
  color: var(--cz-accent-deep);
  padding: 0.15rem 0.4rem;
}

.agenda-nav-label {
  text-transform: capitalize;
  font-weight: 600;
  color: var(--cz-accent-deep);
  min-width: 9rem;
  text-align: center;
}

.agenda-timeline--home {
  margin-top: 0.25rem;
}

.agenda-timeline--home .agenda-timeline-day {
  grid-template-columns: 3.5rem 1fr;
  gap: 0.85rem;
  padding: 0.85rem 0;
}

.agenda-timeline--home .agenda-timeline-daynum {
  font-size: 1.45rem;
}

.agenda-timeline--home .agenda-timeline-link {
  font-size: 0.95rem;
  padding: 0.55rem 0.75rem;
}

.agenda-timeline--home .agenda-timeline-events {
  gap: 0.45rem;
}

.calendar-table td {
  height: 2.75rem;
  text-align: center;
}

.calendar-table .event-chip {
  display: inline;
  margin: 0;
  font-size: 0.85rem;
}

.project-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  color: inherit;
}

.project-card-media {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--cz-accent-soft);
}

.project-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-card-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--cz-accent-deep), var(--cz-accent));
}

.project-card-body {
  padding: 1rem 1.1rem 1.2rem;
  flex: 1;
}

.project-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
  color: var(--cz-accent-deep);
  font-family: var(--cz-serif);
}

.project-card-summary {
  margin: 0;
  font-size: 0.9rem;
  color: var(--cz-muted);
  line-height: 1.4;
}

.pub-card {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.pub-card:hover {
  color: inherit;
}

.pub-card-media {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid var(--cz-line);
  background: var(--cz-surface);
  margin-bottom: 0.65rem;
}

.pub-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s ease;
}

.pub-card:hover .pub-card-media img {
  transform: scale(1.03);
}

.pub-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: flex-end;
  padding: 1rem;
  background: linear-gradient(160deg, var(--cz-accent), var(--cz-accent-deep));
  color: #fff;
  font-family: var(--cz-serif);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.25;
}

.pub-card-title {
  font-size: 0.98rem;
  font-weight: 700;
  margin: 0 0 0.2rem;
  color: var(--cz-accent-deep);
}

.pub-card-sub {
  margin: 0;
  font-size: 0.85rem;
  color: var(--cz-muted);
}

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

.page-subtitle {
  font-size: 1.15rem;
  color: var(--cz-accent-deep);
  margin: 0.35rem 0 0.75rem;
  font-family: var(--cz-serif);
}

.doc-group {
  margin: 1.75rem 0;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--cz-line);
  border-left: 4px solid var(--cz-accent);
  background: var(--cz-surface);
}

.prose--page .doc-group-title,
.doc-group-title {
  font-family: var(--cz-sans);
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
  padding-bottom: 0;
  border-bottom: none;
  color: var(--cz-accent-deep);
}

.doc-group .doc-group-list {
  margin-bottom: 0;
}

.doc-group-list li {
  border-bottom: 1px solid var(--cz-line);
}

.doc-group-list li:last-child {
  border-bottom: none;
}

.doc-group-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0;
  text-decoration: none;
  color: var(--cz-ink);
  font-weight: 600;
}

.doc-group-icon {
  flex-shrink: 0;
  color: var(--cz-accent);
  display: inline-flex;
  line-height: 0;
}

.doc-group-name {
  flex: 1;
  min-width: 0;
}

.doc-group-link:hover {
  color: var(--cz-accent);
}

.doc-group-link:hover .doc-group-icon {
  color: var(--cz-accent-deep);
}

.doc-group-size {
  color: var(--cz-muted);
  font-weight: 400;
  font-size: 0.85rem;
  white-space: nowrap;
}

.photo-gallery {
  margin: 1.75rem 0;
}

.photo-gallery-title {
  font-size: 1.05rem;
  margin: 0 0 0.85rem;
  color: var(--cz-accent-deep);
}

.photo-gallery-item {
  overflow: hidden;
  border: 1px solid var(--cz-line);
  background: #fff;
}

.photo-gallery-link {
  display: block;
  cursor: zoom-in;
  text-decoration: none;
  color: inherit;
}

.photo-gallery-link:hover img {
  opacity: 0.92;
}

.photo-gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: opacity 0.15s ease;
}

.photo-gallery-item figcaption {
  font-size: 0.8rem;
  color: var(--cz-muted);
  padding: 0.4rem 0.55rem;
}

/* Lightbox gallery */
.cz-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1080;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(10, 24, 40, 0.88);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.cz-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.cz-lightbox-dialog {
  position: relative;
  max-width: min(96vw, 1200px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  outline: none;
}

.cz-lightbox-img {
  max-width: 100%;
  max-height: calc(92vh - 3rem);
  width: auto;
  height: auto;
  object-fit: contain;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.cz-lightbox-caption {
  margin: 0.75rem 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.95rem;
  text-align: center;
  max-width: 40rem;
}

.cz-lightbox-btn {
  position: absolute;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cz-lightbox-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}

.cz-lightbox-close {
  top: 1rem;
  right: 1rem;
  position: fixed;
}

.cz-lightbox-prev,
.cz-lightbox-next {
  top: 50%;
  transform: translateY(-50%);
}

.cz-lightbox-prev {
  left: 0.75rem;
  position: fixed;
}

.cz-lightbox-next {
  right: 0.75rem;
  position: fixed;
}

.cz-lightbox-btn[hidden] {
  display: none;
}

@media (max-width: 575.98px) {
  .cz-lightbox-prev,
  .cz-lightbox-next {
    top: auto;
    bottom: 1rem;
    transform: none;
  }

  .cz-lightbox-prev {
    left: 1rem;
  }

  .cz-lightbox-next {
    right: 1rem;
  }
}

/* Schede agenda / notizie: full-width, senza menu laterale */
.entry-header-wrap {
  max-width: 42rem;
}

.entry-header h1 {
  font-size: clamp(1.45rem, 3.2vw, 2rem);
  line-height: 1.25;
  overflow-wrap: anywhere;
  word-break: normal;
  hyphens: auto;
}

.entry-date {
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cz-accent-deep);
  font-weight: 600;
  margin: 0 0 0.65rem;
}

.entry-back {
  margin: 1rem 0 0;
  font-size: 0.95rem;
}

.entry-back a {
  color: var(--cz-muted);
  text-decoration: none;
}

.entry-back a:hover {
  color: var(--cz-accent);
}

.entry-body-wrap {
  max-width: 42rem;
}

.prose--entry {
  max-width: none;
}

.entry-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-top: 2.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--cz-line);
}

.entry-pager-link {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  text-decoration: none;
  color: var(--cz-ink);
  padding: 0.85rem 1rem;
  border: 1px solid var(--cz-line);
  background: var(--cz-surface);
  transition: border-color 0.15s ease, color 0.15s ease;
  min-height: 100%;
}

.entry-pager-link:hover {
  border-color: var(--cz-accent);
  color: var(--cz-accent-deep);
}

.entry-pager-link--next {
  text-align: right;
  align-items: flex-end;
}

.entry-pager-dir {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cz-muted);
  font-weight: 600;
}

.entry-pager-meta {
  font-size: 0.85rem;
  color: var(--cz-accent-deep);
}

.entry-pager-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
}

@media (max-width: 575.98px) {
  .entry-pager {
    grid-template-columns: 1fr;
  }

  .entry-pager-link--next {
    text-align: left;
    align-items: flex-start;
  }
}

/* Scheda evento (nav | contenuto | locandina+partner) */
.event-header h1 {
  font-family: var(--cz-serif);
  font-size: clamp(1.85rem, 4vw, 2.55rem);
  font-weight: 700;
  margin: 0;
  line-height: 1.15;
}

.event-subtitle {
  font-family: var(--cz-serif);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: var(--cz-muted);
  margin: 0.4rem 0 0;
}

.event-details {
  margin: 1.25rem 0 1.35rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--cz-line);
  color: var(--cz-accent);
  font-weight: 700;
  line-height: 1.45;
}

.event-details span {
  display: block;
}

.event-intro {
  background: var(--cz-accent-soft);
  padding: 1.15rem 1.25rem 1rem;
  margin-bottom: 1.5rem;
}

.event-intro p {
  margin-bottom: 0.65rem;
}

.event-intro p:last-child {
  margin-bottom: 0;
}

.event-cta {
  margin: 1.25rem 0 1.5rem;
}

.event-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: normal;
  text-align: center;
  text-decoration: none;
  font-family: var(--cz-sans);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.35;
  padding: 0.75rem 1.4rem;
  max-width: 100%;
  box-shadow: 0 1px 2px rgb(0 0 0 / 12%);
}

.event-cta-btn:hover,
.event-cta-btn:focus-visible {
  text-decoration: none;
  color: #fff;
}

.event-body {
  font-size: 1.2rem;
  line-height: 1.4;
}

.event-body p {
  margin-bottom: 1.15rem;
}

.event-aside {
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
}

.event-poster {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
}

.event-poster:has(.event-flyer) {
  border-radius: 0 0 10px 10px;
}

.event-locandina {
  margin: 0;
}

.event-locandina img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.event-flyer {
  display: flex;
  width: 100%;
  border-radius: 0 0 10px 10px;
  box-shadow: none;
}

.event-subpages {
  margin: 0;
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  overflow: hidden;
}

.event-subpages-title {
  font-family: var(--cz-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cz-ink);
  margin: 0;
  padding: 0.7rem 0.9rem;
  background: var(--cz-paper);
  border-bottom: 1px solid var(--cz-line);
}

.event-subpages ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
}

.event-subpages li + li {
  border-top: 1px solid var(--cz-line);
}

.event-subpages a {
  display: block;
  padding: 0.8rem 0.9rem;
  color: var(--cz-accent);
  font-weight: 600;
  text-decoration: none;
}

.event-subpages a:hover {
  background: var(--cz-accent-soft);
  text-decoration: none;
}

.event-subpages a.is-active {
  color: var(--cz-ink);
  font-weight: 700;
  background: var(--cz-accent-soft);
  box-shadow: inset 3px 0 0 var(--cz-accent);
}

.event-subpages a.is-active:hover {
  text-decoration: none;
}

.partner-group {
  margin-bottom: 1.1rem;
}

.partner-group-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--cz-ink);
  margin: 0 0 0.55rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid var(--cz-line);
}

.partner-group-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.partner-group-list img {
  max-width: 100%;
  height: auto;
  max-height: 4.25rem;
  width: auto;
  object-fit: contain;
  object-position: left center;
  display: block;
}

.partner-name {
  font-size: 0.9rem;
  font-weight: 600;
}

.section-tree {
  background: var(--cz-surface);
  border: 1px solid var(--cz-line);
  overflow: visible;
}

.section-tree-list,
.section-tree-children {
  list-style: none;
  padding: 0;
  margin: 0;
}

.section-tree-branch.is-open {
  margin-bottom: 0.7rem;
}

.section-tree-parent {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.45rem;
  width: 100%;
  margin: 0;
  padding: 0.55rem 0.75rem;
  border: 0;
  border-bottom: 1px solid var(--cz-line);
  background: #fff;
  color: var(--cz-accent);
  font-weight: 700;
  text-align: left;
  text-decoration: none;
  line-height: 1.25;
  cursor: pointer;
}

.section-tree-branch.is-open > .section-tree-parent {
  background: var(--cz-accent);
  border-bottom-color: var(--cz-accent);
  color: #fff;
}

.section-tree-parent-text {
  min-width: 0;
  flex: 1 1 auto;
}

.section-tree-parent:hover {
  color: var(--cz-accent-deep);
}

.section-tree-branch.is-open > .section-tree-parent:hover {
  color: #fff;
}

.section-tree-caret {
  flex: 0 0 auto;
  margin-left: auto;
}

.section-tree-caret::before {
  content: "▼";
  font-size: 0.7rem;
}

.section-tree-branch.is-open > .section-tree-parent .section-tree-caret::before {
  content: "▲";
}

.section-tree-branch:not(.is-open) .section-tree-children {
  display: none;
}

.section-tree-children {
  background: color-mix(in srgb, var(--cz-accent) 10%, #fff);
}

.section-tree-link {
  display: block;
  padding: 0.5rem 0.9rem 0.5rem 0.85rem;
  color: var(--cz-accent);
  font-style: normal;
  text-align: left;
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--cz-accent) 16%, #fff);
}

.section-tree-link.is-active {
  font-weight: 700;
  background: #fff;
  position: relative;
  z-index: 1;
}

.section-tree-link.is-active::after {
  content: "";
  position: absolute;
  right: -11px;
  top: 50%;
  transform: translateY(-50%);
  border-top: 12px solid transparent;
  border-bottom: 12px solid transparent;
  border-left: 11px solid #fff;
  filter: drop-shadow(1px 0 0 var(--cz-accent));
}

.section-tree-link:hover {
  color: var(--cz-accent-deep);
  background: color-mix(in srgb, var(--cz-accent) 6%, #fff);
}

/* Anteprima font contenuto (?preview-fonts=1) */
.prose-font-preview {
  position: fixed;
  z-index: 1080;
  left: 0.75rem;
  bottom: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.65rem;
  padding: 0.45rem 0.7rem;
  font-family: var(--cz-sans);
  font-size: 0.8rem;
  line-height: 1.2;
  color: #fff;
  background: rgba(33, 33, 31, 0.92);
  border-radius: 0.35rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.prose-font-preview a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.prose-font-preview a:hover {
  color: #fff;
}

.prose-font-preview a[aria-current="true"] {
  color: #fff;
  border-bottom-color: #fff;
  font-weight: 600;
}
