/**
 * eLfilms.cz - Responzivní styly pro stránku Prohlížet
 *
 * @package    eLfilms
 * @subpackage Frontend
 * @file       css/prohlizet-responsive.css
 * @version    4.0 - Perfect Edition
 * @datum      Leden 2026
 * @author     eLfilms Team
 * @copyright  2009-2026 eLfilms.cz
 *
 * Responzivní CSS pro stránku prohlížení filmů a seriálů.
 *
 * STYLUJE:
 * - Hero sekce na mobilech
 * - Burger menu (slide-in sidebar)
 * - Layout přepnutí z 2 sloupců na 1
 * - Grid 4 → Grid 2 na mobilech
 * - List view optimalizovaný pro mobil
 *
 * POUŽÍVÁ:
 * - prohlizet.php (parent stránka)
 *
 * DESIGN:
 * - Barvy: tmavě modrá (#0d1b2a, #0b334f–#1a4f72), zlatá (#EEB500)
 * - Max šířka obsahu: 1200px
 *
 * NOTE:
 * - Mobilní breakpoint: max-width: 767px (iPad Mini 768px dostane tablet layout)
 * - Hlavní styly jsou v prohlizet.css
 */

/* ============================================
   HERO – MOBILE (do 767px)
   ============================================ */
@media (max-width: 767px) {
    .hero-section {
        height: auto;
        padding: 100px 20px 30px;
        margin-bottom: 0;
    }

    .hero-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .hero-left {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .hero-right {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 6px;
        text-align: center;
        padding-right: 0;
        margin-bottom: 0;
    }

    .hero-logo {
        max-width: 200px;
        top: 0;
    }

    .hero-subtitle {
        font-size: 16px;
        top: 0;
    }

    .hero-description {
        font-size: 15px;
    }

    .hero-highlight {
        font-size: 14px;
        margin-bottom: 0;
    }
}

/* ============================================
   RESET FILTRŮ – NORMALIZACE (do 767px)
   ============================================ */
@media (max-width: 767px) {
    .reset-filters-btn {
        width: 100%;
        padding: 12px 20px;
        font-size: 13px;
        margin-top: 20px;
    }
}

/* ============================================
   VELMI MALÉ MOBILY (do 359px)
   ============================================ */
@media (max-width: 359px) {
    .page-container {
        padding: 20px 12px 40px;
    }

    .content-header h1 {
        font-size: 20px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px;
    }

    .item-title {
        font-size: 13px;
    }

    .view-list .item-poster {
        width: 100px;
        min-width: 100px;
    }

    .view-list .item-title {
        font-size: 16px;
    }
}

/* ============================================
   MALÉ MOBILY (360px - 479px)
   ============================================ */
@media (min-width: 360px) and (max-width: 479px) {
    .page-container {
        padding: 20px 15px 40px;
    }

    .content-header h1 {
        font-size: 22px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
    }

    .item-title {
        font-size: 14px;
    }

    .view-list .item-poster {
        width: 110px;
        min-width: 110px;
    }

    .view-list .item-title {
        font-size: 17px;
    }
}

/* ============================================
   MOBILY (480px - 767px)
   ============================================ */
@media (min-width: 480px) and (max-width: 767px) {
    .page-container {
        padding: 20px 15px 40px;
    }

    .content-header h1 {
        font-size: 24px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 18px;
    }

    .item-title {
        font-size: 15px;
    }

    .view-list .item-poster {
        width: 120px;
        min-width: 120px;
    }

    .view-list .item-title {
        font-size: 18px;
    }
}

/* ============================================
   VŠECHNY MOBILY (do 767px) – SPOLEČNÉ
   ============================================ */
@media (max-width: 767px) {
    .page-container {
        grid-template-columns: 1fr;
        gap: 0;
        min-height: auto;
        padding: 20px 15px 40px;
    }

    .sidebar {
        position: static;
        padding-right: 0;
    }

    .filter-section:first-child {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 15px;
        margin-bottom: 20px;
    }

    .filter-section:first-child .filter-title {
        display: none;
    }

    .type-toggle {
        flex: 1;
        max-width: 200px;
    }

    .type-toggle button {
        padding: 10px 15px;
        font-size: 13px;
    }

    .filters-burger {
        display: flex !important;
        width: 50px;
        height: 50px;
        background: #EEB500;
        border: none;
        border-radius: 10px;
        cursor: pointer;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        transition: all 0.3s;
        flex-shrink: 0;
    }

    .filters-burger span {
        width: 24px;
        height: 3px;
        background: #0b334f;
        border-radius: 2px;
        transition: all 0.3s;
    }

    .sidebar.filters-hidden .filter-section:not(:first-child) {
        display: none;
    }

    .sidebar.filters-open {
        position: fixed;
        top: 0;
        left: 0;
        width: 85%;
        max-width: 350px;
        height: 100vh;
        background: #0b334f;
        z-index: 1000;
        padding: 20px;
        overflow-y: auto;
        box-shadow: 4px 0 20px rgba(0,0,0,0.5);
        animation: slideIn 0.3s ease-out;
    }

    @keyframes slideIn {
        from { transform: translateX(-100%); }
        to   { transform: translateX(0); }
    }

    .filters-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.6);
        z-index: 999;
    }

    .filters-overlay.active {
        display: block;
    }

    .content-header {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 20px;
        margin-top: 30px;
        gap: 15px;
    }

    .content-tools {
        width: 100%;
        justify-content: space-between;
        gap: 10px;
    }

    .sort-container {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-shrink: 1;
        min-width: 0;
    }

    .sort-label {
        flex-shrink: 0;
        font-size: 12px;
    }

    .sort-select {
        font-size: 12px;
        padding: 6px 4px;
    }

    .view-toggle {
        flex-shrink: 0;
        padding: 3px;
        gap: 4px;
    }

    .view-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .items-grid {
        gap: 20px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .item-card {
        transition: transform 0.2s ease;
    }

    .item-card:hover {
        transform: translateY(-4px);
    }

    .item-poster {
        margin-bottom: 8px;
        border-radius: 8px;
    }

    .item-title {
        font-size: 14px;
        margin-bottom: 3px;
    }

    .view-list .item-card {
        flex-direction: column;
        gap: 15px;
        padding-bottom: 20px;
        padding-top: 20px;
    }

    .view-list .item-poster {
        width: 100%;
        max-width: 180px;
    }

    .view-list .item-title {
        font-size: 18px;
    }

    .view-list .item-description {
        font-size: 13px;
        line-height: 1.5;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .pagination {
        margin-top: 30px;
        padding-top: 25px;
        gap: 5px;
        flex-wrap: wrap;
    }

    .pagination a,
    .pagination span {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }
}

/* ============================================
   TABLET PORTRAIT (768px - 991px)
   ============================================ */
@media (min-width: 768px) and (max-width: 991px) {
    .page-container {
        padding: 30px 20px 40px;
        grid-template-columns: 220px 1fr;
        gap: 30px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 15px;
    }
}

/* ============================================
   TABLET LANDSCAPE (992px - 1199px)
   ============================================ */
@media (min-width: 992px) and (max-width: 1199px) {
    .page-container {
        padding: 40px 40px 60px;
        grid-template-columns: 260px 1fr;
        gap: 35px;
    }

    .items-grid.view-grid-4 {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }
}

/* ============================================
   DESKTOP (1200px+)
   ============================================ */
@media (min-width: 1200px) {
    .page-container {
        max-width: 1200px;
    }

    .items-grid.view-grid-4 {
        gap: 28px;
    }
}