/* ═══════════════════════════════════════════════
   DHAGEYSO — Design System v1
   Unified Somali Religious Audio App
   ═══════════════════════════════════════════════ */

:root {
    --bg-primary: #0a0f1c;
    --bg-secondary: #111827;
    --bg-card: rgba(17, 24, 39, 0.8);
    --bg-input: #1e293b;
    --bg-hover: #1e293b;
    --bg-glass: rgba(10, 15, 28, 0.85);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --accent: #10b981;
    --accent-glow: rgba(16, 185, 129, 0.15);
    --accent-hover: #059669;
    --gold: #f59e0b;
    --gold-glow: rgba(245, 158, 11, 0.12);
    --red: #ef4444;
    --border: rgba(255, 255, 255, 0.06);
    --border-light: rgba(255, 255, 255, 0.1);
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --radius: 16px;
    --radius-sm: 12px;
    --radius-pill: 999px;
    --transition: all 0.25s ease;
    --font: 'Inter', -apple-system, system-ui, sans-serif;
    --tab-bar-h: 64px;
    --mini-player-h: 120px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html,
body {
    height: 100%;
    font-family: var(--font);
    background: var(--bg-primary);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    overflow: hidden;
}

.hidden {
    display: none !important;
}

/* ═══ APP LAYOUT ═══ */
.app {
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

/* ═══ TAB VIEWS ═══ */
.tab-view {
    display: none;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    padding-bottom: var(--tab-bar-h);
}

.tab-view.active {
    display: flex;
}

.tab-view.has-mini-player {
    padding-bottom: calc(var(--tab-bar-h) + var(--mini-player-h));
}

.tab-header {
    padding: max(16px, env(safe-area-inset-top)) 20px 12px;
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.tab-title {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, var(--text-primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tab-count {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

/* ═══ HEADER ROW ═══ */
.header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.header-icon-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-light);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.header-icon-btn:active {
    transform: scale(0.9);
    background: rgba(255, 255, 255, 0.08);
}

.header-icon-btn svg {
    width: 20px;
    height: 20px;
}


/* ═══ SCROLL AREA ═══ */
.scroll-area {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px 20px;
    scrollbar-width: none;
}

.scroll-area::-webkit-scrollbar {
    display: none;
}

/* ═══ CONTENT CARDS ═══ */
.content-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    backdrop-filter: blur(8px);
}

/* ═══ FILTER BAR ═══ */
.filter-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    flex-shrink: 0;
}

.filter-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
}

.dropdown-wrap {
    position: relative;
}

.dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
}

.dropdown-trigger:hover,
.dropdown-trigger.open {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--accent);
    color: var(--accent);
}

.dropdown-trigger.open svg {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 180px;
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    z-index: 100;
    max-height: 260px;
    overflow-y: auto;
}

.dropdown-item {
    padding: 11px 16px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.15s;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.dropdown-item.selected {
    color: var(--accent);
    font-weight: 600;
}

.dropdown-item.selected::after {
    content: " ✓";
}

/* ═══ LIST ITEMS ═══ */
.list-item {
    display: flex;
    align-items: center;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s;
}

.list-item:last-child {
    border-bottom: none;
}

.list-item:active {
    background: rgba(255, 255, 255, 0.04);
}

.list-img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
    margin-right: 14px;
    background: #1e293b;
    flex-shrink: 0;
}

.list-emoji {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    margin-right: 14px;
    background: var(--accent-glow);
    border: 1px solid rgba(16, 185, 129, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.list-info {
    flex: 1;
    min-width: 0;
}

.list-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-bottom: 3px;
}

.list-meta {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
    gap: 6px;
    overflow: hidden;
    white-space: nowrap;
}

.list-meta span {
    overflow: hidden;
    text-overflow: ellipsis;
}

.fav-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition);
}

.fav-btn:active {
    transform: scale(0.85);
}

.fav-btn.active {
    color: var(--red);
}

.fav-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.list-play-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.list-play-btn:active {
    transform: scale(0.9);
}

.list-play-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* ═══ CHAT (LECTURES TAB) ═══ */
.chat-area {
    flex: 1;
    overflow-y: auto;
    padding: 20px 16px;
    scroll-behavior: smooth;
}

.welcome {
    text-align: center;
    padding: 36px 16px 24px;
    animation: fadeIn 0.6s ease;
}

