/* assets/css/style.css - Tema Dark con Background Separati */

* {
    scrollbar-width: thin;
    scrollbar-color: #ffc107 #1a1a1a;
    box-sizing: border-box;
}

*::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

*::-webkit-scrollbar-track {
    background: #1a1a1a;
}

*::-webkit-scrollbar-thumb {
    background-color: #ffc107;
    border-radius: 10px;
}

/* ✅ BACKGROUND FISSO - VERSIONE CORRETTA SENZA CONFLITTI */
html {
    background: url('/uploads/background.jpg') center/cover fixed !important;
    min-height: 100vh;
}

body {
    background: transparent !important;
    color: #f0f0f0 !important;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    font-family: 'Helvetica Neue', Arial, sans-serif;
    position: relative;
}


/* ============================================
   LOGIN & REGISTER PAGES
============================================ */

.auth-wrapper {
    background: url('/uploads/background.jpg') center/cover fixed !important;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    position: relative;
    overflow: hidden;
}

.auth-wrapper::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 0;
}

.auth-wrapper::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,193,7,0.1) 0%, transparent 70%);
    animation: pulse 15s ease-in-out infinite;
    z-index: 1;
}

@keyframes pulse {
    0%, 100% { transform: scale(1) rotate(0deg); opacity: 0.3; }
    50% { transform: scale(1.1) rotate(180deg); opacity: 0.5; }
}

.auth-container {
    max-width: 450px;
    width: 100%;
    padding: 20px;
    position: relative;
    z-index: 10;
}

.auth-card {
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.95) 0%, rgba(42, 42, 42, 0.95) 100%);
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,193,7,0.2);
    padding: 40px;
    border: 2px solid #333;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,193,7,0.1), transparent);
    transition: left 0.5s;
}

.auth-card:hover::before {
    left: 100%;
}

.auth-card:hover {
    box-shadow: 0 15px 50px rgba(255,193,7,0.3), 0 0 0 1px rgba(255,193,7,0.4);
    transform: translateY(-5px);
}

.logo-container {
    text-align: center;
    margin-bottom: 30px;
}

.logo-container h1 {
    color: #ffc107;
    font-weight: bold;
    margin-bottom: 5px;
    font-size: 28px;
    text-shadow: 0 2px 10px rgba(255, 193, 7, 0.3);
}

.logo-container h1 i {
    color: #ff9800;
    margin-right: 10px;
}

.logo-container p {
    color: #c0c0c0;
    font-size: 14px;
    margin: 0;
}

.form-label {
    color: #c0c0c0;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-control, .form-select {
    background-color: #0f0f0f;
    border: 1px solid #444;
    color: #f0f0f0;
    padding: 12px 15px;
    border-radius: 8px;
    transition: all 0.3s;
    font-size: 14px;
}

.form-control:focus, .form-select:focus {
    background-color: #1a1a1a;
    border-color: #ffc107;
    color: #f0f0f0;
    box-shadow: 0 0 0 0.25rem rgba(255, 193, 7, 0.25);
    outline: none;
}

.form-control::placeholder {
    color: #666;
}

.input-group-text {
    background-color: #0f0f0f;
    border: 1px solid #444;
    color: #ffc107;
    border-radius: 8px 0 0 8px;
    padding: 12px 15px;
}

.input-group .form-control {
    border-left: none;
    border-radius: 0 8px 8px 0;
}

.input-group .form-control:focus {
    border-left: 1px solid #ffc107;
}

.form-check {
    padding-left: 1.8em;
}

.form-check-input {
    background-color: #0f0f0f;
    border: 1px solid #444;
    width: 1.2em;
    height: 1.2em;
    margin-top: 0.2em;
    cursor: pointer;
}

.form-check-input:checked {
    background-color: #ffc107;
    border-color: #ffc107;
}

.form-check-input:focus {
    border-color: #ffc107;
    box-shadow: 0 0 0 0.25rem rgba(255, 193, 7, 0.25);
}

.form-check-label {
    color: #c0c0c0;
    cursor: pointer;
    font-size: 14px;
}

.form-check-label i {
    color: #ffc107;
    margin-right: 5px;
}

