/* ==========================================================================
   FindPhotoByFace - Custom Styles
   ========================================================================== */

/* Base & Utilities */
html.dark {
    color-scheme: dark;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Glassmorphism & Cards */
.glass-nav {
    background: rgba(2, 6, 23, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.glass-dropdown {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Gradients & Animations */
.hero-gradient {
    background: radial-gradient(circle at top center, rgba(168, 85, 247, 0.15) 0%, rgba(2, 6, 23, 0) 60%);
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

.animate-fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-scale-in {
    animation: scaleIn 0.3s ease-out forwards;
}

.animation-delay-100 { animation-delay: 100ms; }
.animation-delay-200 { animation-delay: 200ms; }
.animation-delay-300 { animation-delay: 300ms; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

/* Floating Particles Background */
.particle {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    animation: float 20s infinite ease-in-out;
    opacity: 0.5;
}
.particle-1 {
    width: 300px; height: 300px;
    background: rgba(168, 85, 247, 0.15); /* primary-500 */
    top: -100px; left: -100px;
}
.particle-2 {
    width: 250px; height: 250px;
    background: rgba(59, 130, 246, 0.1); /* blue-500 */
    bottom: 20%; right: -50px;
    animation-delay: -5s;
}
.particle-3 {
    width: 200px; height: 200px;
    background: rgba(236, 72, 153, 0.1); /* pink-500 */
    top: 30%; left: 30%;
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(30px, -50px); }
    66% { transform: translate(-20px, 20px); }
}

/* Form Elements */
input:-webkit-autofill,
input:-webkit-autofill:hover, 
input:-webkit-autofill:focus, 
input:-webkit-autofill:active{
    -webkit-box-shadow: 0 0 0 30px #1e293b inset !important;
    -webkit-text-fill-color: white !important;
    transition: background-color 5000s ease-in-out 0s;
}

/* Nav & Sidebar Links */
.nav-link {
    @apply text-sm font-medium text-gray-300 hover:text-white transition-colors py-2;
}

.sidebar-link {
    @apply flex items-center gap-3 px-3 py-2.5 rounded-xl text-sm font-medium text-gray-400 hover:text-white hover:bg-white/5 transition-all;
}
.sidebar-link.active {
    @apply bg-primary-500/10 text-primary-400 font-semibold;
}

/* Photo Grid */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
}
@media (min-width: 640px) {
    .photo-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1.5rem; }
}
@media (min-width: 1024px) {
    .photo-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
}

.photo-item::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 0.75rem;
    pointer-events: none;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.1);
}

/* Dropzone Overrides */
.dropzone {
    min-height: 200px;
}
.dropzone.dz-drag-hover {
    border-color: #a855f7 !important;
    background: rgba(168, 85, 247, 0.05) !important;
}
.dropzone .dz-preview.dz-image-preview {
    background: transparent;
}
.dropzone .dz-preview .dz-image {
    border-radius: 0.75rem;
    z-index: 0;
}
.dropzone .dz-preview:hover .dz-image img {
    transform: scale(1.05);
    filter: blur(8px);
}
.dropzone .dz-preview .dz-details {
    opacity: 1;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    z-index: 2;
    padding: 1em;
}
.dropzone .dz-preview .dz-success-mark, .dropzone .dz-preview .dz-error-mark {
    z-index: 3;
}
.dropzone .dz-preview .dz-error-message {
    top: 140px;
}
