/* Home — hero compatto e professionale */

.page-hero--home {
  padding: calc(var(--site-header) + 1.65rem) 0 1.5rem;
  overflow: hidden;
}

.page-hero--home .page-hero__bg {
  background-image:
    linear-gradient(
      180deg,
      transparent 0%,
      transparent 52%,
      rgba(0, 61, 74, 0.42) 78%,
      rgba(0, 61, 74, 0.72) 100%
    ),
    radial-gradient(circle at 82% 38%, rgba(0, 163, 184, 0.22) 0%, transparent 52%),
    radial-gradient(circle at 12% 88%, rgba(255, 255, 255, 0.05) 0%, transparent 42%),
    linear-gradient(
      102deg,
      rgba(0, 45, 55, 0.94) 0%,
      rgba(0, 61, 74, 0.82) 36%,
      rgba(0, 61, 74, 0.48) 58%,
      rgba(0, 104, 128, 0.18) 100%
    ),
    url('../assets/img/hero-bg.png');
  background-size: 100% 100%, 100% 100%, 100% 100%, 100% 100%, cover;
  background-position: center, center, center, center, 68% center;
  background-repeat: no-repeat;
}

.page-hero--home .page-hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 48, 58, 0.88) 0%,
    rgba(0, 48, 58, 0.5) 36%,
    rgba(0, 61, 74, 0.12) 60%,
    transparent 78%
  );
  pointer-events: none;
}

.page-hero--home .page-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(268px, 0.88fr);
  gap: 2.15rem;
  align-items: center;
}

.home-hero-main {
  min-width: 0;
  padding: 0.25rem 0;
}

.home-hero-text {
  position: relative;
  min-width: 0;
  max-width: 40rem;
  padding-left: 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.home-hero-text::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.1rem;
  bottom: 0.1rem;
  width: 2px;
  border-radius: 2px;
  background: linear-gradient(
    180deg,
    rgba(158, 234, 245, 0.9) 0%,
    rgba(125, 232, 247, 0.35) 42%,
    rgba(255, 255, 255, 0.08) 100%
  );
}

.home-hero-intro {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.home-hero-body {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-top: 0.1rem;
}

.page-hero--home .page-hero__eyebrow {
  margin-bottom: 0.9rem;
  font-size: 0.7rem;
  padding: 0.36rem 0.7rem;
}

.page-hero--home .hero__brand {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.86);
  margin-bottom: 0;
  padding-bottom: 0.85rem;
  border-bottom: none;
  position: relative;
}

.page-hero--home .hero__brand::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: min(100%, 15rem);
  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(158, 234, 245, 0.85) 0%,
    rgba(255, 255, 255, 0.32) 58%,
    transparent 100%
  );
}

.page-hero--home .hero__title {
  margin: 0;
}

.page-hero--home .hero__title-lines {
  display: block;
  margin-top: 1rem;
  min-height: clamp(3.2rem, 7.8vw, 4.75rem);
}

.page-hero--home .hero__title-line {
  display: block;
  font-size: clamp(1.8rem, 3.3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--color-white);
  text-shadow: 0 2px 20px rgba(0, 28, 34, 0.2);
}

.page-hero--home .hero__title-line--accent {
  margin-top: 0.12rem;
  color: #a8eef6;
}

.page-hero--home .hero__tagline {
  margin: 0;
  max-width: 50ch;
  font-size: 0.96875rem;
  font-weight: 400;
  line-height: 1.58;
  color: rgba(255, 255, 255, 0.84);
}

.home-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0;
}