.btn-auth {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border: none;
    color: #000;
    width: 100%;
    padding: 14px 20px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.btn-auth:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(255, 193, 7, 0.5);
    background: linear-gradient(135deg, #ff9800 0%, #ffc107 100%);
}

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

.btn-auth i {
    margin-right: 8px;
}

.alert {
    background-color: rgba(26, 26, 26, 0.9);
    border: 1px solid #444;
    color: #f0f0f0;
    font-size: 14px;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 20px;
}

.alert-success {
    background-color: rgba(26, 46, 26, 0.9);
    border-color: #198754;
    color: #d1f2d1;
}

.alert-danger {
    background-color: rgba(46, 26, 26, 0.9);
    border-color: #dc3545;
    color: #f8d7da;
}

.alert-warning {
    background-color: rgba(46, 42, 26, 0.9);
    border-color: #ffc107;
    color: #fff3cd;
}

.alert i {
    margin-right: 8px;
}

.auth-link {
    text-align: center;
    margin-top: 20px;
}

.auth-link p {
    color: #c0c0c0;
    margin: 0;
    font-size: 14px;
}

.auth-link a {
    color: #ffc107;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.auth-link a:hover {
    color: #ff9800;
    text-decoration: underline;
}

.recaptcha-badge {
    text-align: center;
    font-size: 11px;
    color: #666;
    margin-top: 15px;
}

.recaptcha-badge i {
    color: #ffc107;
    margin: 0 3px;
}

.fake-fields {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 6px;
}

.btn-success {
    background: linear-gradient(135deg, #198754 0%, #157347 100%);
    border: none;
    color: #fff;
    font-weight: 600;
}

.btn-success:hover {
    background: linear-gradient(135deg, #157347 0%, #198754 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(25, 135, 84, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    border: none;
    color: #fff;
    font-weight: 600;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #5a6268 0%, #6c757d 100%);
    transform: translateY(-2px);
}

/* ============================================
   STILI DALLA INDEX.PHP
============================================ */

/* ✅ STILI PER BADGE VIP E LIMITI */
.user-status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    margin-left: 10px;
}

.badge-vip {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.badge-admin {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: #000;
}

.badge-user {
    background: #6c757d;
    color: white;
}

/* ✅ BADGE MESSAGGI */
.message-badge {
    position: relative;
    display: inline-block;
}

.message-badge .badge {
    position: absolute;
    top: -8px;
    right: -8px;
    padding: 3px 6px;
    font-size: 10px;
    border-radius: 10px;
    animation: pulseBadge 2s infinite;
}

@keyframes pulseBadge {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* ✅ STILI PER BOTTONI MODAL */
.modal-action-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

.btn-view-details {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-view-details:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
    color: white;
}

/* ============================================
   HOME PAGE - INDEX
============================================ */

/* Navbar con BG Scuro */
.navbar {
    background-color: rgba(10, 15, 30, 0.95);
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.5);
    border-bottom: 2px solid rgba(255, 193, 7, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 10px;
}

.navbar-brand {
    font-size: 28px;
    font-weight: bold;
    color: #ffc107 !important;
    text-shadow: 0 2px 10px rgba(255, 193, 7, 0.5);
}

.navbar-brand i {
    color: #ff9800;
}

.navbar-nav .nav-link {
    color: #e5e5e5 !important;
    margin: 0 10px;
    padding: 8px 15px;
    border-radius: 5px;
    transition: all 0.3s;
    font-weight: 500;
}

.navbar-nav .nav-link:hover {
    color: #ffc107 !important;
    background-color: rgba(255, 193, 7, 0.1);
}

.navbar-nav .nav-link.active {
    color: #ffc107 !important;
    background-color: rgba(255, 193, 7, 0.2);
}

.btn-register-nav {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    padding: 8px 20px !important;
    border-radius: 20px !important;
    font-weight: bold !important;
}

.btn-register-nav:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.5);
}

/* Search Section con BG Scuro Separato */
.search-section {
    background-color: rgba(10, 15, 30, 0.90);
    backdrop-filter: blur(5px);
    padding: 25px 0;
    margin: 20px 0;
    border: 2px solid rgba(255, 193, 7, 0.2);
    border-radius: 10px;
}

.search-form-top .input-group {
    max-width: 700px;
    margin: 0 auto;
}

.search-form-top .input-group-text {
    background-color: rgba(26, 26, 26, 0.9);
    border: 1px solid #444;
    color: #ffc107;
}

.search-form-top .form-control {
    background-color: rgba(26, 26, 26, 0.9);
    border: 1px solid #444;
    color: #ffffff;
    padding: 14px 20px;
    font-size: 16px;
}

.search-form-top .form-control:focus {
    background-color: rgba(34, 34, 34, 0.9);
    border-color: #ffc107;
    color: #ffffff;
    box-shadow: 0 0 10px rgba(255, 193, 7, 0.3);
}

.search-form-top .form-control::placeholder {
    color: #999;
}

.search-form-top .btn-search {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border: none;
    color: #000;
    padding: 14px 35px;
    font-weight: bold;
    transition: all 0.3s;
}

.search-form-top .btn-search:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.5);
}

