/* ATLAS BEATS v17.1 — song page (#songPage). Scoped. */
#songPage { display: block; min-height: 60vh; color: #fff; }
#songPage .sg-load { display: grid; place-items: center; min-height: 40vh; }
#songPage .sg-load .i, #songPage .spin { width: 28px; height: 28px; animation: sgSpin 1s linear infinite; }
@keyframes sgSpin { to { transform: rotate(360deg); } }
#songPage .sg-nf { display: grid; place-items: center; gap: 14px; min-height: 40vh; text-align: center; color: #b3b3b3; }
#songPage .i { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
#songPage .i.flip { transform: scaleX(-1); }
html[dir="rtl"] #songPage .i.flip { transform: none; }
html[dir="rtl"] #songPage .sg-ctl .sg-mini .i:not(.flip) { transform: scaleX(-1); }
#songPage .num { font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
#songPage .sg-muted { color: #8a8a9a; font-size: 12.5px; }
#songPage .sg-brand { font: 900 13px/1 'Inter', system-ui, sans-serif; letter-spacing: 2px; background: linear-gradient(90deg, #a78bfa, #60a5fa); -webkit-background-clip: text; background-clip: text; color: transparent; }
/* hero */
#songPage .sg-hero { position: relative; isolation: isolate; border-radius: 20px; overflow: hidden; margin: 4px 0 18px; min-height: 300px; }
#songPage .sg-hero-bg { position: absolute; inset: -40px; background: var(--img) center/cover; filter: blur(42px) saturate(1.5) brightness(.5); transform: scale(1.1); z-index: -2; }
#songPage .sg-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 8, 20, .15), rgba(10, 8, 20, .82) 100%); z-index: -1; }
#songPage .sg-hero-in { display: flex; gap: 28px; align-items: flex-end; padding: 36px 32px 30px; }
#songPage .sg-cover { position: relative; flex: none; width: 240px; height: 240px; border-radius: 16px; overflow: hidden; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .9), 0 0 0 1px rgba(255, 255, 255, .08); }
#songPage .sg-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s; }
#songPage .sg-cover:hover img { transform: scale(1.04); }
#songPage .sg-bigplay { position: absolute; inset: 0; margin: auto; width: 72px; height: 72px; border-radius: 50%; border: 0; background: rgba(12, 10, 24, .55); backdrop-filter: blur(8px); color: #fff; display: grid; place-items: center; cursor: pointer; opacity: 0; transform: scale(.9); transition: opacity .25s, transform .25s, background .25s; }
#songPage .sg-bigplay .i { width: 30px; height: 30px; }
#songPage .sg-cover:hover .sg-bigplay, #songPage .sg-cover.on .sg-bigplay { opacity: 1; transform: none; }
#songPage .sg-bigplay:hover { background: linear-gradient(135deg, #7c3aed, #3b82f6); }
#songPage .pa { display: none; }
#songPage .is-on .pa { display: inline-flex; }
#songPage .is-on .pl { display: none; }
#songPage .sg-eq { position: absolute; inset-inline-end: 10px; bottom: 10px; display: none; gap: 3px; align-items: flex-end; height: 18px; }
#songPage .sg-cover.on .sg-eq { display: flex; }
#songPage .sg-eq i { width: 3px; height: 40%; border-radius: 2px; background: #fff; animation: sgEq .9s ease-in-out infinite; }
#songPage .sg-eq i:nth-child(2) { animation-delay: .15s; } #songPage .sg-eq i:nth-child(3) { animation-delay: .3s; } #songPage .sg-eq i:nth-child(4) { animation-delay: .45s; }
@keyframes sgEq { 0%, 100% { height: 35%; } 50% { height: 100%; } }
#songPage .sg-meta { min-width: 0; flex: 1; display: grid; gap: 10px; }
#songPage .sg-kicker { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase; color: #d8d4f5; opacity: .9; }
html[lang="fa"] #songPage .sg-kicker, html[lang="ar"] #songPage .sg-kicker { letter-spacing: 0; font-size: 12.5px; }
#songPage .sg-kicker .i { width: 14px; height: 14px; }
#songPage .sg-h1 { margin: 0; font-size: clamp(24px, 3.6vw, 44px); font-weight: 900; line-height: 1.2; letter-spacing: -.5px; text-shadow: 0 6px 30px rgba(0, 0, 0, .5); overflow-wrap: anywhere; }
#songPage .sg-h1.fa-text { letter-spacing: 0; }
#songPage .sg-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; color: #e8e6f5; font-size: 14px; }
#songPage .sg-dot { opacity: .5; }
#songPage .sg-link { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; color: inherit; font: 700 inherit; font-family: inherit; cursor: pointer; padding: 0; text-decoration: underline transparent; transition: text-decoration-color .2s, color .2s; }
#songPage .sg-link:hover { text-decoration-color: currentColor; color: #fff; }
#songPage .sg-link .i { width: 15px; height: 15px; }
#songPage .sg-pill { font-size: 11.5px; font-weight: 800; padding: 3px 9px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .12); }
#songPage .sg-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 6px; }
#songPage .sg-btn { position: relative; display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 20px; border-radius: 999px; border: 1px solid transparent; font: 800 14px/1 inherit; font-family: inherit; color: #fff; cursor: pointer; transition: transform .2s, filter .2s, background .2s, border-color .2s; white-space: nowrap; }
#songPage .sg-btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
#songPage .sg-btn:active { transform: scale(.98); }
#songPage .sg-btn.primary { background: linear-gradient(135deg, #7c3aed, #3b82f6); box-shadow: 0 14px 34px -12px rgba(124, 58, 237, .95); }
#songPage .sg-btn.dl { background: #fff; color: #0b0a14; box-shadow: 0 14px 34px -14px rgba(255, 255, 255, .5); padding-inline-end: 16px; }
#songPage .sg-btn.dl small { font-size: 10.5px; font-weight: 800; color: #5b21b6; background: rgba(124, 58, 237, .12); padding: 3px 8px; border-radius: 999px; }
#songPage .sg-btn.dl.big { height: 54px; padding: 0 24px; font-size: 15px; }
#songPage .sg-btn.ghost { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .14); backdrop-filter: blur(6px); }
#songPage .sg-btn.ghost:hover { background: rgba(255, 255, 255, .14); }
#songPage .sg-btn.icon { width: 46px; padding: 0; justify-content: center; background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .14); }
#songPage .sg-btn.icon.on { color: #f472b6; border-color: rgba(244, 114, 182, .5); background: rgba(244, 114, 182, .14); }
#songPage .sg-btn.icon.on .i { fill: currentColor; }
/* grid */
#songPage .sg-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
#songPage .sg-card { background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .07); border-radius: 18px; padding: 18px 20px 20px; margin-bottom: 18px; }
#songPage .sg-card h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; font-size: 17px; font-weight: 900; letter-spacing: -.2px; }
#songPage .sg-card h2 .i { width: 18px; height: 18px; color: #a78bfa; }
/* player */
#songPage .sg-wave { position: relative; height: 96px; border-radius: 12px; background: linear-gradient(180deg, rgba(255, 255, 255, .03), rgba(0, 0, 0, .15)); overflow: hidden; cursor: pointer; }
#songPage .sg-wave canvas { display: block; width: 100%; height: 96px; }
#songPage .sg-wave-tip { position: absolute; top: 6px; transform: translateX(-50%); font-size: 11px; font-weight: 800; padding: 2px 7px; border-radius: 6px; background: rgba(0, 0, 0, .7); color: #fff; pointer-events: none; }
html[dir="rtl"] #songPage .sg-wave-tip { transform: translateX(50%); }
#songPage .sg-wave:not(:hover) .sg-wave-tip { display: none; }
#songPage .sg-ctl { display: flex; align-items: center; gap: 12px; margin-top: 14px; }
#songPage .sg-play { width: 50px; height: 50px; border-radius: 50%; border: 0; background: linear-gradient(135deg, #7c3aed, #3b82f6); color: #fff; display: grid; place-items: center; cursor: pointer; box-shadow: 0 10px 26px -10px rgba(124, 58, 237, .9); flex: none; transition: transform .2s; }
#songPage .sg-play:hover { transform: scale(1.05); }
#songPage .sg-play .i { width: 22px; height: 22px; }
#songPage .sg-time { font-size: 12px; font-weight: 700; color: #b3b3b3; min-width: 40px; text-align: center; }
#songPage .sg-bar { position: relative; flex: 1; height: 6px; border-radius: 999px; background: rgba(255, 255, 255, .14); cursor: pointer; }
#songPage .sg-bar i { position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 0; border-radius: inherit; background: linear-gradient(90deg, #a78bfa, #60a5fa); }
#songPage .sg-bar b { position: absolute; top: 50%; inset-inline-start: 0; width: 14px; height: 14px; border-radius: 50%; background: #fff; transform: translate(-50%, -50%); box-shadow: 0 2px 8px rgba(0, 0, 0, .5); opacity: 0; transition: opacity .2s; }
html[dir="rtl"] #songPage .sg-bar b { transform: translate(50%, -50%); }
#songPage .sg-bar:hover b, #songPage .is-cur .sg-bar b { opacity: 1; }
#songPage .sg-mini { width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .06); color: #ddd; display: grid; place-items: center; cursor: pointer; }
#songPage .sg-mini:hover { background: rgba(255, 255, 255, .14); color: #fff; }
/* lyrics */
#songPage .sg-ly-state { margin-inline-start: auto; font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 999px; background: rgba(34, 197, 94, .15); color: #86efac; border: 1px solid rgba(34, 197, 94, .3); }
#songPage .sg-ly-state:empty { display: none; }
#songPage .sg-ly-body { max-height: 520px; overflow: auto; scrollbar-width: thin; padding-inline-end: 6px; }
#songPage .sg-ly-load, #songPage .sg-ly-none { display: flex; align-items: center; gap: 10px; color: #9a97b0; font-size: 13.5px; padding: 14px 4px; }
#songPage .sg-ly-none .i { color: #6d6a85; }
#songPage .sg-ly { display: grid; gap: 4px; }
#songPage .sg-ly-line { margin: 0; font-size: 17px; line-height: 1.9; font-weight: 700; color: #cfcde0; padding: 4px 10px; border-radius: 10px; transition: color .25s, background .25s, transform .25s; }
#songPage .sg-ly-line.fa-text { font-family: 'Vazirmatn', system-ui, sans-serif; }
#songPage .sg-ly.synced .sg-ly-line { cursor: pointer; opacity: .55; }
#songPage .sg-ly.synced .sg-ly-line:hover { opacity: .9; background: rgba(255, 255, 255, .05); }
#songPage .sg-ly.synced .sg-ly-line.on { opacity: 1; color: #fff; background: linear-gradient(90deg, rgba(124, 58, 237, .25), transparent); transform: translateX(0) scale(1.01); text-shadow: 0 0 24px rgba(167, 139, 250, .6); }
/* info */
#songPage .sg-table { width: 100%; border-collapse: collapse; font-size: 14px; }
#songPage .sg-table th { text-align: start; width: 34%; padding: 11px 12px; color: #9a97b0; font-weight: 700; background: rgba(255, 255, 255, .03); border-bottom: 1px solid rgba(255, 255, 255, .06); }
#songPage .sg-table td { padding: 11px 12px; border-bottom: 1px solid rgba(255, 255, 255, .06); font-weight: 700; }
#songPage .sg-table tr:first-child th { border-start-start-radius: 10px; } #songPage .sg-table tr:last-child th, #songPage .sg-table tr:last-child td { border-bottom: 0; }
#songPage .sg-table .fa-text { font-family: 'Vazirmatn', system-ui, sans-serif; }
#songPage .sg-dlrow { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; align-items: center; }
/* side lists */
#songPage .sg-list { display: grid; gap: 4px; }
#songPage .sg-row { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 12px; cursor: pointer; transition: background .2s; min-width: 0; }
#songPage .sg-row:hover { background: rgba(255, 255, 255, .07); }
#songPage .sg-row img { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; background: #1b1830; flex: none; }
#songPage .sg-row-tx { min-width: 0; flex: 1; display: grid; }
#songPage .sg-row-tx b { font-size: 13.5px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#songPage .sg-row-tx small { font-size: 12px; color: #a7a4bd; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#songPage .sg-row .fa-text { font-family: 'Vazirmatn', system-ui, sans-serif; }
#songPage .sg-row-d { font-size: 11.5px; color: #8a8a9a; }
#songPage .sg-row-play { width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .1); color: #fff; display: grid; place-items: center; cursor: pointer; opacity: 0; transition: opacity .2s, background .2s; flex: none; }
#songPage .sg-row:hover .sg-row-play { opacity: 1; }
#songPage .sg-row-play:hover { background: linear-gradient(135deg, #7c3aed, #3b82f6); }
#songPage .sg-row-play .i { width: 15px; height: 15px; }
#songPage .sg-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
#songPage .sg-tile { position: relative; border: 0; padding: 0; border-radius: 12px; overflow: hidden; aspect-ratio: 1; background: linear-gradient(135deg, var(--s1), var(--s2)); cursor: pointer; color: #fff; display: grid; align-items: end; }
#songPage .sg-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
#songPage .sg-tile:hover img { transform: scale(1.06); }
#songPage .sg-tile b { position: relative; font-size: 12px; font-weight: 800; padding: 22px 8px 8px; background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .75)); text-align: start; }
/* search rows: page button */
.ss-row .ss-page { width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .08); color: #ddd; display: grid; place-items: center; cursor: pointer; flex: none; opacity: 0; transition: opacity .2s, background .2s; }
.ss-row:hover .ss-page, .ss-row.on .ss-page { opacity: 1; }
.ss-row .ss-page:hover { background: linear-gradient(135deg, #7c3aed, #3b82f6); color: #fff; }
.ss-row .ss-page .i { width: 14px; height: 14px; }
@media (hover: none) { .ss-row .ss-page { opacity: 1; } }
/* responsive */
@media (max-width: 1100px) { #songPage .sg-grid { grid-template-columns: 1fr; } #songPage .sg-tiles { grid-template-columns: repeat(6, 1fr); } }
@media (max-width: 767px) {
  #songPage .sg-hero { border-radius: 16px; margin: 0 0 14px; min-height: 0; }
  #songPage .sg-hero-in { flex-direction: column; align-items: center; text-align: center; padding: 22px 16px 20px; gap: 16px; }
  #songPage .sg-cover { width: min(230px, 64vw); height: min(230px, 64vw); }
  #songPage .sg-meta { justify-items: center; width: 100%; }
  #songPage .sg-sub { justify-content: center; }
  #songPage .sg-h1 { font-size: clamp(20px, 6.4vw, 28px); }
  #songPage .sg-actions { justify-content: center; gap: 8px; }
  #songPage .sg-btn { height: 42px; padding: 0 15px; font-size: 13px; }
  #songPage .sg-btn.primary { flex: 1 1 100%; justify-content: center; }
  #songPage .sg-btn.dl { flex: 1 1 100%; justify-content: center; }
  #songPage .sg-btn.icon { width: 42px; }
  #songPage .sg-card { padding: 14px 14px 16px; border-radius: 14px; margin-bottom: 12px; }
  #songPage .sg-card h2 { font-size: 15px; }
  #songPage .sg-ctl { gap: 8px; }
  #songPage .sg-mini { display: none; }
  #songPage .sg-ly-line { font-size: 15.5px; }
  #songPage .sg-table th { width: 38%; padding: 9px 10px; font-size: 13px; }
  #songPage .sg-table td { padding: 9px 10px; font-size: 13px; }
  #songPage .sg-tiles { grid-template-columns: repeat(3, 1fr); }
  #songPage .sg-row-play { opacity: 1; }
}

/* Now Playing titles are links into the song page */
#npTitle.sg-link-src, #plTitle.sg-link-src { cursor: pointer; }
#npTitle.sg-link-src:hover, #plTitle.sg-link-src:hover { text-decoration: underline; text-decoration-color: rgba(167, 139, 250, .7); text-underline-offset: 3px; }

/* Persian name of the song (when the source knew it) */
#songPage .sg-fa { margin: -2px 0 0; font: 700 16px/1.5 Vazirmatn, system-ui, sans-serif; color: #e4e1f5; opacity: .92; }
#songPage .sg-fa .sg-muted { font-weight: 600; }
