.footer {
  background-color: #161e2d;
  background-image: none;
}

.main-header .header-lower .inner-container {
  flex-wrap: nowrap;
  gap: 16px;
}

.main-header .nav-outer {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  justify-content: center;
  margin: 0 16px;
}

.main-header .nav-outer .navigation {
  display: flex;
  flex-wrap: nowrap;
  gap: 18px;
}

.main-header .nav-outer .navigation > li {
  white-space: nowrap;
}

.main-header .header-account {
  flex: 0 0 auto;
}

.main-header .nav-outer .main-menu {
  width: 100%;
}

.main-header .nav-outer .navigation {
  justify-content: center;
  width: 100%;
  margin: 0 auto;
}

.dashboard .main-header .main-menu {
  margin-left: 0 !important;
}

.dashboard .main-header .header-account {
  gap: 12px;
}

.dashboard .main-header .inner-container {
  justify-content: center !important;
}

.dashboard .main-header .logo-box {
  margin-right: 24px;
  flex: 0 0 auto;
}

.dashboard .main-header .nav-outer {
  flex: 1 1 auto;
  margin: 0 auto !important;
}

.dashboard .main-header .dropdown {
  margin-left: auto !important;
}

.dashboard .main-header .header-account {
  margin-left: 12px;
}

.dashboard .layout-wrap .main-content-inner {
  padding-top: 40px;
  padding-bottom: 40px;
}

.profile-tabs {
  border-bottom: 1px solid rgba(22, 30, 45, 0.1);
  margin-bottom: 28px;
  padding-bottom: 6px;
  gap: 8px;
}

.profile-tabs .nav-link {
  border: 0;
  color: #6b7280;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 999px;
}

.profile-tabs .nav-link.active {
  background: #ED2027;
  color: #ffffff;
}

.profile-tabs .nav-link:hover {
  color: #ED2027;
}

.profile-tab-content .tab-pane {
  padding-top: 4px;
}

.profile-tab-content .title {
  margin-top: 18px;
  margin-bottom: 12px;
}

.profile-tab-content .box-fieldset {
  margin-bottom: 12px;
}

.dashboard .dashboard-kpi-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.dashboard .dashboard-kpi-link:hover .counter-box {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.header-notifications {
  display: flex;
  align-items: center;
}

.header-notifications .notification-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  color: #ffffff;
  text-decoration: none;
  background: rgba(22, 30, 45, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.body.dashboard .header-notifications .notification-link {
  color: #161e2d;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
}

.header-notifications .notification-link .icon {
  font-size: 18px;
}

.header-notifications .notification-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #ef4444;
  color: #ffffff;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
  font-weight: 700;
  box-shadow: 0 4px 10px rgba(239, 68, 68, 0.4);
}

.header-notifications .notification-menu {
  width: 320px;
  padding: 0;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(22, 30, 45, 0.08);
  box-shadow: 0 20px 60px rgba(22, 30, 45, 0.2);
}

.notification-menu .notification-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: #f8fafc;
}

.notification-menu .notification-title {
  font-weight: 600;
  color: #161e2d;
}

.notification-menu .notification-count {
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 12px;
  line-height: 22px;
  text-align: center;
  font-weight: 700;
}

.notification-menu .notification-body {
  max-height: 320px;
  overflow: auto;
  background: #fff;
}

.notification-menu .notification-empty {
  padding: 16px;
  color: #6b7280;
  font-size: 14px;
}

.notification-menu .notification-item {
  display: block;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(22, 30, 45, 0.06);
  text-decoration: none;
}

.notification-menu .notification-item.is-unread .notification-item-title {
  position: relative;
  padding-left: 14px;
}

.notification-menu .notification-item.is-unread .notification-item-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
}

.notification-menu .notification-item:last-child {
  border-bottom: 0;
}

.notification-menu .notification-item-title {
  font-weight: 600;
  color: #111827;
  font-size: 14px;
  margin-bottom: 4px;
}

.notification-menu .notification-item-text {
  color: #6b7280;
  font-size: 13px;
  line-height: 1.4;
}

.notification-menu .notification-item-meta {
  margin-top: 6px;
  font-size: 12px;
  color: #9ca3af;
}

.notification-menu .notification-footer {
  padding: 12px 16px;
  background: #f8fafc;
  text-align: center;
}

.notification-menu .notification-link-all {
  font-weight: 600;
  color: #1d4ed8;
  text-decoration: none;
}

.wrap-benefit {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
}

.wrap-benefit .box-benefit {
  flex: 1 1 260px;
  max-width: 320px;
}