/* Slider Section con BG Scuro Separato */
.slider-section {
    padding: 30px 0;
    background-color: rgba(10, 15, 30, 0.90);
    backdrop-filter: blur(5px);
    margin: 20px 0;
    border: 2px solid rgba(255, 193, 7, 0.2);
    border-radius: 10px;
}

.slider-title {
    font-size: 24px;
    font-weight: bold;
    color: #ffc107;
    margin-bottom: 20px;
    text-shadow: 0 2px 5px rgba(255, 193, 7, 0.3);
}

.slider-title i {
    color: #ff9800;
    margin-right: 10px;
}

.slider-container {
    position: relative;
    background-color: rgba(26, 26, 26, 0.6);
    border-radius: 10px;
    padding: 20px 50px;
    border: 2px solid rgba(255, 193, 7, 0.2);
}

.slider-wrapper {
    overflow: hidden;
    border-radius: 8px;
}

.slider-track {
    display: flex;
    transition: transform 0.5s ease;
}

.slider-item {
    flex: 0 0 10%;
    padding: 0 2.5px;
    cursor: pointer;
}

.slider-poster-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 150%;
    overflow: hidden;
    border-radius: 6px;
    background-color: #2a2a2a;
    transition: all 0.3s;
    border: 1px solid rgba(255, 193, 7, 0.1);
}

.slider-item:hover .slider-poster-wrapper {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.4);
    z-index: 10;
    border-color: rgba(255, 193, 7, 0.5);
}

.slider-poster {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slider-year-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background-color: #c71a1a;
    color: #fff;
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
}

.slider-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 40px;
    color: rgba(255, 193, 7, 0.8);
    opacity: 0;
    transition: opacity 0.3s;
}

.slider-item:hover .slider-play-icon {
    opacity: 1;
}

.slider-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.95) 100%);
    opacity: 0;
    transition: opacity 0.3s;
    padding: 10px;
}

.slider-item:hover .slider-overlay {
    opacity: 1;
}

.slider-title-text {
    color: #ffffff;
    font-size: 11px;
    font-weight: bold;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border: none;
    color: #000;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 10;
}

.slider-nav:hover {
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.5);
}

.slider-prev {
    left: 5px;
}

.slider-next {
    right: 5px;
}

/* Movies Section con BG Scuro Separato */
.movies-section {
    padding: 30px 0;
    background-color: rgba(10, 15, 30, 0.90);
    backdrop-filter: blur(5px);
    min-height: 60vh;
    margin: 20px 0;
    border: 2px solid rgba(255, 193, 7, 0.2);
    border-radius: 10px;
}

.section-title {
    font-size: 28px;
    font-weight: bold;
    color: #ffc107;
    margin-bottom: 25px;
    text-shadow: 0 2px 5px rgba(255, 193, 7, 0.3);
}

.section-title i {
    color: #ff9800;
    margin-right: 10px;
}

.page-info {
    font-size: 16px;
    color: #999;
    font-weight: normal;
    margin-left: 10px;
}

.search-results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.movie-card {
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 8px;
    overflow: hidden;
}

