/* Calendrier MPR 2027 — matrice par stade, dates en colonnes, couleurs par poule */
body:has(.schedule-stadium-view) main.wrap {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 4px clamp(10px, 1.8vw, 30px) 64px
}

.schedule-page {
    width: 100%;
    max-width: 2200px;
    margin: 0 auto;
    color: #15243a
}

.schedule-hero {
    position: relative;
    overflow: hidden;
    border-radius: 17px;
    padding: clamp(20px, 2.4vw, 34px);
    margin: 0 0 25px;
    color: #fff;
    background: radial-gradient(circle at 88% 12%, #34577c 0, transparent 27%), linear-gradient(115deg, #071426 0%, #102947 65%, #1a3b5d 100%);
    box-shadow: 0 12px 30px #0b1b2d1c
}

.schedule-hero:after {
    content: "";
    position: absolute;
    width: 350px;
    height: 350px;
    border: 1px solid #ffffff12;
    border-radius: 50%;
    right: -90px;
    top: -220px;
    box-shadow: 0 0 0 28px #ffffff08, 0 0 0 58px #ffffff06;
    pointer-events: none
}

.schedule-eyebrow,
.section-kicker {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2.5px;
    color: #dfc17e;
    text-transform: uppercase
}

.schedule-hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    position: relative;
    z-index: 1
}

.schedule-hero h1 {
    font: 800 clamp(30px, 3.4vw, 48px)/1.08 'DM Sans', sans-serif;
    color: #fff;
    margin: 10px 0 8px;
    letter-spacing: -1px
}

.schedule-hero h1 span {
    color: #e0c17b
}

.schedule-hero p {
    margin: 0;
    color: #d1dbe6;
    font-size: 14px
}

.schedule-ball {
    font-size: clamp(48px, 6vw, 76px);
    filter: drop-shadow(0 10px 10px #0005);
    margin-right: 3%
}

.schedule-stats {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 20px;
    position: relative;
    z-index: 1
}

.schedule-stats span {
    padding: 7px 12px;
    border: 1px solid #ffffff30;
    border-radius: 30px;
    background: #ffffff0c;
    color: #e7edf4;
    font-size: 10px
}

.schedule-stats b {
    color: #f0d48f;
    margin-right: 4px
}

.schedule-stats .stat-pending {
    border-color: #e2b66b70
}

.schedule-table-intro {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin: 0 2px 13px
}

.schedule-table-intro h2,
.schedule-pending h2 {
    font: 700 clamp(21px, 2.2vw, 29px) 'DM Sans', sans-serif;
    color: #10233c;
    margin: 5px 0 0
}

.schedule-table-intro p {
    font-size: 11px;
    color: #778497;
    margin: 0 0 3px;
    text-align: right
}

.schedule-scroll {
    width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    border: 1px solid #dce2e8;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 5px 20px #13243a0b;
    scrollbar-color: #b8c2cf #eef1f4;
    scrollbar-width: thin
}

.stadium-calendar {
    width: 100%;
    min-width: 1150px;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed
}

.stadium-calendar th,
.stadium-calendar td {
    border-right: 1px solid #e2e6eb;
    border-bottom: 1px solid #e2e6eb
}

.stadium-calendar tr>*:last-child {
    border-right: 0
}

.stadium-calendar tbody tr:last-child>* {
    border-bottom: 0
}

.stadium-calendar thead th {
    position: sticky;
    top: 0;
    z-index: 3;
    text-align: center
}

.stadium-calendar .venue-head {
    left: 0;
    z-index: 5;
    width: 190px;
    min-width: 190px;
    background: #122b49;
    color: #f4d993;
    text-align: left;
    padding: 13px 16px;
    font-size: 11px;
    letter-spacing: 1.5px
}

.phase-row th {
    padding: 10px 6px;
    color: #fff;
    font-size: 12px;
    letter-spacing: 1.3px;
    text-transform: uppercase;
    border-color: #ffffff25
}

.phase-row .pool-group {
    background: #c44a23
}

.phase-row .final-group {
    background: #173a5c
}

.date-row th {
    background: #f0f3f6;
    padding: 9px 3px 10px;
    color: #203650
}

.date-row th span {
    display: block;
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: .7px;
    color: #738195;
    font-weight: 800
}

.date-row th strong {
    display: block;
    font-size: 21px;
    line-height: 1.15;
    font-weight: 800
}

.date-row th small {
    display: block;
    font-size: 9px;
    text-transform: uppercase;
    color: #68788b;
    font-weight: 700
}

.stadium-calendar tbody th.venue-cell {
    position: sticky;
    left: 0;
    z-index: 2;
    width: 190px;
    background: #f7f8fa;
    text-align: left;
    padding: 13px 12px;
    vertical-align: middle;
    box-shadow: 3px 0 5px #0c1d2d0a
}

.venue-cell .venue-icon {
    display: block;
    font-size: 23px;
    margin-bottom: 5px
}

.venue-cell strong {
    display: block;
    font-size: 11px;
    line-height: 1.35;
    color: #1b3551;
    text-transform: uppercase;
    overflow-wrap: anywhere
}

.match-cell {
    width: 118px;
    min-width: 118px;
    padding: 5px;
    vertical-align: top;
    background: #fff
}

.stadium-fixture {
    border-radius: 7px;
    padding: 8px 7px 7px;
    color: #15243a;
    border: 1px solid #0000000b;
    border-left: 4px solid #8c99a9;
    box-shadow: 0 2px 5px #0b1b2d0d;
    margin: 0 0 5px;
    min-width: 0
}

.stadium-fixture:last-child {
    margin-bottom: 0
}

.stadium-fixture-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 4px;
    padding-bottom: 5px;
    margin-bottom: 5px;
    border-bottom: 1px solid #14243a20
}

