/* ============================================================
   Tema "SalsaAsí" — el tema Light (moderno) vestido de salsa elegante.
   Hereda TODO el layout de moderno (header, hero, secciones en tarjetas)
   y lo re-tematiza con una paleta espresso + oro + rojo salsa, un hero con
   el logo montado en un vinilo, titulares en display y detalles salseros.
   Se carga DESPUÉS de app.css y SOLO en los sitios que activan este tema
   (optin), así que puede redefinir los tokens sin afectar a nadie más.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,600;0,700;0,800;1,500;1,600&display=swap');

/* ---------- Paleta propia (espresso + oro); el rojo salsa llega
   del color de marca del cliente en --accent ---------- */
:root, [data-theme="dark"] {
  --bg:        20 12 10;     /* espresso profundo */
  --surface:   31 19 16;     /* tarjeta */
  --surface-2: 42 26 21;     /* tarjeta elevada */
  --surface-3: 58 36 29;     /* chips / hover */
  --text:      246 235 223;  /* crema */
  --muted:     190 162 147;  /* crema apagada */
  --border:    74 50 41;     /* borde cálido */
  --shadow: 0 26px 60px -22px rgba(0,0,0,.72);
  --sa-gold:   232 183 96;   /* oro */
  --sa-gold-2: 198 146 64;   /* oro hondo */
  --sa-ink:    14 8 7;       /* café casi negro (texto sobre oro) */
}
[data-theme="light"] {
  --bg:        248 241 232;  /* marfil cálido */
  --surface:   255 251 244;
  --surface-2: 250 243 233;
  --surface-3: 240 229 215;
  --text:      38 22 17;     /* café oscuro */
  --muted:     126 96 82;
  --border:    226 209 189;
  --shadow: 0 20px 44px -18px rgba(90,50,20,.26);
  --sa-gold:   150 100 28;   /* oro oscuro: AA 4.5:1 sobre marfil para texto */
  --sa-gold-2: 128 84 24;
  --sa-ink:    252 246 238;
}

/* ---------- Fondo + grano de vinilo ---------- */
body { background:
    radial-gradient(1100px 620px at 50% -6%, rgb(var(--accent) / .14), transparent 60%),
    radial-gradient(900px 560px at 88% 4%, rgb(var(--sa-gold) / .09), transparent 55%),
    rgb(var(--bg));
  position: relative; }
body::before { content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay; }
#pjax-root { position: relative; z-index: 1; }

/* ---------- Tipografía display (titulares) ---------- */
.brand-logo span, .nav-center .brand-logo span,
.section-head .title h2, .hero-content h1, .sa-name,
.footer h5, .hist-title { font-family: 'Playfair Display', Georgia, serif; letter-spacing: -.01em; }
.section-head .title h2 { font-weight: 700; }

/* Acento dorado bajo el título de cada sección */
.section-head .title h2 { position: relative; display: inline-block; padding-bottom: 8px; }
.section-head .title h2::after { content: ""; position: absolute; left: 0; bottom: 0; width: 48px; height: 3px;
  border-radius: 3px; background: linear-gradient(90deg, rgb(var(--accent)), rgb(var(--sa-gold))); }

/* ---------- Header: filete dorado + marca ---------- */
.nav, .nav-center, .hdr2-strip { border-bottom: 1px solid rgb(var(--sa-gold) / .16); }
.nav-links a.active, .nav-links a:hover { color: rgb(var(--sa-gold)); }

