/* ===== CSS RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Light Theme Colors (from image) */
    --bg-primary: #f5f7fa;
    --bg-secondary: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #666666;
    --accent-primary: #4a6bff;
    --accent-secondary: #ff6b6b;
    --card-bg: #ffffff;
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    --nav-bg: #ffffff;
    --modal-bg: #ffffff;
    --rating-badge: linear-gradient(135deg, #4a6bff 0%, #6a11cb 100%);
    --hover-glow: 0 8px 25px rgba(74, 107, 255, 0.2);
    --section-header: #4a6bff;
    --border-color: #e1e5e9;
    
    /* Animation Speeds */
    --transition-speed: 0.3s;
    --transition-slow: 0.5s;
}

[data-theme="dark"] {
    /* Dark Theme Colors */
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --accent-primary: #00ff9d;
    --accent-secondary: #ff2e63;
    --card-bg: #1a1a1a;
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    --nav-bg: #1a1a1a;
    --modal-bg: #1a1a1a;
    --rating-badge: linear-gradient(135deg, #00ff9d 0%, #00b4d8 100%);
    --hover-glow: 0 8px 25px rgba(0, 255, 157, 0.3);
    --section-header: #00ff9d;
    --border-color: #333333;
}

/* ===== BASE STYLES ===== */
body {
    font-family: 'Segoe UI', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    padding-bottom: 70px; /* Space for bottom nav */
    transition: background var(--transition-slow) ease,
                color var(--transition-speed) ease;
    overflow-x: hidden;
}

/* ===== TOP NAVIGATION ===== */
.top-nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--nav-bg);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: all var(--transition-speed) ease;
}

[data-theme="dark"] .top-nav {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.75rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
}

.logo-icon {
    font-size: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 12px;
    color: white;
}

.logo-text h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.logo-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.top-nav-right {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.theme-toggle, .search-toggle {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 1.1rem;
    transition: all var(--transition-speed) ease;
}

.theme-toggle:hover, .search-toggle:hover {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

/* ===== MAIN CONTENT ===== */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

.page {
    display: none;
    animation: fadeIn 0.4s ease;
}

.page.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.page-header {
    margin-bottom: 2rem;
    padding: 0 0.5rem;
}

.page-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.page-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ===== LOADER ===== */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    gap: 1rem;
}

.loader {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* ===== SLIDER SECTIONS ===== */
.slider-section {
    margin-bottom: 3rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding: 0 0.5rem;
}

.section-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-header h3::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 20px;
    background: var(--accent-primary);
    border-radius: 2px;
}

.slider-container {
    position: relative;
    overflow: hidden;
}

.slider {
    display: flex;
    gap: 1rem;
    padding: 0.5rem 0.5rem 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.slider::-webkit-scrollbar {
    display: none;
}

/* ===== CARDS ===== */
.card {
    flex: 0 0 auto;
    width: 140px;
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: all var(--transition-speed) ease;
    cursor: pointer;
    position: relative;
    border: 1px solid var(--border-color);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--hover-glow);
}

.card-image {
    width: 100%;
    height: 210px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    position: relative;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow) ease;
}

.card:hover .card-image img {
    transform: scale(1.08);
}

.card-rating {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--rating-badge);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.card-content {
    padding: 0.75rem;
}

.card-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-primary);
}

.card-year {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

@media (min-width: 768px) {
    .card {
        width: 160px;
    }
    
    .card-image {
        height: 240px;
    }
}

/* ===== SEARCH PAGE ===== */
.search-container {
    max-width: 800px;
    margin: 0 auto;
}

.search-input-wrapper {
    position: relative;
    margin-bottom: 2rem;
}

.search-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
}

#searchInput {
    width: 100%;
    padding: 1rem 3rem 1rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-speed) ease;
}

#searchInput:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(74, 107, 255, 0.1);
}

[data-theme="dark"] #searchInput:focus {
    box-shadow: 0 0 0 3px rgba(0, 255, 157, 0.1);
}

.clear-btn {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all var(--transition-speed) ease;
    display: none;
}

