/* La Ponedora FM: CSS sin build step. Oscuro, acento rosa "al aire" y ámbar. */

:root {
    --bg: #120B12;
    --bg-2: #180F18;
    --surface: #1E141E;
    --surface-2: #281B28;
    --surface-3: #352435;
    --line: #3B2A3A;
    --text: #F7ECF2;
    --text-2: #CDB7C4;
    --text-3: #92798A;
    --accent: #FF3D7F;
    --accent-2: #FFB547;
    --accent-ink: #1A0712;
    --ok: #4ADE80;
    --warn: #FBBF24;
    --danger: #F43F5E;
    --radius: 14px;
    --radius-sm: 9px;
    --font: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --display: 'Unbounded', 'DM Sans', system-ui, sans-serif;
    --player-h: 76px;
    --shadow: 0 10px 40px rgb(0 0 0 / .45);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 130px; }
body {
    margin: 0;
    background: radial-gradient(1200px 600px at 85% -10%, rgb(255 61 127 / .12), transparent 60%), radial-gradient(900px 500px at -10% 10%, rgb(255 181 71 / .07), transparent 60%), var(--bg);
    background-attachment: fixed;
    color: var(--text);
    font: 400 16px/1.55 var(--font);
    min-height: 100vh;
}
body.has-player { padding-bottom: calc(var(--player-h) + 12px); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-color: rgb(255 61 127 / .5); text-underline-offset: 3px; }
a:hover { color: var(--accent); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.12; letter-spacing: -.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(1.7rem, 4vw, 2.6rem); }
h2 { font-size: 1.35rem; }
.h-md { font-size: 1.3rem; }
.h-sm { font-size: 1rem; letter-spacing: 0; }
.h-xs { font-family: var(--font); font-size: .95rem; margin: 1.2em 0 .5em; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
.muted { color: var(--text-3); }
.small { font-size: .875rem; }
.lead { font-size: 1.1rem; color: var(--text-2); max-width: 60ch; }
.error { color: #FF8FA8; font-size: .875rem; margin: .3em 0 0; }
.error.is-info { color: var(--text-2); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }
.ico { flex: none; }
[hidden] { display: none !important; }

.wrap { width: min(1240px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); }
.section { margin-block: 28px 40px; }
.section-head, .page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.section-head h2, .page-head h1 { margin: 0; }
.section-head a { color: var(--text-2); font-size: .9rem; text-decoration: none; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 700; color: var(--accent-2); display: flex; align-items: center; gap: 8px; margin-bottom: .6em; }

/* Carga entre páginas */
html.is-loading main { opacity: .55; transition: opacity .2s .1s; }
html.is-loading body::before { content: ''; position: fixed; inset: 0 0 auto; height: 3px; z-index: 90; background: linear-gradient(90deg, var(--accent), var(--accent-2)); animation: load 1s ease-in-out infinite; }
@keyframes load { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); padding: 10px 18px; border-radius: 999px; font-weight: 700; font-size: .95rem; cursor: pointer; text-decoration: none; transition: transform .12s, background .15s, border-color .15s; white-space: nowrap; }
.btn:hover { color: var(--text); background: var(--surface-3); border-color: var(--text-3); }
.btn:active { transform: scale(.97); }
.btn-accent { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-accent:hover { background: #FF5A92; border-color: #FF5A92; color: var(--accent-ink); }
.btn-ghost { background: transparent; }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-sm { padding: 7px 13px; font-size: .85rem; }
.btn-lg { padding: 13px 24px; font-size: 1rem; }
.btn.is-on { border-color: var(--accent-2); color: var(--accent-2); }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; gap: 3px; min-width: 36px; height: 36px; padding: 0 6px; border: 0; border-radius: 999px; background: transparent; color: var(--text-2); cursor: pointer; text-decoration: none; }
.icon-btn:hover { background: var(--surface-3); color: var(--text); }
.icon-btn.is-on { color: var(--accent-2); }
.icon-btn.is-on svg { fill: currentColor; }
.icon-btn small { font-size: .75rem; }
.link-btn { border: 0; background: none; padding: 0; color: var(--text-3); cursor: pointer; display: inline-flex; align-items: center; gap: 5px; font-size: .85rem; text-decoration: none; }
.link-btn:hover { color: var(--text); }
.link-btn.danger:hover { color: var(--danger); }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 40; background: rgb(18 11 18 / .86); backdrop-filter: blur(14px); border-bottom: 1px solid rgb(59 42 58 / .6); }
.header-row { display: flex; align-items: center; gap: 16px; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.logo:hover { color: var(--text); }
.logo-mark { display: inline-flex; align-items: flex-end; gap: 3px; height: 22px; }
.logo-mark i { width: 4px; border-radius: 3px; background: var(--accent); animation: eq 1.1s ease-in-out infinite; }
.logo-mark i:nth-child(1) { height: 60%; }
.logo-mark i:nth-child(2) { height: 100%; animation-delay: -.4s; background: var(--accent-2); }
.logo-mark i:nth-child(3) { height: 40%; animation-delay: -.7s; }
@keyframes eq { 0%, 100% { transform: scaleY(.45); } 50% { transform: scaleY(1); } }
.logo-mark i { transform-origin: bottom; }
@media (prefers-reduced-motion: reduce) { .logo-mark i, .on-air { animation: none !important; } }
.logo-text { font-family: var(--display); font-weight: 800; font-size: 1.12rem; letter-spacing: -.02em; }
.logo-text b { margin-left: 6px; font-size: .62em; padding: 3px 6px; border-radius: 6px; background: var(--accent); color: var(--accent-ink); vertical-align: 3px; }
.logo-sm .logo-text { font-size: 1rem; }
.header-search { flex: 1; max-width: 460px; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0 14px; color: var(--text-3); }
.header-search:focus-within { border-color: var(--accent); }
.header-search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; height: 40px; color: var(--text); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.main-nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding-bottom: 8px; }
.main-nav::-webkit-scrollbar { display: none; }
.main-nav a { padding: 6px 12px; border-radius: 999px; color: var(--text-2); text-decoration: none; font-size: .92rem; font-weight: 500; white-space: nowrap; }
.main-nav a:hover { background: var(--surface-2); color: var(--text); }
.main-nav a.is-active { background: var(--text); color: var(--bg); }

.dropdown { position: relative; }
.avatar-btn { border: 0; background: none; padding: 0; cursor: pointer; border-radius: 999px; }
.dropdown-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 220px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 6px; z-index: 60; }
.dropdown-menu a, .dropdown-menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border-radius: 8px; text-decoration: none; border: 0; background: none; cursor: pointer; text-align: left; font-size: .93rem; }
.dropdown-menu a:hover, .dropdown-menu button:hover { background: var(--surface-3); color: var(--text); }
.dropdown-head { padding: 8px 12px 10px; border-bottom: 1px solid var(--line); margin-bottom: 4px; display: grid; }
.dropdown-head small { color: var(--text-3); }

