:root {
    --primary-color: #6c5ce7;
    --secondary-color: #a29bfe;
    --accent-color: #fd79a8;
    --dark-color: #2d3436;
    --light-color: #f5f6fa;
    --success-color: #00b894;
    --warning-color: #fdcb6e;
    --danger-color: #d63031;
    --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background:
        radial-gradient(ellipse at top left, #a50029 0%, #5a001a 50%, transparent 100%),
        linear-gradient(155deg, #5a001a 0%, #8b0000 50%, #a50029 100%),
        /* Pure CSS noise effect */
        linear-gradient(rgba(0, 0, 0, 0.03) 0%, rgba(0, 0, 0, 0.03) 100%);
    background-attachment: fixed;
    color: var(--light-color);
    line-height: 1.6;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at top left, transparent 0%, rgba(0, 0, 0, 0.1) 100%);
    pointer-events: none;
    z-index: -1;
    opacity: 0.03;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header Styles */
header {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: bold;
}

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

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav a {
    color: var(--light-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem;
    border-radius: 4px;
}

nav a:hover {
    background: rgba(255, 255, 255, 0.1);
}

.header-search {
    display: inline-block;
    margin-left: 2rem;
    vertical-align: middle;
}

.header-search input[type="text"] {
    padding: 0.3rem 0.6rem;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-size: 0.9rem;
    width: 200px;
}

.header-search button {
    background-color: var(--accent-color);
    border: none;
    color: #fff;
    padding: 0.3rem 0.6rem;
    margin-left: 0.2rem;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
}

.header-search button:hover {
    background-color: #e84393;
}

/* Main Content Styles */
.hero {
    text-align: center;
    padding: 3rem 1rem;
    margin-bottom: 2rem;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.9;
}

.controls {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    backdrop-filter: blur(5px);
}

.filter-options {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    align-items: center;
}

.view-toggle {
    display: flex;
    gap: 0.5rem;
}

.view-toggle button {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    padding: 0.5rem;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.view-toggle button.active {
    background: var(--primary-color);
}

.view-toggle button:hover {
    background: var(--secondary-color);
}

/* Grid & Card Styles */
.category-grid,
.video-grid {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
    min-height: 50vh;
}

.category-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.video-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

.category-card,
.video-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    transition: var(--transition);
    backdrop-filter: blur(5px);
    box-shadow: var(--card-shadow);
}

.category-card:hover,
.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.category-card a {
    display: block;
    text-decoration: none;
    color: inherit;
}

.card-header {
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-letter {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--accent-color);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
}

.card-body {
    padding: 1.5rem;
}

.card-body h3 {
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.card-body p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.card-footer {
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.view-count {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.view-count i {
    color: var(--accent-color);
}

.thumbnail-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 5px;
    background-color: #000;
    overflow: hidden;
    /* prevents overflow if thumbnail is larger */
}

.thumbnail-container img {
    width: 100%;
    /* scale with container */
    height: 100%;
    max-height: 300px;
    /* adjust this limit */
    object-fit: cover;
    /* crop if needed */
    border-radius: 2px;
}

.video-card img {
    width: 100%;
    height: auto;
    display: block;
}

.video-card .content {
    padding: 0.75rem 1rem;
}

.video-card .title {
    font-weight: bold;
    margin-bottom: 0.5rem;
    font-size: 1rem;
    margin-top: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-card p {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    margin: 2px 0;
}

.content .duration,
.content .rating {
    display: inline-block;
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    margin-right: 0.5rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.6);
}

.content .rating {
    color: #4caf50;
    font-weight: 600;
}

.content .duration {
    color: #d4af37;
    font-weight: 600;
}

/* ===== MODERN FOOTER ===== */
footer {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.9));
    color: var(--light-color);
    padding: 3rem 0 2rem;
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}


.footer-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-content>p:first-child {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--accent-color);
    text-align: center;
    margin: 0;
}

.footer-content>p:nth-child(2) {
    line-height: 1.7;
    text-align: center;
    opacity: 0.9;
    max-width: 800px;
    margin: 0 auto;
    font-size: 0.95rem;
}

.footer-content nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content nav a {
    color: var(--light-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    padding: 0.5rem;
    border-radius: 4px;
}

.footer-content nav a:hover {
    color: var(--accent-color);
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.footer-content nav span {
    color: rgba(255, 255, 255, 0.3);
    margin: 0 0.25rem;
}

.page-title {
    font-size: 2.2rem;
    color: white;
    /* Your pink color */
    margin-bottom: 1.5rem;
    text-align: left;
    font-weight: 500;
    text-transform: capitalize;
}

.footer-content>p:last-child {
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.8;
    margin: 0;
}

#hitCount {
    font-weight: bold;
    color: var(--accent-color);
    font-size: 1.1rem;
}

/* Footer responsive design */
@media (max-width: 768px) {
    footer {
        padding: 2rem 0 1.5rem;
    }

    .footer-content {
        gap: 1.5rem;
    }

    .footer-content nav {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }

    .footer-content nav span {
        display: none;
    }

    .footer-content>p:nth-child(2) {
        font-size: 0.9rem;
        padding: 0 1rem;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    nav ul {
        gap: 1rem;
    }

    .filter-options {
        flex-direction: column;
        align-items: stretch;
    }

    .category-grid,
    .video-grid {
        grid-template-columns: 1fr;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

}

.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 768px) {
    .page-title {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }
}