.clear-btn:hover {
    background: rgba(74, 107, 255, 0.1);
    color: var(--accent-primary);
}

.search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1.25rem;
    padding: 1rem 0;
}

.search-placeholder {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
}

.search-placeholder i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

/* ===== WATCHLIST PAGE ===== */
.watchlist-container {
    padding: 1rem 0.5rem;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: var(--accent-primary);
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.watchlist-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1.25rem;
}

.watchlist-card {
    position: relative;
}

.remove-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: #ff4757;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-speed) ease;
    z-index: 2;
    font-size: 0.9rem;
}

[data-theme="dark"] .remove-btn {
    background: rgba(255, 255, 255, 0.1);
    color: #ff6b6b;
}

.remove-btn:hover {
    background: #ff4757;
    color: white;
    transform: scale(1.1);
}

/* ===== DETAILS MODAL ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    z-index: 2000;
    animation: fadeIn var(--transition-speed) ease;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background: var(--modal-bg);
    border-radius: 16px;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid var(--border-color);
    width: 100%;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all var(--transition-speed) ease;
    backdrop-filter: blur(5px);
}

.modal-close:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: rotate(90deg);
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2rem;
}

@media (min-width: 768px) {
    .modal-body {
        grid-template-columns: 300px 1fr;
    }
}

.modal-poster {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.modal-poster img {
    width: 100%;
    height: auto;
    display: block;
}

.modal-info {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.modal-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
    line-height: 1.2;
}

.modal-year {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
}

.modal-rating {
    background: var(--rating-badge);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    font-size: 0.95rem;
}

.modal-overview h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.modal-overview p {
    line-height: 1.6;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.modal-details {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.detail-item i {
    color: var(--accent-primary);
}

.genres h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.genres-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.genre {
    background: var(--accent-primary);
    color: white;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.trailer h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.modal-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.watchlist-btn {
    background: var(--accent-primary);
    border: none;
    padding: 0.85rem 1.5rem;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all var(--transition-speed) ease;
    font-size: 0.95rem;
}

.watchlist-btn:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: var(--hover-glow);
}

.watchlist-btn.in-watchlist {
    background: #00b894;
}

/* ===== BOTTOM NAVIGATION ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    border-top: 1px solid var(--border-color);
    z-index: 1000;
    transition: all var(--transition-speed) ease;
}

.bottom-nav .nav-container {
    display: flex;
    justify-content: space-around;
    padding: 0;
}

.nav-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 0.75rem 0.5rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    transition: all var(--transition-speed) ease;
    flex: 1;
    max-width: 100px;
    position: relative;
}

.nav-btn i {
    font-size: 1.25rem;
    transition: all var(--transition-speed) ease;
}

.nav-btn span {
    font-size: 0.75rem;
    font-weight: 500;
    transition: all var(--transition-speed) ease;
}

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

.nav-btn.active::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 3px;
    background: var(--accent-primary);
    border-radius: 0 0 3px 3px;
}

.nav-btn:hover:not(.active) {
    color: var(--accent-primary);
}

/* ===== SEARCH OVERLAY ===== */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-primary);
    z-index: 3000;
    display: none;
    opacity: 0;
    transition: opacity var(--transition-speed) ease;
}

.search-overlay.active {
    display: block;
    opacity: 1;
    animation: fadeIn var(--transition-speed) ease;
}

.search-overlay-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 1rem;
}

.search-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.search-overlay-header h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
}

.close-search-overlay {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all var(--transition-speed) ease;
}

.close-search-overlay:hover {
    background: var(--border-color);
    color: var(--text-primary);
}

.search-overlay-input {
    position: relative;
    margin-bottom: 1rem;
}

.search-overlay-input i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

#mobileSearchInput {
    width: 100%;
    padding: 1rem 1rem 1rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
}

#mobileSearchInput:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.mobile-search-results {
    flex: 1;
    overflow-y: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
    padding: 1rem 0;
}

