/* ==========================================================================
   STP — Sistema Tram Palermo
   Custom stylesheet — Bootstrap 5 override + brand components
   Naming convention: BEM (.block__element--modifier)
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. CSS Custom Properties (Design Tokens)
   -------------------------------------------------------------------------- */
:root {
  /* Brand colours */
  --stp-yellow: #FAAB00;
  --stp-red: #ED1C50;
  --stp-blue: #005FBD;
  --stp-beige: #F2EFEA;
  --stp-black: #000000;
  --stp-white: #FFFFFF;
  --stp-gray: #999999;
  --stp-gray-label: #AEAEAE;
  --light-gray: #F2EFEA;
  --custom-gray: #D9D9D9;

  /* Typography */
  --stp-font-primary: 'Urbanist', sans-serif;
  --stp-font-secondary: 'Work Sans', sans-serif;

  /* Spacing */
  --stp-px: 150px;
  /* section horizontal padding */
  --stp-section-gap: 130px;
  /* vertical gap between sections */
  --stp-card-radius: 30px;
  --stp-pill-radius: 20px;

  /* Bootstrap overrides */
  --bs-body-font-family: var(--stp-font-primary);
  --bs-body-color: var(--stp-black);
  --bs-link-color: var(--stp-black);
  --bs-link-hover-color: var(--stp-black);
}

/* --------------------------------------------------------------------------
   2. Global Reset / Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--stp-font-primary);
  color: var(--stp-black);
  background: var(--stp-white);
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.arrow-progetti {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%);
}

/* --------------------------------------------------------------------------
   3. Layout — Custom Container
   -------------------------------------------------------------------------- */

/* Full-bleed wrapper with max-width */
.stp-container {}

.pst {
  padding-top: var(--stp-section-gap);
}

.psb {
  padding-bottom: var(--stp-section-gap);
}

/* Sections that need no side padding (full-bleed) */
.stp-container--flush {}

/* Scrollable card row: padding only on first/last card (via inner margin) */
.stp-scroll-row {
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  /* visually align start with section content */
  padding-left: var(--stp-px);
  padding-right: var(--stp-px);
}

.stp-scroll-row::-webkit-scrollbar {
  display: none;
}

.stp-scroll-row__inner {
  display: flex;
  flex-wrap: nowrap;
  gap: 13px;
}

/* --------------------------------------------------------------------------
   4. Typography Utilities
   -------------------------------------------------------------------------- */

.stp-section-title {
  font-size: 40px;
  font-weight: 600;
  line-height: 1.1;
  margin-bottom: 0;
}

.stp-section-title--yellow {
  color: var(--stp-yellow);
}

.stp-section-title--blue {
  color: var(--stp-blue);
}

.stp-section-title--red {
  color: var(--stp-red);
}

/* CTA underline link pattern */
.stp-cta {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}

.stp-cta__text {
  font-size: 18px;
  font-weight: 700;
  line-height: normal;
  color: var(--stp-black);
  white-space: nowrap;
}

.stp-cta__bar {
  height: 4px;
  border-radius: 4px;
  width: 100%;
  display: block;
}

.stp-cta__bar--black {
  background: var(--stp-black);
}

.stp-cta__bar--yellow {
  background: var(--stp-yellow);
}

.stp-cta__bar--red {
  background: var(--stp-red);
}

.stp-cta__bar--white {
  background: var(--stp-white);
}

.stp-cta__bar--blue {
  background: var(--stp-blue);
}

/* Pill / badge component */
.stp-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--stp-pill-radius);
  padding: 4px 20px;
  height: 42px;
  font-size: 18px;
  font-weight: 700;
  white-space: nowrap;
}

.stp-pill--red {
  background: var(--stp-red);
  color: var(--stp-white);
}

.stp-pill--blue {
  background: var(--stp-blue);
  color: var(--stp-white);
}

.stp-pill--yellow {
  background: var(--stp-yellow);
  color: var(--stp-black);
}

.stp-pill--white {
  background: var(--stp-white);
  color: var(--stp-black);
}

/* Pill compatta — usata nelle sidebar card (related news) */
.stp-pill--sm {
  height: 32px;
  padding: 2px 14px;
  font-size: 14px;
}

/* CTA text su sfondo blu (link "Leggi tutti" mobile rassegna stampa) */
.stp-cta__text--blue {
  color: var(--stp-blue);
}

/* Marquee percorso vincolato (route pill nelle fermate) */
.stp-route-badge__marquee--narrow {
  max-width: 280px;
}

/* Messaggio "stato vuoto" (nessun risultato / nessun correlato) */
.stp-empty-note {
  color: var(--stp-gray);
  font-size: 14px;
}

/* --------------------------------------------------------------------------
   5. Section Header Row (title + "leggi tutti" link)
   -------------------------------------------------------------------------- */
.stp-section-header {
  display: flex;
  align-items: center;
  padding-bottom: 32px;
  justify-content: space-between;
  flex-direction: row;
  flex-wrap: nowrap;
}

/* --------------------------------------------------------------------------
   6. Navbar
   -------------------------------------------------------------------------- */
.stp-navbar {
  background: var(--stp-white);
  box-shadow: 0 1px 0 #f0f0f0;
  padding-top: 0;
  padding-bottom: 0;
  min-height: 80px;
}

.stp-navbar .navbar-brand {
  padding: 0;
  margin-right: 0;
}

.stp-navbar .navbar-brand img {
  height: 52px;
  width: auto;
}

.stp-navbar .navbar-nav {
  gap: 32px;
}

