/* Import the same base variables as home page */
@import url('home-style.css');

/* Import custom fonts */
@font-face {
  font-family: 'Hafs';
  src: url('./ramzan/Assets/fonts/hafs.otf') format('opentype');
  font-display: swap;
}

@font-face {
  font-family: 'Jameel-Noori';
  src: url('./ramzan/Assets/fonts/Jameel-Noori.ttf') format('truetype');
  font-display: swap;
}
/* Specific styles for Quran Audio page */
.main-content {
    margin-top: 80px;
    min-height: calc(100vh - 80px);
    padding: 2rem 0;
}

.page-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: var(--border-radius-large);
    margin-bottom: 3rem;
}
.logo {
  display: flex;
  align-items: center;
}
.page-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-family: var(--font-arabic);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Audio Player Styles */
.audio-player-section {
    margin-bottom: 4rem;
}

.current-player {
    background: var(--white);
    border-radius: var(--border-radius-large);
    padding: 2rem;
    box-shadow: var(--shadow-heavy);
    border: 1px solid rgba(12, 123, 75, 0.1);
    position: relative;
    overflow: hidden;
}

.current-player::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
}

.player-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.para-info h2 {
    font-family: var(--font-arabic);
    color: var(--primary-color);
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.para-info p {
    color: var(--gray);
    font-size: 1rem;
}

.player-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.control-btn {
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-medium);
    font-size: 1.2rem;
    position: relative;
    overflow: hidden;
}

.control-btn:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-medium);
}

.play-pause-btn {
    width: 60px;
    height: 60px;
    font-size: 1.4rem;
    background: var(--gradient-secondary);
    color: var(--dark);
}

.control-btn:active {
    transform: scale(0.95);
}

.progress-section {
    margin-bottom: 1.5rem;
}

.time-display {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-family: 'Courier New', monospace;
    color: var(--gray);
    font-size: 0.9rem;
}

.progress-bar {
    position: relative;
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    cursor: pointer;
    margin-bottom: 1rem;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
}

.progress-handle {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    left: 0%;
    cursor: pointer;
    opacity: 0;
    transition: var(--transition-fast);
    box-shadow: var(--shadow-light);
}

.progress-bar:hover .progress-handle {
    opacity: 1;
}


.additional-controls {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: space-between;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--gray);
}

.volume-slider {
    width: 100px;
    height: 4px;
    border-radius: 2px;
    background: #e0e0e0;
    outline: none;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.speed-control select {
    padding: 0.5rem;
    border-radius: var(--border-radius);
    border: 1px solid #e0e0e0;
    background: var(--white);
    color: var(--dark);
    cursor: pointer;
    font-family: inherit;
}

.control-btn.active {
    background: var(--gradient-secondary);
    color: var(--dark);
}

/* Para List Styles */
.para-list-section {
    margin-bottom: 4rem;
}

.section-title {
    font-size: 2rem;
    font-family: var(--font-arabic);
    color: var(--primary-color);
    margin-bottom: 2rem;
    text-align: center;
}

.para-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.para-item {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition-medium);
    text-align: center;
    box-shadow: var(--shadow-light);
    position: relative;
    overflow: hidden;
}

.para-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-color);
}

.para-item.active {
    border-color: var(--secondary-color);
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.1), rgba(230, 200, 90, 0.1));
}

.para-item.playing {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(12, 123, 75, 0.1), rgba(16, 164, 99, 0.1));
}

.para-item.playing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    animation: playing-indicator 2s ease-in-out infinite;
}

@keyframes playing-indicator {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.para-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    font-family: var(--font-arabic);
    margin-bottom: 0.5rem;
}

.para-title {
    font-size: 1.1rem;
    color: var(--dark);
    margin-bottom: 0.5rem;
    font-family: var(--font-arabic);
}

.para-subtitle {
    font-size: 0.9rem;
    color: var(--gray);
    line-height: 1.4;
}

.para-duration {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    background: rgba(12, 123, 75, 0.1);
    color: var(--primary-color);
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Recent Section */
.recent-section {
    margin-bottom: 2rem;
}

.recent-list {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 1rem;
}

.recent-item {
    min-width: 200px;
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 1rem;
    box-shadow: var(--shadow-light);
    cursor: pointer;
    transition: var(--transition-medium);
    border: 1px solid #e0e0e0;
}

.recent-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-medium);
}

.recent-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.recent-item p {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.recent-progress {
    width: 100%;
    height: 3px;
    background: #e0e0e0;
    border-radius: 2px;
    overflow: hidden;
}

.recent-progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

/* Loading Indicator */
.loading-indicator {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-heavy);
    text-align: center;
    z-index: 10000;
    display: none;
}

.loading-indicator.show {
    display: block;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e0e0e0;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .main-content {
        margin-top: 70px;
        padding: 1rem 0;
    }
    
    .current-player {
        padding: 1.5rem;
    }
    
    .player-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .player-controls {
        align-self: center;
    }
    
    .additional-controls {
        flex-direction: row;
        gap: 1rem;
        align-items: stretch;
    }
    
    .volume-control {
        justify-content: center;
    }
    
    .para-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }
    
    .para-item {
        padding: 1rem;
    }
    
    .recent-list {
        gap: 0.5rem;
    }
    
    .recent-item {
        min-width: 150px;
        padding: 0.8rem;
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 1.5rem 1rem;
        margin: 1rem;
        border-radius: var(--border-radius);
    }
    .section-title {
    font-size: 2rem;
    font-family: var(--font-arabic);
    color: var(--primary-color);
    margin-bottom: 2rem;
    text-align: center;
}
    .current-player {
        margin: 0 1rem;
        padding: 1rem;
    }
    
    .control-btn {
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }
    
    .play-pause-btn {
        width: 55px;
        height: 55px;
        font-size: 1.2rem;
    }
    
    .para-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.8rem;
        margin: 0 1rem;
    }
    
    .para-item {
        padding: 0.8rem;
    }
    
    .para-number {
        font-size: 1.5rem;
    }
    
    .para-title {
        font-size: 1rem;
    }
    
    .volume-slider {
        width: 80px;
    }
}

/* Audio element hidden */
.audio-element {
    display: none;
}

/* Custom scrollbar for recent list */
.recent-list::-webkit-scrollbar {
    height: 6px;
}

.recent-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.recent-list::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

.recent-list::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}
