/* ============================================
   PODCAST PAGE MOBILE OPTIMIZATION
   ============================================ */

@media (max-width: 768px) {

/* ============================================
   HERO SECTION - MOBILE
   ============================================ */

.hero {
    min-height: 50vh !important;
    padding: 2rem 0 !important;
}

.hero-content {
    padding: 0 1rem !important;
    position: relative !important;
    top: 100px !important;
}

.hero .display-4 {
    font-size: 2rem !important;
    margin-bottom: 0.75rem !important;
}

.hero .lead {
    font-size: 1rem !important;
    margin-bottom: 1.5rem !important;
}

/* Admin Button - Top Right */
.admin-controls {
    position: absolute !important;
    top: 1rem !important;
    right: 1rem !important;
    left: auto !important;
    margin: 0 !important;
}

.admin-controls .btn {
    padding: 0.5rem 1rem !important;
    font-size: 0.8rem !important;
    border-radius: 20px !important;
}

/* Hero Stats - Icons Only */
.hero-stats {
    flex-direction: column !important;
    gap: 0.75rem !important;
    margin-top: 1rem !important;
}

.hero-stats span {
    font-size: 0.8rem !important;
    justify-content: center !important;
}

.hero-stats i {
    font-size: 1rem !important;
}

/* ============================================
   CONTROLS SECTION - MOBILE
   ============================================ */

.controls {
    padding: 1rem 0 !important;
}

.controls .container {
    flex-direction: column !important;
    gap: 1rem !important;
    padding: 0 1rem !important;
}

.search-box {
    max-width: none !important;
    width: 100% !important;
}

#searchInput {
    padding: 1rem 1rem 1rem 2.5rem !important;
    font-size: 1rem !important;
    min-height: 50px !important;
}

.sort-select {
    width: 100% !important;
    padding: 1rem 1.5rem !important;
    font-size: 1rem !important;
    min-height: 50px !important;
}

/* ============================================
   EPISODES SECTION - MOBILE
   ============================================ */

.episodes {
    padding: 1.5rem 0 !important;
}

.episodes-header {
    flex-direction: column !important;
    gap: 1rem !important;
    align-items: flex-start !important;
    margin-bottom: 1.5rem !important;
    padding: 0 1rem !important;
}

.episodes h2 {
    font-size: 1.5rem !important;
}

/* Carousel Navigation - Hidden on Mobile */
.carousel-nav {
    display: none !important;
}

/* Episode Cards - Mobile Optimized */
.episodes-carousel {
    padding: 0 1rem !important;
}

#episodesContainer {
    gap: 0.75rem !important;
    padding: 0.5rem 0 !important;
}

.episode-card {
    flex: 0 0 200px !important;
    min-width: 200px !important;
    max-width: 200px !important;
    width: 200px !important;
    height: 240px !important;
    min-height: 240px !important;
    max-height: 240px !important;
}

/* Episode Image */
.episode-image {
    height: 120px !important;
}

.episode-image img {
    height: 85px !important;
}

.episode-titleNumber {
    font-size: 0.8rem !important;
    padding: 3px 8px !important;
}

/* Episode Content - Compact */
.episode-content {
    padding: 0.6rem !important;
}

.episode-title {
    font-size: 0.8rem !important;
    height: 1.8rem !important;
    -webkit-line-clamp: 2 !important;
    line-clamp: 2 !important;
    line-height: 1.1 !important;
}

/* Episode Description - Hidden by Default */
.episode-description {
    display: none !important;
}

.episode-meta {
    font-size: 0.55rem !important;
    margin-bottom: 0.4rem !important;
}

/* Episode Actions - Always Visible */
.episode-actions {
    opacity: 1 !important;
    bottom: 6px !important;
    right: 6px !important;
}

.play-btn {
    width: 36px !important;
    height: 36px !important;
}

.favorite-btn,
.share-btn {
    width: 28px !important;
    height: 28px !important;
    opacity: 1 !important;
}

.favorite-btn i,
.share-btn i {
    font-size: 0.7rem !important;
}

/* ============================================
   AUDIO PLAYER - MOBILE
   ============================================ */

.audio-player {
    padding-bottom: env(safe-area-inset-bottom) !important;
}

.player-container {
    flex-direction: column !important;
    padding: 0.75rem 1rem !important;
    gap: 0.5rem !important;
}

.now-playing {
    flex: none !important;
    width: 100% !important;
    justify-content: flex-start !important;
    gap: 1rem !important;
    position: relative !important;
    flex-direction: row !important;
}

.track-info {
    flex: 1 !important;
    text-align: left !important;
}