/* ---------- Botones salsa ---------- */
.btn-primary { background: linear-gradient(135deg, rgb(var(--accent)), rgb(var(--sa-gold-2))); color: #fff; border: none; }
.btn-primary:hover { filter: brightness(1.07); }
.btn-ghost { border: 1px solid rgb(var(--sa-gold) / .5); color: rgb(var(--text)); }
.btn-ghost:hover { border-color: rgb(var(--sa-gold)); color: rgb(var(--sa-gold)); }

/* ---------- Tarjetas con filo dorado ---------- */
.news-card, .event-card, .dir-card, .host-card, .pod-card, .short-card, .prog-slot, .top-row {
  border: 1px solid rgb(var(--border)); }
.news-card:hover, .event-card:hover, .dir-card:hover, .host-card:hover, .pod-card:hover {
  transform: translateY(-3px); border-color: rgb(var(--sa-gold) / .55); }

/* ============================================================
   HERO salsero (sección, con header arriba)
   ============================================================ */
.sa-hero { position: relative; overflow: hidden; padding: 56px 20px 60px; margin-bottom: 8px;
  display: grid; place-items: center; text-align: center; }
.sa-hero-bg { position: absolute; inset: 0; z-index: 0; background-size: cover; background-position: center;
  filter: blur(26px) saturate(1.1) brightness(.45); transform: scale(1.14); opacity: .5; }
.sa-hero-bg::after { content: ""; position: absolute; inset: 0;
  background: radial-gradient(62% 62% at 50% 42%, transparent, rgb(var(--bg) / .9) 82%); }
.sa-hero-frame { position: absolute; inset: 16px; z-index: 1; pointer-events: none; border-radius: 22px;
  border: 1px solid rgb(var(--sa-gold) / .2); box-shadow: inset 0 0 0 6px rgb(var(--sa-gold) / .045); }
.sa-hero-inner { position: relative; z-index: 3; display: flex; flex-direction: column; align-items: center; gap: 16px; width: 100%; max-width: 640px; }

.sa-eyebrow { display: inline-flex; align-items: center; gap: 9px; padding: 7px 16px; border-radius: 999px;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .2em;
  color: rgb(var(--sa-gold)); border: 1px solid rgb(var(--sa-gold) / .4); background: rgb(var(--sa-gold) / .07); }
.sa-eyebrow .live-dot { width: 8px; height: 8px; border-radius: 50%; background: rgb(var(--accent));
  box-shadow: 0 0 0 0 rgb(var(--accent) / .6); animation: saPulse 1.5s ease-out infinite; }
@keyframes saPulse { 0% { box-shadow: 0 0 0 0 rgb(var(--accent) / .6); } 70% { box-shadow: 0 0 0 10px rgb(var(--accent) / 0); } 100% { box-shadow: 0 0 0 0 rgb(var(--accent) / 0); } }

/* ---------- Vinilo con el logo ---------- */
.sa-vinyl-wrap { position: relative; width: 268px; height: 268px; display: grid; place-items: center; margin: 2px 0; }
.sa-vinyl { position: absolute; inset: 0; border-radius: 50%;
  background:
    repeating-radial-gradient(circle at 50% 50%, rgba(0,0,0,.92) 0 2px, rgba(28,20,18,.92) 2px 4px),
    radial-gradient(circle at 42% 38%, rgba(255,255,255,.14), transparent 40%),
    #0b0706;
  box-shadow: 0 30px 70px -26px rgba(0,0,0,.85), inset 0 0 60px rgba(0,0,0,.6), 0 0 0 1px rgb(var(--sa-gold) / .2); }
/* Los surcos concéntricos son simétricos (girarlos no se vería): el movimiento
   es un barrido de luz lento sobre el disco quieto. */
.sa-vinyl::after { content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 210deg, transparent 0 20%, rgb(var(--sa-gold) / .12) 28%, transparent 36% 70%, rgb(255 255 255 / .08) 78%, transparent 86%);
  animation: saSpin 14s linear infinite; }
@keyframes saSpin { to { transform: rotate(360deg); } }
.sa-logo { position: relative; z-index: 2; width: 146px; height: 146px; border-radius: 50%;
  object-fit: contain; background: rgb(var(--surface-2)); padding: 14px;
  border: 4px solid rgb(var(--sa-gold) / .85);
  box-shadow: 0 0 0 7px rgb(var(--bg)), 0 18px 40px -16px rgba(0,0,0,.7); }