.stp-navbar .nav-link {
  font-size: 16px;
  font-weight: 700;
  color: var(--stp-black) !important;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

@media (max-width: 992px) {
  .stp-navbar .nav-link {
    font-size: 36px;
    font-weight: 600;
    align-items: start;
    gap: 15px;
    white-space: nowrap;
  }

  .arrow-progetti {
    top: 40%;
    left: 50%;
    transform: translate(-50%) rotate(90deg);
    transform-origin: center center;
  }
}

.stp-navbar .nav-link .nav-arrow {
  width: 10px;
  height: auto;
}

/* Hamburger customisation */
.stp-navbar .navbar-toggler {
  border: none;
  padding: 0;
}

.stp-navbar .navbar-toggler:focus {
  box-shadow: none;
}

/* ── Brand: Lottie + wordmark ── */
.stp-navbar__brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0;
  margin-right: 0;
}

.stp-navbar__logo {
  width: 302px;
  height: 62px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.stp-navbar__logo svg {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

.stp-navbar__wordmark {
  font-family: var(--stp-font-primary);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.15;
  color: var(--stp-black);
  white-space: nowrap;
}

/* ── Dropdown caret indicator (the small ▾ next to label) ── */
.stp-navbar .nav-link.dropdown-toggle {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
}

/* Hide Bootstrap's default caret — we use a custom SVG/symbol */
.stp-navbar .dropdown-toggle::after {
  display: inline-block;
  margin-left: 4px;
  vertical-align: middle;
  content: "";
  border-top: 5px solid currentColor;
  border-right: 4px solid transparent;
  border-bottom: 0;
  border-left: 4px solid transparent;
}

/* ── Custom dropdown menu (balloon style) ── */
.stp-navbar .dropdown-menu {
  --bs-dropdown-min-width: 240px;
  --bs-dropdown-padding-y: 8px;
  --bs-dropdown-padding-x: 0;
  --bs-dropdown-border-width: 0;
  --bs-dropdown-border-radius: 16px;
  --bs-dropdown-bg: var(--stp-white);
  --bs-dropdown-link-color: var(--stp-black);
  --bs-dropdown-link-hover-bg: transparent;
  --bs-dropdown-link-hover-color: var(--stp-blue);
  margin-top: 18px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid #EFEFEF;
  position: absolute;

  a:not([href]) {
    color: grey !important;
  }
}

/* Balloon caret tip (white square rotated 45°) */
.stp-navbar .dropdown-menu::before {
  content: "";
  position: absolute;
  top: -7px;
  left: 32px;
  width: 14px;
  height: 14px;
  background: var(--stp-white);
  border-top: 1px solid #EFEFEF;
  border-left: 1px solid #EFEFEF;
  transform: rotate(45deg);
}

.stp-navbar .dropdown-item {
  padding: 14px 24px;
  font-size: 16px;
  font-weight: 700;
  color: var(--stp-black);
}

.stp-navbar .dropdown-item:hover,
.stp-navbar .dropdown-item:focus {
  background: transparent;
  color: var(--stp-blue);
}

/* Separator line between items (except after last) */
.stp-navbar .dropdown-item+.dropdown-item {
  border-top: 1px solid #EFEFEF;
}

/* --------------------------------------------------------------------------
   7. Hero Section
   -------------------------------------------------------------------------- */
.stp-hero__card {
  background: var(--stp-beige);
  border-radius: var(--stp-card-radius);
  overflow: hidden;
}

.stp-hero__title {
  position: relative;
  z-index: 2;
  /* foreground layer */
  font-size: 60px;
  font-weight: 600;
  line-height: 1.2;
  max-width: 620px;
  /* extends past the illustration left edge */
}

/* Contenuto Lottie (SVG) o fallback <img> dentro il container hero */
.stp-hero__illustration {
  display: flex;
  justify-content: end;

  svg, img {
    width: 60% !important;
  }
}

/* Motto — centred intro paragraph below hero */
.stp-motto .lead {
  max-width: 742px;
  margin: 0 auto;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
  color: var(--stp-black);
}

.stp-motto .lead strong {
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   8. Tratta Carousel
   -------------------------------------------------------------------------- */
.stp-tratta {
  overflow: hidden;
}

/* Override Bootstrap carousel fade / slide */
.stp-tratta .carousel-item {
  transition-duration: 0.45s;
}

/* Each slide inner layout */
.stp-tratta__slide {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
}

/* Slide title row with arrows */
.stp-tratta__nav-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: 534px;
  max-width: 100%;
}

.stp-tratta__slide-title {
  font-size: 40px;
  font-weight: 600;
  text-align: center;
  flex: 1;
  margin-bottom: 0;
}

.stp-tratta__arrow-btn {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

.stp-tratta__arrow-btn img {
  width: 30px;
  height: 30px;
}

/* Slide main content: yellow card + map */
.stp-tratta__content {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  width: min(1136px, 100%);
  gap: 50px;
}

/* ── Left: yellow info card ── */
.stp-tratta__card {
  background: var(--stp-yellow);
  border-radius: var(--stp-card-radius);
  position: relative;
  overflow: hidden;
}

.stp-tratta__card-tram {
  position: absolute;
  bottom: 0;
  right: -40px;
  height: 260px;
  width: auto;
  object-fit: contain;
  pointer-events: none;
}

.stp-tratta__card-body {
  position: relative;
  padding: 51px 60px 40px;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* Route badge inside card */
.stp-route-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--stp-white);
  border-radius: var(--stp-pill-radius);
  padding: 4px 20px;
  height: 42px;
  overflow: hidden;
  max-width: 100%;
}

.stp-route-badge__name {
  font-size: 28px;
  font-weight: 700;
  white-space: nowrap;
}

.stp-route-badge__sep {
  width: 1.5px;
  height: 26.5px;
  background: #ccc;
  flex-shrink: 0;
}

.stp-route-badge__route {
  font-size: 18px;
  font-weight: 400;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Progress block */
.stp-avanzamenti__title {
  font-size: 28px;
  font-weight: 700;
}

.stp-progress-item {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.stp-progress-item__pct {
  font-size: 28px;
  font-weight: 700;
  min-width: 68px;
}

.stp-progress-item__arrow {
  width: 14px;
  height: 14px;
  margin-top: 6px;
  transform: rotate(90deg);
  flex-shrink: 0;
}

.stp-progress-item__label {
  font-size: 21px;
  font-weight: 700;
}

.stp-progress-divider {
  height: 1px;
  background: rgba(0, 0, 0, 0.15);
  margin: 10px 0;
}

/* ── Right: map ── */
.stp-tratta__map-wrap {
  flex-shrink: 0;
}

.stp-tratta__map {
  width: 100%;
  height: 100%;
  border-radius: var(--stp-card-radius);
  overflow: hidden;
  background: var(--stp-beige);
}

.stp-tratta__map img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Label pill dentro la mappa (Figma: top-left 20,16 — pill bianca) */
.stp-tratta__map-label {
  position: absolute;
  top: 16px;
  left: 20px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 2px 11px;
  background: var(--stp-white);
  border-radius: 999px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

.stp-tratta__map-label-text {
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

.stp-tratta__map-label-text strong {
  font-weight: 700;
}

.stp-tratta__map-label-text .text-yellow {
  color: var(--stp-yellow);
}

/* ── Tram-display marquee inside route badge ── */
.stp-route-badge__marquee {
  overflow: hidden;
  flex: 1 1 auto;
  min-width: 0;
}

.stp-route-badge__marquee-track {
  display: inline-flex;
  white-space: nowrap;
  animation: stp-marquee 18s linear infinite;
}

.stp-route-badge__marquee-track>span {
  padding-right: 60px;
  /* spacing between repeated phrases */
  font-size: 18px;
  font-weight: 400;
}

.stp-tratta__card:hover .stp-route-badge__marquee-track,
.stp-route-badge__marquee:hover .stp-route-badge__marquee-track {
  animation-play-state: paused;
}

@keyframes stp-marquee {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-50%);
  }

  /* duplicated content → seamless loop */
}

/* ── Yellow circular nav arrows (slider header) ── */
.stp-tratta__arrow-btn--filled {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--stp-yellow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.stp-tratta__arrow-btn--filled svg {
  width: 12px;
  height: 12px;
}

/* ── Map endpoint pills (Trapani / Messina) ── */
.stp-tratta__map-wrap {
  position: relative;
}

.stp-tratta__map-pill {
  position: absolute;
  z-index: 2;
  padding: 4px 14px;
  height: 28px;
  border-radius: 999px;
  background: var(--stp-red);
  color: var(--stp-white);
  font-size: 14px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
}

.stp-tratta__map-pill--start {
  top: 36px;
  left: 26px;
}

.stp-tratta__map-pill--end {
  bottom: 60px;
  right: 26px;
}

/* --------------------------------------------------------------------------
   9. Vetture Section
   -------------------------------------------------------------------------- */


.stp-vetture__card {
  background: var(--stp-yellow);
  border-radius: var(--stp-card-radius);
  display: flex;
  align-items: stretch;
  overflow: hidden;
  min-height: 299px;
}

.stp-vetture__left {
  flex: 0 0 540px;
  padding: 50px 50px 50px 60px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.stp-vetture__title {
  font-size: 40px;
  font-weight: 600;
  color: var(--stp-black);
  margin-bottom: 0;
}

.stp-vetture__body {
  font-size: 18px;
  font-weight: 500;
  line-height: 1.55;
}

.stp-vetture__image {
  flex: 1;
  overflow: hidden;
}

.stp-vetture__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center left;
  display: block;
}

/* --------------------------------------------------------------------------
   10. News Card Component (Ordinanze + Rassegna Stampa)
   -------------------------------------------------------------------------- */
.stp-news-card {
  background: var(--stp-beige);
  border-radius: var(--stp-card-radius);
  padding: 31px 15px;
  text-decoration: none;
  color: var(--stp-black);
  transition: transform 0.2s ease;
  display: flex !important;
  flex-direction: column;
  gap: 20px;
  flex-wrap: nowrap;
  align-items: flex-start;
  justify-content: space-around;
}

.stp-news-card:hover {
  transform: translateY(-2px);
  color: var(--stp-black);
}

.stp-news-card__tag-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stp-news-card__location {
  font-size: 18px;
  font-weight: 700;
  white-space: nowrap;
}

.stp-news-card__location--red {
  color: var(--stp-red);
}

.stp-news-card__location--blue {
  color: var(--stp-blue);
}

.stp-news-card__location--yellow {
  color: var(--stp-yellow);
}

.stp-news-card__title {
  font-size: 21px;
  font-weight: 700;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.stp-news-card__body {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.55;
}

.stp-news-card__body .acc-red {
  color: var(--stp-red);
}

.stp-news-card__body .acc-blue {
  color: var(--stp-blue);
}

.stp-news-card__date {
  font-size: 14px;
  font-weight: 400;
  color: var(--stp-gray);
}

/* Rassegna variant: shorter */
.stp-news-card--press {
  min-height: 313px;
}

/* --------------------------------------------------------------------------
   11. Rigenerazione Urbana Section
   -------------------------------------------------------------------------- */

/* Titolo centrato sopra il reel */
.stp-reel-heading {
  padding-bottom: 30px;
  text-align: center;
}

/* ── Reel wrapper ── */
.stp-reel {
  position: relative;
  overflow: hidden;
  /* Altezza esplicita: garantisce che l'overlay abbia riferimento (Figma: 480px) */
  height: 480px;
}

/* ── Track: no padding — posizione calcolata via JS ── */
.stp-reel__track {
  display: flex;
  gap: 24px;
  /* transition gestita dal JS (aggiunta/rimossa dinamicamente) */
  will-change: transform;
  height: 100%;
}

/* Singola foto */
.stp-reel__photo {
  flex-shrink: 0;
  width: 640px;
  height: 480px;
  border-radius: 20px;
  overflow: hidden;
}

.stp-reel__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── Overlay: fisso al centro del wrapper, non dentro il track ── */
.stp-reel__overlay {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.70);
  border-radius: var(--stp-card-radius);
  width: min(948px, 90%);
  padding: 28px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  z-index: 10;
  /* Pointer-events attivi anche durante lo scroll delle foto */
  pointer-events: auto;
}

.stp-reel__text {
  font-size: 28px;
  font-weight: 700;
  color: var(--stp-white);
  text-align: center;
  white-space: nowrap;
}

.stp-reel__overlay .stp-cta__text {
  color: var(--stp-white);
}

/* ── Dots ── */
.stp-reel__dots {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 11;
}

.stp-reel__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}

.stp-reel__dot.is-active {
  background: var(--stp-white);
  transform: scale(1.3);
}

.img-rigenerazione {
  height: 480px;
}

/* --------------------------------------------------------------------------
   11b. Rassegna Stampa — Hero card with background image
   -------------------------------------------------------------------------- */
.stp-rassegna-hero {
  position: relative;
  border-radius: var(--stp-card-radius);
  overflow: hidden;
  min-height: 400px;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}

/* Dark gradient: solid left → transparent right */
.stp-rassegna-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
      rgba(0, 0, 0, 0.95) 0%,
      rgba(0, 0, 0, 0.80) 25%,
      rgba(0, 0, 0, 0.40) 55%,
      rgba(0, 0, 0, 0) 75%);
  z-index: 1;
}

.stp-rassegna-hero__content {
  position: relative;
  z-index: 2;
  padding: 2em;
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex-wrap: nowrap;
  align-items: flex-start;
  justify-content: center;
}

.stp-rassegna-hero__label {
  font-size: 18px;
  font-weight: 700;
  color: var(--stp-blue);
  margin: 0;
}

.stp-rassegna-hero__title {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--stp-white);
  margin: 0;
}

.stp-rassegna-hero__body {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--stp-white);
  opacity: 0.9;
  margin: 0;
}

