/* ============================================
   FLOOZENUploader - ОСНОВНЫЕ СТИЛИ
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #0a0a0f;
    color: #e5e7eb;
    min-height: 100vh;
}

/* ============ HEADER ============ */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 40px;
    background: rgba(10, 10, 15, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(124, 58, 237, 0.2);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo-link {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: opacity 0.3s;
}

.logo-link:hover {
    opacity: 0.8;
}

.logo {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 24px;
    font-weight: 700;
}

.logo i {
    font-size: 28px;
    color: #7c3aed;
    text-shadow: 0 0 30px rgba(124, 58, 237, 0.5);
    margin-right: 8px;
}

.logo .main-name {
    background: linear-gradient(135deg, #7c3aed, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo .sub-name {
    font-weight: 300;
    color: #a78bfa;
    font-size: 18px;
    margin-left: 4px;
}

nav {
    display: flex;
    align-items: center;
    gap: 30px;
}

nav a {
    color: #9ca3af;
    text-decoration: none;
    font-size: 15px;
    transition: color 0.3s;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
}

nav a:hover,
nav a.active {
    color: #a78bfa;
    border-bottom-color: #7c3aed;
}

.auth-btn {
    background: #7c3aed;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-btn:hover {
    background: #6d28d9;
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(124, 58, 237, 0.4);
}

/* ============ HERO ============ */
.hero {
    text-align: center;
    padding: 60px 20px 40px;
    background: radial-gradient(ellipse at center top, rgba(124, 58, 237, 0.15), transparent 70%);
}

.hero h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #fff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    color: #9ca3af;
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 40px;
}

.stat {
    text-align: center;
}

.stat .num {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: #a78bfa;
}

.stat .label {
    color: #6b7280;
    font-size: 14px;
}

/* ============ GALLERY ============ */
.gallery {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.gallery-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.gallery-header h2 {
    font-size: 24px;
    color: #e5e7eb;
}

.filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    background: rgba(124, 58, 237, 0.1);
    color: #9ca3af;
    border: 1px solid rgba(124, 58, 237, 0.2);
    padding: 6px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 13px;
}

.filter-btn:hover {
    background: rgba(124, 58, 237, 0.2);
    color: #a78bfa;
}

.filter-btn.active {
    background: #7c3aed;
    color: white;
    border-color: #7c3aed;
}

.filter-btn i {
    margin-right: 4px;
}

/* ============ FILES GRID ============ */
.files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

.file-card {
    background: rgba(20, 20, 30, 0.8);
    border-radius: 12px;
    border: 1px solid rgba(124, 58, 237, 0.15);
    overflow: hidden;
    transition: all 0.3s;
    cursor: pointer;
}

.file-card:hover {
    border-color: #7c3aed;
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(124, 58, 237, 0.15);
}

.file-card .preview {
    width: 100%;
    height: 180px;
    background: #111118;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.file-card .preview img,
.file-card .preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-card .preview .file-icon {
    font-size: 48px;
    color: #7c3aed;
}

.file-card .file-info {
    padding: 14px 16px;
}

.file-card .file-info .name {
    font-size: 15px;
    font-weight: 500;
    color: #e5e7eb;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-card .file-info .meta {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 12px;
    color: #6b7280;
}

.file-card .file-info .meta .type-badge {
    background: rgba(124, 58, 237, 0.2);
    padding: 2px 10px;
    border-radius: 12px;
    color: #a78bfa;
}

.file-card .file-info .meta .views {
    display: flex;
    align-items: center;
    gap: 4px;
}

.loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 0;
    color: #6b7280;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
    header {
        padding: 12px 16px;
        flex-wrap: wrap;
        gap: 12px;
    }
    
    nav {
        width: 100%;
        justify-content: space-between;
        gap: 12px;
    }
    
    nav a {
        font-size: 13px;
    }
    
    .hero h1 {
        font-size: 28px;
    }
    
    .hero p {
        font-size: 15px;
    }
    
    .stats {
        gap: 30px;
        flex-wrap: wrap;
    }
    
    .stat .num {
        font-size: 28px;
    }
    
    .files-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 18px;
    }
    
    .logo i {
        font-size: 20px;
    }
    
    .logo .sub-name {
        font-size: 14px;
    }
    
    .auth-btn {
        padding: 6px 14px;
        font-size: 12px;
    }
}
/* ============================================
   БЛЮР ДЛЯ ПРЕВЬЮ
   ============================================ */

/* По умолчанию — всё размыто */
.file-card .preview video,
.file-card .preview img {
    filter: blur(25px);
    transition: filter 0.4s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* При наведении — размытие убирается */
.file-card:hover .preview video,
.file-card:hover .preview img {
    filter: blur(0);
}

/* Картинки не размываем (они обычно безопасны) */
.file-card .preview img {
    filter: blur(0);
}

.file-card:hover .preview img {
    filter: blur(0);
}

/* ============================================
   БЛЮР ДЛЯ ПРЕВЬЮ В ГАЛЕРЕЕ
   ============================================ */
.file-card .preview img {
    filter: blur(25px);
    transition: filter 0.4s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-card:hover .preview img {
    filter: blur(0);
}

/* Плейсхолдер для видео (если нет миниатюры) */
.file-card .preview .video-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: #0a0a0f;
    font-size: 48px;
    color: #7c3aed;
    filter: blur(20px);
    transition: filter 0.4s ease;
}

.file-card:hover .preview .video-placeholder {
    filter: blur(0);
}