.track-info h4 {
    font-size: 0.9rem !important;
    margin-bottom: 0.1rem !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.track-info p {
    display: none !important;
}

.player-controls {
    width: auto !important;
    justify-content: flex-end !important;
    gap: 1rem !important;
}

.progress-section {
    display: none !important;
}

.volume-toggle {
    display: none !important;
}

.volume-controls {
    display: none !important;
}

/* Expanded State */
.player-container.expanded {
    padding: 1rem !important;
    gap: 1rem !important;
}

.player-container.expanded .now-playing {
    justify-content: center !important;
}

.player-container.expanded .track-info {
    text-align: center !important;
}

.player-container.expanded .track-info h4 {
    font-size: 1rem !important;
    margin-bottom: 0.25rem !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
}

.player-container.expanded .track-info p {
    display: block !important;
}

.player-container.expanded .player-controls {
    width: 100% !important;
    justify-content: center !important;
    gap: 1.5rem !important;
}

.player-container.expanded .progress-section {
    display: flex !important;
    width: 100% !important;
    flex-direction: column !important;
    gap: 0.75rem !important;
}

.player-container.expanded .volume-toggle {
    display: flex !important;
}

/* Expand/Collapse Button */
.player-expand-btn {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    width: 32px !important;
    height: 32px !important;
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    z-index: 10 !important;
}

.player-expand-btn:hover {
    background: var(--primary-green) !important;
    color: white !important;
    transform: scale(1.1) !important;
}

.player-expand-btn i {
    font-size: 0.8rem !important;
    transition: transform 0.3s ease !important;
}

.player-container.expanded .player-expand-btn i {
    transform: rotate(180deg) !important;
}

#currentTrackImage {
    width: 60px !important;
    height: 60px !important;
}

.track-info {
    flex: 1 !important;
    text-align: center !important;
}

.track-info h4 {
    font-size: 1rem !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
}

.track-info p {
    font-size: 0.9rem !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
}

.player-controls {
    width: 100% !important;
    justify-content: center !important;
    gap: 1.5rem !important;
}

.control-btn {
    padding: 1rem !important;
    min-width: 50px !important;
    min-height: 50px !important;
}

.play-pause-btn {
    width: 60px !important;
    height: 60px !important;
    font-size: 1.5rem !important;
}

.progress-section {
    width: 100% !important;
    flex-direction: column !important;
    gap: 0.75rem !important;
}

.time-current,
.time-duration {
    font-size: 0.8rem !important;
    min-width: auto !important;
}

.progress-container {
    width: 100% !important;
    height: 8px !important;
}

.progress-bar {
    height: 8px !important;
}

/* Volume Controls - Hidden by Default */
.volume-controls {
    display: none !important;
}

/* Volume Toggle Button */
.volume-toggle {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 50px !important;
    height: 50px !important;
    background: none !important;
    border: none !important;
    color: var(--text-primary) !important;
    cursor: pointer !important;
    border-radius: 50% !important;
    transition: all var(--animation-normal) !important;
}

.volume-toggle:hover {
    color: var(--primary-green) !important;
    background: var(--light-green) !important;
}

.volume-toggle i {
    font-size: 1.2rem !important;
}

/* Volume Controls - Show when toggled */
.volume-controls.show {
    display: flex !important;
    width: 100% !important;
    justify-content: center !important;
    gap: 1rem !important;
    padding: 0.5rem 0 !important;
}

.volume-slider {
    width: 120px !important;
    height: 8px !important;
}

/* ============================================
   SUBSCRIBE SECTION - MOBILE
   ============================================ */

.subscribe-section {
    padding: 2rem 0 !important;
}

.subscribe-section h3 {
    font-size: 1.2rem !important;
    margin-bottom: 1.5rem !important;
    padding: 0 1rem !important;
}

.subscribe-section .container {
    padding: 0 1rem !important;
}

/* ============================================
   UPLOAD MODAL - MOBILE
   ============================================ */

.modal-dialog {
    margin: 0 !important;
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
}

.modal-content {
    border-radius: 0 !important;
    height: 100% !important;
    max-height: 100vh !important;
}

.modal-body {
    padding: 1.5rem !important;
}

.modal-body .form-control {
    padding: 1rem !important;
    font-size: 1rem !important;
    min-height: 50px !important;
}

.modal-body .form-label {
    font-size: 1rem !important;
    font-weight: 600 !important;
    margin-bottom: 0.5rem !important;
}

.modal-footer {
    padding: 1rem 1.5rem !important;
}

.modal-footer .btn {
    padding: 1rem 1.5rem !important;
    font-size: 1rem !important;
    min-height: 50px !important;
}

/* ============================================
   TABLET OPTIMIZATION (481px - 768px)
   ============================================ */

@media (min-width: 481px) and (max-width: 768px) {
    .episode-card {
        flex: 0 0 calc(50vw - 2rem) !important;
        min-width: calc(50vw - 2rem) !important;
        max-width: calc(50vw - 2rem) !important;
        width: calc(50vw - 2rem) !important;
    }
}

/* ============================================
   SMALL MOBILE (320px - 480px)
   ============================================ */

@media (max-width: 480px) {
    .hero .display-4 {
        font-size: 1.75rem !important;
    }
    
    .hero .lead {
        font-size: 0.9rem !important;
    }
    
    .episode-card {
        height: 260px !important;
        min-height: 260px !important;
        max-height: 260px !important;
    }
    
    .episode-image {
        height: 120px !important;
    }
    
    .episode-image img {
        height: 85px !important;
    }
}

} /* End @media (max-width: 768px) */
