/* 
  Design System - Télévie Qu4tre 2026 
  Inspiré de : https://24h-televie.be/fr-FR/inscrivez-vous
*/

:root {
    /* Couleurs Télévie officielles / inspirées */
    --televie-red: #e30613;
    --televie-orange: #EB5228;
    --televie-yellow: #f9b233;
    --televie-dark: #121212;
    --televie-darker: #0a0a0a;
    --televie-light: #ffffff;
    --televie-gray: #f2f2f2;
    --televie-text-muted: #555555;
    /* Assombri pour fond clair */

    /* Variables de design - Thème CLAIR */
    --bg-color: var(--televie-light);
    --text-color: #333333;
    --primary: var(--televie-orange);
    --secondary: var(--televie-red);

    /* Typographie moderne */
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Outfit', 'Inter', system-ui, sans-serif;

    /* Espacements & Rayons */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-pill: 9999px;
    --spacing-section: 80px;

    /* Effets Glassmorphism Light */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.05);
    --glass-blur: blur(12px);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.05);
}

/* Base */
body,
html {
    margin: 0;
    padding: 0;
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    font-weight: 700;
    margin-top: 0;
    line-height: 1.2;
    color: var(--televie-dark);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--secondary);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Layout */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

section {
    padding: var(--spacing-section) 0;
    position: relative;
}

/* Header & Nav */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    padding: 15px 0;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo-qu4tre {
    height: 40px;
}

.logo-televie {
    height: 40px;
}

/* Boutons (CTA) */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: var(--radius-pill);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.1rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--televie-orange) 0%, var(--televie-red) 100%);
    color: white !important;
    box-shadow: 0 4px 15px rgba(227, 6, 19, 0.2);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 25px rgba(227, 6, 19, 0.4);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 80px;
    /* offset header */
    background: radial-gradient(circle at 50% 30%, rgba(227, 6, 19, 0.05) 0%, rgba(255, 255, 255, 1) 70%);
    text-align: center;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    margin-bottom: 20px;
    background: linear-gradient(135deg, var(--televie-dark) 0%, #444 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p.lead {
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    color: var(--televie-text-muted);
    max-width: 800px;
    margin: 0 auto 40px auto;
}

/* Video Hero */
.video-hero-container {
    margin: 0 auto 30px auto;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    max-width: 640px;
    width: 100%;
    position: relative;
    line-height: 0;
    /* Élimine l'espace pour les descendantes de texte */
    font-size: 0;
}

.video-hero-container .freecaster-player {
    display: block;
}

.unmute-hint {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    /* Aligné à droite du bloc de 640px */
    gap: 8px;
    margin: -34px auto 20px auto;
    /* Remonté pour être juste sous le player */
    max-width: 640px;
    /* Même largeur que la vidéo */
    width: 100%;
    padding-right: 96px;
    /* Augmenté pour viser l'icône de volume (plus à gauche que HD) */
    box-sizing: border-box;
    color: var(--televie-red);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    animation: fadeIn 1s ease;
}

.unmute-hint .arrow-pointer {
    animation: bounce-up 1.5s infinite;
    display: flex;
    color: var(--televie-red);
}

@keyframes bounce-up {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-8px);
    }

    60% {
        transform: translateY(-4px);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Compteur (Countdown) */
.countdown {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.countdown-item {
    background: #ffffff;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 15px 20px;
    min-width: 80px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.countdown-value {
    font-size: 2.5rem;
    font-weight: 700;
    font-family: var(--font-display);
    color: var(--primary);
    line-height: 1;
}

.countdown-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--televie-text-muted);
    letter-spacing: 1px;
    margin-top: 5px;
}

/* Progress Bar (Dons) */
.donation-tracker {
    background: #ffffff;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 40px;
    margin: -50px auto 50px auto;
    position: relative;
    z-index: 10;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    max-width: 900px;
    text-align: center;
}

.donation-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-family: var(--font-display);
    font-size: 1.2rem;
}

.amount-current {
    font-weight: 700;
    color: var(--televie-red);
    font-size: 2rem;
}

.amount-goal {
    color: var(--televie-text-muted);
}

.progress-container {
    height: 24px;
    background: var(--televie-gray);
    border-radius: var(--radius-pill);
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--televie-orange) 0%, var(--televie-red) 100%);
    width: 0%;
    /* Définie via JS */
    border-radius: var(--radius-pill);
    transition: width 1.5s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
}

/* Animation Stripe sur la progress bar */
.progress-bar::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image: linear-gradient(-45deg,
            rgba(255, 255, 255, 0.2) 25%,
            transparent 25%,
            transparent 50%,
            rgba(255, 255, 255, 0.2) 50%,
            rgba(255, 255, 255, 0.2) 75%,
            transparent 75%,
            transparent);
    z-index: 1;
    background-size: 50px 50px;
    animation: move-stripes 2s linear infinite;
    border-radius: var(--radius-pill);
}

@keyframes move-stripes {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 50px 50px;
    }
}

/* Twitch Iframe */
.twitch-container {
    width: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    background: #000;
    aspect-ratio: 16 / 9;
    margin: 40px auto;
    display: none;
    /* Affiché via JS pendant le live */
    border: 3px solid var(--primary);
}

.twitch-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Contenu Editorial (Article) */
.editorial {
    background: #ffffff;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 50px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    font-size: 1.1rem;
    color: #444;
}

.editorial h2 {
    color: var(--televie-red);
    margin-bottom: 25px;
}

.editorial img {
    border-radius: var(--radius-sm);
    margin: 20px 0;
}

/* Footer */
footer {
    border-top: 1px solid var(--televie-gray);
    padding: 40px 0;
    text-align: center;
    color: var(--televie-text-muted);
    background: #ffffff;
}

footer .logo-container {
    justify-content: center;
    margin-bottom: 20px;
}

/* Animations au scroll */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .countdown {
        flex-wrap: wrap;
    }

    .countdown-item {
        min-width: calc(50% - 10px);
        margin-bottom: 10px;
    }

    .donation-tracker {
        padding: 25px 15px;
    }

    .editorial {
        padding: 25px 15px;
    }
}