.movie-card:hover {
    transform: translateY(-10px) scale(1.03);
    box-shadow: 0 10px 30px rgba(255, 193, 7, 0.4);
    z-index: 10;
}

.movie-poster-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 150%;
    overflow: hidden;
    border-radius: 8px;
    background-color: #2a2a2a;
    border: 2px solid rgba(255, 193, 7, 0.1);
}

.movie-card:hover .movie-poster-wrapper {
    border-color: rgba(255, 193, 7, 0.5);
}

.movie-poster {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.movie-year-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background-color: rgba(255, 193, 7, 0.95);
    color: #000;
    padding: 4px 10px;
    border-radius: 2px;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
}

.movie-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.95) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 15px;
}

.movie-card:hover .movie-overlay {
    opacity: 1;
}

.movie-title {
    color: #ffffff;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 5px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-info-text {
    color: #cccccc;
    font-size: 11px;
}

.movie-info-text i {
    color: #ffc107;
}

.play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 60px;
    color: rgba(255, 193, 7, 0.9);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.movie-card:hover .play-icon {
    opacity: 1;
}

/* Pagination */
.pagination-wrapper {
    margin-top: 40px;
}

.pagination {
    background-color: rgba(26, 26, 26, 0.9);
    backdrop-filter: blur(10px);
    padding: 15px 20px;
    border-radius: 50px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.5);
    border: 2px solid rgba(255, 193, 7, 0.2);
}

.pagination .page-item .page-link {
    background-color: rgba(42, 42, 42, 0.8);
    border: 1px solid #444;
    color: #e5e5e5;
    margin: 0 5px;
    border-radius: 8px;
    padding: 10px 18px;
    transition: all 0.3s;
    font-weight: 500;
}

.pagination .page-item.active .page-link {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border-color: #ffc107;
    color: #000;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.4);
}

.pagination .page-item .page-link:hover {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border-color: #ffc107;
    color: #000;
    transform: scale(1.1);
}

.pagination .page-item.disabled .page-link {
    background-color: rgba(26, 26, 26, 0.5);
    border-color: #333;
    color: #555;
}

/* Footer con BG Scuro */
footer {
    background-color: rgba(10, 15, 30, 0.95);
    padding: 30px 20px;
    margin-top: 0;
    text-align: center;
    color: #808080;
    border: 2px solid rgba(255, 193, 7, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 10px;
}

footer p {
    margin: 0;
    font-size: 14px;
}

/* Modal */
.modal-content {
    background-color: rgba(26, 26, 26, 0.98);
    backdrop-filter: blur(10px);
    border: 2px solid #ffc107;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
}

.modal-header {
    border-bottom: 1px solid #444;
    background-color: rgba(0, 0, 0, 0.8);
    border-radius: 15px 15px 0 0;
}

.modal-body {
    padding: 30px;
}

.file-info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #444;
    font-size: 14px;
}

.file-info-row:last-child {
    border-bottom: none;
}

.file-info-label {
    color: #ffc107;
    font-weight: bold;
}

.file-info-label i {
    margin-right: 8px;
}

.file-info-value {
    color: #e5e5e5;
    text-align: right;
    word-break: break-all;
    max-width: 65%;
}

.download-btn-modal {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #000;
    border: none;
    padding: 15px 50px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    display: inline-block;
}

.download-btn-modal:hover {
    transform: scale(1.08);
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.6);
    color: #000;
}

/* Modal Registrazione */
.register-required {
    text-align: center;
    padding: 40px 20px;
}

.register-required .icon {
    font-size: 80px;
    color: #ffc107;
    margin-bottom: 25px;
    animation: pulseIcon 2s infinite;
}

@keyframes pulseIcon {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.register-required h4 {
    color: #ffc107;
    margin-bottom: 15px;
    font-size: 26px;
}

.register-required p {
    color: #e5e5e5;
    margin-bottom: 30px;
    font-size: 16px;
}

.btn-register-now {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
    margin: 0 10px;
    font-size: 16px;
}

.btn-register-now:hover {
    transform: scale(1.08);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.6);
    color: white;
}

.btn-login-now {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #000;
    border: none;
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
    margin: 0 10px;
    font-size: 16px;
}