.footer .footer-partners {
  display: flex;
  justify-content: center;
  padding: 16px 0 8px;
}

.footer .footer-partners img {
  max-width: 420px;
  width: 100%;
  height: auto;
}

.dashboard-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(22, 30, 45, 0.15);
}

/* CMS pages: keep spacing and cards aligned with template rhythm */
.cms-site-page .flat-title-page {
  padding: 72px 0 40px;
}

.cms-site-page .cms-page-content > section:first-child {
  padding-top: 36px !important;
}

.cms-site-page .cms-page-content section.flat-section {
  padding-top: 72px;
  padding-bottom: 72px;
}

.vetrina-skeleton-card {
  padding: 14px;
}

.vetrina-skeleton-image {
  width: 100%;
  height: 220px;
  border-radius: 12px;
  background: linear-gradient(90deg, #eef2f7 25%, #e5ebf3 37%, #eef2f7 63%);
  background-size: 400% 100%;
  animation: vetrina-shimmer 1.3s ease infinite;
  margin-bottom: 14px;
}

.vetrina-skeleton-line {
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, #eef2f7 25%, #e5ebf3 37%, #eef2f7 63%);
  background-size: 400% 100%;
  animation: vetrina-shimmer 1.3s ease infinite;
  margin-bottom: 10px;
}

#vetrina-load-more.is-loading {
  opacity: .75;
  pointer-events: none;
}

@keyframes vetrina-shimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: 0 0;
  }
}

.cms-site-page .cms-page-content .row.g-4,
.cms-site-page .cms-page-content .row.g-5 {
  align-items: stretch;
}

.cms-site-page .cms-page-content .row.g-4 > [class*="col-"],
.cms-site-page .cms-page-content .row.g-5 > [class*="col-"] {
  display: flex;
  flex-direction: column;
}

.cms-site-page .cms-page-content .box,
.cms-site-page .cms-page-content .box-benefit,
.cms-site-page .cms-page-content .tf-card,
.cms-site-page .cms-page-content .flat-service {
  height: 100%;
}

.cms-site-page .cms-page-content img {
  max-width: 100%;
  height: auto;
}

.page-chi-siamo .flat-title-page {
  padding: 52px 0 28px;
}

.page-chi-siamo .cms-page-content > section {
  padding-top: 56px !important;
  padding-bottom: 56px !important;
}

.page-chi-siamo .cms-page-content > section:first-child {
  padding-top: 20px !important;
}

.page-chi-siamo .cms-page-content .row {
  --bs-gutter-y: 24px;
  align-items: stretch;
}

.page-chi-siamo .cms-page-content .box,
.page-chi-siamo .cms-page-content .box-benefit,
.page-chi-siamo .cms-page-content .tf-card {
  height: 100%;
}

.page-chi-siamo .cms-page-content .box img,
.page-chi-siamo .cms-page-content .box-benefit img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Chi siamo: first 3 benefit boxes should span full content width */
.page-chi-siamo .cms-page-content > section:first-child .row.align-items-center > .col-lg-7 {
  flex: 0 0 100%;
  max-width: 100%;
}

.page-chi-siamo .cms-page-content > section:first-child .row.align-items-center > .col-lg-5 {
  display: none;
}

.page-chi-siamo .cms-page-content > section:first-child .row.mt-20.g-3 {
  margin-top: 28px !important;
}

.page-chi-siamo .cms-page-content > section:first-child .row.mt-20.g-3 > [class*="col-"] {
  display: flex;
}

/* Contact page: use content-defined hero, avoid duplicated page heading */
.page-contatti .flat-title-page {
  display: none;
}

.page-chi-siamo .flat-title-page,
.page-come-funziona .flat-title-page {
  display: none;
}

.page-contatti .cms-page-content > section:first-child {
  padding-top: 56px !important;
}

.page-chi-siamo .cms-page-content > section:first-child,
.page-come-funziona .cms-page-content > section:first-child {
  padding-top: 56px !important;
}

.page-contatti .cms-page-content > section {
  padding-top: 56px !important;
  padding-bottom: 56px !important;
}

.page-contatti .cms-page-content .row {
  --bs-gutter-y: 24px;
  align-items: stretch;
}

.page-contatti .cms-page-content .box {
  height: 100%;
}

.page-contatti .cms-page-content iframe,
.page-contatti .cms-page-content .leaflet-container {
  min-height: 360px;
  border-radius: 12px;
}

