/*
Theme Name: Wapka Portal
Theme URI: https://sonicvault.io
Author: SonicVault Studio
Author URI: https://sonicvault.io
Description: Classic retro Wapka / EpisodeBD style ultra-fast audio download portal theme featuring cyan-blue glossy gradients, category track counts, WAP chevron navigation, direct multi-server download buttons, instant audio playback, and complete responsive layout.
Version: 1.0.0
License: Commercial
Text Domain: wapka-portal
*/

:root {
    --wap-blue-top: #1da1f2;
    --wap-blue-bottom: #0077b6;
    --wap-bar-start: #23afff;
    --wap-bar-mid: #008be3;
    --wap-bar-end: #0076c1;
    --wap-bar-border: #0067a8;
    --wap-red: #a80000;
    --wap-red-hover: #e00000;
    --wap-blue-link: #0066cc;
    --wap-text: #222222;
    --wap-muted: #555555;
    --wap-bg: #f0f3f8;
    --wap-container-bg: #ffffff;
    --wap-row-alt: #f7f9fc;
    --wap-border: #e2e8f0;
    --wap-pill-bg: #e2e8f0;
    --wap-pill-text: #4a5568;
    --wap-pill-border: #cbd5e1;
    --wap-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

[data-theme="dark"] {
    --wap-blue-top: #0f4c81;
    --wap-blue-bottom: #082d4f;
    --wap-bar-start: #195f9c;
    --wap-bar-mid: #104c80;
    --wap-bar-end: #0a3861;
    --wap-bar-border: #062847;
    --wap-red: #ff5252;
    --wap-red-hover: #ff7b7b;
    --wap-blue-link: #38bdf8;
    --wap-text: #e2e8f0;
    --wap-muted: #94a3b8;
    --wap-bg: #0b0f19;
    --wap-container-bg: #121826;
    --wap-row-alt: #182234;
    --wap-border: #1e293b;
    --wap-pill-bg: #1e293b;
    --wap-pill-text: #cbd5e1;
    --wap-pill-border: #334155;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--wap-font);
    background-color: var(--wap-bg);
    color: var(--wap-text);
    font-size: 13px;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--wap-blue-link);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Page Frame / Container */
.wap-wrapper {
    max-width: 980px;
    margin: 0 auto;
    background: var(--wap-container-bg);
    min-height: 100vh;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
}

/* Header */
.wap-header {
    background: linear-gradient(180deg, var(--wap-blue-top) 0%, var(--wap-blue-bottom) 100%);
    padding: 14px 12px 10px;
    text-align: center;
    border-bottom: 2px solid var(--wap-bar-border);
}

.wap-logo-wrap {
    margin-bottom: 10px;
}

.wap-logo-text {
    font-size: 28px;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.5px;
    text-shadow: 2px 2px 0px rgba(0, 50, 110, 0.8), 0 3px 6px rgba(0, 0, 0, 0.35);
    display: inline-block;
    font-family: "Impact", "Arial Black", var(--wap-font);
}

.wap-logo-img {
    max-height: 46px;
    max-width: 260px;
    object-fit: contain;
}

/* Top Action Navigation Pill Buttons */
.wap-nav-bar {
    display: flex;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 6px;
}

.wap-nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: #ffffff !important;
    font-size: 12px;
    font-weight: 700;
    font-family: inherit;
    border-radius: 4px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    transition: all 0.2s ease;
    text-decoration: none !important;
    cursor: pointer;
    line-height: normal;
}

.wap-nav-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: #ffffff;
    transform: translateY(-1px);
}

.wap-theme-toggle-btn {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.65);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.wap-theme-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.4);
}