.home-hero-meta__item {
  display: inline-flex;
  align-items: center;
  padding: 0.34rem 0.7rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: rgba(255, 255, 255, 0.74);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.home-hero-aside {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 0;
  position: relative;
  z-index: 3;
}

.page-hero--home .hero__live-card {
  padding: 0.95rem 1rem 1rem;
  border-radius: 14px;
  box-shadow:
    0 12px 28px rgba(0, 28, 34, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}

.page-hero--home .hero__live-card__glow {
  opacity: 0.65;
}

.page-hero--home .hero__live-head {
  margin-bottom: 0.65rem;
  padding: 0.28rem 0.55rem 0.28rem 0.45rem;
  font-size: 0.58rem;
}

.page-hero--home .hero__live-metrics {
  gap: 0.55rem;
}

.page-hero--home .hero__live-metric {
  padding: 0.65rem 0.75rem;
  border-radius: 12px;
}

.page-hero--home .hero__live-num {
  font-size: 1.65rem;
}

.page-hero--home .hero__live-num--sm {
  font-size: 1.2rem;
}

.page-hero--home .hero__live-label-main {
  font-size: 0.72rem;
}

.page-hero--home .hero__live-label-period {
  font-size: 0.65rem;
}

.page-hero--home .home-hero-hours {
  padding: 0.95rem 1rem 1rem;
  border-radius: 14px;
  box-shadow: var(--shadow-md);
}

.page-hero--home .home-hero-hours h3 {
  margin-bottom: 0.65rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-primary-dark);
}

.page-hero--home .hours-schedule__head,
.page-hero--home .hours-schedule__row {
  font-size: 0.78rem;
}

/* Barra tasti: rientra nella fascia blu con sfumatura (come design originale) */
.page-hero--home + .quick-actions {
  margin-top: -2rem;
  padding-top: 0;
  padding-bottom: 1rem;
  position: relative;
  z-index: 2;
}

.page-hero--home + .quick-actions .quick-actions__grid {
  background:
    linear-gradient(
      180deg,
      rgba(0, 95, 115, 0.14) 0%,
      rgba(230, 244, 247, 0.72) 22%,
      rgba(255, 255, 255, 0.97) 52%,
      #ffffff 100%
    ),
    linear-gradient(
      90deg,
      rgba(13, 115, 119, 0.12) 0%,
      rgba(230, 244, 247, 0.45) 32%,
      rgba(255, 255, 255, 0.98) 68%,
      #ffffff 100%
    );
  border-color: rgba(255, 255, 255, 0.55);
  box-shadow:
    0 14px 34px rgba(0, 30, 38, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.65);
  padding-top: 1.45rem;
}

@media (min-width: 901px) {
  /* I box prelievi/orari restano sopra la zona di overlap della barra */
  .home-hero-aside {
    margin-bottom: 2.25rem;
  }
}

@media (max-width: 992px) {
  .page-hero--home .hero__tagline {
    max-width: none;
  }
}

/* Area Referti nel box quick-actions (desktop e mobile) */
.page-hero--home + .quick-actions .quick-action--referti {
  background: linear-gradient(145deg, #004a5a 0%, #006880 52%, #008ea6 100%);
  border-color: rgba(125, 232, 247, 0.38);
  color: var(--color-white);
  box-shadow:
    0 10px 22px rgba(0, 45, 55, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    inset 0 0 0 1px rgba(0, 163, 184, 0.18);
}

.page-hero--home + .quick-actions .quick-action--referti .quick-action__icon {
  color: #9eeaf5;
  filter: drop-shadow(0 0 6px rgba(125, 232, 247, 0.4));
}

.page-hero--home + .quick-actions .quick-action--referti .quick-action__label,
.page-hero--home + .quick-actions .quick-action--referti .quick-action__label--stack span {
  color: rgba(255, 255, 255, 0.96);
}

.page-hero--home + .quick-actions .quick-action--referti:hover {
  background: linear-gradient(145deg, #005f73 0%, #007a94 55%, #00a3b8 100%);
  border-color: rgba(158, 234, 245, 0.5);
  color: var(--color-white);
  box-shadow:
    0 12px 26px rgba(0, 45, 55, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

@media (max-width: 900px) {
  .home-hero-body {
    gap: 0;
  }

  .page-hero--home + .quick-actions {
    margin-top: -1.2rem;
    padding-bottom: 0.75rem;
  }

  .page-hero--home + .quick-actions .quick-actions__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
    gap: 0.6rem;
    max-width: none;
    width: 100%;
    margin-inline: 0;
    padding: 0.9rem 0.85rem 0.85rem;
    padding-top: 1.05rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.42);
    box-shadow:
      0 10px 28px rgba(0, 30, 38, 0.09),
      inset 0 1px 0 rgba(255, 255, 255, 0.38);
    background:
      linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.14) 0%,
        rgba(230, 244, 247, 0.78) 40%,
        rgba(255, 255, 255, 0.94) 100%
      );
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
  }

  .page-hero--home + .quick-actions .quick-action {
    aspect-ratio: auto;
    min-height: 4.85rem;
    padding: 0.62rem 0.4rem 0.66rem;
    gap: 0.4rem;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.62);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45);
  }

  .page-hero--home + .quick-actions .quick-action__icon {
    width: 38px;
    height: 38px;
  }

  .page-hero--home + .quick-actions .quick-action__icon svg {
    width: 24px;
    height: 24px;
  }

  .page-hero--home + .quick-actions .quick-action__label {
    font-size: 0.68rem;
    letter-spacing: 0.032em;
    line-height: 1.22;
  }

  .page-hero--home + .quick-actions .quick-action__label--stack {
    gap: 0.06rem;
  }

  .page-hero--home + .quick-actions .quick-action--referti {
    background: linear-gradient(145deg, rgba(0, 74, 90, 0.92) 0%, rgba(0, 104, 128, 0.9) 52%, rgba(0, 142, 166, 0.88) 100%);
    border-color: rgba(125, 232, 247, 0.35);
    box-shadow:
      0 6px 16px rgba(0, 45, 55, 0.16),
      inset 0 1px 0 rgba(255, 255, 255, 0.14);
  }

  .page-hero--home + .quick-actions .quick-action--referti .quick-action__icon {
    filter: drop-shadow(0 0 5px rgba(125, 232, 247, 0.38));
  }

  .page-hero--home {
    padding: calc(var(--site-header) + 1rem) 0 1.15rem;
  }

  .page-hero--home .page-hero__bg::after {
    background: linear-gradient(
      180deg,
      rgba(0, 48, 58, 0.82) 0%,
      rgba(0, 48, 58, 0.62) 42%,
      rgba(0, 61, 74, 0.28) 100%
    );
  }

  .page-hero--home .page-hero__inner {
    grid-template-columns: 1fr;
    gap: 1.05rem;
    align-items: stretch;
  }

  .home-hero-main {
    padding: 0;
  }

  .home-hero-text {
    max-width: min(36rem, 100%);
    padding-left: 0;
    padding-inline: 0.5rem;
    text-align: center;
    align-items: center;
    gap: 0.75rem;
  }

  .home-hero-intro {
    width: 100%;
    max-width: min(22rem, 92vw);
    margin-inline: auto;
  }

  .home-hero-text::before {
    display: none;
  }

  .home-hero-intro,
  .home-hero-body {
    align-items: center;
  }

  .page-hero--home .page-hero__eyebrow {
    margin-bottom: 0.7rem;
    margin-inline: auto;
  }

  .page-hero--home .hero__brand {
    display: inline-block;
  }

  .page-hero--home .hero__brand::after {
    left: 50%;
    transform: translateX(-50%);
    width: min(13rem, 78vw);
  }

  .page-hero--home .hero__title-lines {
    margin-top: 0.8rem;
    min-height: clamp(2.75rem, 10.5vw, 3.45rem);
  }

  .page-hero--home .hero__title-line {
    font-size: clamp(1.55rem, 5.2vw, 1.95rem);
  }

  .page-hero--home .hero__tagline {
    margin: 0.25rem auto 0;
    max-width: 100%;
    font-size: 0.9rem;
    line-height: 1.5;
    text-wrap: balance;
  }

  .home-hero-body {
    gap: 0;
    width: 100%;
    max-width: min(21rem, 92vw);
    margin-inline: auto;
    padding-bottom: 0;
  }

  .home-hero-meta {
    display: none;
  }

  .home-hero-aside {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.7rem;
    align-items: stretch;
    margin-top: 0.2rem;
    margin-bottom: 1.15rem;
  }

  .page-hero--home .hero__live-card,
  .page-hero--home .home-hero-hours {
    height: auto;
  }

  .page-hero--home .hero__live-metrics {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .page-hero--home {
    padding: calc(var(--site-header) + 0.85rem) 0 0.8rem;
  }

  .page-hero--home .page-hero__inner {
    gap: 0.9rem;
  }

  .home-hero-text {
    gap: 0.65rem;
    padding-inline: 0.25rem;
  }

  .home-hero-intro {
    max-width: min(20rem, 94vw);
  }

  .home-hero-body {
    max-width: min(20rem, 94vw);
    gap: 0;
  }

  .page-hero--home .hero__brand {
    padding-bottom: 0.7rem;
  }

  .page-hero--home .hero__title-lines {
    margin-top: 0.65rem;
    min-height: clamp(2.35rem, 11.5vw, 2.95rem);
  }

  .page-hero--home .hero__title-line {
    font-size: clamp(1.36rem, 6.2vw, 1.65rem);
    line-height: 1.16;
  }

  .page-hero--home .hero__tagline {
    font-size: 0.84rem;
    line-height: 1.48;
  }

  .page-hero--home .hero__live-card {
    padding: 0.85rem 0.9rem 0.9rem;
  }

  .page-hero--home .hero__live-num {
    font-size: 1.45rem;
  }

  .page-hero--home .home-hero-hours {
    padding: 0.85rem 0.9rem 0.9rem;
  }

  .home-hero-aside {
    margin-top: 0.15rem;
    margin-bottom: 0.85rem;
  }

  .page-hero--home + .quick-actions {
    margin-top: -1.1rem;
  }

  .page-hero--home + .quick-actions .quick-actions__grid {
    gap: 0.55rem;
    padding: 0.82rem 0.78rem 0.78rem;
    padding-top: 0.95rem;
  }

  .page-hero--home + .quick-actions .quick-action {
    min-height: 4.6rem;
    padding: 0.58rem 0.35rem 0.62rem;
    gap: 0.36rem;
  }

  .page-hero--home + .quick-actions .quick-action__icon {
    width: 36px;
    height: 36px;
  }

  .page-hero--home + .quick-actions .quick-action__icon svg {
    width: 22px;
    height: 22px;
  }

  .page-hero--home + .quick-actions .quick-action__label {
    font-size: 0.65rem;
  }
}
