/* ==========================================================
   murottal.css
   Pemutar murottal: pill pemutar, equalizer, panel pilihan surat, pencarian, dan daftar surat.
   ========================================================== */

/* ===== MUROTTAL PLAYER (pill minimalis + panel pilihan surat) ===== */
#murottalRow { position: relative; z-index: 30; }
.murottal-wrap {
    position: relative;
    display: inline-block;
    max-width: 100%;
}
.murottal-pill {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: 100%;
    padding: 4px 12px 4px 4px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(15, 17, 26, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 14px rgba(0, 243, 255, 0.06);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.murottal-wrap.is-playing .murottal-pill {
    border-color: rgba(0, 243, 255, 0.4);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 18px rgba(0, 243, 255, 0.18);
}
.murottal-btn {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    border: 0;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    color: #06070b;
    background: linear-gradient(135deg, #00f3ff, #b026ff);
    box-shadow: 0 0 10px rgba(0, 243, 255, 0.4);
    cursor: pointer;
}
.murottal-btn.pulse { animation: murottal-pulse 1.8s ease-in-out infinite; }
@keyframes murottal-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0, 243, 255, 0.55); }
    50% { box-shadow: 0 0 0 6px rgba(0, 243, 255, 0); }
}
.murottal-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    cursor: pointer;
    text-align: left;
}
.murottal-eq, .murottal-mini-eq {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 10px;
    flex-shrink: 0;
}
.murottal-eq span, .murottal-mini-eq span {
    width: 2px;
    height: 3px;
    border-radius: 2px;
    background: #00f3ff;
    opacity: 0.4;
}
.murottal-wrap.is-playing .murottal-eq span,
.murottal-wrap.is-playing .murottal-item.active .murottal-mini-eq span {
    opacity: 1;
    animation: murottal-eq 0.9s ease-in-out infinite;
}
.murottal-wrap.is-playing .murottal-eq span:nth-child(2),
.murottal-wrap.is-playing .murottal-item.active .murottal-mini-eq span:nth-child(2) { animation-delay: 0.2s; }
.murottal-wrap.is-playing .murottal-eq span:nth-child(3),
.murottal-wrap.is-playing .murottal-item.active .murottal-mini-eq span:nth-child(3) { animation-delay: 0.4s; }
.murottal-wrap.is-playing .murottal-eq span:nth-child(4) { animation-delay: 0.1s; }
@keyframes murottal-eq {
    0%, 100% { height: 3px; }
    50% { height: 10px; }
}
.murottal-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
}
.murottal-label {
    font-size: 7px;
    line-height: 1;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 3px;
    white-space: nowrap;
}
.murottal-name {
    min-width: 92px;
    font-family: 'Outfit', sans-serif;
    font-size: 10.5px;
    font-weight: 500;
    line-height: 1.15;
    color: #e2e8f0;
    white-space: nowrap;
}
.murottal-chevron {
    font-size: 8px;
    color: #00f3ff;
    transition: transform 0.25s ease;
}
.murottal-trigger[aria-expanded="true"] .murottal-chevron { transform: rotate(180deg); }
.murottal-progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.06);
    pointer-events: none;
}
.murottal-progress span {
    display: block;
    height: 100%;
    transform-origin: left center;
    transform: scaleX(0);
    background: linear-gradient(90deg, #00f3ff, #b026ff, #ff007f);
}

/* Panel pilihan surat */
.murottal-panel {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    z-index: 40;
    width: 276px;
    max-width: calc(100vw - 32px);
    transform: translateX(-50%);
    border-radius: 16px;
    overflow: hidden;
    background: rgba(10, 12, 20, 0.98);
    border: 1px solid rgba(0, 243, 255, 0.22);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.65), 0 0 28px rgba(0, 243, 255, 0.1);
}
.murottal-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #00f3ff, #b026ff, #ff007f);
}
.murottal-panel.open {
    display: block;
    animation: murottal-pop 0.22s ease-out;
}
@keyframes murottal-pop {
    from { opacity: 0; transform: translateX(-50%) translateY(-6px) scale(0.97); }
    to { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}
.murottal-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 13px 14px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.murottal-search i { font-size: 11px; color: #00f3ff; }
.murottal-search input {
    flex: 1;
    min-width: 0;
    padding: 0;
    border: 0;
    outline: none;
    background: transparent;
    color: #e2e8f0;
    font-size: 12px;
}
.murottal-search input::placeholder { color: #64748b; }
@media (pointer: coarse) { .murottal-search input { font-size: 16px; } }
.murottal-list {
    position: relative;
    max-height: 252px;
    overflow-y: auto;
    padding: 6px;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 243, 255, 0.35) transparent;
}
.murottal-list::-webkit-scrollbar { width: 4px; }
.murottal-list::-webkit-scrollbar-thumb { background: rgba(0, 243, 255, 0.35); border-radius: 4px; }
.murottal-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 7px 8px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #cbd5e1;
    text-align: left;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.murottal-item:hover, .murottal-item:focus-visible {
    outline: none;
    background: rgba(255, 255, 255, 0.06);
}
.murottal-item.active {
    color: #fff;
    background: linear-gradient(90deg, rgba(0, 243, 255, 0.15), rgba(176, 38, 255, 0.1));
    box-shadow: inset 2px 0 0 #00f3ff;
}
.murottal-num {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 9.5px;
    font-weight: 600;
    color: #00f3ff;
    background: rgba(0, 243, 255, 0.08);
    border: 1px solid rgba(0, 243, 255, 0.18);
}
.murottal-item.active .murottal-num {
    color: #06070b;
    background: linear-gradient(135deg, #00f3ff, #b026ff);
    border-color: transparent;
}
.murottal-iname {
    flex: 1;
    min-width: 0;
    font-size: 11.5px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.murottal-mini-eq { display: none; }
.murottal-wrap.is-playing .murottal-item.active .murottal-mini-eq { display: flex; }
.murottal-ar {
    flex-shrink: 0;
    direction: rtl;
    font-family: 'Noto Naskh Arabic', 'Amiri', 'Scheherazade New', 'Traditional Arabic', serif;
    font-size: 15px;
    line-height: 1.2;
    color: #94a3b8;
}
.murottal-item.active .murottal-ar { color: #00f3ff; }
.murottal-empty {
    padding: 18px 8px;
    text-align: center;
    font-size: 11px;
    color: #64748b;
}
.murottal-panel-foot {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 8.5px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #64748b;
}
.murottal-panel-foot i { color: #b026ff; }