/* Sub-header Ticker / Category Bar */
.wap-subnav-bar {
    background: var(--wap-container-bg);
    padding: 6px 10px;
    border-bottom: 1px solid var(--wap-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}

.wap-subnav-tag {
    color: var(--wap-muted);
    font-weight: 600;
    text-transform: lowercase;
}

.wap-dash-sep {
    padding: 3px 10px;
    font-size: 11px;
    color: var(--wap-muted);
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
    text-align: left;
}

.wap-updates-box {
    background: var(--wap-container-bg);
    padding: 4px 10px;
    font-size: 11px;
    color: var(--wap-muted);
    border-bottom: 1px solid var(--wap-border);
    min-height: 20px;
}

.wap-site-bottom-tag {
    padding: 4px 10px;
    font-size: 11px;
    color: var(--wap-muted);
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
    text-align: left;
}

.wap-theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    padding: 2px 6px;
    border-radius: 4px;
    color: var(--wap-muted);
}

/* Search Bar Box */
.wap-search-box {
    padding: 8px 10px;
    background: var(--wap-row-alt);
    border-bottom: 1px solid var(--wap-border);
}

.wap-search-form {
    display: flex;
    gap: 4px;
}

.wap-search-input {
    flex: 1;
    padding: 6px 10px;
    font-size: 13px;
    border: 1px solid var(--wap-border);
    background: var(--wap-container-bg);
    color: var(--wap-text);
    border-radius: 3px;
    outline: none;
}

.wap-search-input:focus {
    border-color: var(--wap-blue-link);
}

.wap-search-submit {
    padding: 6px 14px;
    background: linear-gradient(180deg, var(--wap-bar-start) 0%, var(--wap-bar-end) 100%);
    border: 1px solid var(--wap-bar-border);
    color: #ffffff;
    font-weight: 700;
    font-size: 12px;
    border-radius: 3px;
    cursor: pointer;
}

/* Ad Banner Spaces */
.wap-ad-container {
    padding: 8px 10px;
    text-align: center;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
}

.wap-ad-banner {
    display: inline-block;
    max-width: 100%;
    margin: 0 auto;
}

.wap-ad-placeholder {
    display: inline-block;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    font-weight: 700;
    padding: 10px 16px;
    border-radius: 4px;
    text-decoration: none !important;
    font-size: 13px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Marquee / Live Ticker */
.wap-ticker {
    background: #fff8e1;
    border-bottom: 1px solid #ffe082;
    padding: 5px 8px;
    font-size: 11px;
    color: #b78103;
    overflow: hidden;
    white-space: nowrap;
}

[data-theme="dark"] .wap-ticker {
    background: #242010;
    border-color: #483d16;
    color: #f6d365;
}

.wap-ticker-item {
    color: inherit;
    text-decoration: none !important;
    font-weight: 700;
    margin-right: 36px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: opacity 0.2s ease;
}

.wap-ticker-item:hover {
    opacity: 0.85;
}

.wap-ticker-badge {
    background: #ef4444;
    color: #ffffff !important;
    font-size: 9px;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.wap-ticker-title {
    color: inherit;
    font-weight: 700;
}

.wap-ticker-snippet {
    font-weight: 400;
    opacity: 0.88;
}

.wap-ticker-song {
    background: rgba(2, 132, 199, 0.12);
    border: 1px solid rgba(2, 132, 199, 0.3);
    color: #0284c7;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 3px;
    font-weight: 600;
}

[data-theme="dark"] .wap-ticker-song {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.3);
    color: #38bdf8;
}

.wap-ticker-cta {
    color: #0284c7;
    font-weight: 800;
    font-size: 10px;
    text-decoration: underline;
}

[data-theme="dark"] .wap-ticker-cta {
    color: #38bdf8;
}

/* Glossy Blue Section Header Strip */
.wap-section-bar {
    background: linear-gradient(180deg, var(--wap-bar-start) 0%, var(--wap-bar-mid) 50%, var(--wap-bar-end) 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.4);
    border-bottom: 1px solid var(--wap-bar-border);
    padding: 6px 12px;
    color: #ffffff;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.2px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.wap-section-bar.center {
    justify-content: center;
    text-align: center;
}

.wap-section-title {
    color: #ffffff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
}

/* Filter / Sort Sub-Bar */
.wap-filter-bar {
    background: var(--wap-container-bg);
    padding: 6px 12px;
    border-bottom: 1px solid var(--wap-border);
    font-size: 11px;
    text-align: center;
}

.wap-filter-bar a {
    color: var(--wap-blue-link);
    font-weight: 600;
    margin: 0 4px;
}

.wap-filter-bar a.active {
    color: var(--wap-red);
    font-weight: 700;
    text-decoration: underline;
}

.wap-filter-bar .sep {
    color: #94a3b8;
}

/* List Items - Categories / Folders */
.wap-cat-list {
    list-style: none;
}

.wap-cat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px solid var(--wap-border);
    background: var(--wap-container-bg);
    transition: background-color 0.15s ease;
}