.stp-rassegna-hero__date {
  font-size: 14px;
  font-weight: 400;
  color: var(--stp-gray-label);
  margin: 8px 0 0;
}

.stp-rassegna-hero .stp-cta__text {
  color: var(--stp-white);
}

/* Headline variant — used when hero is the heading itself (no external section title) */
.stp-rassegna-hero__heading {
  font-size: 40px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 8px;
}

.stp-rassegna-hero--yellow .stp-rassegna-hero__heading {
  color: var(--stp-yellow);
}

.stp-rassegna-hero--yellow .stp-rassegna-hero__body {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.25;
  max-width: 490px;
  opacity: 1;
}

/* Video background — sits behind ::before overlay */
.stp-rassegna-hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* --------------------------------------------------------------------------
   11c. Sistema Tram — Title pill + intro + photo
   -------------------------------------------------------------------------- */
/* Title pill: rounded bar. Sfondo giallo di default; rosso/blu nelle
   pagine archivio (ordinanze / rassegna stampa) seguendo la logica dei filtri. */
.stp-sistema__bar {
  background: var(--stp-yellow);
  border-radius: var(--stp-card-radius);
  position: relative;
  padding: 20px 25px;
}

.stp-sistema__bar--yellow {
  background: var(--stp-yellow);
}