.stadium-fixture-top b {
    font-size: 9px;
    letter-spacing: .4px;
    white-space: nowrap
}

.stadium-fixture-top span {
    font-size: 8px;
    text-align: right;
    font-weight: 800;
    opacity: .78
}

.stadium-team {
    font-size: 11px;
    font-weight: 800;
    line-height: 1.25;
    overflow-wrap: anywhere;
    padding: 2px 0
}

.stadium-vs {
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 1px;
    color: #536276;
    line-height: 1.2
}

.stadium-kickoff {
    border-top: 1px solid #14243a20;
    padding-top: 5px;
    margin-top: 5px;
    font-size: 11px;
    font-weight: 900
}

.stadium-status {
    font-size: 8px;
    font-weight: 900;
    letter-spacing: .5px;
    margin-top: 3px
}

.pool-a {
    background: #eadcf7;
    border-left-color: #9861c4
}

.pool-b {
    background: #d8f0e9;
    border-left-color: #269b7b
}

.pool-c {
    background: #f9dce5;
    border-left-color: #d35d84
}

.pool-d {
    background: #dceafa;
    border-left-color: #4b87cb
}

.pool-e {
    background: #faedcf;
    border-left-color: #d49a2f
}

.pool-f {
    background: #e3efd9;
    border-left-color: #73a24d
}

.pool-unknown {
    background: #eeece7;
    border-left-color: #9a9488
}

.stage-r16 {
    background: #d9eee9;
    border-left-color: #289b83
}

.stage-quarter {
    background: #fbe0d2;
    border-left-color: #d87945
}

.stage-semi {
    background: #e2e5eb;
    border-left-color: #78869a
}

.stage-bronze {
    background: #eee3d1;
    border-left-color: #b18a50
}

.stage-final {
    background: #faedb9;
    border-left-color: #c69a21
}

.schedule-scroll-hint {
    display: none;
    text-align: center;
    color: #718096;
    font-size: 10px;
    padding: 8px
}

.schedule-color-key {
    display: flex;
    align-items: center;
    gap: 10px 16px;
    flex-wrap: wrap;
    padding: 13px 15px;
    margin: 15px 0 25px;
    background: #fff;
    border: 1px solid #e5e7e9;
    border-radius: 10px;
    font-size: 10px;
    color: #5e6b7b
}

.schedule-color-key>strong {
    font-size: 11px;
    color: #172a43;
    margin-right: 3px
}

.schedule-color-key span {
    display: flex;
    align-items: center;
    gap: 6px
}

.key-dot {
    width: 11px;
    height: 11px;
    border-radius: 3px;
    display: inline-block
}

.schedule-empty {
    background: #fff;
    border: 1px solid #e1e5e9;
    border-radius: 14px;
    padding: 42px 20px;
    text-align: center
}

.empty-icon {
    font-size: 35px
}

.schedule-empty h2 {
    font-size: 22px;
    color: #142943;
    margin: 12px 0
}

.schedule-empty p {
    color: #68778a;
    line-height: 1.6;
    max-width: 720px;
    margin: 0 auto 10px
}

.schedule-empty small {
    color: #a17e3d;
    font-weight: 700
}

.schedule-pending {
    padding: 20px;
    background: #fff;
    border: 1px solid #e1e5e9;
    border-radius: 13px;
    margin-top: 22px
}

.schedule-pending>header {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 12px;
    margin-bottom: 15px
}

.schedule-pending>header>b {
    font-size: 11px;
    color: #755d2e;
    background: #f5efdf;
    border-radius: 20px;
    padding: 7px 11px
}

.pending-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 9px
}

.pending-fixture {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 11px;
    border: 1px solid #e8e4dc;
    border-radius: 8px;
    min-width: 0
}

.pending-fixture>b {
    font-size: 10px;
    color: #9b7739
}

.pending-fixture>span,
.pending-fixture small {
    font-size: 10px;
    color: #778497
}

.pending-fixture strong {
    font-size: 12px;
    line-height: 1.4;
    overflow-wrap: anywhere
}

.pending-fixture i {
    font-style: normal;
    color: #a17e3d;
    font-weight: 500
}

@media(min-width:1600px) {

    .stadium-calendar .venue-head,
    .stadium-calendar tbody th.venue-cell {
        width: 120px
    }

    .match-cell {
        width: 130px
    }

    .stadium-fixture {
        padding: 9px
    }

    .stadium-team {
        font-size: 12px
    }
}

@media(max-width:800px) {
    body:has(.schedule-stadium-view) main.wrap {
        padding: 16px 10px 42px
    }

    .schedule-hero {
        padding: 20px 16px
    }

    .schedule-hero h1 {
        font-size: 30px
    }

    .schedule-hero p {
        font-size: 12px
    }

    .schedule-ball {
        font-size: 43px
    }

    .schedule-table-intro {
        display: block
    }

    .schedule-table-intro p {
        text-align: left;
        margin-top: 6px
    }

    .stadium-calendar {
        min-width: 1050px
    }

    .stadium-calendar .venue-head,
    .stadium-calendar tbody th.venue-cell {
        width: 55px;
        min-width: 55px
    }

    .match-cell {
        width: 112px;
        min-width: 112px
    }

    .schedule-scroll-hint {
        display: block
    }

    .pending-list {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }
}

@media(max-width:520px) {
    .schedule-stats span {
        font-size: 9px;
        padding: 6px 8px
    }

    .schedule-ball {
        display: none
    }

    .pending-list {
        grid-template-columns: 1fr
    }

    .schedule-color-key {
        gap: 8px 11px;
        padding: 11px
    }

    .schedule-pending {
        padding: 14px
    }
}