/* ===== UTILITY CLASSES ===== */
.fallback-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Dark mode skeleton */
[data-theme="dark"] .skeleton {
    background: linear-gradient(90deg, #2a2a2a 25%, #333333 50%, #2a2a2a 75%);
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */
@media (max-width: 480px) {
    .nav-container {
        padding: 0.5rem 0.75rem;
    }
    
    .logo-icon {
        width: 42px;
        height: 42px;
        font-size: 1.75rem;
    }
    
    .logo-text h1 {
        font-size: 1.25rem;
    }
    
    .logo-subtitle {
        font-size: 0.7rem;
    }
    
    .theme-toggle, .search-toggle {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    
    .modal-content {
        padding: 0.5rem;
    }
    
    .modal-body {
        padding: 1rem;
        gap: 1.5rem;
    }
    
    .modal-title {
        font-size: 1.5rem;
    }
    
    .page-header h2 {
        font-size: 1.5rem;
    }
    
    .card {
        width: 130px;
    }
    
    .card-image {
        height: 195px;
    }
    
    .search-results {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 1rem;
    }
}

@media (min-width: 768px) {
    .search-toggle {
        display: none;
    }
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 4px;
    opacity: 0.3;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-secondary);
    opacity: 0.7;
}

/* ===== NOTIFICATIONS ===== */
.notification {
    position: fixed;
    top: 80px;
    right: 1rem;
    background: var(--accent-primary);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    box-shadow: var(--card-shadow);
    z-index: 3000;
    animation: slideIn 0.3s ease;
    font-weight: 500;
    max-width: 300px;
}

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

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for accessibility */
button:focus,
input:focus {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

/* Hide elements visually but keep for screen readers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.error-message {
    color: #ff4757;
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
}

.loader {
    text-align: center;
    padding: 2rem;
}

.loader .loader {
    margin: 0 auto 1rem;
}

/* Add to style.css */
.trailer {
    margin-top: 1.5rem;
}

.trailer h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.trailer-container {
    margin-top: 1rem;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    aspect-ratio: 16/9;
    background: var(--bg-secondary);
}

.trailer-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Responsive trailer */
@media (max-width: 768px) {
    .trailer-container {
        aspect-ratio: 16/9;
    }
}

/* Add to style.css */
.slider-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 250px;
    width: 100%;
}

.slider-loading .loader {
    width: 40px;
    height: 40px;
}
/* Add to style.css */
.sliders-container {
    padding-bottom: 2rem;
}

.slider-section:last-child {
    margin-bottom: 1rem;
}

.error-message {
    color: var(--text-secondary);
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
    font-style: italic;
}

/* Improve card titles */
.card-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-primary);
    height: 1.2rem;
    line-height: 1.2;
}

.card-year {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* Make sliders more responsive */
.slider {
    display: flex;
    gap: 1rem;
    padding: 0.5rem 0.5rem 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

@media (min-width: 768px) {
    .slider {
        gap: 1.25rem;
        padding: 0.75rem 0.5rem 2rem;
    }
}

@media (min-width: 1024px) {
    .slider {
        gap: 1.5rem;
    }
}
/* Add to style.css in the BOTTOM NAVIGATION section */
.nav-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 0.75rem 0.5rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    transition: all var(--transition-speed) ease;
    flex: 1;
    max-width: 100px;
    position: relative;
    /* Remove outline on click */
    outline: none;
}

/* Remove the default focus outline */
.nav-btn:focus {
    outline: none;
}

/* Alternative: Add a custom focus style for accessibility */
.nav-btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
    border-radius: 6px;
}

/* Make sure the active button doesn't show rectangle */
.nav-btn.active:focus {
    outline: none;
    box-shadow: none;
}

/* Also add to remove focus from search button */
.search-toggle:focus,
.theme-toggle:focus {
    outline: none;
}

.search-toggle:focus-visible,
.theme-toggle:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
    border-radius: 10px;
}

/* Add to style.css after the slider styles */

/* Country Grid Styles */
.country-grid-container {
    position: relative;
    width: 100%;
}

.country-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1.25rem;
    padding: 0.5rem 0.5rem 1.5rem;
}

