/* ==========================================================================
   Events – page unique
   S'appuie sur booking-page.css (boutons, titres, animations)
   ========================================================================== */

/* ---------- Chiffres clés (en-tête) ---------- */
.ev-stats {
    list-style: none;
    display: flex;
    gap: 0;
    margin-top: 22px !important;
    border: 1px solid var(--bk-line);
    width: fit-content;
    max-width: 100%;
}
.ev-stats li {
    padding: 10px 18px;
    border-right: 1px solid var(--bk-line);
    font-size: 11px;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--bk-muted);
}
.ev-stats li:last-child { border-right: 0; }
.ev-stats strong { display: block; font-size: 22px; letter-spacing: 0; color: #fff; margin-bottom: 2px; }
.ev-stats:empty { display: none; }

/* ---------- Prochain événement ---------- */
.ev-featured {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    border: 1px solid var(--bk-line);
    background: var(--bk-surface);
}
.ev-featured + .ev-featured { margin-top: 12px; }
.ev-featured-media {
    position: relative;
    display: block;
    padding: 0;
    border: 0;
    border-right: 1px solid var(--bk-line);
    background: #000;
    cursor: zoom-in;
    overflow: hidden;
    min-height: 100%;
}
/* Affiche entière (contain) sur un fond flou tiré de l'affiche : pas de bande noire, pas de texte coupé */
.ev-featured-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    transition: transform .9s var(--bk-ease);
}
.ev-featured-media img.ev-featured-bg {
    object-fit: cover;
    filter: blur(28px) brightness(.45);
    transform: scale(1.2);
}
.ev-featured-media:hover img:not(.ev-featured-bg) { transform: scale(1.03); }
.ev-featured-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 26px;
}
.ev-date-row { display: flex; align-items: stretch; gap: 16px; }
.ev-bigdate {
    flex-shrink: 0;
    width: 78px;
    text-align: center;
    border: 1px solid var(--bk-line);
    background: var(--bk-deep);
}
.ev-bigdate-month {
    display: block;
    padding: 6px 0;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .2em;
    background: #fff;
    color: #0d0e0d;
}
.ev-bigdate-day { display: block; font-size: 32px; font-weight: 700; line-height: 1; padding: 10px 0 4px; }
.ev-bigdate-year { display: block; font-size: 11px; color: var(--bk-muted); padding-bottom: 8px; }
.ev-date-meta { display: flex; flex-direction: column; justify-content: center; gap: 4px; min-width: 0; }
.ev-date-meta .ev-weekday { font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--bk-muted); }
.ev-featured h4 { font-size: clamp(22px, 3vw, 32px); line-height: 1.1; font-weight: 700; }
.ev-location {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #d6d6d6;
    text-decoration: none;
}
.ev-location:hover { color: #fff; text-decoration: underline; }
.ev-location svg { width: 14px; height: 14px; flex-shrink: 0; }

.ev-lineup-label { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--bk-muted); margin-bottom: 8px !important; }
.ev-lineup { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; }
.ev-lineup li a,
.ev-lineup li span {
    display: inline-block;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    border: 1px solid var(--bk-line);
    text-decoration: none;
}
.ev-lineup li a { border-color: #8a8b8a; }
.ev-lineup li a:hover { background: #fff; color: #0d0e0d; }

/* Compte à rebours */
.ev-countdown { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--bk-line); }
.ev-countdown div { padding: 10px 6px; text-align: center; border-right: 1px solid var(--bk-line); }
.ev-countdown div:last-child { border-right: 0; }
.ev-countdown strong { display: block; font-size: 24px; font-weight: 700; font-variant-numeric: tabular-nums; }
.ev-countdown span { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--bk-muted); }
.ev-today {
    padding: 10px 14px;
    border: 1px solid #fff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    text-align: center;
}

.ev-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.ev-soldout {
    display: inline-flex;
    align-items: center;
    padding: 12px 22px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    border: 1px solid #e0605f;
    color: #ff8a89;
}