.wap-cat-item:nth-child(even) {
    background: var(--wap-row-alt);
}

.wap-cat-item:hover {
    background: rgba(29, 161, 242, 0.08);
}

.wap-cat-link {
    color: var(--wap-red);
    font-weight: 700;
    font-size: 13px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wap-cat-link:hover {
    color: var(--wap-red-hover);
    text-decoration: underline;
}

.wap-cat-count {
    color: var(--wap-red);
    font-weight: 700;
    font-size: 12px;
}

.wap-chevron-btn,
.wap-cat-icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 24px;
    background: var(--wap-pill-bg);
    color: var(--wap-bar-mid);
    border: 1px solid var(--wap-pill-border);
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    text-decoration: none !important;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-left: 8px;
}

.wap-chevron-btn:hover,
.wap-cat-icon-badge:hover,
.wap-cat-item:hover .wap-cat-icon-badge {
    background: var(--wap-bar-mid);
    color: #ffffff;
    border-color: var(--wap-bar-border);
    transform: scale(1.05);
}

.wap-cat-lead-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--wap-bar-mid);
    margin-right: 6px;
    flex-shrink: 0;
}

/* Wapka Carousel Section */
.wap-carousel-container {
    position: relative;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
    overflow: hidden;
}

.wap-carousel-track {
    display: flex;
    transition: transform 0.4s ease-in-out;
    width: 100%;
}

.wap-carousel-slide {
    min-width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, rgba(29, 161, 242, 0.08) 0%, rgba(0, 119, 182, 0.03) 100%);
}

.wap-slide-thumb-wrap {
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid var(--wap-border);
    box-shadow: 0 3px 8px rgba(0,0,0,0.12);
    position: relative;
    background: #000;
}

.wap-slide-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wap-slide-content {
    flex: 1;
    min-width: 0;
}

.wap-slide-badge {
    display: inline-block;
    padding: 2px 7px;
    background: linear-gradient(180deg, var(--wap-bar-start) 0%, var(--wap-bar-end) 100%);
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.wap-slide-title {
    font-size: 13px;
    font-weight: 800;
    color: var(--wap-red);
    line-height: 1.35;
    margin-bottom: 4px;
    word-break: break-word;
}

.wap-slide-title a {
    color: inherit;
    text-decoration: none;
}

.wap-slide-title a:hover {
    color: var(--wap-red-hover);
    text-decoration: underline;
}

.wap-slide-desc {
    font-size: 11px;
    color: var(--wap-muted);
    margin-bottom: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wap-slide-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

.wap-slide-btn-play {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px;
    background: linear-gradient(180deg, var(--wap-bar-start) 0%, var(--wap-bar-end) 100%);
    color: #ffffff !important;
    font-size: 11px;
    font-weight: 700;
    border-radius: 3px;
    border: 1px solid var(--wap-bar-border);
    cursor: pointer;
    text-decoration: none !important;
}

.wap-slide-btn-dl {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px;
    background: var(--wap-pill-bg);
    color: var(--wap-pill-text) !important;
    font-size: 11px;
    font-weight: 700;
    border-radius: 3px;
    border: 1px solid var(--wap-pill-border);
    text-decoration: none !important;
}

.wap-carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 28px;
    background: rgba(0, 0, 0, 0.4);
    color: #ffffff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    z-index: 5;
    transition: all 0.2s;
    border-radius: 2px;
}

.wap-carousel-arrow:hover {
    background: var(--wap-bar-mid);
}

.wap-carousel-prev { left: 4px; }
.wap-carousel-next { right: 4px; }

.wap-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 5px;
    padding: 6px 0 8px;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
}

