:root {
    --bg: #050716;
    --neon-pink: #ff2bd6;
    --neon-blue: #00d9ff;
    --neon-purple: #8b5cf6;
    --text: #f8fbff;
    --bg-image: none;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    font-family: Inter, system-ui, sans-serif;
    overflow-x: hidden;

    background:
            linear-gradient(90deg, rgba(5,7,22,.96), rgba(5,7,22,.78), rgba(5,7,22,.92)),
            radial-gradient(circle at 20% 15%, rgba(255,43,214,.35), transparent 35%),
            radial-gradient(circle at 85% 10%, rgba(0,217,255,.25), transparent 32%),
            var(--bg-image),
            #050716;

    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* BLUR BACKGROUND */

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;

    background: var(--bg-image);
    background-size: cover;
    background-position: center;

    filter: blur(18px) brightness(.5);
    transform: scale(1.1);
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;

    background:
            linear-gradient(
                    180deg,
                    rgba(5,7,22,.25),
                    rgba(5,7,22,.85)
            );
}

/* HEADER */

h1 {
    position: sticky;
    top: 0;
    z-index: 20;

    margin: 0;
    padding: 20px 30px;

    font-size: clamp(28px, 4vw, 48px);
    text-transform: uppercase;

    backdrop-filter: blur(20px);

    background-color: rgba(5,7,22,.7);
    border-bottom: 1px solid rgba(255,43,214,.2);

    background-image:
            linear-gradient(
                    90deg,
                    var(--neon-blue),
                    var(--neon-pink)
            );

    -webkit-background-clip: text;
    color: transparent;
}

/* GRID */

.grid {
    display: grid;
    grid-template-columns:
            repeat(auto-fill, minmax(200px, 1fr));

    gap: 28px;
    padding: 40px;
}

/* CARD */

.card {
    cursor: pointer;

    padding: 10px;
    border-radius: 18px;

    border: 1px solid rgba(0,217,255,.2);

    background: rgba(255,255,255,.05);

    transition: .2s ease;
}

.card:hover {
    transform: scale(1.05);
    border-color: var(--neon-pink);
}

.card img {
    width: 100%;

    aspect-ratio: 2/3;

    object-fit: cover;

    border-radius: 14px;
}

.card-info {
    padding-top: 8px;
}

.card-info h3 {
    margin: 0;
    font-size: 15px;
}

.card-info p {
    margin: 4px 0 0;

    font-size: 12px;
    color: var(--neon-blue);
}

.card.focused {
    transform: scale(1.08);

    border-color: var(--neon-pink);

    box-shadow:
            0 0 40px rgba(255,43,214,.6),
            0 0 80px rgba(0,217,255,.3);

    z-index: 10;
}

/* PREVIEW PANEL */

.preview-panel {
    grid-column: span 3;

    display: grid;
    grid-template-columns: 1.2fr .8fr;

    gap: 20px;

    max-height: 0;
    opacity: 0;
    overflow: hidden;

    transform: translateY(-10px);

    transition: .3s ease;

    border-radius: 24px;

    background: rgba(10,12,35,.9);

    border:
            1px solid rgba(255,43,214,.3);
}

.preview-panel.active {
    max-height: none;
    min-height: 420px;
    opacity: 1;
    padding: 16px;
}
/* PREVIEW VIDEO */

.preview-video-wrap {
    border-radius: 18px;

    overflow: hidden;

    background: #000;

    min-height: 260px;
}

.preview-wide {
    width: 100%;
    height: 100%;

    object-fit: cover;
}

/* DETAILS */

.preview-details {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.preview-desc {
    font-size: 14px;
    color: #ddd;
    max-height: 190px;
    overflow-y: auto;
    line-height: 1.45;
}

.preview-meta {
    font-size: 12px;

    color: var(--neon-blue);

    letter-spacing: 2px;
}

.preview-details h2 {
    margin: 8px 0;

    font-size: 36px;

    font-family: "Maven Pro", sans-serif;
}

.preview-desc {
    font-size: 14px;
    color: #ddd;
}

.preview-actions {
    margin-top: 15px;

    display: flex;
    gap: 10px;
}

.preview-actions button {
    border: none;

    padding: 10px 18px;

    border-radius: 999px;

    cursor: pointer;

    font-weight: bold;
}

.play-main {
    background:
            linear-gradient(
                    90deg,
                    var(--neon-pink),
                    var(--neon-blue)
            );

    color: white;
}

.close-preview {
    background: rgba(255,255,255,.1);
    color: white;
}

/* PLAYER */

.player-modal {
    position: fixed;
    inset: 0;

    z-index: 99999;

    background: rgba(0,0,0,.96);

    display: none;

    align-items: center;
    justify-content: center;

    overflow: hidden;
}

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

/* VIDEOJS ROOT */

.video-js {
    width: 100vw !important;
    height: 100vh !important;

    background: black !important;
}

/* VIDEO ELEMENT */

.video-js video {
    width: 100% !important;
    height: 100% !important;

    object-fit: contain !important;
}

/* PLAYER */

#player {
    width: 100vw !important;
    height: 100vh !important;
}

/* FULLSCREEN FIX */

.video-js.vjs-fullscreen {
    width: 100vw !important;
    height: 100vh !important;
}

/* CONTROL BAR */

.vjs-control-bar {
    font-size: 14px;
}

/* BIG PLAY BUTTON */

.vjs-big-play-button {
    top: 50% !important;
    left: 50% !important;

    transform:
            translate(-50%, -50%) !important;
}

/* CLOSE BUTTON */

.close-player {
    position: fixed;

    top: 18px;
    right: 22px;

    z-index: 100000;

    width: 48px;
    height: 48px;

    border-radius: 999px;
    border: none;

    background: rgba(255,255,255,.12);

    color: white;

    font-size: 28px;

    cursor: pointer;

    backdrop-filter: blur(10px);
}

/* LOGIN */

.login-overlay {
    position: fixed;
    inset: 0;

    z-index: 9999;

    background: #050716;

    display: flex;

    align-items: center;
    justify-content: center;
}

.login-box {
    width: min(90vw, 360px);

    padding: 28px;

    border-radius: 20px;

    background: #0b1028;

    border: 1px solid #ff2bd6;

    text-align: center;
}

.login-box input {
    width: 100%;

    padding: 14px;

    margin-bottom: 12px;

    border-radius: 999px;

    border: 1px solid #00d9ff;

    background: #050716;

    color: white;
}

.login-box button {
    width: 100%;

    padding: 14px;

    border-radius: 999px;

    border: none;

    cursor: pointer;

    font-weight: bold;

    background:
            linear-gradient(
                    90deg,
                    var(--neon-pink),
                    var(--neon-blue)
            );

    color: white;
}

#loginError {
    color: #ff5c8a;
}

/* RESPONSIVE */

@media (max-width: 1100px) {
    .preview-panel {
        grid-column: span 2;
    }
}

@media (max-width: 700px) {
    .preview-panel {
        grid-column: 1 / -1;

        grid-template-columns: 1fr;
    }
}

.search-container {
    text-align: center;
    margin: 20px 0;
}

#searchInput {
    width: 50%;
    max-width: 500px;
    padding: 12px 25px;
    font-size: 16px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    outline: none;
    transition: all 0.3s ease;
}

#searchInput:focus {
    border-color: var(--neon-pink);
    box-shadow: 0 0 15px rgba(255, 43, 214, 0.4);
    width: 60%;
}