:root {
    /* Couleurs principales existantes */
    --card: #004170;
    --accent: #ffffff;
    --success: #35b548;
    --warning: #ff9800;
    --yellow: #ffd700;
    --danger: #ff2d55;
    --text: #ffffff;

    /* Arrière-plans des événements */
    --bg-goal: #dff5e1;
    --bg-yellow: #fff4b3;
    --bg-red: #ffd6d6;
    --bg-sub: #ffe3c2;

    /* --- NOUVELLES VARIABLES POUR LA PERSONNALISATION DU BAS --- */
    --inline-section-title-border: #dddddd;   /* Ligne sous les titres "Derniers Matchs" / "Matchs à venir" */
    --inline-match-bg: #ffffff;               /* Fond de chaque ligne de match */
    --inline-match-shadow: #0000000D;         /* Ombre légère sous les lignes */
    --inline-date-color: #888888;             /* Couleur des dates (ex: 24/11/2026) */
    --inline-team-color: #333333;             /* Couleur du nom des équipes dans la liste */
    --inline-score-bg: #f4f4f4;               /* Fond du petit bloc score/vs */
    --inline-score-text: #000000;             /* Couleur du texte du score/vs */
}

@font-face {
    font-family: Poppins-Regular;
    src: url(fonts/Poppins/Poppins-Regular.ttf);
}

@font-face {
    font-family: Poppins-Bold;
    src: url(fonts/Poppins/Poppins-Bold.ttf);
}

#live-score-container,
#countdown {
    font-family: 'Poppins-Regular';
    max-width: 860px;
    margin: 0 auto;
    padding: 15px;
    color: var(--text);
}

/* =========================================================================
   STYLE DES LISTES DE MATCHS 
   ========================================================================= */
.section-title {
    font-family: 'Poppins-Bold', sans-serif;
    color: var(--card);
    font-size: 1.1rem;
    margin: 25px 0 10px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--inline-section-title-border);
    padding-bottom: 5px;
}

.match-list-inline {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
}

.match-row-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--inline-match-bg);
    padding: 8px 12px;
    border-radius: 4px;
    box-shadow: 0 1px 2px var(--inline-match-shadow);
    font-size: 0.9rem;
}

.inline-date {
    color: var(--inline-date-color);
    font-size: 0.8rem;
    min-width: 45px;
}

.inline-team {
    flex: 1;
    font-weight: 500;
    color: var(--inline-team-color);
}

.inline-team.home { 
    text-align: right; 
    padding-right: 15px; 
}

.inline-team.away { 
    text-align: left; 
    padding-left: 15px; 
}

.inline-score {
    font-weight: bold;
    background: var(--inline-score-bg);
    padding: 2px 10px;
    border-radius: 3px;
    min-width: 45px;
    text-align: center;
    color: var(--inline-score-text);
}

/* Gestion de la bannière publicitaire (sans match) */
.no-match-banner {
    text-align: center;
    padding: 10px 0;
}

.no-match-banner .banner-img {
    max-width: 100%; 
    height: 100px; 
    width: 175px; 
    border-radius: 8px;
}

/* =========================================================================
   STRUCTURE EXISTANTE DU COMPOSANT
   ========================================================================= */
.match-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.team-block {
    flex: 1;
    text-align: center;
}

.team-logo {
    height: 64px;
    width: auto;
    object-fit: contain;
    margin-bottom: 8px;
}

.team-name {
    font-size: 15px;
    font-family: 'Poppins-Bold';
    color: var(--text);
}

.score-block {
    min-width: 160px;
    text-align: center;
}

.score {
    font-size: 42px;
    font-family: 'Poppins-Bold';
    color: var(--text);
    line-height: 1.1;
}

.competition-name{
    text-align: center;
    margin-bottom: 12px;
    font-family: 'Poppins-Bold';
    color: var(--text);
    font-size: 0.7rem;
}

.competition-round{
    text-align: center;
    margin-bottom: 12px;
    font-family: 'Poppins-Bold';
    color: var(--text);
}

