:root {
  --brand: #0a7493;        /* turchese del logo */
  --brand-2: #0e9cc4;
  --sun: #ffb703;          /* accento caldo, sole di Menorca */
  --ink: #0b1f2a;
  --bg: #f4f8fa;
  --card: #ffffff;
  --navy: #06202e;
  --muted: #5b7180;
  --line: #dde7ec;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(6, 32, 46, .12);
  --player-h: 76px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: Inter, system-ui, sans-serif; color: var(--ink); background: var(--bg);
  padding-bottom: var(--player-h); line-height: 1.55;
}
h1, h2, h3, .prog-name, .song-title, .btn, .mainnav a { font-family: Montserrat, Inter, sans-serif; }
img { max-width: 100%; height: auto; display: block; } /* height: auto = mai deformate quando si restringono */
a { color: var(--brand); }
.muted { color: var(--muted); }
.wrap { max-width: 1180px; margin: 0 auto; padding: 48px 20px; }
.wrap.narrow { max-width: 760px; }
.page { display: none; }
.page.active { display: block; }
.page-title { font-size: clamp(30px, 4vw, 44px); margin: 0 0 8px; }
.section-title { font-size: 24px; margin: 48px 0 18px; }
.label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; }

/* ---------- Header ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50; display: flex; align-items: center; gap: 24px;
  padding: 10px 24px; background: rgba(6, 32, 46, .96); backdrop-filter: blur(8px);
}
.brand img { height: 46px; width: auto; }
.mainnav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.mainnav a {
  color: #d7e9f0; text-decoration: none; font-weight: 600; font-size: 14px; padding: 8px 12px; border-radius: 999px;
}
.mainnav a:hover { background: rgba(255,255,255,.08); }
.mainnav a.active { background: var(--brand); color: #fff; }
.nav-sep { width: 1px; height: 20px; align-self: center; margin: 0 8px; background: var(--sun); } /* prima di News, Sport e Meteo */
.nav-group { display: flex; gap: 4px; flex-wrap: nowrap; }
.langs { display: flex; gap: 4px; }
.langs button {
  background: transparent; border: 1px solid rgba(255,255,255,.25); color: #d7e9f0; border-radius: 8px;
  font: 600 12px Inter, sans-serif; padding: 6px 8px; cursor: pointer;
}
.langs button.active { background: var(--sun); border-color: var(--sun); color: var(--navy); }
.burger { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.burger span { display: block; width: 24px; height: 2px; background: #fff; margin: 5px 0; }

/* ---------- Bottoni ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px; border: 0; cursor: pointer; text-decoration: none;
  background: var(--sun); color: var(--navy); font-weight: 700; font-size: 16px; padding: 14px 24px; border-radius: 999px;
  box-shadow: 0 6px 18px rgba(255, 183, 3, .35); transition: transform .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--brand); border: 2px solid var(--brand); box-shadow: none; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.pi { display: inline-grid; width: 20px; height: 20px; place-items: center; }
.pi > * { grid-area: 1 / 1; width: 20px; height: 20px; }
.pi .i-pause, .pi .i-load { display: none; }
body.playing .pi .i-play, body.loading .pi .i-play { display: none; }
body.playing .pi .i-pause { display: block; }
body.loading .pi .i-load {
  display: block; border-radius: 50%; border: 3px solid currentColor; border-right-color: transparent;
  animation: spin .8s linear infinite; box-sizing: border-box;
}
@keyframes spin { to { transform: rotate(360deg); } }

.pill {
  display: inline-flex; align-items: center; gap: 6px; background: var(--sun); color: var(--navy);
  font: 700 11px Inter, sans-serif; text-transform: uppercase; letter-spacing: .06em; padding: 4px 10px; border-radius: 999px;
}
.live-pill { background: #e63946; color: #fff; font-size: 10px; padding: 3px 9px; gap: 5px; vertical-align: top; margin-top: 4px; } /* un po' più piccolo del bollino standard */
.live-pill i { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .2; } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; color: #fff; background: var(--navy); }
.hero-bg {
  position: absolute; inset: 0 -28% 0 28%; background: url(../img/fondo.jpg) center/cover; /* foto spostata a destra: il microfono non sta sotto le scritte */
  opacity: .35; filter: saturate(1.2);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 30%);   /* il bordo sinistro della foto sfuma nel blu */
  mask-image: linear-gradient(to right, transparent 0%, #000 30%);
}
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(6,32,46,.95) 0%, rgba(10,116,147,.55) 100%); }
.hero-inner {
  position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 20px 20px 72px; /* in alto: "In diretta" alla stessa altezza di YouTube */
  display: grid; gap: 40px; align-items: center;
}
.hero h1 { font-size: clamp(34px, 5vw, 58px); line-height: 1.05; margin: 16px 0; }
.hero-logo { display: block; width: min(420px, 80vw); height: auto; aspect-ratio: 600 / 287; margin: 18px 0 4px; } /* logo animato 600x287, sempre nelle sue proporzioni */
.hero p { font-size: 18px; color: #d7e9f0; max-width: 520px; margin-bottom: 28px; }

.prog-now { display: flex; gap: 12px; align-items: center; margin-top: 8px; }
.prog-now img { width: 56px; height: 56px; border-radius: 10px; }
.prog-now .prog-name { font-weight: 800; font-size: 18px; }
.prog-now .prog-time { color: #9fd3e3; font-size: 14px; }
.prog-next { margin-top: 12px; font-size: 14px; color: #d7e9f0; }
.prog-next span { color: var(--sun); font-weight: 600; }

/* ---------- Home ---------- */
.welcome { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: stretch; } /* foto alta quanto il blocco "Sta suonando" */
.welcome-img { border-radius: var(--radius); box-shadow: var(--shadow); object-fit: cover; width: 100%; height: 100%; } /* ritaglio, mai deformata */
@media (max-width: 960px) { .welcome-img { height: auto; aspect-ratio: 4/5; } } /* cellulare: stesso formato verticale delle foto della slideshow */
.today-strip { position: relative; display: flex; gap: 14px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.today-strip::-webkit-scrollbar { display: none; }
.strip-item {
  flex: 0 0 170px; background: var(--card); border-radius: 16px; padding: 10px;
  text-decoration: none; color: var(--ink); box-shadow: 0 2px 10px rgba(6,32,46,.06); display: grid; gap: 4px; border: 2px solid transparent;
}
.strip-item img { border-radius: 10px; aspect-ratio: 1; object-fit: cover; }
.strip-time { font-weight: 700; color: var(--brand); font-size: 14px; }
.strip-name { font-weight: 600; font-size: 14px; line-height: 1.25; }
.strip-item.now { border-color: var(--sun); }
.strip-item .pill { justify-self: start; }
.promo {
  margin-top: 48px; background: linear-gradient(120deg, var(--brand), var(--brand-2)); color: #fff;
  border-radius: 24px; padding: 32px; display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap;
}
.promo h3 { margin: 0 0 6px; font-size: 24px; }
.promo p { margin: 0; color: #e3f5fa; }

/* ---------- Palinsesto ---------- */
.schedule { display: grid; gap: 14px; margin-top: 24px; }
.prog {
  display: grid; grid-template-columns: 110px 1fr; gap: 18px; align-items: center; background: var(--card);
  border-radius: var(--radius); padding: 14px; box-shadow: 0 2px 10px rgba(6,32,46,.06); border: 2px solid transparent;
}
.prog img { border-radius: 12px; aspect-ratio: 1; object-fit: cover; }
.prog .prog-time { font-weight: 700; color: var(--brand); }
.prog .prog-name { font-size: 20px; font-weight: 800; }
.prog .prog-desc { color: var(--muted); }
.prog.now { border-color: var(--sun); position: relative; }
.prog.now::after {
  content: "● ON AIR"; position: absolute; top: 14px; right: 16px; font: 700 11px Inter, sans-serif; letter-spacing: .08em;
  color: #e63946;
}
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.card { background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: 0 2px 10px rgba(6,32,46,.06); }
.card img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.card-body { padding: 16px; }
.card-body h3 { margin: 0 0 6px; }
.card-body p { margin: 0; color: var(--muted); }

/* ---------- Meteo ---------- */
.weather { margin-top: 24px; }
.w-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.w-tabs button {
  border: 2px solid var(--brand); background: transparent; color: var(--brand); border-radius: 999px; padding: 6px 14px;
  font: 600 13px Montserrat, sans-serif; cursor: pointer;
}
@media (max-width: 520px) {
  /* cellulare: le 4 lingue sempre su una riga, larghe uguali */
  .w-tabs { flex-wrap: nowrap; gap: 6px; }
  /* testo e spazi scalano con la larghezza dello schermo: restano su una riga anche sui telefoni più stretti */
  .w-tabs button { flex: 1 1 0; min-width: 0; padding: 5px 2px; font-size: clamp(9px, 3.3vw, 13px); white-space: nowrap; }
}
.w-tabs button.active { background: var(--brand); color: #fff; }
.w-card { background: var(--card); border-radius: 24px; padding: 28px; box-shadow: var(--shadow); max-width: 820px; }
.w-head { display: flex; gap: 16px; align-items: center; margin-bottom: 20px; }
.w-icon { font-size: 48px; }
.w-card audio { width: 100%; margin: 8px 0 20px; }
/* testo del bollettino, richiudibile sotto il player */

/* ---------- Squadra, partner, ascolto ---------- */
.team { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; margin-top: 24px; }
.member { background: var(--card); border-radius: var(--radius); padding: 20px; text-align: center; box-shadow: 0 2px 10px rgba(6,32,46,.06); }
.member img { width: 160px; height: 160px; border-radius: 50%; object-fit: cover; margin: 0 auto 12px; background: var(--bg); }
.member h3 { margin: 0; font-size: 22px; }
.member p { margin: 4px 0 0; color: var(--muted); }
.podcast-card { display: grid; grid-template-columns: 200px 1fr; gap: 24px; background: var(--card); border-radius: var(--radius); padding: 20px; box-shadow: 0 2px 10px rgba(6,32,46,.06); margin-top: 24px; }
.podcast-card img { border-radius: 14px; }
.partners { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; margin-top: 24px; }
.partner {
  background: var(--card); border-radius: var(--radius); padding: 20px; display: grid; place-items: center;
  box-shadow: 0 2px 10px rgba(6,32,46,.06); transition: transform .15s;
}
.partner:hover { transform: translateY(-3px); }
.partner img { height: 90px; width: 100%; object-fit: contain; }
/* computer, tablet e cellulare orizzontale: 3 riquadri per riga, solo il logo (cliccabile, apre il sito del partner) */
@media (min-width: 600px) {
  .partners { grid-template-columns: repeat(3, 1fr); }
  .partner { padding: 18px 14px; }
}
/* Come ascoltarci (js/listen.js): righe immagine tonda + riquadro sfumato, come sul vecchio sito */
.listen { margin-top: 8px; max-width: 900px; }
.listen-intro { text-align: center; margin-bottom: 28px; }
.listen-waves { width: min(300px, 70%); margin: 0 auto 14px; mix-blend-mode: multiply; }
.listen-intro p { text-align: left; font-size: 17px; }
.lrow { display: grid; grid-template-columns: 1fr 2fr; gap: 32px; align-items: start; }
.lrow-img { display: grid; justify-items: center; }
.lrow-img img { width: 180px; mix-blend-mode: multiply; } /* il bianco dei loghi Alexa sparisce sul grigio della pagina */
.lrow-img.round img { mix-blend-mode: normal; width: 160px; height: 160px; border-radius: 50%; object-fit: cover; box-shadow: 0 4px 14px rgba(6,32,46,.15); }
.lcard { background: linear-gradient(45deg, rgba(237,237,237,.07) 0%, rgba(169,183,194,.57) 100%); border-radius: 12px; padding: 16px 22px; font-size: 15px; }
.lcard h3 { margin: 0 0 6px; font-size: 16px; }
.lcard p { margin: 0 0 8px; }
.lcard p:last-child { margin-bottom: 0; }
.lcard a { color: var(--brand); font-weight: 700; }
.llist { list-style: none; padding: 0; margin: 4px 0 10px; }
.llist li::before { content: "· "; font-weight: 700; }
.llist a { color: var(--ink); }
.licons { display: flex; justify-content: space-around; align-items: center; gap: 12px; margin-top: 22px; flex-wrap: wrap; }
.licons img { width: 56px; height: 56px; object-fit: contain; border-radius: 12px; transition: transform .15s; }
.licons a:hover img { transform: scale(1.08); }
.lsep { border: 0; border-top: 2px solid #abb8c3; margin: 30px 0; }
.alexa-cmds { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.alexa-cmd { background: linear-gradient(45deg, rgba(237,237,237,.07) 0%, rgba(169,183,194,.57) 100%); border-radius: 12px; padding: 16px 10px; text-align: center; font-style: italic; font-size: 14px; }
.alexa-lang { display: block; font-style: normal; font-weight: 700; font-size: 13px; text-transform: uppercase; color: var(--ink); margin-bottom: 10px; }
.alexa-cmd p { margin: 8px 0; }
@media (max-width: 640px) {
  .lrow { grid-template-columns: 1fr; gap: 16px; }
  .lrow-img.round img { width: 140px; height: 140px; }
  .alexa-cmds { grid-template-columns: repeat(2, 1fr); }
}
.contact-list { display: grid; gap: 10px; margin-top: 24px; }
.contact-list a {
  background: var(--card); border-radius: 14px; padding: 16px 20px; text-decoration: none; color: var(--ink);
  font-weight: 600; font-size: 18px; box-shadow: 0 2px 10px rgba(6,32,46,.06);
}
.contact-list .wa-icon { width: 1.15em; height: 1.15em; vertical-align: -.2em; }

/* ---------- Footer ---------- */
.footer { background: var(--navy); color: #d7e9f0; text-align: center; padding: 40px 20px; }
.footer img { height: 100px; width: auto; margin: 0 auto 4px; }
.footer p { margin: 2px 0; line-height: 1.3; }
.footer .footer-links { font-size: 10px; } /* la riga prende l'altezza del link piccolo */
.footer .muted { color: #7f98a6; font-size: 12px; }

/* ---------- Player fisso ---------- */
.playerbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; height: var(--player-h);
  display: flex; align-items: center; gap: 14px; padding: 0 18px; background: var(--navy); color: #fff;
  box-shadow: 0 -6px 24px rgba(0,0,0,.25); border-top: 3px solid var(--brand);
}
.pb-play {
  width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--sun); color: var(--navy);
  display: grid; place-items: center; cursor: pointer; flex: 0 0 auto;
}
.pb-cover { width: 52px; height: 52px; border-radius: 8px; object-fit: cover; background: #fff; flex: 0 0 auto; }
.pb-info { min-width: 0; flex: 1; }
.pb-title { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pb-artist { color: #9fd3e3; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pb-program { font-size: 14px; color: #d7e9f0; white-space: nowrap; }
/* titolo/artista lunghi: scorrimento lento (fitMarquee in app.js).
   Sfumatura solo dal lato dove il testo esce, sincronizzata con lo scorrimento:
   fermo all'inizio -> solo a destra (70px); in movimento -> entrambi; fermo alla fine -> solo a sinistra (5px). */
@property --fl { syntax: "<length>"; inherits: false; initial-value: 0px; }
@property --fr { syntax: "<length>"; inherits: false; initial-value: 70px; }
.pb-title .mq, .pb-artist .mq { display: inline-block; }
.pb-title.mq-on, .pb-artist.mq-on {
  text-overflow: clip; --fl: 0px; --fr: 70px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--fl), #000 calc(100% - var(--fr)), transparent);
  mask-image: linear-gradient(90deg, transparent, #000 var(--fl), #000 calc(100% - var(--fr)), transparent);
  animation: mqfade var(--mq-time, 8s) ease-in-out infinite alternate;
}
.mq-on .mq { animation: mq var(--mq-time, 8s) ease-in-out infinite alternate; }
@keyframes mq { 0%, 20% { transform: translateX(0); } 80%, 100% { transform: translateX(calc(-1 * var(--mq-dist, 0px))); } }
@keyframes mqfade { 0%, 20% { --fl: 0px; --fr: 70px; } 25% { --fl: 5px; } 75% { --fr: 70px; } 80%, 100% { --fl: 5px; --fr: 0px; } }
@media (prefers-reduced-motion: reduce) {
  .mq-on .mq, .pb-title.mq-on, .pb-artist.mq-on { animation: none; }
}
.pb-program .label { color: var(--sun); margin-right: 6px; }
.pb-vol { width: 110px; accent-color: var(--sun); }
.pb-volbox { display: flex; }
.pb-volbtn { display: none; }
body.no-volume .pb-volbox, body.no-volume .pb-volbtn { display: none !important; } /* iPhone/iPad: volume solo con i tasti */
body.playing .pb-play { animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,183,3,.6); } 70% { box-shadow: 0 0 0 14px rgba(255,183,3,0); } 100% { box-shadow: 0 0 0 0 rgba(255,183,3,0); } }

/* ---------- Mobile ---------- */
@media (max-width: 960px) {
  .hero-inner, .welcome { grid-template-columns: 1fr; }
  .hero-inner { padding: 12px 16px 48px; }
  .burger { display: block; order: -1; margin-left: -8px; } /* cellulare: il menu a sinistra, prima del logo */
  .mainnav {
    display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--navy); padding: 12px 16px 20px;
  }
  body.menu-open .mainnav { display: flex; }
  .nav-sep { width: auto; height: 1px; margin: 6px 12px; align-self: stretch; }
  .nav-group { flex-direction: column; gap: 4px; }
  .langs { order: 2; margin-left: auto; }
  .topbar { gap: 12px; padding: 10px 16px; }
  .brand img { height: 38px; }
  .pb-program, .pb-volbox { display: none; }
  /* volume su cellulare: altoparlante a destra, lo slider si apre in un riquadro sopra la barra */
  .pb-volbtn {
    display: grid; place-items: center; flex: 0 0 auto; width: 44px; height: 44px; border: 0; border-radius: 50%;
    background: rgba(255,255,255,.1); color: #d7e9f0; cursor: pointer;
  }
  .pb-volbtn svg { width: 22px; height: 22px; }
  body.vol-open .pb-volbtn { background: var(--sun); color: var(--navy); }
  body.vol-open .pb-volbox {
    display: flex; position: absolute; right: 12px; bottom: calc(100% + 10px); padding: 16px 18px; border-radius: 14px;
    background: var(--navy); box-shadow: 0 6px 24px rgba(0,0,0,.35);
  }
  body.vol-open .pb-vol { width: min(220px, 60vw); }
  .prog { grid-template-columns: 80px 1fr; }
  .podcast-card { grid-template-columns: 1fr; }
  .wrap { padding: 32px 16px; }
}

/* ---------- Copertina: onda sonora quando non c'è (jingle o copertina non trovata) ---------- */
/* senza copertina: onda sonora animata (blu) su fondo bianco, con un bordino azzurro chiarissimo che la stacca dalle card */
img.no-cover { object-fit: contain !important; background: #fff !important; border: 2px solid #cfe4ec; padding: 2px; box-sizing: border-box; }

/* ---------- Home: ultime canzoni + notizie ---------- */
.history { display: grid; gap: 8px; }
.hist-item {
  display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; background: var(--card);
  border-radius: 12px; padding: 8px 12px 8px 8px; box-shadow: 0 2px 10px rgba(6,32,46,.05);
}
.hist-item img { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; }
.hist-title { font-weight: 600; line-height: 1.2; }
.hist-artist { color: var(--muted); font-size: 14px; }
.hist-time { color: var(--brand); font-weight: 600; font-size: 13px; }
.news { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.news-item {
  background: var(--card); border-radius: 14px; overflow: hidden; text-decoration: none; color: var(--ink);
  box-shadow: 0 2px 10px rgba(6,32,46,.05); display: flex; flex-direction: column; border: 0; padding: 0;
  text-align: left; cursor: pointer; font: inherit; transition: transform .15s;
}
.news-item:hover { transform: translateY(-3px); }
.news-item img { aspect-ratio: 16/9; object-fit: cover; width: 100%; }
.news-body { padding: 10px 12px 14px; }
.news-body h3 { font-size: 15px; margin: 4px 0 0; line-height: 1.3; }
.news-meta { font-size: 12px; color: var(--brand); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.small { font-size: 13px; }

/* ---------- Meteo: ora, mare, alba/tramonto, prossimi giorni ---------- */
.forecast { margin-top: 32px; max-width: 820px; }
.w-live { margin: 0 0 10px; }
.now-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.now-box { background: var(--card); border-radius: 16px; padding: 16px; display: grid; gap: 4px; box-shadow: 0 2px 10px rgba(6,32,46,.05); }
.now-box .big { font: 800 24px Montserrat, sans-serif; }
.days { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.day { background: var(--card); border-radius: 14px; padding: 12px 8px; display: grid; gap: 4px; justify-items: center; text-align: center; box-shadow: 0 2px 10px rgba(6,32,46,.05); }
.day-name { font-weight: 600; text-transform: capitalize; font-size: 14px; }
.day-ico { font-size: 30px; }

/* ---------- Social ---------- */
.social-row { display: flex; gap: 12px; margin-top: 20px; }
.social-row.center { justify-content: center; margin: 12px 0; }
.social-row[hidden] { display: none; } /* senza profili social la riga non occupa spazio */
.social { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: #fff; }
.social svg { width: 22px; height: 22px; }
/* footer: cerchi bianchi semitrasparenti */
.footer-social .social { width: 40px; height: 40px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.35); }
.footer-social .social:hover { background: var(--sun); color: var(--navy); border-color: var(--sun); }
/* hero: YouTube, Instagram e TikTok in colonna in alto a destra, con i colori dei marchi */
.hero-social { position: absolute; top: 24px; right: 20px; margin: 0; z-index: 2; flex-direction: column; gap: 10px; }
.hero-social .social { width: 42px; height: 42px; box-shadow: 0 4px 12px rgba(0,0,0,.3); transition: transform .15s; }
.hero-social .social:hover { transform: scale(1.08); }
.hero-social .social-youtube, .contact-social .social-youtube { background: #ff0000; color: #fff; }
.hero-social .social-instagram, .contact-social .social-instagram { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285aeb 90%); color: #fff; }
.hero-social .social-tiktok, .contact-social .social-tiktok { background: #000; color: #fff; }
.hero-social .social-tiktok svg, .contact-social .social-tiktok svg { filter: drop-shadow(-1.5px -1px 0 #25f4ee) drop-shadow(1.5px 1px 0 #fe2c55); }
/* Contatti: stessi loghi colorati della home, il 50% più grandi (42px -> 63px) */
.contact-social { gap: 16px; }
.contact-social .social { width: 63px; height: 63px; box-shadow: 0 4px 12px rgba(0,0,0,.2); transition: transform .15s; }
.contact-social .social:hover { transform: scale(1.08); }
.contact-social .social svg { width: 33px; height: 33px; }
@media (max-width: 960px) { .hero-social { top: 16px; right: 16px; gap: 8px; } .hero-social .social { width: 36px; height: 36px; } .hero-social .social svg { width: 18px; height: 18px; } }

@media (max-width: 960px) {
  .now-grid { grid-template-columns: repeat(2, 1fr); }
  .news { grid-template-columns: repeat(2, 1fr); }
  .days { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 520px) { .news { grid-template-columns: 1fr; } }

/* ---------- Pagine legali ---------- */
.footer-links a { color: #9fd3e3; font-size: 10px; }
.legal { font-size: 12px; line-height: 1.5; }
.legal h1 { font-size: 20px; }
.legal h2 { font-size: 15px; margin-top: 22px; }
.legal p, .legal li { color: #2c4250; margin: 6px 0; }
.legal .xxx { background: #fff3c4; padding: 0 4px; border-radius: 4px; font-weight: 600; }
.legal table { border-collapse: collapse; width: 100%; font-size: 12px; }
.legal td, .legal th { border: 1px solid var(--line); padding: 8px; text-align: left; vertical-align: top; }

/* ---------- Menorca News ---------- */
.news-head { margin-bottom: 4px; }
.title-link a { color: inherit; text-decoration: none; } /* titoli della home cliccabili */
.title-link a:hover { color: var(--brand); }
.prog { scroll-margin-top: 90px; }
.prog.flash { animation: prog-flash 2.2s ease-out; }
@keyframes prog-flash { 0%, 35% { box-shadow: 0 0 0 4px var(--sun); } 100% { box-shadow: 0 0 0 0 transparent; } }
.news-sub { margin: 0 0 16px; color: var(--muted); }
.mad-logo { display: inline-block; vertical-align: -0.2em; }
.mad-logo img { height: 1.05em; width: auto; display: inline-block; }
.modal { position: fixed; inset: 0; z-index: 100; background: rgba(6,32,46,.7); display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-box { position: relative; background: var(--card); border-radius: 22px; max-width: 640px; width: 100%; max-height: 88vh; overflow: auto; box-shadow: var(--shadow); }
.modal-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.modal-content { padding: 22px 26px 26px; }
.modal-content h2 { margin: 6px 0 12px; font-size: 24px; line-height: 1.25; }
.modal-content p { font-size: 17px; white-space: pre-line; } /* le cronache delle partite vanno a capo tra risultato e commento */
.modal-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px; }
.modal-foot a { font-weight: 600; }
.modal-close { position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255,255,255,.9); font-size: 18px; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
body.modal-open { overflow: hidden; }
.now-box .sub { font-weight: 600; color: var(--brand); }
.wi { width: 1.1em; height: 1.1em; vertical-align: -0.15em; }
.w-card .label { margin-bottom: 6px; display: block; }
.w-card audio { margin: 4px 0 0; }
.legal-toc { font-weight: 600; }
.legal hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0 6px; }
.legal h2 { scroll-margin-top: 90px; }
.legal h3 { font-size: 13px; margin-top: 14px; scroll-margin-top: 90px; }
.w-card .w-title { margin-bottom: 8px; font-size: 14px; color: var(--muted); }
.w-card .w-title b { color: var(--ink); }
.w-card .w-title .sep { font-weight: 400; font-size: .6em; margin: 0 .8em; vertical-align: .15em; }
.now-box .big .mm { font-size: .55em; font-weight: 600; color: var(--muted); }
.now-box .big .nw { white-space: nowrap; }

/* ---------- Home: blocco unico "Sta suonando / Canzoni precedenti / Ora in onda" ---------- */
.live-block { background: var(--card); border-radius: 18px; padding: 6px 18px; box-shadow: 0 2px 10px rgba(6,32,46,.05); }
.lb-section { padding: 14px 0; }
.lb-section + .lb-section { border-top: 1px solid var(--line); }
.lb-now { display: flex; gap: 12px; align-items: center; margin-top: 8px; }
.lb-cover { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; flex: none; }
.lb-title { font: 800 18px/1.2 Montserrat, Inter, sans-serif; }
.live-block .history { gap: 0; margin-top: 4px; }
.live-block .hist-item { background: none; box-shadow: none; border-radius: 0; padding: 6px 0; }
.live-block .hist-item img { width: 40px; height: 40px; }
.live-block .hist-item { grid-template-columns: 40px 1fr auto; }
.lb-program .prog-now img { width: 48px; height: 48px; }
.lb-program .prog-now .prog-name { font-size: 16px; }
.lb-program .prog-now .prog-time { color: var(--muted); }
.lb-program .prog-next { color: var(--ink); }
.lb-program .prog-next span { color: var(--brand); }
/* Hero: pulsanti accanto ad "Ascolta in diretta", scritta e bordo bianchi */
.hero-btns { margin-top: 0; align-items: center; } /* bianchi più piccoli, centrati sul pulsante giallo */
.btn-ghost.btn-light { color: #fff; border-color: #fff; padding: 0 16px; min-height: 38px; font-size: 14px; }
@media (max-width: 520px) {
  /* cellulare: i tre pulsanti bianchi affiancati sotto "Ascolta in diretta" */
  .hero-btns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .hero-btns .btn-play { grid-column: 1 / -1; justify-self: start; }
  .hero-btns .btn-light { justify-content: center; text-align: center; line-height: 1.15; padding: 0 6px; font-size: clamp(11px, 3.6vw, 14px); white-space: nowrap; }
}
.news-head { scroll-margin-top: 90px; }
.news-tag { color: #c77d00; } /* Volley / Basket nelle notizie sportive */
/* raffiche: stesso stile di "km/h", su una riga propria che può andare a capo nei box stretti */
.now-box .w-sub { font: 600 13.2px/1.3 Montserrat, sans-serif; color: var(--muted); }
.now-box { align-content: start; }               /* i box più bassi non centrano il contenuto in verticale */
.now-box .big { line-height: 1.2; }              /* se "da NORD/OVEST" va a capo, la riga resta compatta */
.now-box .w-sub .nw, .now-box .w-sub.nw { white-space: nowrap; }


@media (max-width: 520px) {
  /* cellulare: "© 2026 Viva Menorca Radio · ..." sempre su una riga, il testo scala con lo schermo */
  .footer .muted { white-space: nowrap; font-size: clamp(9px, 2.85vw, 12px); }
}

@media (max-width: 640px) {
  /* cellulare: programma in onda al centro, metà del precedente e del successivo ai lati */
  .today-strip { scroll-snap-type: x mandatory; }
  .strip-item { flex: 0 0 calc(50% - 14px); scroll-snap-align: center; }
}

.song-year { font-size: .85em; font-style: italic; opacity: .85; } /* anno dopo l'artista: più piccolo e in corsivo */

/* ---------- Pagina in costruzione (Team, Studio) ---------- */
.team[hidden] { display: none; }
.wip { text-align: center; background: var(--card); border-radius: 24px; padding: 56px 24px; margin-top: 24px; box-shadow: 0 2px 10px rgba(6,32,46,.06); }
.wip-icon { width: 84px; height: 84px; margin: 20px auto 18px; border-radius: 50%; display: grid; place-items: center; background: var(--sun); color: var(--navy); }
.wip-icon svg { width: 76px; height: 76px; overflow: visible; } /* l'archetto delle cuffie esce dal cerchio */ /* cono da cantiere con le cuffie */
.wip h2 { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); }
.wip p { margin: 0 auto 24px; max-width: 460px; }

/* ---------- Archivio News ---------- */
.news-more { margin: 18px 0 0; }
.news-more a { text-decoration: none; color: var(--brand); }
.news-more a:hover { text-decoration: underline; }
.arch-month { border-top: 1px solid var(--line); }
.arch-month:last-child { border-bottom: 1px solid var(--line); }
.arch-month summary { cursor: pointer; padding: 14px 0; font: 700 20px/1.2 Montserrat, sans-serif; color: var(--ink); }
.arch-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; padding-bottom: 18px; }
.arch-item {
  display: flex; gap: 12px; align-items: flex-start; text-align: left; background: var(--card); border: 0; border-radius: 12px;
  padding: 8px; cursor: pointer; font: inherit; color: var(--ink); box-shadow: 0 2px 10px rgba(6,32,46,.05); transition: transform .15s;
}
.arch-item:hover { transform: translateY(-2px); }
.arch-item img, .arch-noimg { flex: none; width: 112px; aspect-ratio: 16/9; object-fit: cover; border-radius: 8px; background: #e6f0f4; }
.arch-body { display: grid; gap: 4px; }
.arch-title { font-weight: 600; font-size: 14.5px; line-height: 1.3; }
@media (max-width: 720px) { .arch-list { grid-template-columns: 1fr; } .arch-item img, .arch-noimg { width: 96px; } }
