:root {
    --color-bg-dark: #141414;
    --color-bg-darker: #0a0a0a;
    --color-bg-light: #181818;
    --color-bg-card: #222;
    --color-bg-hover: #333;
    --color-text-primary: #ffffff;
    --color-text-secondary: #ccc;
    --color-text-muted: #666;
    --color-accent: #e50914;
    --color-accent-alt: #ff2a44;
    --color-accent-hover: #ff6b6b;
    --font-primary: 'Inter', sans-serif;
    --font-heading: 'Montserrat', sans-serif;
    --font-alt: 'Roboto', sans-serif;
    --transition: 0.3s ease;
    --radius: 8px;
}


body {
    background-color: var(--color-bg-dark);
    color: var(--color-text-primary);
    font-family: var(--font-primary);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    scroll-behavior: smooth;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1400px;
    padding: 0 15px;
    margin: 0 auto;
}


/* =========================================
   HEADER & NAVIGATION
   ========================================= */

#mainHeader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    padding: 0.5rem 0;
    background: var(--color-bg-dark);
    transition: var(--transition);
}

.header-scrolled {
    background: var(--color-bg-darker);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--color-accent-alt);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
    transition: color var(--transition);
}

.logo:hover {
    color: var(--color-accent-hover);
}

.nav-list {
    display: flex;
    gap: 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-list li a {
    color: var(--color-text-primary);
    text-decoration: none;
    font-weight: 600;
    position: relative;
    transition: color var(--transition);
}

.nav-list li a:hover {
    color: var(--color-accent-alt);
}

.nav-list li a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-accent-alt);
    transition: width 0.2s ease;
}

.nav-list li a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--color-text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: transform var(--transition);
}

.menu-toggle:hover {
    transform: rotate(90deg);
}

/* =========================================
   LOADING OVERLAYS & SPINNER
   ========================================= */

#loadingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #ff2a44;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


/* =========================================
   VIDEO & AD SECTIONS
   ========================================= */
.video-main {
    padding-top: 80px;
}

.video-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.video-ad-wrapper {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
}

.video-player-section {
    flex: 3;
}

.video-player-wrapper {
    position: relative;
    padding-top: 56.25%;
    background: #000;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.video-player-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-title {
    font-size: 1rem;
    color: var(--color-text-primary);
    margin: 20px 0 10px;
    font-weight: 700;
}

.video-details {
    background: var(--color-bg-light);
    padding: 20px;
    border-radius: var(--radius);
    font-size: 0.9rem;
    color: var(--color-text-secondary);
}

.video-details a {
    color: var(--color-accent-alt);
    text-decoration: none;
}

.video-details a:hover {
    text-decoration: underline;
}

.ad-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ad-box {
    background: var(--color-bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform var(--transition);
}

.ad-box:hover {
    transform: scale(1.02);
}

.ad-box img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================
   VIDEO GRID / CARDS
   ========================================= */



.related-videos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    padding-bottom: 20px;
}

.video-card,
.category-card {
    background: var(--color-bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
    position: relative;
}

.video-card:hover,
.category-card:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 42, 68, 0.5);
}

.video-card img,
.category-card img {
    width: 100%;
    height: 280px;
    object-fit: cover;
}

.card-overlay,
.video-card .overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    padding: 10px;
    color: var(--color-text-primary);
}

.video-card h5,
.category-card h5 {
    font-family: var(--font-heading);
    font-size: 1rem;
    text-align: center;
    margin: 0;
}

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

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    font-size: 3rem;
    color: var(--color-accent-alt);
    transition: transform var(--transition), opacity var(--transition);
}

.video-card:hover .play-btn,
.card:hover .play-btn {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
}

/* =========================================
   COMMENTS
   ========================================= */


.comments-list {
    background: var(--color-bg-light);
    padding: 20px;
    border-radius: var(--radius);
}

.comment {
    border-bottom: 1px solid var(--color-bg-hover);
    padding: 15px 0;
}

.comment p {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
}

.comment a {
    color: var(--color-accent-alt);
}

.comment a:hover {
    text-decoration: underline;
}

.comment .replies {
    margin-left: 20px;
    border-left: 2px solid var(--color-accent-alt);
    padding-left: 10px;
}

/* =========================================
   FOOTER
   ========================================= */

#loadingMore {
    display: flex;
    justify-content: center;
    padding: 20px;
}

#ageVerificationModal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9998;
    transition: opacity 0.3s ease;
}

.modal-content {
    background: #222;
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 0 20px rgba(255, 42, 68, 0.5);
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

#ageVerificationModal[style*="display: flex"] .modal-content {
    transform: scale(1);
}

.modal-content h3 {
    font-family: 'Montserrat', sans-serif;
    color: #ff2a44;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.modal-content p {
    color: #ccc;
    margin-bottom: 20px;
}

.btn-primary {
    background: linear-gradient(45deg, #ff2a44, #ff6b6b);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    color: #fff;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 10px rgba(255, 42, 68, 0.7);
}

.btn-primary:active {
    transform: scale(0.95);
}

.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('https://placehold.co/1920x600.png?text=Hardcore+Hero');
    background-size: cover;
    background-position: center;
    padding: 80px 0;
    text-align: center;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 3rem;
    color: #ff2a44;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6);
    animation: slideUp 0.8s ease-out forwards;
}

.hero p {
    font-size: 1.2rem;
    color: #ccc;
    max-width: 600px;
    margin: 0 auto 20px;
    animation: slideUp 0.8s ease-out 0.2s forwards;
}