.stp-sistema__bar--red {
  background: var(--stp-red);
}

.stp-sistema__bar--blue {
  background: var(--stp-blue);
}

.stp-sistema__title {
  font-size: 60px;
  font-weight: 600;
  line-height: 1.0;
  margin: 0;
  color: var(--stp-white);
}

.stp-sistema__title.subtitle {
  font-size: 40px;
}

/* Testo nero solo sullo sfondo giallo; bianco su qualsiasi altro colore. */
.stp-sistema__bar--yellow .stp-sistema__title {
  color: var(--stp-black);
}

/* ── Featured news card (larger variant for archive top) ── */
.stp-news-card--featured {
  min-height: 334px;
  padding: 31px 20px;
}

.stp-news-card--featured .stp-news-card__title {
  font-size: 28px;
  -webkit-line-clamp: 3;
}

.stp-news-card--featured .stp-news-card__body {
  font-size: 16px;
}

/* ── Filtra sidebar ── */
.stp-filter-side {
  position: sticky;
  top: 24px;
}

.stp-filter-side__header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.stp-filter-side__icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--stp-black);
}

.stp-filter-side__label {
  font-size: 14px;
  font-weight: 400;
  color: var(--stp-black);
  margin: 0;
}

.stp-filter-side__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.stp-filter-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--stp-red);
  border-radius: var(--stp-pill-radius);
  padding: 4px 20px;
  height: 42px;
  font-size: 18px;
  font-weight: 700;
  color: var(--stp-red);
  background: transparent;
  text-decoration: none;
  width: fit-content;
  transition: background 0.2s, color 0.2s;
  cursor: pointer;
}

.stp-filter-pill:hover,
.stp-filter-pill.is-active {
  background: var(--stp-red);
  color: var(--stp-white);
}