.wap-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--wap-pill-border);
    cursor: pointer;
    transition: all 0.2s;
}

.wap-dot.active {
    background: var(--wap-bar-mid);
    transform: scale(1.3);
}

/* List Items - Audio Files */
.wap-file-list {
    list-style: none;
}

.wap-file-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--wap-border);
    background: var(--wap-container-bg);
    transition: background-color 0.15s ease;
}

.wap-file-item:nth-child(even) {
    background: var(--wap-row-alt);
}

.wap-file-item:hover {
    background: rgba(29, 161, 242, 0.08);
}

.wap-file-thumb-wrap {
    position: relative;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    border-radius: 3px;
    overflow: hidden;
    border: 1px solid var(--wap-border);
    background: #000000;
}

.wap-file-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wap-file-play-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    cursor: pointer;
    color: #ffffff;
}

.wap-file-thumb-wrap:hover .wap-file-play-overlay,
.wap-file-item.playing .wap-file-play-overlay {
    opacity: 1;
}

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

.wap-file-title {
    color: var(--wap-red);
    font-weight: 700;
    font-size: 13px;
    line-height: 1.35;
    text-decoration: none;
    display: block;
    word-break: break-word;
}

.wap-file-title:hover {
    color: var(--wap-red-hover);
    text-decoration: underline;
}

.wap-file-meta {
    font-size: 11px;
    color: var(--wap-muted);
    margin-top: 2px;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.wap-file-size {
    font-weight: 700;
    color: var(--wap-text);
}

.wap-file-pill {
    background: var(--wap-pill-bg);
    color: var(--wap-pill-text);
    padding: 1px 5px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: 600;
}

/* Pagination Box */
.wap-pagination {
    padding: 10px 12px;
    text-align: center;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
    display: flex;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
}

.wap-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 24px;
    padding: 0 6px;
    background: var(--wap-container-bg);
    border: 1px solid var(--wap-border);
    color: var(--wap-blue-link);
    font-size: 11px;
    font-weight: 700;
    border-radius: 3px;
    text-decoration: none;
    transition: all 0.15s ease;
}

.wap-page-btn:hover {
    background: var(--wap-row-alt);
    border-color: var(--wap-blue-link);
}

.wap-page-btn.active {
    background: var(--wap-pill-bg);
    color: var(--wap-text);
    border-color: #94a3b8;
}

.wap-page-dots {
    display: inline-flex;
    align-items: center;
    color: var(--wap-muted);
    font-size: 11px;
    padding: 0 2px;
}

/* Related Tags Section */
.wap-tags-box {
    padding: 8px 12px;
    background: var(--wap-row-alt);
    border-bottom: 1px solid var(--wap-border);
    font-size: 11px;
    color: var(--wap-muted);
    line-height: 1.6;
}

.wap-tag-link {
    color: var(--wap-blue-link);
    text-decoration: none;
    margin-right: 4px;
}

.wap-tag-link:hover {
    color: var(--wap-red);
    text-decoration: underline;
}

/* Breadcrumbs (Bottom & Top) */
.wap-breadcrumb {
    padding: 8px 12px;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
    font-size: 11px;
    color: var(--wap-muted);
    line-height: 1.4;
}

.wap-breadcrumb a {
    color: var(--wap-red);
    font-weight: 700;
    text-decoration: none;
}

.wap-breadcrumb a:hover {
    text-decoration: underline;
}

.wap-breadcrumb .sep {
    margin: 0 4px;
    color: var(--wap-muted);
    font-weight: normal;
}

.wap-breadcrumb-tag {
    color: var(--wap-muted);
    font-weight: 600;
    margin-top: 3px;
}

/* Single Track & Download Page */
.wap-single-container {
    padding: 0;
}

.wap-single-hero {
    text-align: center;
    padding: 16px 12px 12px;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
}