.welcome-icon {
    font-size: 56px;
    margin-bottom: 16px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.welcome h2 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 10px;
    background: linear-gradient(135deg, var(--text-primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.welcome p {
    color: var(--text-secondary);
    font-size: 14px;
    max-width: 400px;
    margin: 0 auto 24px;
    line-height: 1.6;
}

.suggestion-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    max-width: 500px;
    margin: 0 auto;
}

.chip {
    padding: 9px 14px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
    white-space: nowrap;
}

.chip:hover {
    background: var(--accent-glow);
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-1px);
}

.messages {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.message {
    display: flex;
    gap: 10px;
    animation: slideIn 0.3s ease;
    max-width: 95%;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.user {
    flex-direction: row-reverse;
    align-self: flex-end;
}

.message-avatar {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.message.bot .message-avatar {
    background: var(--accent-glow);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.message.user .message-avatar {
    background: var(--gold-glow);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.message-bubble {
    padding: 12px 16px;
    border-radius: var(--radius);
    line-height: 1.6;
    font-size: 14px;
}

.message.bot .message-bubble {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-primary);
    border-top-left-radius: 4px;
}

.message.user .message-bubble {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(16, 185, 129, 0.08));
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--text-primary);
    border-top-right-radius: 4px;
}

.lecture-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    margin: 8px 0 4px;
    transition: var(--transition);
}

.lecture-card:hover {
    border-color: var(--accent);
}

.lecture-title {
    font-weight: 600;
    font-size: 13px;
    color: var(--accent);
    margin-bottom: 5px;
}

.lecture-meta {
    display: flex;
    gap: 10px;
    font-size: 11px;
    color: var(--text-muted);
    align-items: center;
    flex-wrap: wrap;
}

.lecture-meta span {
    display: flex;
    align-items: center;
    gap: 3px;
}

.lecture-play-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: var(--radius-pill);
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
    margin-left: auto;
}

.lecture-play-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 4px;
}

.typing-dot {
    width: 7px;
    height: 7px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingBounce {

    0%,
    60%,
    100% {
        transform: translateY(0);
    }

    30% {
        transform: translateY(-6px);
    }
}

.input-area {
    padding: 10px 16px max(10px, env(safe-area-inset-bottom));
    border-top: 1px solid var(--border);
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    flex-shrink: 0;
}

.chat-form {
    display: flex;
    gap: 8px;
}

.chat-form input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 14px;
    font-family: var(--font);
    outline: none;
    transition: var(--transition);
}

.chat-form input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.chat-form input::placeholder {
    color: var(--text-muted);
}

.btn-send {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.btn-send:disabled {
    background: var(--bg-hover);
    color: var(--text-muted);
    cursor: default;
}

.btn-send:not(:disabled):hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

/* ═══ FAVORITES TAB ═══ */
.fav-section {
    margin-bottom: 20px;
}

.fav-section-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 10px;
    padding-left: 4px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 16px;
    color: var(--text-muted);
    text-align: center;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.4;
}

.empty-state p {
    font-size: 14px;
    line-height: 1.6;
    max-width: 280px;
}

/* ═══ ABOUT TAB ═══ */
.about-content {
    padding: 20px 16px;
}

.about-card-main {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px 24px;
    text-align: center;
    margin-bottom: 20px;
}

.about-app-icon {
    font-size: 56px;
    margin-bottom: 12px;
}

.about-app-name {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.about-version {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.about-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
    max-width: 360px;
    margin-left: auto;
    margin-right: auto;
}

.about-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin-bottom: 24px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 28px;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: -1px;
    line-height: 1;
}

.stat-label {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-divider {
    width: 1px;
    height: 32px;
    background: var(--border-light);
}

.about-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--accent);
    color: white;
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.about-share-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.03);
}

.about-section {
    margin-bottom: 20px;
}

.about-section h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.about-section p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.about-section a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
}

.about-socials {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-top: 20px;
}

.social-link {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.social-link:active {
    transform: scale(0.9);
    background: rgba(255, 255, 255, 0.1);
}

.social-link svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* ═══ MINI PLAYER DOCK ═══ */
.mini-player {
    position: fixed;
    bottom: var(--tab-bar-h);
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 800px;
    background: linear-gradient(180deg, #141e30, #0e1726);
    border-top: 1px solid rgba(16, 185, 129, 0.15);
    padding: 8px 14px 10px;
    z-index: 50;
    box-shadow: 0 -6px 28px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mp-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.mp-info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
    cursor: pointer;
}

.mp-info:hover .mp-title {
    color: var(--text-primary);
}

.mp-cover {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
    background: #1e293b;
}

.mp-cover.hidden {
    display: none;
}

.mp-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.mp-icon.hidden {
    display: none;
}

.mp-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    transition: var(--transition);
}

.mp-expand {
    width: 26px;
    height: 26px;
    border: 1px solid var(--border-light);
    border-radius: 6px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition);
}

.mp-expand:hover {
    background: var(--bg-hover);
    color: var(--accent);
}

.mp-close-btn {
    width: 26px;
    height: 26px;
    border: 1px solid var(--border-light);
    border-radius: 6px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition);
}

