/* =====================================
   Short Drama Website - Integrated Custom Styles File
   Contains: Font Configuration, UI Styles, Animation Effects, Layout Styles
   ===================================== */

/* ===== Font Configuration - IMDB Style ===== */
/* IMDB-like font configuration */
:root {
  --font-primary: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --font-secondary: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

body {
  font-family: var(--font-primary);
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Typography improvements - IMDB style */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

/* Navigation and UI elements */
nav, .nav, .menu {
  font-family: var(--font-primary);
  font-weight: 500;
}

/* Content text - Set normal font weight */
p, span, div {
  font-family: var(--font-primary);
  font-weight: 400; /* Set to normal weight */
}

/* Links should be normal weight unless specified */
a {
  font-family: var(--font-primary);
  font-weight: 400;
}

/* Button styling like IMDB */
button, .btn {
  font-family: var(--font-primary);
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* IMDB-style font weights */
.font-light {
  font-weight: 300;
}

.font-regular {
  font-weight: 400;
}

.font-medium {
  font-weight: 500;
}

.font-semibold {
  font-weight: 600;
}

.font-bold {
  font-weight: 700;
}

/* Specific improvements for readability */
.text-sm {
  font-size: 0.875rem;
  line-height: 1.4;
  font-weight: 400;
}

.text-base {
  font-size: 1rem;
  line-height: 1.6;
  font-weight: 400;
}

.text-lg {
  font-size: 1.125rem;
  line-height: 1.5;
  font-weight: 400;
}

/* IMDB-style improvements */
.imdb-title {
  font-weight: 600;
  letter-spacing: -0.02em;
}

.imdb-subtitle {
  font-weight: 500;
  opacity: 0.9;
}

.imdb-description {
  line-height: 1.7;
  font-weight: 400;
}

/* Rating and metadata styling */
.rating, .meta {
  font-weight: 500;
  font-size: 0.9rem;
}

/* Normal text weight for common elements */
li, td, th, label, input, textarea, select {
  font-weight: 400;
}

/* Ensure crisp text rendering on all devices */
* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ===== Navigation and Page Layout Styles ===== */
#sticky-header {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

#sticky-header.scrolled {
    background: rgba(17, 24, 39, 0.95);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.neon-text {
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.2),
        0 0 16px rgba(255, 255, 255, 0.2), 0 0 24px rgba(255, 192, 203, 0.1),
        0 0 32px rgba(255, 105, 180, 0.1);
}

/* ===== Button Animation Effects ===== */
button[data-modal-target="trailer-modal"] svg {
    animation: pulse-play 1.5s infinite;
}

@keyframes pulse-play {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* ===== Search Results Styles ===== */
#search-results-desktop {
    overflow-x: hidden;
}

#search-results-mobile {
    max-width: 100%;
    overflow-x: hidden;
}

#search-results-desktop a,
#search-results-mobile a {
    text-decoration: none;
    color: inherit;
}

#search-results-desktop a:hover,
#search-results-mobile a:hover {
    background-color: #f3f4f6;
}

.dark #search-results-desktop a:hover,
.dark #search-results-mobile a:hover {
    background-color: #374151;
}

/* ===== Notification and Tooltip Styles ===== */
#toast-container > div {
    -moz-box-shadow: 0 0 2px #999999;
    -webkit-box-shadow: 0 0 2px #999999;
    box-shadow: 0 0 2px #999999;
}

[x-cloak] {
    display: none !important;
}

/* ===== Image Lazy Loading Styles ===== */
img.lozad {
    opacity: 0;
    transition: opacity 0.3s ease;
    object-fit: cover;
}

.lozad.loaded {
    opacity: 1;
}

/* Style du placeholder */
img.lozad[src*="data:image/svg"] {
    height: 100%;
}

/* Fade in animation for lazy loaded images */
.fade-in {
    opacity: 1 !important;
    transition: opacity 0.5s ease-in-out;
}

/* ===== Media Player Styles ===== */
@media screen and (max-width: 768px) {
    .plyr__volume input[type=range]{
        display: none;
    }
}

/* Video player common styles */
.video-player {
    max-height: 85vh;
    width: 100%;
    object-fit: contain;
}