@keyframes slideUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.content-section {
    padding: 40px 0;
    display: none;
}

.content-section.visible {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem;
    color: #ff2a44;
    margin-bottom: 30px;
    text-transform: uppercase;
    text-align: center;
}

.section-title::after {
    content: '';
    display: block;
    width: 50px;
    height: 3px;
    background: #ff2a44;
    margin: 10px auto 0;
}

.search-section {
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
}

.search-input {
    width: 100%;
    max-width: 600px;
    padding: 12px;
    background: #222;
    border: 1px solid #ff2a44;
    border-radius: 5px;
    color: #fff;
    font-size: 1rem;
}

.search-input:focus {
    outline: none;
    box-shadow: 0 0 10px rgba(255, 42, 68, 0.5);
}

.suggestions-dropdown {
    position: absolute;
    background: #222;
    border: 1px solid #ff2a44;
    border-radius: 5px;
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    width: 100%;
    max-width: 600px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
}

.suggestion-item {
    padding: 10px;
    color: #fff;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.suggestion-item:hover {
    background: #ff2a44;
}

.form-select.glass {
    background: #222;
    border: 1px solid #ff2a44;
    color: #fff;
    border-radius: 5px;
    padding: 8px;
}

.form-select.glass option {
    background: #222;
    color: #fff;
}

.toggle-label {
    color: #ccc;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.video-card, .category-card {
    background: #222;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
    position: relative;
}

.video-card:hover, .category-card:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 42, 68, 0.5);
}

.video-card img, .category-card img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
}

.video-card .overlay, .category-card .card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    padding: 10px;
    color: #fff;
}

.video-card h5, .category-card h5 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    margin: 0;
    text-align: center;
}

.video-card .small {
    font-size: 0.8rem;
    color: #ccc;
}

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    font-size: 3rem;
    color: #ff2a44;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.card:hover .play-btn {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.page-btn {
    background: #222;
    border: 1px solid #ff2a44;
    color: #fff;
    padding: 8px 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover, .page-btn.active {
    background: #ff2a44;
    color: #000;
}

.row-carousel {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding-bottom: 20px;
    scrollbar-width: thin;
    scrollbar-color: #ff2a44 #222;
}

.row-carousel::-webkit-scrollbar {
    height: 6px;
}

.row-carousel::-webkit-scrollbar-thumb {
    background: #ff2a44;
    border-radius: 10px;
}

.row-carousel::-webkit-scrollbar-track {
    background: #222;
}

.image-card {
    min-width: 200px;
    background: #222;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.card-placeholder {
    width: 100%;
    height: 150px;
    background: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
}

.category-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    padding: 0;
    list-style: none;
}

.category-list li a {
    display: block;
    background: #222;
    padding: 10px;
    border-radius: 5px;
    color: #fff;
    text-decoration: none;
    text-align: center;
    font-weight: 600;
    transition: background 0.3s, transform 0.3s;
}

.category-list li a:hover {
    background: #ff2a44;
    transform: translateY(-4px);
}

footer {
    background: #111;
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid #333;
}

footer p {
    color: #ccc;
    margin: 0;
}

footer h5 {
    font-family: 'Montserrat', sans-serif;
    color: #ff2a44;
    margin-bottom: 20px;
}

footer a {
    color: #ccc;
    text-decoration: none;
}

footer a:hover {
    color: #ff2a44;
}

footer hr {
    border-color: #333;
}

.error-message {
    color: #ff2a44;
    text-align: center;
    padding: 20px;
    background: #222;
    border-radius: 5px;
}

.categories-main, .search-main, .video-main {
    padding-top: 80px;
}

@media (max-width: 992px) {
    .container {
        max-width: 960px;
    }
    .nav-list {
        gap: 15px;
    }
    .video-card img, .category-card img {
        height: 200px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 10px;
    }
    .logo {
        font-size: 1.5rem;
    }
    .nav-list {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: #1a1a1a;
        padding: 20px;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    }
    .nav-list.show {
        display: flex;
    }
    .menu-toggle {
        display: block;
    }
    .hero {
        padding: 60px 15px;
        min-height: 50vh;
    }
    .hero h2 {
        font-size: 2rem;
    }
    .hero p {
        font-size: 1rem;
    }
    .category-list {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 1.5rem;
    }
    .btn-primary {
        width: 100%;
    }
    .search-input, .suggestions-dropdown {
        max-width: 100%;
    }
    .video-card img, .category-card img {
        height: 150px;
    }
    .category-list {
        grid-template-columns: 1fr;
    }
}

a:focus, button:focus, input:focus {
    outline: 2px solid #ff2a44;
    outline-offset: 2px;
}

img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img[loading="lazy"]:loaded {
    opacity: 1;
}

.video-details {
    background: linear-gradient(135deg, #181818 0%, #222 100%);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: slideIn 0.5s ease-out forwards;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    transition: transform 0.3s ease, background 0.3s ease;
}

.detail-item:hover {
    transform: translateY(-3px);
    background: rgba(229, 9, 20, 0.1);
}

.detail-icon {
    font-size: 1.2rem;
    color: #e50914;
    transition: transform 0.3s ease;
}

.detail-item:hover .detail-icon {
    transform: scale(1.2);
}

.detail-label {
    font-weight: 500;
    color: #ccc;
    font-size: 0.9rem;
}

.detail-value {
    font-weight: 400;
}