.sa-logo-ph { display: grid; place-items: center; font-family: 'Playfair Display', serif; font-size: 64px; font-weight: 800; color: rgb(var(--sa-gold)); }
.sa-vinyl-hole { position: absolute; z-index: 3; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 14px; height: 14px; border-radius: 50%; background: rgb(var(--bg)); box-shadow: inset 0 0 0 2px rgb(var(--sa-gold) / .5); }
.sa-tonearm { position: absolute; z-index: 4; top: -6px; right: 6px; width: 110px; height: 110px; pointer-events: none;
  color: rgb(var(--sa-gold) / .7); transform: rotate(8deg); transform-origin: top right;
  transition: transform .6s ease; }

/* El disco (la etiqueta = logo) gira cuando la radio está sonando. El JS del
   player pone .radio-playing en <body>; al pausar, se detiene suave. */
.sa-logo { transition: transform .4s ease; }
body.radio-playing .sa-logo { animation: saLogoSpin 4.2s linear infinite; }
@keyframes saLogoSpin { to { transform: rotate(360deg); } }
/* Al sonar, el brazo baja un poco sobre el disco (gesto de tocadiscos). */
body.radio-playing .sa-tonearm { transform: rotate(16deg); }

/* "Ahora suena" (metadata del stream) bajo el vinilo */
.sa-now { display: inline-flex; align-items: center; gap: 8px; max-width: 92%; margin-top: 2px;
  padding: 8px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  color: rgb(var(--sa-gold)); border: 1px solid rgb(var(--sa-gold) / .4); background: rgb(var(--sa-gold) / .07);
  animation: saNowIn .4s ease; }