/* Video container 16:9 aspect ratio */
.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
}

/* ===== Swiper Carousel Styles ===== */
.trending-dramas {
    margin-left: auto;
    margin-right: auto;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.swiper-button-prev,
.swiper-button-next {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    box-shadow: 1px 4px 10px 0 rgba(42, 44, 50, .16);
    background-color: #fff;
    color: #757A84;
    font-weight: 700;
}

.swiper-button-prev:hover,
.swiper-button-next:hover {
    color: #FA320A;
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 16px;
}

.swiper-slide-duplicate .description,
.swiper-slide-duplicate .title,
.swiper-slide .description,
.swiper-slide .title {
  display: block;
  opacity: 0;
  transition: 0.5s ease 0.5s;
}

.swiper-slide-duplicate-active .description,
.swiper-slide-duplicate-active .title,
.swiper-slide-active .description,
.swiper-slide-active .title {
  opacity: 1;
}

.swiper-slide-duplicate-active .title,
.swiper-slide-active .title {
  margin-bottom: 0.5rem;
  font-size: 24px;
  color: #fff;
  transition: opacity 0.5s ease 0.5s;
}

.swiper-slide-duplicate-active .description,
.swiper-slide-active .description {
  font-size: 16px;
  color: #fff;
  transition: opacity 0.5s ease 0.75s;
}

/* ===== Image Gallery Styles ===== */
.gallery-top {
  height: 55vh;
}

@media screen and (max-width: 768px) {
  .gallery-top {
    height: 40vh;
  }
}

.gallery-thumbs {
  height: 55vh;
}

.gallery-thumbs .swiper-wrapper {
  flex-direction: row;
}

@media (min-width: 480px) {
  .gallery-thumbs .swiper-wrapper {
    flex-direction: column;
  }
}

.gallery-thumbs .swiper-slide {
  width: 25%;
  flex-flow: row nowrap;
  height: 100%;
  opacity: 0.75;
  cursor: pointer;
}

@media (min-width: 480px) {
  .gallery-thumbs .swiper-slide {
    flex-flow: column nowrap;
    width: 100%;
  }
}

.gallery-thumbs .swiper-slide-thumb-active {
  opacity: 1;
}

.gallery-thumbs .swiper-slide-thumb-active .drama-title{
    color: #dc2626;
    font-weight: bold;
}

.gallery-thumbs .swiper-slide-thumb-active .drama-summary{
    color: #2a2c32;
}

/* ===== Shadow and Background Styles ===== */
.shadow-sm{
    box-shadow: rgba(28, 28, 30, 0.06) 0px 0px 28px 0px;
    -webkit-box-shadow: rgba(28, 28, 30, 0.06) 0px 0px 28px 0px;
}

/* Background image styles */
.bg-login {
    background-image: url('/assets/images/bg_login.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.bg-placeholder {
    background-color: #3434358a;
}

.bg-gray-placeholder {
    background-color: #f3f4f6;
}

/* ===== Rating and Progress Bar Styles ===== */
.rating-display {
    font-size: 1rem;
    font-weight: 400;
}

/* Progress bar styles */
.progress-bar-custom {
    height: 2.5px;
    border-radius: 9999px;
    transition: width 0.3s ease;
}

/* ===== Text Truncation Utility Classes ===== */
.line-clamp-1 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
}

.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

/* ===== Scrollbar Styles ===== */
.scrollbar-none {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.scrollbar-none::-webkit-scrollbar {
    display: none;
}

/* Thumbnail container styles */
.thumbnail-slider-container {
    height: calc(100% - 30px);
    overflow: hidden;
}

/* ===== Form and Input Styles ===== */
.form-control-custom {
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control-custom:focus {
    border-color: #dc2626;
    box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.25);
}

/* ===== Modal and Popup Styles ===== */
.modal-content-custom {
    border-radius: 0.75rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* ===== Hide/Show Utility Classes ===== */
.hidden-custom {
    display: none !important;
}

.block-custom {
    display: block !important;
}

/* ===== File Preview Styles ===== */
.thumbnail-preview {
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.thumbnail-preview:hover {
    opacity: 0.8;
}

/* Image preview */
.image-preview {
    max-height: 400px;
    max-width: 100%;
    object-fit: contain;
}

/* Video preview */
.video-preview {
    max-height: 400px;
    max-width: 100%;
}

/* ===== Loading Indicator ===== */
.loading-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Card and Layout Styles ===== */
.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* ===== Admin Panel Special Styles ===== */
.admin-preview-container {
    max-height: 400px;
    overflow-y: auto;
}

.admin-color-preview {
    width: 40px;
    height: 40px;
    border-radius: 0.375rem;
    border: 2px solid #e5e7eb;
}

.admin-image-preview {
    height: 120px;
    object-fit: cover;
    border-radius: 0.375rem;
}

/* File manager styles */
.file-manager-input {
    max-width: 350px;
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
    .mobile-hidden {
        display: none;
    }
    
    .mobile-full-width {
        width: 100%;
    }
}

@media (min-width: 769px) {
    .desktop-hidden {
        display: none;
    }
}

/* ===== Print Styles ===== */
@media print {
    .no-print {
        display: none !important;
    }
}

/* ===== Accessibility Styles ===== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus style improvements */
.focus-visible:focus {
    outline: 2px solid #dc2626;
    outline-offset: 2px;
}

/* Fix Swiper Container Width Issue */
.flex-1.relative {
    min-width: 0 !important;
    max-width: 100% !important;
    overflow: hidden;
}

nav .flex-1.relative {
    overflow: visible !important;
}

#sticky-header .flex-1 {
    overflow: visible !important;
}

.hero-slider {
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
}

.hero-slider .swiper-wrapper {
    width: 100% !important;
    transform: translate3d(0px, 0px, 0px) !important;
}

.hero-slider .swiper-slide {
    width: 100% !important;
    flex-shrink: 0 !important;
    display: block !important;
}

/* Hero Slider Navigation */
.hero-nav-btn {
    background: rgba(0, 0, 0, 0.6) !important;
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    margin-top: -20px !important;
    color: white !important;
    transition: all 0.3s ease !important;
    backdrop-filter: blur(4px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    z-index: 10 !important;
    cursor: pointer !important;
    pointer-events: auto !important;
    position: absolute !important;
}

.hero-nav-btn:hover {
    background: rgba(0, 0, 0, 0.8) !important;
    color: rgb(220, 38, 38) !important;
    transform: scale(1.1);
    border-color: rgba(220, 38, 38, 0.3);
}

.hero-nav-btn:after {
    font-size: 14px !important;
    font-weight: 600 !important;
}

.hero-slider .swiper-slide {
    pointer-events: none;
}

.hero-slider .swiper-slide-active {
    pointer-events: auto !important;
    z-index: 10 !important;
}

.hero-slider .swiper-slide:not(.swiper-slide-active) {
    pointer-events: none !important;
    z-index: 1 !important;
}

.hero-slider.swiper-container-fade .swiper-slide {
    pointer-events: none;
}

.hero-slider.swiper-container-fade .swiper-slide-active {
    pointer-events: auto;
}

/* Ensure arrow buttons are not blocked by other elements */
.swiper-button-next.hero-nav-btn {
    right: 10px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.swiper-button-prev.hero-nav-btn {
    left: 10px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Ensure arrow icons are visible */
.hero-nav-btn:after {
    position: static !important;
    line-height: 1 !important;
}

/* Thumbnail Container */
.thumbnail-slider-container::-webkit-scrollbar {
    width: 4px;
}

.thumbnail-slider-container::-webkit-scrollbar-track {
    background: transparent;
}

.thumbnail-slider-container::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.3);
    border-radius: 2px;
}

.thumbnail-slider-container::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.5);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .thumbnail-slider-container {
        display: flex;
        flex-direction: row;
        overflow-x: auto;
        overflow-y: hidden;
        gap: 12px;
        padding-bottom: 8px;
    }
    
    .thumbnail-item {
        flex-shrink: 0;
        width: 280px;
    }
    
    .space-y-3 {
        display: flex;
        gap: 12px;
    }
    
    .space-y-3 > * + * {
        margin-top: 0;
    }
}

@media (max-width: 768px) {
    .hero-nav-btn {
        width: 35px !important;
        height: 35px !important;
        margin-top: -17px !important;
    }
    
    .hero-nav-btn:after {
        font-size: 12px !important;
    }
}

/* Utility Classes */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Enhanced animations */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-slider .swiper-slide-active .max-w-md > * {
    animation: slideIn 0.6s ease-out forwards;
}

/* Loading state */
.swiper-container.swiper-container-initialized .swiper-slide:not(.swiper-slide-visible) img {
    filter: blur(2px);
    transition: filter 0.3s ease;
}

.swiper-container.swiper-container-initialized .swiper-slide.swiper-slide-visible img {
    filter: none;
}

.explore-dropdown {
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.explore-dropdown a {
    transition: all 0.15s ease-in-out;
}

.explore-dropdown a:hover {
    background-color: #f8fafc;
    color: #1f2937;
    padding-left: 1.25rem;
}

.dropdown-arrow {
    transition: transform 0.2s ease-in-out;
}

.dropdown-open .dropdown-arrow {
    transform: rotate(180deg);
}

@media (max-width: 1024px) {
    .mobile-explore-menu {
        background-color: rgba(0, 0, 0, 0.05);
        border-left: 3px solid #3b82f6;
    }
}

/* Active thumbnail styling */
[data-slide].active {
    background: white !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.aspect-\[4\/3\] {
    aspect-ratio: 4 / 3;
}

#sticky-header {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #111827;
}

#sticky-header.scrolled {
    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

#sticky-header a[href="/"] img {
    transition: all 0.3s ease;
}

#sticky-header a[href="/"]:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.search-input-enhanced:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

#mobile-search-container {
    transform: translateY(-100%);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-search-container.show {
    transform: translateY(0);
    opacity: 1;
}

.dropdown-menu-enhanced {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 
        0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 10px 10px -5px rgba(0, 0, 0, 0.04),
        0 0 0 1px rgba(255, 255, 255, 0.05);
}

#mobile-menu {
    transform: translateY(-20px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-menu.show {
    transform: translateY(0);
    opacity: 1;
    display: block !important;
}

#mobile-menu.hidden {
    display: none;
}

@media (min-width: 1024px) {
    #mobile-menu {
        display: none !important;
    }
}

@media (min-width: 1024px) {
    .mobile-menu-toggle,
    #menu-toggle {
        display: none !important;
    }
}