/* Aucun événement annoncé */
.ev-empty {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 24px;
    align-items: center;
    padding: 32px 28px;
    border: 1px solid var(--bk-line);
    background: var(--bk-surface);
}
.ev-empty h4 { font-size: 24px; font-weight: 700; }
.ev-empty p { margin-top: 10px !important; font-size: 14px; line-height: 1.6; color: #d6d6d6; max-width: 560px; }
.ev-empty .ev-actions { margin-top: 0; }
.ev-pulse {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 10px;
    border-radius: 50%;
    background: #fff;
    vertical-align: middle;
    animation: evPulse 1.8s ease-in-out infinite;
}
@keyframes evPulse { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }

/* ---------- Événements passés ---------- */
.ev-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.ev-filter {
    padding: 7px 14px;
    font: inherit;
    font-size: 12px;
    letter-spacing: .1em;
    color: #d6d6d6;
    background: transparent;
    border: 1px solid var(--bk-line);
    cursor: pointer;
    transition: background-color .25s, color .25s, border-color .25s;
}
.ev-filter:hover { border-color: #8a8b8a; color: #fff; }
.ev-filter.is-active { background: #fff; border-color: #fff; color: #0d0e0d; font-weight: 700; }
.ev-filter:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.ev-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
.ev-card {
    display: flex;
    flex-direction: column;
    padding: 0;
    font: inherit;
    text-align: left;
    color: #fff;
    background: var(--bk-surface);
    border: 1px solid var(--bk-line);
    cursor: pointer;
    transition: border-color .3s;
}
.ev-card[hidden] { display: none; }
/* Apparition au défilement (bk-reveal) : garde la transition du survol, décalage par colonne */
.bk-js .ev-card.bk-reveal { transition: opacity .7s var(--bk-ease), transform .7s var(--bk-ease), border-color .3s; }
.bk-js .ev-card.bk-reveal:nth-child(3n+2) { transition-delay: .08s, .08s, 0s; }
.bk-js .ev-card.bk-reveal:nth-child(3n) { transition-delay: .16s, .16s, 0s; }
.ev-card:hover { border-color: #8a8b8a; }
.ev-card:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.ev-card-media { position: relative; aspect-ratio: 1.91 / 1; overflow: hidden; background: #000; }
.ev-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: grayscale(100%);
    transition: filter .6s ease, transform .9s var(--bk-ease);
}
.ev-card:hover .ev-card-media img,
.ev-card:focus-visible .ev-card-media img { filter: grayscale(0%); transform: scale(1.05); }
.ev-card-date {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 5px 9px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .14em;
    background: rgba(13, 14, 13, .88);
    border: 1px solid var(--bk-line);
}
.ev-card-body { padding: 16px 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.ev-card-name { font-size: 16px; font-weight: 700; line-height: 1.25; }
.ev-card-place { font-size: 12px; color: var(--bk-muted); }
.ev-card-lineup { font-size: 12px; color: #d6d6d6; line-height: 1.5; }

/* Squelettes de chargement */
.ev-skeleton {
    border: 1px solid var(--bk-line);
    background: linear-gradient(90deg, #1f1f1f 0%, #2a2a2a 50%, #1f1f1f 100%);
    background-size: 200% 100%;
    animation: evShimmer 1.4s linear infinite;
}
.ev-skeleton-featured { height: 340px; }
.ev-skeleton-card { aspect-ratio: 1.3 / 1; }
@keyframes evShimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.ev-error { font-size: 14px; color: #ff8a89; padding: 16px 0; }

/* ---------- Visionneuse ---------- */
.ev-lightbox {
    width: min(1100px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
    padding: 0;
    border: 1px solid var(--bk-line);
    background: var(--bk-surface);
    color: #fff;
}
.ev-lightbox::backdrop { background: rgba(0, 0, 0, .85); }
.ev-lightbox[open] { animation: evZoom .35s var(--bk-ease); }
@keyframes evZoom { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
.ev-lightbox img { display: block; width: 100%; height: auto; max-height: 70vh; object-fit: contain; background: #000; }
.ev-lightbox-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-top: 1px solid var(--bk-line);
}
.ev-lightbox-info strong { display: block; font-size: 16px; }
.ev-lightbox-info span { font-size: 12px; color: var(--bk-muted); }
.ev-lightbox-nav { display: flex; gap: 6px; align-items: center; }
.ev-lightbox-nav a.bk-btn { padding: 9px 14px; font-size: 13px; }

@media (prefers-reduced-motion: reduce) {
    .ev-pulse, .ev-skeleton, .ev-lightbox[open] { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .ev-featured { grid-template-columns: 1fr; }
    .ev-featured-media { border-right: 0; border-bottom: 1px solid var(--bk-line); aspect-ratio: 1.91 / 1; min-height: 0; }
    .ev-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ev-empty { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .ev-grid { grid-template-columns: 1fr; }
    .ev-featured-body { padding: 20px 16px; }
    .ev-stats li { padding: 8px 12px; }
    .ev-stats strong { font-size: 18px; }
    .ev-actions .bk-btn, .ev-actions .ev-soldout { flex: 1 1 auto; justify-content: center; }
}