/* =========================
   STATUS
========================= */
.status {
    text-align: center;
    margin-bottom: 14px;
    font-family: 'Poppins-Bold';
}

.status.live {
    color: var(--success);
}

.status.finished {
    color: var(--danger);
}

.status.waiting {
    color: var(--text);
}

.minute {
    margin-top: 6px;
    font-family: 'Poppins-Bold';
    color: var(--success);
}

.period {
    font-size: 13px;
}

/* Bouton Détail Live Score */
.detail-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
    padding: 7px 16px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text);
    background-color: var(--card);
    border: 1px solid var(--text);
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.detail-link:hover {
    color: var(--card);
    background-color: var(--text);
    border-color: var(--card);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.detail-link:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.detail-link::before {
    content: "📊";
    font-size: 14px;
    opacity: 0.7;
}

/* =========================
   EVENTS SECTION
========================= */
.events-section {
    display: flex;
    gap: 16px;
    margin-top: 20px;
    padding-top: 20px;
}

.events-column {
    flex: 1;
    min-width: 0;
}

.event-group {
    margin-bottom: 12px;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid var(--accent);
    box-sizing: border-box;
}

.event-group h4 {
    margin: 0 0 10px 0;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Poppins-Bold';
}

.event-group.event-goals {
    background: var(--bg-goal);
    color: var(--text); 
}

.event-group.event-yellow {
    background: var(--bg-yellow);
    color: var(--text);
}

.event-group.event-red {
    background: var(--bg-red);
    color: var(--text);
}

.event-group.event-sub {
    background: var(--bg-sub);
    color: var(--text);
}

.event {
    padding: 8px 6px;
    border-bottom: 1px solid #dddddd;
    font-size: 14px;
    display: block;
    width: 100%;
    box-sizing: border-box;
    overflow-wrap: break-word;
}

.event:last-child {
    border-bottom: none;
}

.no-events {
    opacity: 0.7;
    text-align: center;
    padding: 15px 0;
}

/* =========================
   GLOBAL BOX
========================= */
.live-box,
.countdown-box {
    background: var(--card);
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--accent);
    box-shadow: 0 4px 18px #00000033;
}

/* =========================
   COMPTE À REBOURS
========================= */
.countdown-wrapper {
    display: inline-flex;
    flex-direction: column;
    align-items: stretch;
    padding-top: 0.1rem;
}

.countdown-wrapper .status.waiting {
    background: transparent;
    border-radius: 0.7rem 0.7rem 0 0;
    padding: 0.15rem 0;
    margin: 0;
    border: 0.0625rem solid var(--white-14);
    border-bottom: none;
    align-self: stretch;
}

.countdown-grid {
    display: flex;
    justify-content: center;
    gap: 0.35rem;
    box-sizing: border-box;
}

.countdown-inner {
    display: inline-flex;
    border-bottom: 0rem solid var(--white-14);
}

.time-box {
    width: 3.2rem;
    flex: 0 0 3.2rem;
    background: var(--white-08);
    border: 0.0625rem solid var(--white-14);
    border-radius: 0.7rem;
    padding: 0.45rem 0.3rem;
    text-align: center;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.time-box:first-child {
    border-top-left-radius: 0;
}

.time-box:last-child {
    border-top-right-radius: 0;
}

.time-number {
    font-size: 1.1rem;
    font-family: 'Poppins-Bold';
}

.time-label {
    font-size: 0.5rem;
    text-transform: uppercase;
}

.bet-link {
    display: block;
    text-align: center;
    color: var(--card);
    font-family: 'Poppins-Bold';
    font-size: 0.7rem;
    margin: 15px 0 25px 0;
}

.bet-link a {
    text-decoration: none;
    color: var(--warning);
}

/* =========================
   RESPONSIVE FIX
========================= */
@media(max-width:768px){
    .match-row {
        gap: 10px;
    }

    .team-logo {
        height: 48px;
    }

    .team-name {
        font-size: 13px;
    }

    .score {
        font-size: 28px;
    }

    .score-block {
        min-width: 110px;
    }

    .events-section {
        flex-direction: column;
    }
}