.stp-filter-pill--blue {
  border-color: var(--stp-blue);
  color: var(--stp-blue);
}

.stp-filter-pill--blue:hover,
.stp-filter-pill--blue.is-active {
  background: var(--stp-blue);
  color: var(--stp-white);
}

.stp-filter-pill--red {
  border-color: var(--stp-red);
  color: var(--stp-red);
}

.stp-filter-pill--red:hover,
.stp-filter-pill--red.is-active {
  background: var(--stp-red);
  color: var(--stp-white);
}

.stp-filter-pill--yellow {
  border-color: var(--stp-yellow);
  color: var(--stp-yellow);
}

.stp-filter-pill--yellow:hover,
.stp-filter-pill--yellow.is-active {
  background: var(--stp-yellow);
  color: var(--stp-black);
}

/* ── Pagination ── */
.stp-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  padding: 40px 0;
  font-size: 18px;
  font-weight: 700;
}

.stp-pagination a,
.stp-pagination span {
  color: var(--stp-black);
  text-decoration: none;
}

.stp-pagination .is-current {
  color: var(--stp-red);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.stp-pagination--blue .is-current {
  color: var(--stp-blue);
}

.stp-pagination--yellow .is-current {
  color: var(--stp-yellow);
}

/* Body row */
.stp-sistema__body {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--stp-black);
  margin: 0;
}

.stp-sistema__photo {
  width: 100%;
  height: auto;
  border-radius: 24px;
  object-fit: cover;
  display: block;
}

/* Responsive */
@media (max-width: 992px) {

  .stp-hero__illustration {
    svg, img {
      width: 100% !important;
    }
  }

  .stp-sistema__bar {
    padding: 18px 20px;
  }

  .stp-sistema__title {
    font-size: 42px;
  }

  .stp-sistema__title.subtitle {
    font-size: 28px;
  }

  .stp-sistema__body {
    font-size: 18px;
  }
}

@media (max-width: 576px) {
  .stp-sistema__bar {
    padding: 16px;
  }

  .stp-sistema__title {
    font-size: 28px;
  }

  .stp-sistema__title.subtitle {
    font-size: 18px;
  }

  .stp-sistema__body {
    font-size: 16px;
  }
}

/* --------------------------------------------------------------------------
   12. Ferma A — Stops Section
   -------------------------------------------------------------------------- */
.stp-ferma__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1rem;
}

/* Tratta route pill (yellow, for Ferma section) */
.stp-route-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--stp-yellow);
  border-radius: var(--stp-pill-radius);
  padding: 4px 20px;
  height: 42px;
}

.stp-route-pill__name {
  font-size: 18px;
  font-weight: 700;
}

.stp-route-pill__sep {
  width: 1.5px;
  height: 22px;
  background: rgba(0, 0, 0, 0.2);
}

.stp-route-pill__route {
  font-size: 18px;
  font-weight: 400;
}

/* Stops scroll container */
.stp-stops {
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  padding: 0 var(--stp-px);
}

.stp-stops::-webkit-scrollbar {
  display: none;
}

/* When inside a Bootstrap container, drop the wrapper padding (container handles it) */
.container .stp-stops,
.stp-stops[data-stp-autoplay] {
  padding: 0;
}

/* Autoplay variant: overflow visible so the strip bleeds beyond container edge */
.stp-stops[data-stp-autoplay] {
  overflow: visible;
}

.stp-stops[data-stp-autoplay] .stp-stops__inner {
  will-change: transform;
}

.stp-stops__inner {
  display: flex;
  gap: 15px;
  position: relative;
  /* space for timeline */
}

/* Timeline horizontal line */
/*.stp-stops__inner::after {
  content: '';
  position: absolute;
  top: 269px;
  left: -100%;
  right: 0;
  height: 6px;
  background: var(--stp-yellow);
  pointer-events: none;
  width: 9999px;
  overflow: visible;
}*/

.stp-stop {
  flex-shrink: 0;
  width: 370px;
  display: flex;
  flex-direction: column;
}

.stp-stop__photo {
  width: 370px;
  height: 257px;
  object-fit: cover;
  border-radius: 12px;
  display: block;
}

.stp-stop__bottom {
  position: relative;
  height: 60px;
}

.stp-stop__linee {
  position: absolute;
  top: 12px;
  right: 0;
  height: 6px;
  background: var(--stp-yellow);
  pointer-events: none;
  width: 9999px;
  overflow: visible;
}

.stp-stop__dot {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 3px solid var(--stp-black);
  background: var(--stp-white);
  z-index: 1;
}

.stp-stop__label-bg {
  position: relative;
  margin-top: 30px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--stp-yellow);
  border-radius: var(--stp-pill-radius);
  padding: 2px 8px;
}

.stp-stop__name {
  font-size: 16px;
  font-weight: 600;
  white-space: nowrap;
  z-index: 1;
}

.stp-ferma__caption {
  padding-top: 16px;
  font-size: 18px;
  font-weight: 400;
  color: var(--stp-gray-label);
}

/* --------------------------------------------------------------------------
   13. Footer
   -------------------------------------------------------------------------- */
.stp-footer {
  background-color: var(--stp-beige);
  position: relative;
  overflow: hidden;
}

.stp-footer__address, .stp-footer__caf-address, .stp-footer__address p, .stp-footer__caf-address p {
  font-size: 14px;
  font-weight: 500;
  color: var(--stp-black);
  margin-bottom: 0 !important;
}

.stp-footer__comune {
  width: 75px;
  height: 75px;
  flex-shrink: 0;
  object-fit: cover;
}

.stp-footer__spacer {
  flex: 1;
}