.wap-single-artwork {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 4px;
    border: 2px solid var(--wap-border);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    margin: 0 auto 12px;
    display: block;
}

.wap-single-info-table {
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
    font-size: 12px;
    text-align: left;
    border-collapse: collapse;
}

.wap-single-info-table tr {
    border-bottom: 1px solid var(--wap-border);
}

.wap-single-info-table td {
    padding: 5px 8px;
}

.wap-single-info-table td.label {
    font-weight: 700;
    color: var(--wap-muted);
    width: 120px;
}

.wap-single-info-table td.value {
    color: var(--wap-text);
    font-weight: 600;
}

/* Wapka Theme Waveform Audio Player */
.wap-theme-player-card {
    max-width: 550px;
    margin: 14px auto 8px;
    background: var(--wap-row-alt);
    border: 1px solid var(--wap-border);
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    text-align: left;
}

.wap-player-top-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.wap-player-play-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(180deg, var(--wap-bar-start) 0%, var(--wap-bar-end) 100%);
    border: 1px solid var(--wap-bar-border);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 119, 182, 0.35);
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.wap-player-play-btn:hover {
    transform: scale(1.06);
    box-shadow: 0 4px 14px rgba(0, 119, 182, 0.5);
}

.wap-player-meta-wrap {
    flex: 1;
    min-width: 0;
}

.wap-player-track-name {
    font-size: 13px;
    font-weight: 800;
    color: var(--wap-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wap-player-artist-time {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: var(--wap-muted);
    margin-top: 3px;
    gap: 8px;
}

.wap-player-artist {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wap-player-timer {
    font-family: monospace;
    font-weight: 700;
    color: var(--wap-blue-link);
    flex-shrink: 0;
}

.wap-player-volume-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.wap-volume-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    padding: 2px;
}

.wap-volume-slider {
    width: 55px;
    height: 4px;
    accent-color: var(--wap-bar-mid);
    cursor: pointer;
}

/* Waveform Canvas & Scrubber */
.wap-waveform-container {
    position: relative;
    background: var(--wap-container-bg);
    border: 1px solid var(--wap-border);
    border-radius: 6px;
    padding: 6px 8px;
    cursor: pointer;
    height: 70px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

#wapWaveCanvas {
    width: 100%;
    height: 100%;
    display: block;
}

.wap-wave-hover-line {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(239, 68, 68, 0.7);
    pointer-events: none;
    display: none;
}

.wap-waveform-container:hover .wap-wave-hover-line {
    display: block;
}

.wap-player-bottom-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    font-size: 11px;
}

.wap-quality-badge {
    font-size: 10px;
    font-weight: 700;
    color: var(--wap-bar-mid);
    background: rgba(29, 161, 242, 0.1);
    padding: 2px 7px;
    border-radius: 3px;
}

/* HTML5 Audio Player fallback */
.wap-player-box {
    max-width: 550px;
    margin: 12px auto 6px;
    background: var(--wap-row-alt);
    border: 1px solid var(--wap-border);
    border-radius: 6px;
    padding: 10px;
    text-align: center;
}

.wap-audio-element {
    width: 100%;
    height: 38px;
    outline: none;
}
    outline: none;
}

/* Download Server Links */
.wap-download-box {
    padding: 12px;
    background: var(--wap-container-bg);
    text-align: center;
    border-bottom: 1px solid var(--wap-border);
}