.avatar { --s: 40px; --h: 330; width: var(--s); height: var(--s); flex: none; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 700; font-size: calc(var(--s) * .38); color: #fff; background: linear-gradient(135deg, hsl(var(--h) 75% 55%), hsl(calc(var(--h) + 40) 70% 40%)); letter-spacing: -.02em; }
.avatar.is-ghost { background: var(--surface-3); color: var(--text-3); }
.flag { display: inline-block; border-radius: 2px; vertical-align: -2px; object-fit: cover; }

/* ---------- Avisos ---------- */
.flash { margin-top: 16px; padding: 12px 16px; border-radius: var(--radius-sm); background: rgb(74 222 128 / .1); border: 1px solid rgb(74 222 128 / .35); color: #C9F7DA; }
.flash-warn { background: rgb(251 191 36 / .1); border-color: rgb(251 191 36 / .35); color: #FDE9B4; margin: 0 0 16px; }
.toast { position: fixed; left: 50%; bottom: calc(var(--player-h) + 24px); transform: translate(-50%, 20px); opacity: 0; transition: .25s; z-index: 80; background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-weight: 500; box-shadow: var(--shadow); max-width: calc(100% - 32px); text-align: center; }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--surface-3); color: var(--text-2); vertical-align: 2px; }
.badge-warn { background: rgb(251 191 36 / .16); color: var(--warn); }
.badge-e { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 4px; background: var(--text-2); color: var(--bg); font: 800 .66rem/1 var(--font); }

/* ---------- Anuncios ---------- */
/* isolation: los z-index de las redes no tapan los menús del header. */
.ad { display: grid; justify-items: center; align-content: center; gap: 6px; max-width: 100%; overflow: hidden; isolation: isolate; }
.ad::before { content: attr(data-ad-label); font-size: 11px; line-height: 1; color: var(--text-3); }
.ad > *:not(template) { max-width: 100%; }
.ad-band { margin: 24px auto; }
.ad-side { margin: 0 0 24px; }
.ad-image { display: block; line-height: 0; }
.ad-image img { max-width: 100%; height: auto; border-radius: 6px; }
.song-card-ad { min-height: 250px; padding: 12px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }

/* ---------- Portada ---------- */
.hero { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: center; padding-block: 36px 12px; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 800; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.on-air { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgb(255 61 127 / .7); animation: onair 1.6s infinite; }
@keyframes onair { 70% { box-shadow: 0 0 0 10px rgb(255 61 127 / 0); } 100% { box-shadow: 0 0 0 0 rgb(255 61 127 / 0); } }
.hero-art { position: relative; height: 320px; }
.hero-art img { position: absolute; width: 200px; height: 200px; border-radius: 16px; box-shadow: var(--shadow); object-fit: cover; left: calc(var(--i) * 15%); top: calc(50% - 100px + (var(--i) - 2) * 18px); transform: rotate(calc((var(--i) - 2) * 6deg)); z-index: calc(10 - var(--i)); }

.chips-scroll { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.chips-wrap { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { flex: none; padding: 8px 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); text-decoration: none; font-weight: 500; font-size: .92rem; }
.chip small { color: var(--text-3); margin-left: 4px; }
.chip:hover { border-color: var(--accent); color: var(--text); }

/* ---------- Tags (artistas y géneros) ---------- */
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: .8rem; font-weight: 500; text-decoration: none; background: var(--surface-3); color: var(--text-2); line-height: 1.6; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tag:hover { color: var(--text); background: #47304A; }
.tag small { color: var(--text-3); }
.tag-artist { background: rgb(255 61 127 / .13); color: #FFC2D6; }
.tag-artist:hover { background: rgb(255 61 127 / .25); color: #fff; }
.tag-genre { background: rgb(255 181 71 / .12); color: #FFD9A0; }
.tag-genre:hover { background: rgb(255 181 71 / .24); color: #fff; }
.tag-lg { font-size: .95rem; padding: 5px 13px; }

/* ---------- Tarjeta de canción ---------- */
.song-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(214px, 1fr)); gap: 18px; }
.song-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: border-color .15s, transform .15s; min-width: 0; }
.song-card:hover { border-color: #5A3E57; transform: translateY(-2px); }
.song-card.is-playing { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 8px 30px rgb(255 61 127 / .2); }
.song-art { position: relative; aspect-ratio: 1; background: linear-gradient(135deg, var(--surface-3), var(--surface-2)); }
.song-art img { width: 100%; height: 100%; object-fit: cover; }
.song-art img.is-broken { visibility: hidden; }
.song-art-empty { display: grid; place-items: center; width: 100%; height: 100%; color: var(--text-3); aspect-ratio: 1; }
.song-number { position: absolute; left: 10px; top: 10px; font: 700 .8rem/1 var(--display); background: rgb(0 0 0 / .65); padding: 5px 8px; border-radius: 6px; }
.song-art .badge-e { position: absolute; right: 10px; top: 10px; }
.song-play { position: absolute; right: 12px; bottom: 12px; width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; cursor: pointer; box-shadow: 0 8px 22px rgb(0 0 0 / .5); opacity: 0; transform: translateY(8px); transition: .18s; }
.song-play svg { margin-left: 3px; }
.song-card:hover .song-play, .song-play:focus-visible, .song-play.is-playing { opacity: 1; transform: none; }
.song-play.is-playing { background: var(--accent-2); animation: pulse 1.6s infinite; }
@media (hover: none) { .song-play { opacity: 1; transform: none; width: 46px; height: 46px; } }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgb(255 181 71 / .15); } }
.song-body { padding: 12px 14px 4px; flex: 1; min-width: 0; }
.song-title { font: 700 1rem/1.3 var(--font); margin: 0 0 6px; overflow-wrap: anywhere; }
.song-title a { text-decoration: none; }
.song-artists { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 6px; }
.song-artists-lg { gap: 8px; margin-bottom: 18px; }
.song-album { font-size: .82rem; color: var(--text-3); margin: 0 0 6px; display: flex; align-items: center; gap: 5px; min-width: 0; }
.song-album a { text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: .8rem; color: var(--text-3); margin: 0; }
.song-meta > span + span::before { content: '·'; margin-right: 8px; }
.song-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 8px 8px 8px 10px; border-top: 1px solid var(--line); margin-top: 10px; }
.song-tools { display: flex; }
.song-tools .icon-btn { min-width: 32px; height: 32px; }

/* ---------- Reacciones ---------- */
.reactions { display: flex; gap: 4px; flex-wrap: wrap; }
.reactions.is-busy { opacity: .6; pointer-events: none; }
.reaction { display: inline-flex; align-items: center; gap: 4px; border: 1px solid transparent; background: transparent; border-radius: 999px; padding: 3px 7px; cursor: pointer; color: var(--text-2); font-size: .82rem; transition: background .15s, border-color .15s; }
.reaction:hover { background: var(--surface-3); }
.reaction-emoji { font-size: 1rem; line-height: 1; filter: grayscale(.6); transition: filter .15s, transform .15s; }
.reaction:hover .reaction-emoji, .reaction.is-mine .reaction-emoji { filter: none; }
.reaction.is-mine { background: rgb(255 61 127 / .14); border-color: rgb(255 61 127 / .5); color: var(--text); }
.reaction.pop .reaction-emoji { animation: pop .35s; }
@keyframes pop { 50% { transform: scale(1.45); } }
.reaction-count:empty { display: none; }
.reactions-lg { gap: 8px; margin-top: 18px; }
.reactions-lg .reaction { padding: 8px 14px; border-color: var(--line); background: var(--surface-2); font-size: .92rem; }
.reactions-lg .reaction-emoji { font-size: 1.2rem; }
.reactions-lg .reaction-count { font-weight: 700; }

/* ---------- Filtros ---------- */
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin-bottom: 20px; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.filter { display: grid; gap: 3px; font-size: .75rem; color: var(--text-3); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.filter select { text-transform: none; letter-spacing: 0; font-weight: 500; font-size: .9rem; color: var(--text); background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 30px 7px 10px; appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 15px) 52%, calc(100% - 10px) 52%; background-size: 5px 5px; background-repeat: no-repeat; cursor: pointer; }
.filters-total { margin-left: auto; font-size: .85rem; align-self: center; }
.seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; flex-wrap: wrap; }
.seg a { padding: 6px 12px; border-radius: 999px; text-decoration: none; font-size: .86rem; color: var(--text-2); }
.seg a.is-active { background: var(--surface-3); color: var(--text); }
.letters { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 18px; }
.letters a { min-width: 32px; text-align: center; padding: 4px 8px; border-radius: 6px; text-decoration: none; background: var(--surface); font-size: .88rem; }
.letters a.is-active { background: var(--accent); color: var(--accent-ink); }

/* ---------- Paginación ---------- */
.pager { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; margin: 28px 0; }
.pager-pages { display: flex; gap: 4px; flex-wrap: wrap; }
.pager-btn, .pager-num { padding: 7px 13px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; font-size: .9rem; }
.pager-num.is-current { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 700; }
.pager-btn.is-disabled { opacity: .4; }
.pager-gap { padding: 7px 4px; color: var(--text-3); }

/* ---------- Página de canción ---------- */
.song-page { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; margin-block: 24px 40px; }
.song-hero { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: 28px; background: linear-gradient(160deg, var(--surface-2), var(--surface)); border: 1px solid var(--line); border-radius: 20px; padding: 22px; }
.song-hero-art img, .song-hero-art .song-art-empty { width: 100%; height: auto; aspect-ratio: 1; border-radius: 14px; box-shadow: var(--shadow); object-fit: cover; background: var(--surface-3); }
.song-hero-title { font-size: clamp(1.6rem, 3.6vw, 2.5rem); font-weight: 800; overflow-wrap: anywhere; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px 18px; margin: 0 0 18px; }
.facts div { min-width: 0; }
.facts dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-3); font-weight: 700; }
.facts dd { margin: 2px 0 0; overflow-wrap: anywhere; }
.tags-inline { display: flex; flex-wrap: wrap; gap: 4px; }
.song-hero-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.listen { margin: 24px 0; }
.listen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.listen-link { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); text-decoration: none; font-weight: 500; color: var(--text); }
.listen-link svg:first-child { color: var(--c); }
.listen-link span { flex: 1; }
.listen-link:hover { border-color: var(--c); color: var(--text); background: color-mix(in srgb, var(--c) 10%, var(--surface)); }
.apple-credit { margin-top: 10px; }