.stp-footer__bar {
  background: var(--stp-yellow);
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  padding: 0 20px;

  a {
    font-family: var(--stp-font-secondary);
    font-size: 16px;
    font-weight: 700;
    color: var(--stp-black);
    text-decoration: underline;
  }
}

.stp-footer__address, .stp-footer__caf-address {
  font-style: normal;
}

.stp-footer__sis-logo {
  max-width: 175px;
  aspect-ratio: 25/14;
}

.stp-footer__caf-logo {
  max-width: 140px;
  aspect-ratio: 14/5;
}

.stp-footer__comune {
  aspect-ratio: 1/1;
  width: 75px;
  height: 75px;
}

@media (max-width: 992px) {
  .stp-footer__bar {
    height: unset;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    padding: 20px;
  }

  .stp-ferma__header {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
}

/* sistema tram palermo */
.content-sistema {
  h1, h2, h2, h3, h4, h5, a {
    color: var(--stp-yellow);
    font-weight: bold;
  }
}

/* Rigenerazione Urbana Gallery Carousel */
#rigenerazioneCarousel .rg-img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

@media (max-width: 992px) {
  #rigenerazioneCarousel .rg-img {
    height: 420px;
  }

  .img-rigenerazione {
    height: 300px;
  }
}

@media (max-width: 768px) {
  #rigenerazioneCarousel .rg-img {
    height: 320px;
  }
}

/* --------------------------------------------------------------------------
   14. Multi-card Slider (Ordinanze, Rassegna — reusable)
   -------------------------------------------------------------------------- */

/* Outer: clips overflow on right, aligns left with section padding */
.stp-slider {
  overflow: hidden;
  cursor: grab;
  user-select: none;
}

.stp-slider:active {
  cursor: grabbing;
}

/* Sliding track: flex row, animates via transform */
.stp-slider__track {
  display: flex;
  gap: 15px;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

/* Cards inside slider: fixed width — 4 visibili nel container (Figma: 274px, gap 15) */
.stp-slider .stp-news-card {
  flex: 0 0 274px;
  width: 274px;
  /* override any width set outside slider context */
  min-height: 382px;
}

/* Arrow buttons */
.stp-slider-arrow {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
}

.stp-slider-arrow:disabled {
  opacity: 0.3;
  cursor: default;
}

.stp-slider-arrow svg {
  display: block;
}

/* Ordinanze section top-level spacing */
.stp-ordinanze-title {
  color: var(--stp-red);
}

/* --------------------------------------------------------------------------
   15. Single — CPT Tratta
   -------------------------------------------------------------------------- */
.stp-single-tratta {
  padding-bottom: 80px;
}

/* Intro card: beige, below title bar */
.stp-tratta-intro {
  background: var(--stp-beige);
  border-radius: var(--stp-card-radius);
  padding: 32px 40px 36px;
  margin-top: 24px;
}

.stp-tratta-intro__label {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--stp-black);
}

.stp-tratta-intro__name {
  font-size: 24px;
  font-weight: 700;
  color: var(--stp-yellow);
  margin-bottom: 24px;
}

.stp-tratta-intro__map {
  width: 100%;
  object-fit: contain;
}

/* Immagine in evidenza tratta */
.stp-tratta-intro__img-wrap {
  width: 100%;
}

.stp-tratta-intro__img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 400px;
  /* immagine orizzontale: altezza massima */
  object-fit: contain;
}

@media (max-width: 767.98px) {

  /* Su mobile l'immagine (orizzontale) viene ruotata in verticale:
     larga quanto il contenitore e centrata.
     --ar = larghezza/altezza reale dell'immagine, impostata inline nel template. */
  .stp-tratta-intro__img-wrap {
    position: relative;
    aspect-ratio: 1 / var(--ar, 1.6);
    overflow: hidden;
  }

  .stp-tratta-intro__img {
    position: absolute;
    top: 50%;
    left: 50%;
    width: auto;
    max-width: none;
    /* annulla il global img{max-width:100%} che la teneva piccola */
    max-height: none;
    /* annulla il max-height dello stato orizzontale */
    height: calc(100% / var(--ar, 1.6));
    transform: translate(-50%, -50%) rotate(90deg);
    transform-origin: center;
  }
}

/* Two-column section */
.stp-tratta-apertura__title {
  font-size: 40px;
  font-weight: 700;
  line-height: 1.15;
  color: var(--stp-yellow);
  margin-bottom: 16px;
}

.stp-tratta-apertura__body {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  color: var(--stp-black);
  margin-bottom: 32px;
}

.stp-tratta-apertura__photo {
  width: 100%;
  height: 100%;
  min-height: 400px;
  object-fit: cover;
  border-radius: var(--stp-card-radius);
  display: block;
}

/* Avanzamento card — extends stp-tratta__card */
.stp-avanzamento-card {
  background: var(--stp-yellow);
  border-radius: var(--stp-card-radius);
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Navigazione altre tratte */
.stp-tratte-nav {
  background: #2B2B2B;
  border-radius: var(--stp-card-radius);
  padding: 1.5rem 2.5rem;
}

.stp-tratte-nav__title {
  font-size: 40px;
  font-weight: 700;
  color: var(--stp-white);
  white-space: nowrap;
  margin: 0;
  padding-bottom: 1.5rem;
}

@media (max-width: 992px) {
  .stp-tratte-nav__title {
    font-size: 22px;
  }
}

.stp-tratte-nav__list {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.stp-tratte-nav__item {
  width: 45%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--stp-yellow);
  border-radius: var(--stp-pill-radius);
  padding: 6px 24px;
  text-decoration: none;
  overflow: hidden;
  transition: opacity 0.2s;
}

@media (max-width: 992px) {
  .stp-tratte-nav__list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
  }

  .stp-tratte-nav__item {
    width: 100%;
  }
}