.btn-enhanced {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-enhanced::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.5s ease;
}

.btn-enhanced:hover::before {
    width: 200%;
    height: 200%;
}

.btn-enhanced:active {
    transform: scale(0.98);
}

.notification-badge {
    animation: pulse-notification 2s infinite;
}

@keyframes pulse-notification {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.9;
    }
}

.language-selector {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.language-selector:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.search-results-container {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-results-container.show {
    max-height: 24rem;
}

.search-results-container::-webkit-scrollbar {
    width: 6px;
}

.search-results-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.search-results-container::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.3);
    border-radius: 3px;
}

.search-results-container::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.5);
}

@media (max-width: 640px) {
    #sticky-header nav {
        padding: 0.5rem 1rem;
    }
    
    .logo img {
        height: 1.5rem;
    }
}

@media (max-width: 768px) {
    .desktop-search {
        display: none;
    }
    
    .mobile-search-toggle {
        display: block;
    }
}

@media (min-width: 769px) {
    .mobile-search-toggle {
        display: none;
    }
    
    #mobile-search-container {
        display: none !important;
    }
}

@media (max-width: 1023px) {
    .desktop-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@media (prefers-color-scheme: dark) {
    .dropdown-menu-enhanced {
        background: rgba(31, 41, 55, 0.95);
        border-color: rgba(75, 85, 99, 0.3);
    }
    
    .search-results-container {
        background: rgba(31, 41, 55, 0.95);
        border-color: rgba(75, 85, 99, 0.3);
    }
}

.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.interactive-element {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.interactive-element:hover {
    transform: translateY(-1px);
}

.interactive-element:active {
    transform: translateY(0);
}

.focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
    border-radius: 0.375rem;
}

.menu-icon {
    transition: transform 0.3s ease;
}

.menu-icon.active {
    transform: rotate(180deg);
}

.premium-button {
    background: linear-gradient(45deg, #f59e0b, #d97706);
    position: relative;
    overflow: hidden;
}

.premium-button::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.5s ease;
    opacity: 0;
}

.premium-button:hover::after {
    animation: premium-shine 0.8s ease-in-out;
}

@keyframes premium-shine {
    0% {
        transform: rotate(45deg) translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: rotate(45deg) translateX(100%);
        opacity: 0;
    }
}

#search-results-desktop,
#search-results-mobile {
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    border-radius: 1rem !important;
    border: 1px solid #e5e7eb !important;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04) !important;
    z-index: 9999 !important;
    position: absolute !important;
    margin: 0 !important;
    background-color: #ffffff !important;
    max-height: 24rem !important;
    margin-top: 0.25rem !important;
}