.cookie-banner {
  position: fixed;
  left: 24px;
  right: 24px;
  bottom: 24px;
  z-index: 1050;
  max-width: 980px;
  margin: 0 auto;
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(22, 30, 45, 0.2);
  border: 1px solid rgba(22, 30, 45, 0.08);
}

.cookie-banner.cookie-hidden {
  display: none;
}

.cookie-banner .cookie-inner {
  padding: 24px 28px;
}

.cookie-banner .cookie-title {
  font-weight: 600;
  font-size: 18px;
  margin-bottom: 8px;
  color: #161e2d;
}

.cookie-banner .cookie-body {
  font-size: 14px;
  color: #5b6476;
  line-height: 1.6;
}

.cookie-banner .cookie-body a {
  color: #1d4ed8;
  text-decoration: underline;
}

.cookie-banner .cookie-prefs {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(22, 30, 45, 0.08);
}

.cookie-banner .pref-title {
  font-weight: 600;
  color: #161e2d;
  margin-bottom: 12px;
}

.cookie-banner .pref-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
}

.cookie-banner .pref-text .pref-title {
  margin-bottom: 4px;
}

.cookie-banner .pref-desc {
  font-size: 13px;
  color: #6b7280;
}

.cookie-banner .pref-toggle {
  position: relative;
  width: 44px;
  height: 24px;
  background: #e5e7eb;
  border-radius: 999px;
  cursor: pointer;
  flex: 0 0 auto;
}

.cookie-banner .pref-toggle span {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: #ffffff;
  border-radius: 999px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s ease;
}

.cookie-banner .pref-toggle input {
  display: none;
}

.cookie-banner .pref-toggle input:checked + span {
  transform: translateX(20px);
  background: #ffffff;
  border: 1px solid #1d4ed8;
  box-shadow: 0 2px 6px rgba(29, 78, 216, 0.4);
}

.cookie-banner .pref-toggle.disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.cookie-banner .pref-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
}

.cookie-banner .btn {
  border: none;
  background: #1d4ed8;
  color: #ffffff;
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

.cookie-banner .btn.ghost {
  background: transparent;
  color: #1d4ed8;
  border: 1px solid rgba(29, 78, 216, 0.4);
}

@media (max-width: 768px) {
  .cookie-banner {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .cookie-banner .cookie-inner {
    padding: 18px;
  }

  .cookie-banner .pref-row {
    align-items: flex-start;
  }
}

@media (max-width: 1200px) {
  .main-header .nav-outer {
    display: none !important;
  }

  .main-header .mobile-nav-toggler {
    display: inline-flex !important;
  }
}

.vetrina-cover {
  aspect-ratio: 4 / 3;
}

.vetrina-cover img {
  height: 100%;
  object-fit: cover;
  display: block;
}

b,
strong {
  font-weight: 700;
}

.project-richtext {
  line-height: 1.7;
}

.project-richtext p,
.project-richtext ul,
.project-richtext ol,
.project-richtext blockquote,
.project-richtext table {
  margin: 0 0 14px;
}

.project-richtext p:last-child,
.project-richtext ul:last-child,
.project-richtext ol:last-child,
.project-richtext blockquote:last-child,
.project-richtext table:last-child {
  margin-bottom: 0;
}

.project-richtext h1,
.project-richtext h2,
.project-richtext h3,
.project-richtext h4,
.project-richtext h5,
.project-richtext h6 {
  margin: 16px 0 10px;
  line-height: 1.35;
  color: #161e2d;
}

.project-richtext h1:first-child,
.project-richtext h2:first-child,
.project-richtext h3:first-child,
.project-richtext h4:first-child,
.project-richtext h5:first-child,
.project-richtext h6:first-child {
  margin-top: 0;
}

.project-richtext b,
.project-richtext strong {
  font-weight: 700;
}

.project-richtext ul {
  list-style: disc;
  padding-left: 1.35rem;
}

.project-richtext ol {
  list-style: decimal;
  padding-left: 1.35rem;
}

.project-richtext li + li {
  margin-top: 6px;
}

.project-richtext a {
  color: #1d4ed8;
  text-decoration: underline;
}

.project-richtext blockquote {
  border-left: 3px solid #ed2027;
  padding: 10px 14px;
  background: rgba(237, 32, 39, 0.06);
  border-radius: 8px;
}

.project-richtext img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.project-richtext table {
  width: 100%;
  border-collapse: collapse;
}

.project-richtext table th,
.project-richtext table td {
  border: 1px solid rgba(22, 30, 45, 0.15);
  padding: 8px 10px;
}