.song-side { min-width: 0; }
.side-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 18px; }
.mini-list, .plain-list { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 4px; }
.plain-list li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.song-row { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 10px; min-width: 0; }
.song-row:hover, .song-row.is-playing { background: var(--surface-2); }
.song-row-play { position: relative; width: 48px; height: 48px; flex: none; border: 0; padding: 0; border-radius: 8px; overflow: hidden; background: var(--surface-3); cursor: pointer; color: #fff; }
.song-row-play img { width: 100%; height: 100%; object-fit: cover; }
.song-row-play svg { position: absolute; inset: 0; margin: auto; opacity: 0; filter: drop-shadow(0 1px 3px #000); transition: .15s; }
.song-row-play:hover svg, .song-row-play.is-playing svg, .song-row-play:focus-visible svg { opacity: 1; }
.song-row-play:hover img { filter: brightness(.6); }
.song-row-text { display: grid; min-width: 0; }
.song-row-text a { text-decoration: none; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-row-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-report { margin-top: 8px; }
.admin-edit { display: inline-block; margin: 8px 0; font-size: .85rem; color: var(--accent-2); }

/* ---------- Comentarios ---------- */
.comments { margin-top: 28px; }
.comment-form { display: flex; gap: 12px; margin-bottom: 22px; }
.comment-form-body { flex: 1; min-width: 0; }
.comment-form textarea, .field input, .field textarea, .field select, .submit-form textarea, .inline-create input[type=text], .new-playlist input[type=text], .link-field input, .big-search input, .country-panel input { width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; color: var(--text); outline: 0; resize: vertical; }
.comment-form textarea:focus, .field input:focus, .field textarea:focus, .submit-form textarea:focus, .link-field input:focus, .inline-create input:focus, .new-playlist input:focus { border-color: var(--accent); }
.comment-form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
.comment-form-reply { margin: 10px 0 6px calc(min(var(--depth, 0), 5) * 0px + 42px); }
.comment-login { padding: 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px dashed var(--line); }
.comment-list, .comment-replies { list-style: none; margin: 0; padding: 0; }
.comment-list > .comment { margin-bottom: 14px; }
.comment-replies { margin-left: 22px; border-left: 2px solid var(--line); padding-left: 14px; }
.comment-replies:empty { display: none; }
.comment-replies .comment { margin-top: 12px; }
/* Hilos muy hondos: deja de sangrar a partir del nivel 5 para no aplastar el texto. */
.comment[style*="--depth: 5"] > .comment-replies { margin-left: 0; padding-left: 10px; }
.comment-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.comment.is-new > .comment-box { animation: flashnew 2s; }
@keyframes flashnew { from { border-color: var(--accent-2); box-shadow: 0 0 0 3px rgb(255 181 71 / .25); } }
.comment-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.comment-author { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.comment-body { overflow-wrap: anywhere; }
.comment-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; }
.comment.is-pending > .comment-box { opacity: .75; border-style: dashed; }
.comment.is-deleted > .comment-box { background: transparent; border-style: dashed; padding-block: 8px; }
/* Quien envió la canción: etiqueta y borde de color en todos sus comentarios. */
.badge-submitter { background: linear-gradient(90deg, var(--accent), var(--accent-2)); color: var(--accent-ink); }
.comment.is-submitter > .comment-box { border-color: rgb(255 61 127 / .45); }
/* La nota que vino con la canción: fijada arriba, con diseño propio. */
.comment.is-pinned { margin-bottom: 22px !important; }
.comment.is-pinned > .comment-box { position: relative; border: 0; padding: 16px 18px; background: linear-gradient(var(--surface-2), var(--surface-2)) padding-box, linear-gradient(120deg, var(--accent), var(--accent-2)) border-box; border: 2px solid transparent; box-shadow: 0 10px 30px rgb(255 61 127 / .12); }
.comment.is-pinned > .comment-box .comment-body { font-size: 1.05rem; }
.comment.is-pinned > .comment-box::after { content: '“'; position: absolute; right: 16px; top: -6px; font: 800 4rem/1 var(--display); color: rgb(255 181 71 / .25); pointer-events: none; }
.pinned-label { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--accent-2); }
.comment-ad { list-style: none; }
.empty-comments { padding: 18px 0; }

/* ---------- Archivos (álbum, artista, género, playlist) ---------- */
.archive-head { display: flex; gap: 28px; align-items: flex-end; flex-wrap: wrap; margin-top: 28px; }
.archive-head > div:last-child { flex: 1; min-width: 260px; }
.archive-art img { width: 240px; height: 240px; border-radius: 16px; box-shadow: var(--shadow); object-fit: cover; }
.album-stat { font-size: 1.05rem; margin: 10px 0 6px; }
.album-stat strong { font-family: var(--display); font-size: 1.6rem; color: var(--accent); margin-right: 4px; }
.meter { height: 6px; max-width: 320px; background: var(--surface-3); border-radius: 99px; overflow: hidden; }
.meter span { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 18px; }
.album-card { display: grid; gap: 4px; text-decoration: none; min-width: 0; }
.album-card img, .album-card .song-art-empty { width: 100%; aspect-ratio: 1; border-radius: 12px; object-fit: cover; background: var(--surface-3); margin-bottom: 6px; transition: transform .15s; }
.album-card:hover img { transform: translateY(-3px); }
.album-card strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.album-card small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.album-count { color: var(--accent-2); font-weight: 700; }
.genre-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.genre-tile { --h: 330; display: grid; align-content: end; gap: 2px; min-height: 120px; padding: 16px; border-radius: var(--radius); text-decoration: none; background: linear-gradient(140deg, hsl(var(--h) 70% 45%), hsl(calc(var(--h) + 50) 65% 25%)); transition: transform .15s; overflow-wrap: anywhere; }
.genre-tile:hover { transform: translateY(-3px); color: #fff; }
.genre-tile strong { font: 700 1.1rem/1.15 var(--display); }
.genre-tile small { opacity: .8; }

/* Playlists */
.pl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 18px; }
.pl-card { display: grid; gap: 8px; text-decoration: none; min-width: 0; }
.pl-mosaic { display: grid; grid-template-columns: 1fr 1fr; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--surface-3); transition: transform .15s; }
.pl-card:hover .pl-mosaic { transform: translateY(-3px); }
.pl-mosaic img { width: 100%; height: 100%; object-fit: cover; }
.pl-mosaic.is-single { grid-template-columns: 1fr; }
.pl-mosaic-empty { display: grid; place-items: center; color: var(--text-3); grid-column: 1 / -1; }
.pl-mosaic-lg { width: 240px; box-shadow: var(--shadow); }
.pl-body { display: grid; gap: 2px; min-width: 0; }
.pl-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-body .badge { justify-self: start; }
.inline-create { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.inline-create input[type=text] { flex: 1; min-width: 200px; }
.track-list { list-style: none; margin: 0; padding: 0; }
.track { display: grid; grid-template-columns: 28px 48px minmax(0, 2fr) minmax(0, 1.2fr) auto 48px auto; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 10px; }
.track:hover, .track.is-playing { background: var(--surface); }
.track.is-playing .track-text a { color: var(--accent); }
.track.is-dragging { opacity: .4; }
.track[draggable=true] { cursor: grab; }
.track-num { color: var(--text-3); text-align: right; font-variant-numeric: tabular-nums; }
.track-text { display: grid; min-width: 0; }
.track-text a { text-decoration: none; }
.track-text > a { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.track-text small { color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.track-album a { color: var(--text-3); text-decoration: none; font-size: .9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.track-time { font-variant-numeric: tabular-nums; font-size: .9rem; text-align: right; }
.track-tools { display: flex; }

/* Perfil */
.profile-head { display: flex; gap: 24px; align-items: flex-start; margin-top: 30px; flex-wrap: wrap; }
.profile-info { flex: 1; min-width: 240px; }
.profile-info h1 { margin-bottom: .2em; }
.profile-bio { max-width: 60ch; white-space: pre-line; }
.socials { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.social { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); text-decoration: none; font-size: .88rem; }
.social:hover { border-color: var(--c); color: var(--text); }
.social-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); display: inline-block; }
.profile-stats { display: flex; gap: 20px; flex-wrap: wrap; color: var(--text-2); }
.profile-stats strong { color: var(--text); font-family: var(--display); }

/* Búsqueda */
.big-search { display: flex; align-items: center; gap: 10px; color: var(--text-3); margin-bottom: 10px; }
.big-search input { flex: 1; padding: 13px 16px; font-size: 1.05rem; border-radius: 999px; }
.search-extra { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin: 18px 0 28px; }

/* ---------- Formularios ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px; margin-bottom: 20px; }
.card-danger { border-color: rgb(244 63 94 / .4); }
.form-grid { display: grid; gap: 14px; }
.form-grid > .h-sm { margin: 6px 0 0; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { display: grid; gap: 5px; }
.field > span:first-child { font-size: .88rem; font-weight: 500; color: var(--text-2); }
.input-prefix { display: flex; align-items: center; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding-left: 12px; }
.input-prefix:focus-within { border-color: var(--accent); }
.input-prefix b { color: var(--text-3); font-weight: 500; }
.input-prefix input { border: 0 !important; background: none !important; padding-left: 4px !important; }
.check, .radio { display: flex; align-items: center; gap: 9px; cursor: pointer; }
.check input, .radio input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.radio-list { display: grid; gap: 10px; border: 0; padding: 0; margin: 0; }
.radio-list legend { font-weight: 700; margin-bottom: 8px; }
.radio { align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg-2); }
.radio input { margin-top: 3px; }
.radio:has(input:checked) { border-color: var(--accent); }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; align-items: center; margin-top: 6px; }
.auth { display: grid; place-items: start center; }
.auth .card { width: min(440px, 100%); }
.socials-grid, .links-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.link-field { display: grid; gap: 4px; }
.link-field > span { display: flex; align-items: center; gap: 7px; font-size: .85rem; font-weight: 500; color: var(--text-2); }
.link-field > span svg { color: var(--c); }
.link-field input { padding: 8px 10px; font-size: .9rem; }
.link-field input:not(:placeholder-shown) { border-color: color-mix(in srgb, var(--c) 45%, var(--line)); }

/* Selector de país */
.country-picker { position: relative; }
.country-btn { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; text-align: left; }
.country-btn::after { content: ''; margin-left: auto; width: 8px; height: 8px; border-right: 2px solid var(--text-3); border-bottom: 2px solid var(--text-3); transform: rotate(45deg) translateY(-3px); }
.country-btn img, .country-panel img { border-radius: 2px; width: 22px; height: 16px; object-fit: cover; flex: none; }
.country-panel { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 6px); background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow); padding: 8px; }
.country-panel ul { list-style: none; margin: 8px 0 0; padding: 0; max-height: 260px; overflow-y: auto; }
.country-panel li { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 7px; cursor: pointer; }
.country-panel li:hover, .country-panel li.is-on { background: var(--surface-3); }
.flag-none { width: 22px; text-align: center; }

/* Enviar canción */
.limit-note { padding: 10px 14px; border-radius: var(--radius-sm); background: rgb(255 181 71 / .08); border: 1px solid rgb(255 181 71 / .3); }
.step-n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: .8rem; margin-right: 6px; }
.results { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; }
.result { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-2); cursor: pointer; text-align: left; text-decoration: none; }
.result:hover { border-color: var(--accent); }
.result img { width: 60px; height: 60px; border-radius: 8px; object-fit: cover; flex: none; background: var(--surface-3); }
.result-text { flex: 1; display: grid; min-width: 0; }
.result-text strong, .result-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.result.is-picked { cursor: default; border-color: var(--accent); }
.step + .step { margin-top: 10px; }