@media (min-width: 768px) {
    .country-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 1.5rem;
    }
}

@media (min-width: 1024px) {
    .country-grid {
        grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
        gap: 1.75rem;
    }
}

.grid-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    width: 100%;
    grid-column: 1 / -1;
}

.grid-loading .loader {
    width: 40px;
    height: 40px;
}

/* Keep horizontal scroll for popular/trending/top_rated sections */
.slider-container {
    position: relative;
    overflow: hidden;
}

.slider {
    display: flex;
    gap: 1rem;
    padding: 0.5rem 0.5rem 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.slider::-webkit-scrollbar {
    display: none;
}

/* Responsive adjustments for sliders */
@media (min-width: 768px) {
    .slider {
        gap: 1.25rem;
        padding: 0.75rem 0.5rem 2rem;
    }
    
    .slider .card {
        width: 160px;
    }
}

@media (min-width: 1024px) {
    .slider {
        gap: 1.5rem;
    }
    
    .slider .card {
        width: 170px;
    }
}

/* Add to style.css in the SEARCH PAGE section or at the end */

.search-tip {
    font-size: 0.8rem;
    opacity: 0.7;
    margin-top: 0.5rem;
}

.search-results-count {
    grid-column: 1 / -1;
    padding: 0.5rem 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.search-placeholder .fa-keyboard {
    color: var(--accent-primary);
}

/* Add a search button for better UX */
.search-input-wrapper {
    position: relative;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
    pointer-events: none;
}

#searchInput {
    width: 100%;
    padding: 1rem 3rem 1rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-speed) ease;
    flex: 1;
}

/* Add a search button */
.search-btn {
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 1rem 1.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    display: none; /* Hide by default, show on mobile if needed */
}

.search-btn:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

.search-btn:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .search-btn {
        display: block;
    }
    
    .search-input-wrapper {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    #searchInput {
        padding: 1rem 3rem 1rem 2.5rem;
    }
}

/* Add Enter key hint */
.search-hint {
    position: absolute;
    right: 3.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 0.8rem;
    opacity: 0.6;
    pointer-events: none;
}

@media (max-width: 768px) {
    .search-hint {
        display: none;
    }
}

/* ===== SIMILAR CONTENT STYLES ===== */
.similar-content {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.similar-content h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.similar-content h3::before {
    content: '🎬';
    font-size: 1.1rem;
}

.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
    margin-top: 0.5rem;
}

.similar-card {
    background: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: 1px solid var(--border-color);
    position: relative;
}

.similar-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--hover-glow);
}

.similar-card-image {
    position: relative;
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    overflow: hidden;
}

.similar-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow) ease;
}

.similar-card:hover .similar-card-image img {
    transform: scale(1.08);
}

.similar-card-rating {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--rating-badge);
    color: white;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.similar-card-rating i {
    font-size: 0.7rem;
}

.similar-card-content {
    padding: 0.6rem;
}

.similar-card-title {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-primary);
}

.similar-card-year {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

/* Responsive adjustments for similar content */
@media (min-width: 768px) {
    .similar-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1.25rem;
    }
    
    .similar-card-image {
        height: 225px;
    }
}

@media (max-width: 480px) {
    .similar-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 0.75rem;
    }
    
    .similar-card-image {
        height: 180px;
    }
    
    .similar-card-title {
        font-size: 0.8rem;
    }
}

/* Animation for similar cards */
.similar-card {
    animation: fadeInUp 0.4s ease backwards;
}

.similar-card:nth-child(1) { animation-delay: 0.05s; }
.similar-card:nth-child(2) { animation-delay: 0.1s; }
.similar-card:nth-child(3) { animation-delay: 0.15s; }
.similar-card:nth-child(4) { animation-delay: 0.2s; }
.similar-card:nth-child(5) { animation-delay: 0.25s; }
.similar-card:nth-child(6) { animation-delay: 0.3s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.similar-card-year-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    color: white;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
}

.similar-note {
    font-size: 12px;
    font-weight: normal;
    color: var(--text-secondary);
    margin-left: 8px;
}