#search-results-mobile {
    top: 3.5rem !important; /* 14 * 0.25rem = 3.5rem */
    max-height: 20rem !important;
}

#search-results-desktop.show,
#search-results-mobile.show {
    opacity: 1;
    transform: translateY(0);
}

#search-results-desktop a,
#search-results-mobile a {
    display: flex;
    align-items: center;
    padding: 1rem !important;
    margin: 0 !important;
    border-bottom: 1px solid #f3f4f6;
    transition: background-color 0.15s ease;
    text-decoration: none;
}

#search-results-desktop a:last-child:not([href*="/search"]),
#search-results-mobile a:last-child:not([href*="/search"]) {
    border-bottom: none;
}

#search-results-desktop a:hover,
#search-results-mobile a:hover {
    background-color: #f9fafb !important;
}

#search-results-desktop img,
#search-results-mobile img {
    width: 3rem !important; /* w-12 = 48px */
    height: 4rem !important; /* h-16 = 64px */
    object-fit: cover;
    border-radius: 0.5rem; /* rounded-lg */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-right: 1rem;
    flex-shrink: 0;
}

#search-results-desktop h3,
#search-results-mobile h3 {
    font-size: 0.875rem !important; /* text-sm */
    font-weight: 500 !important; /* font-medium */
    color: #111827 !important; /* text-gray-900 */
    line-height: 1.25rem;
    margin-bottom: 0.25rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#search-results-desktop p,