.stp-tratte-nav__item:hover {
  opacity: 0.85;
}

.stp-tratte-nav__item .stp-route-badge__name {
  font-size: 18px;
  font-weight: 700;
  color: var(--stp-black);
  white-space: nowrap;
}

.stp-tratte-nav__item .stp-route-badge__sep {
  width: 1.5px;
  height: 26px;
  background: rgba(0, 0, 0, 0.25);
  flex-shrink: 0;
}

@media (max-width: 992px) {
  .stp-tratta-intro {
    padding: 24px 28px;
  }

  .stp-tratta-apertura__title {
    font-size: 30px;
  }

  .stp-tratta-apertura__photo {
    min-height: 280px;
  }

  .stp-tratte-nav {
    padding: 24px 28px;
    gap: 20px;
  }
}

@media (max-width: 576px) {
  .stp-tratta-intro {
    padding: 20px;
  }

  .stp-tratta-apertura__title {
    font-size: 26px;
  }

  .stp-tratte-nav {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* --------------------------------------------------------------------------
   16. Single Post
   -------------------------------------------------------------------------- */
.stp-single {
  padding-top: 40px;
}

/* Header card — beige rounded, full-width */
.stp-single__header {
  background: var(--stp-beige);
  border-radius: var(--stp-card-radius);
  padding: 32px 40px 36px;
  margin-bottom: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Small category label above title */
.stp-single__cat {
  font-size: 16px;
  font-weight: 700;
  text-transform: none;
  text-decoration: none;
}

.stp-single__cat--red {
  color: var(--stp-red);
}

.stp-single__cat--blue {
  color: var(--stp-blue);
}

.stp-single__cat--yellow {
  color: var(--stp-yellow);
}

/* Post title */
.stp-single__title {
  font-size: 42px;
  font-weight: 700;
  line-height: 1.15;
  margin: 0;
  color: var(--stp-black);
}

/* Pills row */
.stp-single__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

/* Date below header */
.stp-single__date {
  font-size: 14px;
  font-weight: 400;
  color: var(--stp-gray);
  margin-bottom: 24px;
}

/* Post content typography */
.stp-single__content {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  color: var(--stp-black);

  h1, h2, h3, h4, h5 {
    font-family: 'Urbanist', sans-serif;
    color: #FAAB00;
  }

  h2 {
    font-size: 26px;
    font-weight: 700;
  }

  h3 {
    font-size: 28px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
  }

  strong {
    font-weight: 700;
  }

  a {
    color: var(--stp-red);
    text-decoration: underline;
  }
}

.tram-in-movimento {
  position: absolute;
  top: 50%;
  left: 0;
  height: 100%;
  width: auto;
  max-width: none;
  will-change: transform;
  animation: treno-attraversa 10s linear infinite;
}

@keyframes treno-attraversa {
  from {
    transform: translate(100vw, -50%);
  }

  to {
    transform: translate(-100%, -50%);
  }
}

/* "Altre News" sidebar */
.stp-sidebar-news__heading {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 20px;
}

.stp-sidebar-news__heading--red {
  color: var(--stp-red);
}

.stp-sidebar-news__heading--blue {
  color: var(--stp-blue);
}

.stp-sidebar-news__heading--yellow {
  color: var(--stp-yellow);
}

/* Compact related post card (reuses stp-news-card base, smaller gap) */
.stp-sidebar-card {
  background: var(--stp-beige);
  border-radius: var(--stp-card-radius);
  padding: 16px;
  text-decoration: none;
  color: var(--stp-black);
  transition: transform 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.stp-sidebar-card:last-child {
  margin-bottom: 0;
}

.stp-sidebar-card:hover {
  transform: translateY(-2px);
  color: var(--stp-black);
}

.stp-sidebar-card__tag-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.stp-sidebar-card__title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

.stp-sidebar-card__date {
  font-size: 13px;
  font-weight: 400;
  color: var(--stp-gray);
  margin: 0;
}

/* Allegati section */
.stp-allegati {
  padding: 2rem;
  border-radius: var(--stp-card-radius);
  background: var(--stp-beige);
}

.stp-allegati__title, .stp-ordinanze-title {
  font-size: 40px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--stp-black);
}

.stp-allegati__card {
  display: flex;
  align-items: center;
  gap: 14px;
  /* padding: 20px 28px; */
  margin-bottom: 12px;
  text-decoration: none;
  color: var(--stp-black);
  transition: transform 0.2s ease;
}

.stp-allegati__card:last-child {
  margin-bottom: 0;
}

.stp-allegati__card:hover {
  transform: translateY(-1px);
  color: var(--stp-black);
}

.stp-allegati__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stp-allegati__name {
  font-size: 16px;
  font-weight: 500;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 3px;
  flex: 1;
}

.stp-allegati__size {
  font-size: 14px;
  font-weight: 400;
  color: var(--stp-gray);
  white-space: nowrap;
}

.stp-ordinanza__card {
  background: var(--stp-beige);
  padding: 1.5rem;
  border-radius: var(--stp-card-radius);
  color: var(--stp-black);

  span {
    font-size: 16px;
    font-weight: 500;
  }
}

/* Responsive single */
@media (max-width: 992px) {
  .stp-single__header {
    padding: 24px 28px;
  }

  .stp-single__title {
    font-size: 32px;
  }
}

@media (max-width: 576px) {
  .stp-single__header {
    padding: 20px;
  }

  .stp-single__title {
    font-size: 26px;
  }

  .stp-single__content {
    font-size: 15px;
  }
}

/* ==========================================================================
   RESPONSIVE OVERRIDES
   ========================================================================== */

/* ── xxl: ≥1400px — design at its full 1440px intent ── */
@media (max-width: 1400px) {
  :root {
    --stp-px: 80px;
  }

  .stp-hero__title {
    font-size: 52px;
  }

  .stp-tratta__content {
    gap: 30px;
  }

  .stp-tratta__map {
    width: 100%;
  }

  .stp-vetture__left {
    flex: 0 0 460px;
  }

  .stp-footer__logos {
    padding-left: 80px;
    padding-right: 80px;
  }
}

/* ── xl: ≥1200px ── */
@media (max-width: 1200px) {
  :root {
    --stp-px: 60px;
  }

  .stp-section-title {
    font-size: 34px;
  }

  .stp-tratta__map {
    width: 100%;
  }

  .stp-vetture__left {
    flex: 0 0 400px;
    padding: 40px;
  }

  .stp-footer__logos {
    padding-left: 60px;
    padding-right: 60px;
    gap: 24px;
  }
}

/* ── lg: ≥992px ── */
@media (max-width: 992px) {
  :root {
    --stp-px: 40px;
    --stp-section-gap: 100px;
  }

  .stp-hero__title {
    font-size: 42px;
    max-width: 100%;
  }

  .stp-tratta__nav-row {
    width: 100%;
  }

  .stp-tratta__content {
    flex-direction: column;
    align-items: stretch;
    gap: 24px;
  }

  .stp-tratta__card-tram {
    height: 200px;
  }

  .stp-tratta__map-wrap {
    width: 100%;
  }

  .stp-tratta__map {
    width: 100%;
    height: 300px;
  }

  .stp-vetture__card {
    flex-direction: column;
  }

  .stp-vetture__left {
    flex: none;
    padding: 40px;
  }

  .stp-vetture__image {
    min-height: 250px;
  }

  .stp-reel {
    height: 380px;
  }

  .stp-reel__photo {
    width: 320px;
    height: 380px;
  }

  .stp-reel__overlay {
    width: calc(100% - 80px);
    padding: 20px 24px;
  }

  .stp-reel__text {
    font-size: 20px;
  }

  .stp-stops {
    padding: 0 var(--stp-px);
  }

  .stp-stop {
    width: 280px;
  }

  .stp-stop__photo {
    width: 280px;
    height: 190px;
  }

  .stp-footer__logos {
    flex-wrap: wrap;
    padding: 40px;
    gap: 24px;
  }

  .stp-footer__bar {
    gap: 24px;
  }

  .stp-footer__bar a {
    font-size: 14px;
  }
}

/* ── md: ≥768px ── */
@media (max-width: 768px) {
  :root {
    --stp-px: 24px;
  }

  .stp-section-title {
    font-size: 28px;
  }

  .stp-hero__title {
    font-size: 38px;
  }

  .stp-tratta__slide-title {
    font-size: 28px;
  }

  .stp-route-badge__name {
    font-size: 18px;
  }

  .stp-avanzamenti__title {
    font-size: 22px;
  }

  .stp-progress-item__pct {
    font-size: 22px;
  }

  .stp-vetture__title {
    font-size: 28px;
  }

  .stp-vetture__body {
    font-size: 16px;
  }

  .stp-news-card {
    width: 100%;
  }

  /* Slider: mobile — 1 card + peek of next */
  .stp-slider .stp-news-card {
    flex: 0 0 calc(100vw - var(--stp-px) - 48px);
    width: calc(100vw - var(--stp-px) - 48px);
  }

  .stp-reel__track {
    gap: 10px;
    /* piccolo gap — JS legge questo valore da getComputedStyle */
  }

  .stp-reel__overlay {
    bottom: 16px;
    width: calc(100% - 32px);
    padding: 14px 18px;
  }

  .stp-reel__text {
    font-size: 24px;
    white-space: normal;
    text-align: center;
  }

  /* Rassegna hero — mobile */
  .stp-rassegna-hero {
    min-height: 460px;
    background-position: center right -120px;
  }

  .stp-rassegna-hero::before {
    background: linear-gradient(180deg,
        rgba(0, 0, 0, 0.85) 0%,
        rgba(0, 0, 0, 0.55) 60%,
        rgba(0, 0, 0, 0.30) 100%);
  }

  .stp-rassegna-hero__content {
    padding: 36px 28px;
    max-width: 100%;
  }

  .stp-rassegna-hero__title {
    font-size: 26px;
  }

  .stp-rassegna-hero__body {
    font-size: 15px;
  }

  .stp-rassegna-hero__heading {
    font-size: 36px;
  }

  .stp-rassegna-hero--yellow .stp-rassegna-hero__body {
    font-size: 24px;
  }

  .stp-footer__logos {
    flex-direction: column;
    align-items: flex-start;
  }

  .stp-footer__spacer {
    display: none;
  }
}

/* ── sm: <576px ── */
@media (max-width: 576px) {
  :root {
    --stp-px: 16px;
  }

  .stp-hero__title {
    font-size: 38px;
  }

  .stp-hero__intro {
    font-size: 15px;
  }

  .stp-tratta__card-body {
    padding: 32px 24px 28px;
    gap: 24px;
  }

  .stp-tratta__card-tram {
    height: 160px;
    right: -20px;
  }

  .stp-vetture__left {
    padding: 28px 20px;
  }

  .stp-section-header {
    padding-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
  }

  .stp-footer__bar {
    height: auto;
    padding: 16px 20px;
    gap: 16px;
    flex-direction: column;
    align-items: center;
  }
}