/* style.css - Mise à jour avec barre de recherche et scroll infini */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;700&display=swap');

:root {
    --bg-dark: #080808;
    --card-bg: #121212;
    --text-main: #ffffff;
    --text-muted: #888888;
    --accent: #ff0000;
    --hover-bg: #1a1a1a;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    margin: 0;
    padding: 0;
    padding-top: 100px;
}

/* Header */
header {
    background: rgba(8, 8, 8, 0.95);
    backdrop-filter: blur(15px);
    height: 80px;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 4%;
    box-sizing: border-box;
    z-index: 1000;
    border-bottom: 2px solid #111;
}

.logo {
    font-size: 20px;
    font-weight: 800;
    color: #fff;
    text-decoration: none;
    flex-shrink: 0;
}

.logo span {
    background: var(--accent);
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 4px;
}

/* Barre de recherche */
.search-container {
    flex-grow: 1;
    max-width: 600px;
    margin: 0 40px;
    position: relative;
}

#searchInput {
    width: 100%;
    background: #151515;
    border: 1px solid #333;
    border-radius: 25px;
    padding: 12px 25px;
    color: #fff;
    font-size: 15px;
    outline: none;
    transition: all 0.3s ease;
}

#searchInput:focus {
    border-color: var(--accent);
    background: #1a1a1a;
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.1);
}

/* Grille */
.container {
    max-width: 1800px;
    margin: 0 auto;
    padding: 0 20px 60px 20px;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

/* Cartes Vidéo */
.video-card {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    border: 1px solid #1a1a1a;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    border-color: #333;
}

.thumb-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
}

.thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.duration-tag {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.8);
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
}

.info-box {
    padding: 15px;
}

.video-title {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 10px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.meta-row {
    font-size: 13px;
    color: var(--text-muted);
}

/* Loader */
#loader {
    text-align: center;
    padding: 40px;
    grid-column: 1 / -1;
    color: var(--text-muted);
    font-size: 14px;
}

@media (max-width: 768px) {
    .search-container { margin: 0 10px; }
    .logo { font-size: 16px; }
}