.mp-close-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.mp-seek-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.mp-time {
    font-size: 10px;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
    font-weight: 500;
    min-width: 32px;
    text-align: center;
}

.mp-seek-bar {
    flex: 1;
    height: 3px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.mp-seek-bar::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: 2px solid #141e30;
}

.mp-controls-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.mp-speed-btn {
    padding: 2px 8px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
    min-width: 36px;
    text-align: center;
}

.mp-speed-btn:hover {
    background: var(--bg-hover);
    color: var(--accent);
    border-color: var(--accent);
}

.mp-center-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mp-ctrl {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.mp-ctrl:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.mp-play-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    box-shadow: 0 2px 12px rgba(16, 185, 129, 0.25);
}

.mp-play-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

.mp-spacer {
    min-width: 36px;
}

/* ═══ FULL SCREEN PLAYER ═══ */
.full-player {
    position: fixed;
    inset: 0;
    max-width: 800px;
    margin: 0 auto;
    background: linear-gradient(180deg, #0d1520 0%, #0a1628 30%, #081420 100%);
    z-index: 200;
    animation: playerSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow-y: auto;
}

@keyframes playerSlideUp {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

.full-player-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100%;
    padding: max(20px, env(safe-area-inset-top)) 24px 40px;
    justify-content: space-between;
}

.fp-top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding-bottom: 16px;
}

.fp-minimize {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.fp-minimize:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.fp-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.fp-speed {
    padding: 5px 12px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
}

.fp-speed:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--accent);
    border-color: var(--accent);
}

.fp-artwork {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px 0;
}

.fp-artwork-inner {
    width: clamp(200px, 55vw, 300px);
    aspect-ratio: 1;
    border-radius: 20px;
    background: linear-gradient(135deg, #1a3a4a, #0f2b3a, #162a3a);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 80px rgba(16, 185, 129, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.04);
    position: relative;
    overflow: hidden;
}

.fp-artwork-inner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 30%, rgba(16, 185, 129, 0.08), transparent 60%);
}

.fp-cover-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: relative;
    z-index: 1;
    border-radius: 20px;
}

.fp-artwork-emoji {
    font-size: clamp(56px, 14vw, 90px);
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
}

.fp-info {
    text-align: center;
    padding: 4px 0 20px;
    width: 100%;
}

.fp-title {
    font-size: clamp(18px, 4.5vw, 22px);
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
    margin-bottom: 4px;
}

.fp-category {
    font-size: 13px;
    color: var(--text-muted);
}

.fp-progress {
    width: 100%;
    padding: 0 0 12px;
}

.fp-seek-bar {
    width: 100%;
    height: 5px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

.fp-seek-bar::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: 3px solid var(--bg-primary);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.3);
}

.fp-times {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 6px;
    font-variant-numeric: tabular-nums;
}

.fp-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 4px 0 12px;
    width: 100%;
}

.fp-ctrl-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    position: relative;
}

.fp-ctrl-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.fp-ctrl-btn.active {
    color: var(--accent);
}

.ctrl-label {
    position: absolute;
    font-size: 8px;
    font-weight: 700;
    color: var(--text-muted);
    bottom: 4px;
}

.fp-play-btn {
    width: 64px;
    height: 64px;
    background: var(--accent);
    color: white;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.3);
}

.fp-play-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
    color: white;
}

.fp-fav-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    font-size: 13px;
    font-weight: 500;
}

.fp-fav-btn:hover {
    background: rgba(255, 255, 255, 0.08);
}

.fp-fav-btn.active {
    color: var(--red);
    border-color: rgba(239, 68, 68, 0.3);
}

.fp-fav-btn.active svg {
    fill: var(--red);
}

/* ═══ BOTTOM TAB BAR ═══ */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 800px;
    height: var(--tab-bar-h);
    background: rgba(10, 15, 28, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding-bottom: max(0px, env(safe-area-inset-bottom));
    z-index: 100;
}

.tab-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    padding: 6px 12px;
    font-family: var(--font);
    -webkit-tap-highlight-color: transparent;
}

.tab-btn svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
    transition: var(--transition);
}

.tab-btn.active {
    color: var(--accent);
}

.tab-btn:active {
    transform: scale(0.9);
}

/* ═══ TOAST ═══ */
#toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(255, 255, 255, 0.92);
    color: #000;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 4000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    width: max-content;
    max-width: 80%;
}

#toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 520px) {
    .tab-header {
        padding-left: 16px;
        padding-right: 16px;
    }

    .filter-bar {
        padding: 8px 16px;
    }

    .fp-controls {
        gap: 10px;
    }

    .fp-ctrl-btn {
        width: 38px;
        height: 38px;
    }

    .fp-play-btn {
        width: 56px;
        height: 56px;
    }
}