/*
 * Veiflix - Custom Style Customizations
 * Extends Tailwind CSS utilities with specialized Netflix components.
 */

:root {
    --brand-red: #ff4757;
    --brand-blue: #2e86de;
    --brand-bg: #0a0a0f;
    --brand-card: #13131f;
    --brand-gray: #1c1c2e;
    --text-white: #ffffff;
    --text-muted: #9ca3af;
}

/* Custom smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom premium scrollbar for body */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--brand-bg);
}
::-webkit-scrollbar-thumb {
    background: #2a2a3e;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--brand-red);
}

/* Hide default horizontal scrollbar in lists but support scrolling */
.scrollbar-hide::-webkit-scrollbar {
    display: none;
}
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Custom styles for card sliders */
.mylist {
    scroll-snap-type: x mandatory;
    scroll-padding: 0 10px;
    scrollbar-width: none; /* Firefox */
}
.mylist::-webkit-scrollbar {
    display: none; /* Safari and Chrome */
}

/* Card image transitions for lazy load */
.lesprofiles {
    transition: opacity 0.4s ease, transform 0.4s ease;
}
.loaded {
    opacity: 1 !important;
}

/* Skeleton animation */
@keyframes pulse-bg {
    0% {
        background-color: rgba(28, 28, 46, 0.4);
    }
    50% {
        background-color: rgba(44, 44, 70, 0.7);
    }
    100% {
        background-color: rgba(28, 28, 46, 0.4);
    }
}

.skeleton-card div {
    animation: pulse-bg 1.5s infinite ease-in-out;
}

/* Custom keyframes */
@keyframes bounce-subtle {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}
.animate-bounce-subtle {
    animation: bounce-subtle 3s infinite ease-in-out;
}

/* Navigation layout adjustments */
.menu-Alfa li a {
    position: relative;
    padding-bottom: 6px;
    color: #9ca3af;
    font-weight: 500;
}
.menu-Alfa li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    border-radius: 9999px;
    background-color: var(--brand-red);
    box-shadow: 0 0 10px var(--brand-red);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.menu-Alfa li a:hover::after,
.menu-Alfa li a.active-nav-item::after {
    width: 100%;
}
.menu-Alfa li a.active-nav-item {
    color: #ffffff !important;
    text-shadow: 0 0 8px rgba(255, 71, 87, 0.4);
}

/* Glassmorphism search input styling */
#search-nav-input {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
#search-nav-input:focus {
    box-shadow: 0 0 20px rgba(255, 71, 87, 0.15), inset 0 2px 4px rgba(0, 0, 0, 0.6);
}

/* Suggestions Dropdown Premium Styling */
#search-suggestions {
    background-color: rgba(19, 19, 31, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1rem;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}
#search-suggestions::-webkit-scrollbar {
    width: 6px;
}
#search-suggestions::-webkit-scrollbar-track {
    background: transparent;
}
#search-suggestions::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 99px;
}
#search-suggestions::-webkit-scrollbar-thumb:hover {
    background: var(--brand-red);
}

/* Premium Sidebar Link Styling */
.sidebar-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}
.sidebar-link:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.05);
}
.sidebar-link.active-sidebar-item {
    color: var(--brand-red) !important;
    background-color: rgba(255, 71, 87, 0.08);
    font-weight: 600;
}
.sidebar-link.active-sidebar-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 25%;
    height: 50%;
    width: 3px;
    background-color: var(--brand-red);
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 8px var(--brand-red);
}

/* Scroll Offset for Navigation anchors */
[id] {
    scroll-margin-top: 5.5rem;
}

/* Back to Top button shadow hover */
#back-to-top-btn:hover {
    box-shadow: 0 10px 15px -3px rgba(255, 71, 87, 0.4);
    transform: scale(1.05);
}

/* Custom detail backdrop hero overlay */
.backdrop-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, var(--brand-bg) 5%, rgba(10, 10, 15, 0.4) 60%, rgba(10, 10, 15, 0.8) 100%);
    z-index: 1;
}

/* Modal video iframe wrapper */
#trailer-modal iframe {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
}

/* Custom star rating inputs style (if any) */
.star-rating-display {
    color: #ffb81c;
}

/* Smooth zoom transition on list items */
.animelistitems {
    will-change: transform;
}

/* Dynamic details header blur */
.glass-header {
    background-color: rgba(19, 19, 31, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Premium select dropdowns (Season / Episode) */
.veiflix-select {
    padding-right: 2.25rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%239ca3af' stroke-width='2.5' viewBox='0 0 24 24'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19.5 8.25l-7.5 7.5-7.5-7.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 14px 14px;
}
.veiflix-select:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23ffffff' stroke-width='2.5' viewBox='0 0 24 24'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19.5 8.25l-7.5 7.5-7.5-7.5'/%3E%3C/svg%3E");
}
.veiflix-select option {
    background-color: #13131f;
    color: #ffffff;
    padding: 8px 12px;
}