#search-results-mobile p {
    font-size: 0.75rem !important; /* text-xs */
    color: #6b7280 !important; /* text-gray-500 */
    line-height: 1rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#search-results-desktop a[href*="/search"],
#search-results-mobile a[href*="/search"] {
    border-top: 1px solid #e5e7eb !important;
    border-bottom: none !important;
    margin-top: 0 !important;
    padding: 1rem !important;
    color: #dc2626 !important;
    font-weight: 500 !important; /* font-medium */
    justify-content: center !important;
    background-color: #f8fafc !important; /* bg-slate-50 */
    font-size: 0.875rem !important;
}

#search-results-desktop a[href*="/search"]:hover,
#search-results-mobile a[href*="/search"]:hover {
    background-color: #dbeafe !important; /* hover:bg-blue-50 */
}

#search-results-desktop .loading-skeleton,
#search-results-mobile .loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

.line-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

nav .flex-1.relative {
    overflow: visible !important;
}

#sticky-header .flex-1 {
    overflow: visible !important;
}

nav .flex-1.relative form {
    position: relative;
}

#search-results-desktop::-webkit-scrollbar,
#search-results-mobile::-webkit-scrollbar {
    width: 6px;
}

#search-results-desktop::-webkit-scrollbar-track,
#search-results-mobile::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 3px;
}

#search-results-desktop::-webkit-scrollbar-thumb,
#search-results-mobile::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

#search-results-desktop::-webkit-scrollbar-thumb:hover,
#search-results-mobile::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

nav form input[type="text"]:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

@media (max-width: 768px) {
    #search-results-mobile {
        max-width: calc(100vw - 2rem);
        left: 1rem !important;
        right: 1rem !important;
        width: auto !important;
    }
}