/* Netflix Theme */
.theme-netflix {
    --netflix-red: #E50914;
    --netflix-red-dark: #B20710;
    --netflix-black: #000000;
    --netflix-dark: #141414;
    --netflix-gray: #333333;
    --netflix-light-gray: #666666;
    --netflix-white: #FFFFFF;
    
    --brand-accent: var(--netflix-red);
    --brand-secondary: var(--netflix-red-dark);
    --bg-primary: var(--netflix-black);
    --bg-secondary: var(--netflix-dark);
    --bg-dark: var(--netflix-gray);
    --bg-light: var(--netflix-light-gray);
    --text-primary: var(--netflix-white);
    --text-secondary: #B3B3B3;
    --border-color: var(--netflix-gray);
}

/* Disney+ Theme */
.theme-disney {
    --disney-blue: #0063E5;
    --disney-blue-dark: #004DB3;
    --disney-purple: #6421FF;
    --disney-black: #000000;
    --disney-dark: #0F1419;
    --disney-gray: #1A1D29;
    --disney-light-gray: #2A2D39;
    --disney-white: #FFFFFF;
    
    --brand-accent: var(--disney-blue);
    --brand-secondary: var(--disney-purple);
    --bg-primary: var(--disney-black);
    --bg-secondary: var(--disney-dark);
    --bg-dark: var(--disney-gray);
    --bg-light: var(--disney-light-gray);
    --text-primary: var(--disney-white);
    --text-secondary: #B3B3B3;
    --border-color: var(--disney-gray);
}

/* OSN+ Theme */
.theme-osn {
    --osn-orange: #FF6B35;
    --osn-orange-dark: #E55A2B;
    --osn-blue: #1E3A8A;
    --osn-black: #000000;
    --osn-dark: #0F172A;
    --osn-gray: #1E293B;
    --osn-light-gray: #334155;
    --osn-white: #FFFFFF;
    
    --brand-accent: var(--osn-orange);
    --brand-secondary: var(--osn-blue);
    --bg-primary: var(--osn-black);
    --bg-secondary: var(--osn-dark);
    --bg-dark: var(--osn-gray);
    --bg-light: var(--osn-light-gray);
    --text-primary: var(--osn-white);
    --text-secondary: #B3B3B3;
    --border-color: var(--osn-gray);
}

/* Shahid Theme */
.theme-shahid {
    --shahid-green: #00D4AA;
    --shahid-green-dark: #00B894;
    --shahid-blue: #0984E3;
    --shahid-black: #000000;
    --shahid-dark: #0A0A0A;
    --shahid-gray: #1A1A1A;
    --shahid-light-gray: #2D2D2D;
    --shahid-white: #FFFFFF;
    
    --brand-accent: var(--shahid-green);
    --brand-secondary: var(--shahid-blue);
    --bg-primary: var(--shahid-black);
    --bg-secondary: var(--shahid-dark);
    --bg-dark: var(--shahid-gray);
    --bg-light: var(--shahid-light-gray);
    --text-primary: var(--shahid-white);
    --text-secondary: #B3B3B3;
    --border-color: var(--shahid-gray);
}

/* News Section Styles */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.news-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border-color: var(--brand-accent);
}

.news-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--brand-accent);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.news-content {
    padding: 1.5rem;
}

.news-content h4 {
    color: var(--text-primary);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.news-content p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.news-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
}

.release-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--brand-accent);
    font-weight: 500;
}

.release-date i {
    font-size: 0.9rem;
}