/* ---------- Diálogos ---------- */
.modal { border: 1px solid var(--line); border-radius: 18px; background: var(--surface-2); color: var(--text); padding: 0; width: min(460px, calc(100% - 32px)); box-shadow: var(--shadow); }
.modal::backdrop { background: rgb(8 3 8 / .7); backdrop-filter: blur(3px); }
.modal-body { padding: 22px; display: grid; gap: 12px; }
.modal-title { font-size: 1.2rem; margin: 0; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.pick-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; max-height: 280px; overflow-y: auto; }
.pick { width: 100%; text-align: left; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); cursor: pointer; }
.pick:hover:not(:disabled) { border-color: var(--accent); }
.pick.is-on { opacity: .55; cursor: default; }
.pick.is-on::after { content: ' ✓ ya está'; color: var(--ok); font-size: .85rem; }
.new-playlist { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding-top: 12px; border-top: 1px solid var(--line); }
.new-playlist input[type=text] { flex: 1 1 100%; }

.empty { display: grid; justify-items: center; gap: 10px; padding: 40px 16px; text-align: center; color: var(--text-3); background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); grid-column: 1 / -1; }
.empty p { margin: 0; }
.empty-big { background: none; border: 0; padding-block: 70px; }
.empty-big h1 { color: var(--text); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 40px; padding: 30px 0 20px; background: var(--bg-2); }
.footer-row { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.footer-row p { max-width: 46ch; font-size: .88rem; margin-top: 12px; }
.footer-links { display: flex; gap: 8px 18px; flex-wrap: wrap; align-content: flex-start; }
.footer-links a { text-decoration: none; color: var(--text-2); font-size: .92rem; }
.footer-legal { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: .8rem; margin-top: 20px; }

/* ---------- Reproductor ---------- */
.player { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; }
.player-bar { height: var(--player-h); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) minmax(0, 1fr); align-items: center; gap: 16px; padding: 0 16px; background: rgb(24 15 24 / .96); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
.player-now { display: flex; align-items: center; gap: 12px; min-width: 0; text-decoration: none; }
.player-art { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; background: var(--surface-3); flex: none; }
.player.is-playing .player-art { box-shadow: 0 0 0 2px var(--accent); }
.player-meta { display: grid; min-width: 0; }
.player-meta strong, .player-meta small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-meta small { color: var(--text-3); }
.player-center { display: grid; gap: 2px; justify-items: center; }
.player-controls { display: flex; align-items: center; gap: 10px; }
.play-btn { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--text); color: var(--bg); display: grid; place-items: center; cursor: pointer; }
.play-btn:hover { transform: scale(1.06); }
.play-btn .when-playing, .player.is-playing .play-btn .when-paused { display: none; }
.player.is-playing .play-btn .when-playing { display: block; }
.play-btn .when-paused { margin-left: 2px; }
.player-progress { display: flex; align-items: center; gap: 8px; width: 100%; max-width: 520px; font-size: .72rem; color: var(--text-3); font-variant-numeric: tabular-nums; }
.player-progress input { flex: 1; accent-color: var(--accent); height: 4px; cursor: pointer; }
.player.is-uncontrollable .player-progress { visibility: hidden; }
.player-side { display: flex; align-items: center; justify-content: flex-end; gap: 4px; min-width: 0; }
.player-sources { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; min-width: 0; margin-right: 4px; }
.src-chip { flex: none; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--text-2); font-size: .75rem; font-weight: 700; cursor: pointer; }
.src-chip:hover { color: var(--text); border-color: var(--text-3); }
.src-chip.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.src-chip.src-spotify.is-active { background: #1ED760; border-color: #1ED760; color: #052E14; }
.src-chip.src-youtube.is-active, .src-chip.src-youtube_music.is-active { background: #FF0033; border-color: #FF0033; color: #fff; }
.src-chip.src-deezer.is-active { background: #A238FF; border-color: #A238FF; color: #fff; }
.src-chip.src-soundcloud.is-active { background: #FF5500; border-color: #FF5500; color: #fff; }
/* Panel con el reproductor oficial (YouTube pide que su video se vea: mínimo 200 px). */
.player-stage { position: absolute; right: 16px; bottom: calc(var(--player-h) + 12px); width: 360px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); }
.player-stage.is-big { width: min(720px, calc(100vw - 32px)); }
.player-stage-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 4px 6px 4px 12px; font-size: .8rem; color: var(--text-2); }
.player-stage-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stage-holder iframe { display: block; border: 0; width: 100%; }
.stage-youtube { aspect-ratio: 16 / 9; min-height: 200px; }
.stage-youtube iframe { height: 100%; }
.player-queue { position: absolute; left: 16px; bottom: calc(var(--player-h) + 12px); width: 340px; max-height: 50vh; display: flex; flex-direction: column; background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; }
.player-queue-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 8px 14px; border-bottom: 1px solid var(--line); }
.player-queue-list { list-style: decimal; margin: 0; padding: 6px 6px 6px 34px; overflow-y: auto; color: var(--text-3); font-size: .85rem; }
.player-queue-list button { display: grid; width: 100%; text-align: left; border: 0; background: none; padding: 6px 8px; border-radius: 8px; cursor: pointer; }
.player-queue-list button:hover { background: var(--surface-3); }
.player-queue-list strong, .player-queue-list small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-queue-list strong { color: var(--text); font-weight: 500; }
.player-queue-list .is-current strong { color: var(--accent); }

/* ---------- Responsivo ---------- */
@media (max-width: 1000px) {
    .song-page { grid-template-columns: 1fr; }
    .hero { grid-template-columns: 1fr; }
    .hero-art { display: none; }
}
@media (max-width: 760px) {
    .hide-sm { display: none !important; }
    .header-row { gap: 10px; height: 58px; }
    .logo-text { font-size: .98rem; }
    .header-search { order: 3; }
    .header-row { flex-wrap: wrap; height: auto; padding-block: 10px 6px; }
    .header-search { flex: 1 1 100%; max-width: none; }
    .song-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .song-body { padding: 10px 10px 2px; }
    .song-title { font-size: .92rem; }
    .song-foot { flex-direction: column; align-items: stretch; padding: 6px; }
    .song-foot .reactions { justify-content: space-between; }
    .song-tools { justify-content: space-between; }
    .song-hero { grid-template-columns: 1fr; padding: 14px; }
    .song-hero-art { max-width: 240px; margin-inline: auto; }
    .row-2 { grid-template-columns: 1fr; }
    .archive-art img, .pl-mosaic-lg { width: 160px; height: 160px; }
    .track { grid-template-columns: 22px 44px minmax(0, 1fr) auto auto; gap: 8px; padding: 6px 4px; }
    .track-num { font-size: .8rem; }
    .comment-replies { margin-left: 8px; padding-left: 10px; }
    .comment-form-reply { margin-left: 0; }
    .comment-form > .avatar { display: none; }
    :root { --player-h: 118px; }
    .player-bar { grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; gap: 4px 10px; padding: 8px 12px; }
    .player-center { grid-column: 2; grid-row: 1; }
    .player-progress { grid-column: 1 / -1; }
    .player-center .player-progress { display: none; }
    .player-side { grid-column: 1 / -1; grid-row: 2; justify-content: space-between; }
    .player-stage { left: 8px; right: 8px; width: auto; bottom: calc(var(--player-h) + 8px); }
    .player-stage.is-big { width: auto; }
    .player-queue { left: 8px; right: 8px; width: auto; }
    .filters { padding: 10px; }
    .filter { flex: 1 1 140px; }
    .filter select { width: 100%; }
}