.btn-login-now:hover {
    transform: scale(1.08);
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.6);
    color: #000;
}

/* ✅ FIX PER TABLET - DISABILITA BACKDROP-FILTER SE CAUSA PROBLEMI */
@media (max-width: 1024px) {
    .search-section,
    .slider-section,
    .movies-section,
    .navbar,
    footer,
    .pagination {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

/* Responsive Slider */
@media (max-width: 1399px) {
    .slider-item { flex: 0 0 12.5%; }
}

@media (max-width: 1199px) {
    .slider-item { flex: 0 0 16.666%; }
}

@media (max-width: 991px) {
    .slider-item { flex: 0 0 20%; }
}

@media (max-width: 767px) {
    .slider-item { flex: 0 0 25%; }
}

@media (max-width: 575px) {
    .slider-item { flex: 0 0 33.333%; }
    .slider-container { padding: 15px 40px; }
    .slider-nav { width: 35px; height: 35px; font-size: 16px; }
    .slider-title { font-size: 20px; }
}

/* Responsive Grid */
@media (max-width: 575px) {
    .search-form-top .btn-search {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .section-title {
        font-size: 22px;
    }
    
    .navbar-brand {
        font-size: 22px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .file-info-row {
        flex-direction: column;
        gap: 5px;
    }
    
    .file-info-value {
        text-align: left;
        max-width: 100%;
    }
    
    .download-btn-modal {
        padding: 12px 30px;
        font-size: 16px;
    }
    
    .btn-register-now,
    .btn-login-now {
        display: block;
        margin: 10px auto;
        width: 90%;
    }
    
    .register-required .icon {
        font-size: 60px;
    }
    
    .register-required h4 {
        font-size: 22px;
    }
    
    .search-section,
    .slider-section,
    .movies-section {
        margin: 10px 0;
        border-radius: 5px;
    }
    
    .modal-action-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-view-details {
        width: 100%;
        justify-content: center;
    }
}

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

.auth-card,
.movie-card,
.slider-item {
    animation: fadeIn 0.5s ease-out;
}

/* Loading Spinner */
.spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.3em;
}

/* Offline Page */
.offline-wrapper {
    background: url('/uploads/background.jpg') center/cover fixed !important;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.offline-wrapper::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 0;
}

.offline-card {
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.95) 0%, rgba(42, 42, 42, 0.95) 100%);
    border-radius: 15px;
    padding: 60px 40px;
    text-align: center;
    max-width: 600px;
    border: 2px solid rgba(255, 193, 7, 0.3);
    box-shadow: 0 10px 40px rgba(0,0,0,0.7);
    position: relative;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.offline-icon {
    font-size: 100px;
    color: #ffc107;
    margin-bottom: 30px;
    animation: pulseIcon 2s infinite;
}

.offline-card h1 {
    color: #ffc107;
    font-size: 36px;
    margin-bottom: 20px;
}

.offline-card p {
    color: #e5e5e5;
    font-size: 18px;
    margin-bottom: 30px;
}

/* ============================================
   FIX PAGINAZIONE RESPONSIVE E CENTRATA PER SMARTPHONE
============================================ */

@media (max-width: 575px) {
    .pagination-wrapper {
        margin-top: 20px;
        display: flex;
        justify-content: center;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0 10px;
    }
    
    .pagination {
        padding: 10px 15px;
        border-radius: 30px;
        display: inline-flex;
        min-width: auto;
        justify-content: center;
        margin: 0 auto;
    }
    
    .pagination .page-item .page-link {
        margin: 0 2px;
        border-radius: 6px;
        padding: 6px 10px;
        font-size: 13px;
        min-width: 32px;
        text-align: center;
    }
    
    /* Nascondi le icone doppie freccia su mobile per risparmiare spazio */
    .pagination .page-item:first-child,
    .pagination .page-item:last-child {
        display: none;
    }
}

@media (max-width: 400px) {
    .pagination .page-item .page-link {
        padding: 5px 8px;
        font-size: 12px;
        min-width: 28px;
    }
    
    .pagination {
        padding: 8px 10px;
    }
}