/* Streaming Service Specific Header Styling */
.theme-netflix .game-title {
    color: var(--netflix-red);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.theme-disney .game-title {
    background: linear-gradient(45deg, var(--disney-blue), var(--disney-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.theme-osn .game-title {
    color: var(--osn-orange);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.theme-shahid .game-title {
    color: var(--shahid-green);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

/* Feature Items with Brand Colors */
.theme-netflix .feature-item i {
    color: var(--netflix-red);
}

.theme-disney .feature-item i {
    color: var(--disney-blue);
}

.theme-osn .feature-item i {
    color: var(--osn-orange);
}

.theme-shahid .feature-item i {
    color: var(--shahid-green);
}

/* Button Styling */
.theme-netflix .btn-success {
    background: var(--netflix-red);
    border-color: var(--netflix-red);
}

.theme-netflix .btn-success:hover {
    background: var(--netflix-red-dark);
    border-color: var(--netflix-red-dark);
}

.theme-disney .btn-success {
    background: var(--disney-blue);
    border-color: var(--disney-blue);
}

.theme-disney .btn-success:hover {
    background: var(--disney-blue-dark);
    border-color: var(--disney-blue-dark);
}

.theme-osn .btn-success {
    background: var(--osn-orange);
    border-color: var(--osn-orange);
}

.theme-osn .btn-success:hover {
    background: var(--osn-orange-dark);
    border-color: var(--osn-orange-dark);
}

.theme-shahid .btn-success {
    background: var(--shahid-green);
    border-color: var(--shahid-green);
}

.theme-shahid .btn-success:hover {
    background: var(--shahid-green-dark);
    border-color: var(--shahid-green-dark);
}

/* Card Headers */
.theme-netflix .card-header {
    background: var(--netflix-red);
    color: var(--netflix-white);
    border-bottom: 1px solid var(--netflix-red);
}

.theme-disney .card-header {
    background: var(--disney-blue);
    color: var(--disney-white);
    border-bottom: 1px solid var(--disney-blue);
}

.theme-osn .card-header {
    background: var(--osn-orange);
    color: var(--osn-white);
    border-bottom: 1px solid var(--osn-orange);
}

.theme-shahid .card-header {
    background: var(--shahid-green);
    color: var(--shahid-white);
    border-bottom: 1px solid var(--shahid-green);
}

/* Responsive Design */
@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .news-image {
        height: 180px;
    }
    
    .news-content {
        padding: 1rem;
    }
    
    .news-content h4 {
        font-size: 1.1rem;
    }
    /* Hide header image only, keep title and info visible */
    .game-header-image {
        display: none !important;
    }
    /* Hide user actions, center logo in header */
    .main-header .header-user-actions {
        display: none !important;
    }
    .main-header .header-content {
        justify-content: center !important;
    }
    /* Hide game features on mobile */
    .game-features {
        display: none !important;
    }
}

@media (max-width: 576px) {
    /* Compact product cards */
    .game-package {
        padding: 0.5rem !important;
        margin-bottom: 0.5rem !important;
        border-radius: 7px !important;
    }
    .game-package .game-image-container {
        height: 80px !important;
    }
    .game-package .product-title {
        font-size: 0.95rem !important;
        margin-bottom: 0.15rem !important;
    }
    .game-package .product-price {
        font-size: 1.05rem !important;
        margin-bottom: 0.2rem !important;
    }
    .game-package .product-description {
        font-size: 0.75rem !important;
        margin-bottom: 0.2rem !important;
    }
    .game-package .btn {
        padding: 0.3rem 0.5rem !important;
        font-size: 0.75rem !important;
        margin-bottom: 0.2rem !important;
    }
    /* Compact benefit cards */
    .benefit-card {
        padding: 0.7rem !important;
        margin-bottom: 0.7rem !important;
        border-radius: 7px !important;
    }
    .benefit-card h5 {
        font-size: 0.95rem !important;
        margin-bottom: 0.3rem !important;
    }
    .benefit-card p {
        font-size: 0.8rem !important;
        margin-bottom: 0 !important;
    }
    /* Reduce margins between sections */
    .row.mb-5 {
        margin-bottom: 1rem !important;
    }
    .mb-4 {
        margin-bottom: 0.7rem !important;
    }
    /* 2 cards per row on mobile */
    .col-6 {
        flex: 0 0 50% !important;
        max-width: 50% !important;
    }
}

/* Animation for News Cards */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-card {
    animation: fadeInUp 0.6s ease forwards;
}

.news-card:nth-child(1) { animation-delay: 0.1s; }
.news-card:nth-child(2) { animation-delay: 0.2s; }
.news-card:nth-child(3) { animation-delay: 0.3s; }

/* Loading Placeholder */
.news-placeholder {
    background: linear-gradient(90deg, var(--bg-dark) 25%, var(--bg-light) 50%, var(--bg-dark) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 8px;
    height: 200px;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* RTL fix: keep news grid horizontal, but card content RTL */
.rtl .news-grid {
    direction: ltr !important;
    text-align: left !important;
    unicode-bidi: plaintext !important;
}
.rtl .news-card {
    direction: rtl !important;
    text-align: right !important;
    float: none !important;
    clear: none !important;
}

/* Modal Styles for Dark Theme */
.modal-content {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.modal-header {
    background-color: var(--bg-dark);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
}

.modal-header .btn-close {
    filter: invert(1);
}

.modal-body {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
}

.modal-footer {
    background-color: var(--bg-dark);
    border-top: 1px solid var(--border-color);
}

.modal .form-control {
    background-color: var(--bg-dark);
    border-color: var(--border-color);
    color: var(--text-primary);
}

.modal .form-control:focus {
    background-color: var(--bg-dark);
    border-color: var(--brand-accent);
    color: var(--text-primary);
    box-shadow: 0 0 0 0.25rem rgba(229, 9, 20, 0.25);
}

.modal .form-control::placeholder {
    color: var(--text-secondary);
}

.modal .form-label {
    color: var(--text-primary);
    font-weight: 500;
}

.modal .form-text {
    color: var(--text-secondary);
}

.modal .alert {
    background-color: rgba(13, 110, 253, 0.1);
    border-color: rgba(13, 110, 253, 0.2);
    color: #0d6efd;
}

.modal .btn-outline-secondary {
    color: var(--text-secondary);
    border-color: var(--border-color);
}

.modal .btn-outline-secondary:hover {
    background-color: var(--bg-dark);
    border-color: var(--text-secondary);
    color: var(--text-primary);
}

.plan-details h6 {
    color: var(--text-primary);
    font-weight: 600;
}

.plan-price {
    color: var(--brand-accent);
    font-size: 1.2rem;
    font-weight: 600;
}

.plan-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Theme-specific modal focus colors */
.theme-netflix .modal .form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(229, 9, 20, 0.25);
}

.theme-disney .modal .form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(0, 99, 229, 0.25);
}

.theme-osn .modal .form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 107, 53, 0.25);
}

.theme-shahid .modal .form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(0, 212, 170, 0.25);
} 