.wap-dl-btn-server {
    display: block;
    margin: 8px auto;
    max-width: 480px;
    padding: 10px 16px;
    background: linear-gradient(180deg, #38bdf8 0%, #0284c7 100%);
    color: #ffffff !important;
    font-weight: 700;
    font-size: 14px;
    border-radius: 4px;
    text-decoration: none !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    border: 1px solid #0369a1;
    transition: all 0.2s ease;
}

.wap-dl-btn-server:hover {
    background: linear-gradient(180deg, #60a5fa 0%, #2563eb 100%);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

.wap-dl-btn-low {
    display: block;
    margin: 6px auto;
    max-width: 480px;
    padding: 8px 14px;
    background: linear-gradient(180deg, #e2e8f0 0%, #cbd5e1 100%);
    color: #1e293b !important;
    font-weight: 700;
    font-size: 12px;
    border-radius: 4px;
    text-decoration: none !important;
    border: 1px solid #94a3b8;
}

.wap-dl-btn-low:hover {
    background: #e2e8f0;
}

[data-theme="dark"] .wap-dl-btn-low {
    background: linear-gradient(180deg, #334155 0%, #1e293b 100%);
    color: #f1f5f9 !important;
    border-color: #475569;
}

.wap-problem-notice {
    font-size: 11px;
    color: var(--wap-muted);
    margin-top: 10px;
}

.wap-problem-notice a {
    color: var(--wap-red);
    font-weight: 700;
}

/* Share This File Box */
.wap-share-box {
    padding: 12px;
    background: var(--wap-row-alt);
    border-bottom: 1px solid var(--wap-border);
    text-align: center;
}

.wap-share-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--wap-text);
    margin-bottom: 6px;
    text-align: left;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.wap-share-textarea {
    width: 100%;
    max-width: 480px;
    height: 60px;
    font-size: 11px;
    padding: 6px 8px;
    border: 1px solid var(--wap-border);
    border-radius: 3px;
    background: var(--wap-container-bg);
    color: var(--wap-text);
    font-family: monospace;
    resize: none;
    outline: none;
}

.wap-copy-btn {
    display: block;
    margin: 6px auto 0;
    max-width: 480px;
    padding: 6px 14px;
    background: var(--wap-pill-bg);
    border: 1px solid var(--wap-pill-border);
    color: var(--wap-pill-text);
    font-size: 12px;
    font-weight: 700;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wap-copy-btn:hover {
    background: var(--wap-bar-mid);
    color: #ffffff;
}

/* Countdown Intermission Box */
.wap-countdown-box {
    text-align: center;
    padding: 24px 16px;
    background: var(--wap-container-bg);
    border-bottom: 1px solid var(--wap-border);
}

.wap-countdown-number {
    font-size: 42px;
    font-weight: 900;
    color: var(--wap-red);
    margin: 8px 0;
}

.wap-countdown-sub {
    font-size: 13px;
    color: var(--wap-muted);
}

/* Floating Mini Audio Bar across page navigation */
.wap-mini-dock {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #0f172a;
    color: #ffffff;
    border-top: 2px solid var(--wap-bar-mid);
    padding: 8px 12px;
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    z-index: 99999;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.4);
}

.wap-mini-dock.active {
    display: flex;
}

.wap-dock-thumb {
    width: 36px;
    height: 36px;
    border-radius: 3px;
    object-fit: cover;
}

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

.wap-dock-title {
    font-size: 12px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wap-dock-artist {
    font-size: 10px;
    color: #94a3b8;
}

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

.wap-dock-btn {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
}

/* Footer */
.wap-footer {
    background: linear-gradient(180deg, var(--wap-blue-top) 0%, var(--wap-blue-bottom) 100%);
    color: #ffffff;
    text-align: center;
    padding: 12px 10px;
    font-size: 12px;
    border-top: 2px solid var(--wap-bar-border);
    margin-top: auto;
}

.wap-footer a {
    color: #ffffff;
    text-decoration: underline;
}

.wap-footer-links {
    margin-bottom: 6px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 11px;
}

.wap-footer-copy {
    font-weight: 700;
    letter-spacing: 0.3px;
}

.wap-footer-version {
    font-size: 10px;
    opacity: 0.85;
    margin-top: 2px;
}

/* Media Queries for Mobile Responsiveness */
@media (max-width: 640px) {
    .wap-logo-text {
        font-size: 24px;
    }
    .wap-nav-btn {
        padding: 5px 10px;
        font-size: 11px;
    }
    .wap-file-title {
        font-size: 12px;
    }
    .wap-cat-link {
        font-size: 12px;
    }
}