.sa-now[hidden] { display: none; }
.sa-now .material-symbols-outlined { font-size: 17px; }
.sa-now-txt { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px; }
@keyframes saNowIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.sa-name { font-weight: 800; line-height: 1.02; font-size: clamp(36px, 7vw, 64px);
  background: linear-gradient(100deg, rgb(var(--sa-gold)) 0%, #fff4dc 48%, rgb(var(--sa-gold-2)) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: 0 2px 30px rgb(var(--sa-gold) / .16); }
[data-theme="light"] .sa-name { background: linear-gradient(100deg, rgb(var(--sa-gold-2)) 0%, rgb(var(--accent)) 52%, rgb(var(--sa-gold-2)) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; }
.sa-sub { font-family: 'Playfair Display', serif; font-style: italic; font-weight: 600; font-size: clamp(16px, 2.6vw, 20px);
  color: rgb(var(--accent)); margin-top: -4px; }
[data-theme="light"] .sa-sub { color: rgb(var(--sa-gold-2)); }
.sa-tag { color: rgb(var(--muted)); max-width: 460px; font-size: 15.5px; line-height: 1.6; }

.sa-rule { display: flex; align-items: center; gap: 12px; color: rgb(var(--sa-gold) / .75); margin: 2px 0; }
.sa-rule::before, .sa-rule::after { content: ""; height: 1px; width: 54px; background: linear-gradient(90deg, transparent, rgb(var(--sa-gold) / .6)); }
.sa-rule::after { background: linear-gradient(90deg, rgb(var(--sa-gold) / .6), transparent); }
.sa-rule .material-symbols-outlined { font-size: 18px; }

.sa-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 4px; }

/* ---------- Redes (aro dorado) ---------- */
.sa-socials { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 2px; }
.sa-socials a { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  color: rgb(var(--text)); border: 1px solid rgb(var(--sa-gold) / .42); background: rgb(var(--surface) / .5);
  transition: transform .2s ease, color .2s ease, border-color .2s ease, background .2s ease; }
.sa-socials a:hover { transform: translateY(-4px); color: rgb(var(--sa-ink)); border-color: transparent;
  background: linear-gradient(135deg, rgb(var(--sa-gold)), rgb(var(--sa-gold-2))); }

/* ---------- Ecualizador inferior (transform, no height) ---------- */
.sa-eq { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; height: 120px;
  display: flex; align-items: flex-end; justify-content: center; gap: 6px; padding: 0 12px; opacity: .2; pointer-events: none; }
.sa-eq span { flex: 0 0 auto; width: 6px; height: 96px; border-radius: 3px 3px 0 0; transform-origin: bottom; transform: scaleY(.12);
  background: linear-gradient(180deg, rgb(var(--sa-gold)), rgb(var(--accent)));
  animation: saEq 1.1s ease-in-out infinite; will-change: transform; }
@keyframes saEq { 0%,100% { transform: scaleY(.12); } 50% { transform: scaleY(var(--s, .6)); } }

/* ---------- Siluetas decorativas ---------- */
.sa-deco { position: absolute; z-index: 1; color: rgb(var(--sa-gold)); opacity: .06; pointer-events: none; line-height: 1; user-select: none; }
.sa-deco-l { left: 1%; bottom: 8%; font-size: 220px; transform: rotate(-12deg); }
.sa-deco-r { right: 1%; top: 10%; font-size: 170px; transform: rotate(10deg); }

/* ============================================================
   Sección "Historia" (editable desde el panel → Nosotros)
   ============================================================ */
.hist { padding: 44px 0; }
.hist-wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 34px; align-items: center; }
.hist-eyebrow { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .2em; color: rgb(var(--sa-gold)); }
.hist-title { font-size: clamp(26px, 4vw, 40px); font-weight: 800; line-height: 1.1; margin: 8px 0 14px; }
.hist-text { color: rgb(var(--muted)); line-height: 1.8; font-size: 16px; }
.hist-text p { margin-bottom: 12px; }
.hist-media { position: relative; }
.hist-media img { width: 100%; border-radius: 18px; border: 1px solid rgb(var(--sa-gold) / .3); box-shadow: var(--shadow); }
.hist-media::before { content: ""; position: absolute; inset: -10px -10px auto auto; width: 120px; height: 120px; z-index: -1;
  border-radius: 18px; background: radial-gradient(circle, rgb(var(--sa-gold) / .3), transparent 70%); }
.hist-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.hist-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px;
  font-size: 13px; font-weight: 600; color: rgb(var(--sa-gold)); border: 1px solid rgb(var(--sa-gold) / .35); background: rgb(var(--sa-gold) / .06); }
.hist-chip .material-symbols-outlined { font-size: 17px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid rgb(var(--sa-gold) / .18); background: rgb(var(--bg)); position: relative; z-index: 2; }
.footer h5 { color: rgb(var(--sa-gold)); }
.footer .dev-credit a { color: rgb(var(--sa-gold)); }
.social-btn:hover { color: rgb(var(--sa-gold)); border-color: rgb(var(--sa-gold)); }

/* ---------- Player flotante: aro cálido ---------- */
.player.player-floating, .player.player-pill { border: 1px solid rgb(var(--sa-gold) / .28); }
.player .play-btn { background: linear-gradient(135deg, rgb(var(--accent)), rgb(var(--sa-gold-2))); color: #fff; }

/* ---------- backdrop-filter con prefijo WebKit ---------- */
.nav-center, .player.player-floating { -webkit-backdrop-filter: blur(10px); }

/* ---------- Reduce motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .sa-vinyl::after, .sa-eq span, .sa-eyebrow .live-dot, body.radio-playing .sa-logo { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) { .sa-deco { display: none; } }
@media (max-width: 820px)  { .hist-wrap { grid-template-columns: 1fr; gap: 22px; } .hist-media { order: -1; } }
@media (max-width: 560px) {
  .sa-hero { padding: 40px 16px 48px; }
  .sa-vinyl-wrap { width: 216px; height: 216px; }
  .sa-logo { width: 112px; height: 112px; padding: 11px; }
  .sa-tonearm { width: 88px; height: 88px; }
  .sa-hero-frame { inset: 10px; }
}
