/*
 * gdm-event.css — GenevaDance Members — Module Événements
 * v2.4.0
 *
 * Scope : .gdm-event-submit-wrap, .gdm-event-list-wrap,
 *         .gdm-my-events-wrap, .gdm-single-event-wrap
 *
 * Ce fichier ne contient que des styles SPÉCIFIQUES aux événements.
 * Boutons  → .gdm-btn        (gdm-base.css)
 * Champs   → .gdm-input / .gdm-select / .gdm-textarea (gdm-base.css)
 * Labels   → .gdm-label / .gdm-label-sm               (gdm-base.css)
 * Alertes  → .gdm-alert                               (gdm-base.css)
 * Tags     → .gdm-tag / .gdm-tag--option              (gdm-base.css)
 *
 * Tokens utilisés : var(--gdm-primary), var(--gdm-primary-light),
 *   var(--gdm-text-mid), var(--gdm-bg-subtle), var(--gdm-border),
 *   var(--gdm-radius), var(--gdm-radius-sm), var(--gdm-shadow),
 *   var(--gdm-shadow-card)
 *
 * Dépendance déclarée dans Assets.php : ['gdm-base']
 */

/* ============================================================
   TOAST (fixé en bas d'écran — composant propre event)
   ============================================================ */

.gdm-event-toast {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 24px;
    border-radius: var(--gdm-radius-pill);
    font-size: 0.9rem;
    font-weight: 600;
    color: #fff;
    z-index: 9999;
    pointer-events: none;
    box-shadow: 0 4px 16px rgba(0,0,0,0.18);
    font-family: var(--gdm-font-body);
}
.gdm-event-toast--success { background: var(--gdm-success); }
.gdm-event-toast--error   { background: var(--gdm-error); }


/* ============================================================
   FORMULAIRE PUBLICATION — layout seul
   ============================================================ */

.gdm-event-submit-wrap {
    max-width: 740px;
    margin: 0 auto;
}

.gdm-event-submit-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--gdm-text-title);
    margin-bottom: 4px;
    font-family: var(--gdm-font-heading);
}

.gdm-event-submit-intro {
    color: var(--gdm-text-mid);
    margin-bottom: 32px;
    font-size: 1rem;
}

/* Chaque champ du formulaire */
.gdm-event-submit-form {
    display: flex;
    flex-direction: column;
    gap: 0; /* séparation visuelle assurée par .gdm-label border-top */
}

.gdm-event-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 8px;
}

/* Neutraliser le border-top de .gdm-label dans ce contexte —
   la densité du formulaire d'événement n'en a pas besoin */
.gdm-event-submit-wrap .gdm-label {
    border-top: 1px solid var(--gdm-border);
    padding-top: 1.2rem;
    margin-top: 0.5rem;
}
.gdm-event-submit-wrap .gdm-event-field:first-child .gdm-label {
    border-top: none;
    padding-top: 0;
    margin-top: 0;
}

/* Textarea taille longue */
.gdm-textarea--tall { min-height: 140px; }

/* Ajustements width sur les inputs date/time */
.gdm-event-input--date { width: auto; flex: 1; min-width: 130px; }
.gdm-event-input--time { width: 110px; flex-shrink: 0; }

/* Groupe dates */
.gdm-event-dates {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.gdm-event-date-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.gdm-event-date-label {
    font-size: 0.82rem;
    color: var(--gdm-text-mid);
    font-weight: 600;
    min-width: 36px;
    font-family: var(--gdm-font-body);
}

/* Récurrence end */
.gdm-event-recurrence-end {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 6px;
}

/* Sous-form nouveau lieu */
.gdm-event-new-venue {
    margin-top: 10px;
    padding: 16px;
    border: 1.5px solid var(--gdm-border);
    border-radius: var(--gdm-radius-sm);
    background: var(--gdm-bg-light);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.gdm-event-new-venue-title {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--gdm-text-title);
    margin: 0;
    font-family: var(--gdm-font-body);
}

.gdm-event-venue-row {
    display: flex;
    gap: 10px;
}

.gdm-event-venue-row .gdm-input {
    flex: 1;
}

/* ============================================================
   CHIPS STYLES DE DANSE
   Les chips utilisent .gdm-tag.gdm-tag--dance.gdm-tag--option (gdm-base.css).
   Ici on configure uniquement le conteneur et l'état actif coloré.
   ============================================================ */

.gdm-event-dance-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0;
}

/* Quand un style est sélectionné : utilise la couleur de la danse
   (--tag-bg / --tag-text injectés en style inline) */
.gdm-event-dance-chips .gdm-tag--active {
    background: var(--tag-bg, var(--gdm-text-title)) !important;
    color: var(--tag-text, var(--gdm-white)) !important;
    border-color: var(--tag-bg, var(--gdm-text-title)) !important;
}

/* Tag "Toutes danses" — neutre gris si pas de couleur */
.gdm-tag--all-dances {
    --tag-bg: var(--gdm-text-mid);
    --tag-text: #fff;
}

/* ============================================================
   CHECKBOXES THÈME / DRESS CODE
   ============================================================ */

.gdm-event-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
    padding: 12px 14px;
    border: 1.5px solid var(--gdm-border);
    border-radius: var(--gdm-radius-sm);
    background: var(--gdm-bg-light);
}

/* Tags libres (étiquettes ajoutées manuellement) */
.gdm-event-tag-free {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.gdm-event-tag-free .gdm-input {
    flex: 1;
}

.gdm-event-free-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.gdm-event-free-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--gdm-primary-light);
    color: var(--gdm-primary);
    border-radius: var(--gdm-radius-pill);
    padding: 3px 10px;
    font-size: 0.82rem;
    font-weight: 600;
    font-family: var(--gdm-font-body);
}

.gdm-event-free-tag button {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gdm-primary);
    font-size: 1rem;
    line-height: 1;
    padding: 0;
}

/* ============================================================
   IMAGE UPLOAD
   ============================================================ */

.gdm-event-file-zone {
    position: relative;
    display: flex;
    align-items: stretch;
    border: 2px dashed var(--gdm-border);
    border-radius: var(--gdm-radius-sm);
    overflow: hidden;
    transition: border-color .15s, background .15s;
    cursor: pointer;
}

.gdm-event-file-zone:hover,
.gdm-event-file-zone:focus-within {
    border-color: var(--gdm-primary);
    background: var(--gdm-primary-light);
}

/* Input couvre toute la zone — clic direct sans JS */
.gdm-event-file-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 1;
    font-size: 0;
    color: transparent;
}

.gdm-event-file-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 28px 20px;
    color: var(--gdm-text-mid);
    font-size: 0.9rem;
    text-align: center;
    width: 100%;
    pointer-events: none;
    z-index: 0;
    font-family: var(--gdm-font-body);
}

.gdm-event-file-visual svg   { width: 28px; height: 28px; }
.gdm-event-file-visual small { font-size: 0.78rem; color: var(--gdm-text-muted); }

.gdm-event-img-preview {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.gdm-event-img-thumb {
    max-width: 200px;
    max-height: 140px;
    border-radius: var(--gdm-radius-sm);
    object-fit: cover;
}

/* Actions (bouton soumettre) */
.gdm-event-actions {
    padding-top: 16px;
    padding-bottom: 8px;
}


/* ============================================================
   LISTING PUBLIC — [gdm_event_list]
   ============================================================ */

.gdm-event-list-wrap {
    max-width: 900px;
    margin: 0 auto;
}

/* Filtres */
.gdm-event-filters       { margin-bottom: 24px; }
.gdm-event-filters-row   { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.gdm-event-search-input  { flex: 1; min-width: 200px; }
.gdm-event-filter-select { width: auto; min-width: 180px; }

/* CTA publier */
.gdm-event-publish-cta { margin-bottom: 20px; }

/* Vide */
.gdm-event-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--gdm-text-mid);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    font-family: var(--gdm-font-body);
}

/* Grille cards */
.gdm-event-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

/* Card */
.gdm-event-card {
    background: var(--gdm-white);
    border-radius: var(--gdm-radius-lg);
    box-shadow: var(--gdm-shadow-card);
    overflow: hidden;
    transition: transform .2s, box-shadow .2s;
    display: flex;
    flex-direction: column;
}

.gdm-event-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--gdm-shadow-hover);
}

/* Image card */
.gdm-event-card-img-link {
    display: block;
    position: relative;
    aspect-ratio: 1/1;
    overflow: hidden;
}

.gdm-event-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s;
}

.gdm-event-card:hover .gdm-event-card-img { transform: scale(1.04); }

.gdm-event-card-img-placeholder {
    width: 100%;
    height: 100%;
    max-height: 300px;
    background: var(--gdm-bg-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gdm-primary-light);
}

.gdm-event-card-img-placeholder svg {
    width: 56px !important;
    height: 56px !important;
    max-width: 56px !important;
    max-height: 56px !important;
    color: var(--gdm-primary-light) !important;
}

/* Badge date sur image — couleur via style="background:..." inline */
.gdm-event-card-date-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255,255,255,0.95);
    border-radius: var(--gdm-radius);
    padding: 6px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: var(--gdm-shadow-sm);
    min-width: 52px;
    text-align: center;
}

.gdm-event-card-date-day {
    font-size: 3rem;
    line-height: 1.2rem;
    font-weight: 700;
    color: var(--gdm-text-title);
    line-height: 1;
}

.gdm-event-card-date-month {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.3rem;
    color: var(--gdm-text-title);
    text-transform: uppercase;
    letter-spacing: .04em;
}

/* Corps card */
.gdm-event-card-body {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Tags catégorie */
.gdm-event-card-cats { display: flex; flex-wrap: wrap; gap: 5px; }

.gdm-event-cat-tag {
    display: inline-block;
    background: var(--gdm-primary-light);
    color: var(--gdm-primary);
    border-radius: var(--gdm-radius-pill);
    padding: 4px 14px;
    font-size: 0.82rem;
    font-weight: 700;
    text-decoration: none;
    transition: background .15s;
}

.gdm-event-cat-tag:hover {
    background: var(--gdm-primary);
    color: #fff;
}

.gdm-event-card-title {
    font-size: 1.85rem;
    font-weight: 700;
    color: var(--gdm-text-title);
    margin: 0;
    line-height: 1.3;
}

.gdm-event-card-title a { color: inherit; text-decoration: none; }
.gdm-event-card-title a:hover { color: var(--gdm-primary); }

.gdm-event-card-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.gdm-event-card-time,
.gdm-event-card-location {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 1rem;
    line-height: 1.4rem;
    color: var(--gdm-text);
}

.gdm-event-card-time svg,
.gdm-event-card-location svg { width: 14px; height: 14px; flex-shrink: 0; }

.gdm-event-card-excerpt {
    font-size: 0.85rem;
    color: var(--gdm-text-mid);
    line-height: 1.45;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gdm-event-card-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gdm-primary);
    text-decoration: none;
    margin-top: 0px !important;
}

.gdm-event-card-link:hover { text-decoration: underline; }

/* Pagination */
.gdm-event-pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 36px;
    flex-wrap: wrap;
}

.gdm-event-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--gdm-bg-subtle);
    color: var(--gdm-text);
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    transition: background .15s;
}

.gdm-event-page-btn:hover,
.gdm-event-page-btn--active {
    background: var(--gdm-primary);
    color: #fff;
}


/* ============================================================
   MES ÉVÉNEMENTS — [gdm_my_events]
   ============================================================ */

.gdm-my-events-wrap { max-width: 760px; margin: 0 auto; }

.gdm-my-events-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

.gdm-my-events-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--gdm-text-title);
    margin: 0;
    font-family: var(--gdm-font-heading);
}

.gdm-my-events-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.gdm-my-event-row {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--gdm-white);
    border-radius: var(--gdm-radius);
    box-shadow: var(--gdm-shadow-card);
    padding: 12px;
    transition: opacity .35s;
}

.gdm-my-event-img-link { flex-shrink: 0; }

.gdm-my-event-img {
    width: 80px;
    height: 56px;
    object-fit: cover;
    border-radius: var(--gdm-radius-sm);
    display: block;
}

.gdm-my-event-img--placeholder {
    width: 80px;
    height: 56px;
    background: var(--gdm-bg-subtle);
    border-radius: var(--gdm-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gdm-text-muted);
}

.gdm-my-event-img--placeholder svg { width: 22px; height: 22px; }

.gdm-my-event-date {
    flex-shrink: 0;
    text-align: center;
    min-width: 36px;
}

.gdm-my-event-date-day {
    display: block;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--gdm-text-title);
    line-height: 1;
}

.gdm-my-event-date-month {
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--gdm-primary);
    text-transform: uppercase;
}

.gdm-my-event-info { flex: 1; min-width: 0; }

.gdm-my-event-title {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--gdm-text-title);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gdm-my-event-title:hover { color: var(--gdm-primary); }

.gdm-my-event-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 4px;
}

/* Status badges */
.gdm-status {
    display: inline-block;
    padding: 2px 9px;
    border-radius: var(--gdm-radius-pill);
    font-size: 0.72rem;
    font-weight: 700;
    font-family: var(--gdm-font-body);
}

.gdm-status--published { background: var(--gdm-success-bg);  color: var(--gdm-success); }
.gdm-status--pending   { background: #fff8e1;                 color: var(--gdm-warning); }
.gdm-status--draft     { background: var(--gdm-bg-subtle);    color: var(--gdm-text-mid); }

.gdm-event-recurrence-badge,
.gdm-event-past-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 0.72rem;
    color: var(--gdm-text-mid);
    font-family: var(--gdm-font-body);
}

.gdm-event-recurrence-badge svg { width: 11px; height: 11px; }
.gdm-event-past-badge           { color: var(--gdm-text-muted); }

/* Actions icônes (boutons circulaires, conservés) */
.gdm-my-event-actions { display: flex; gap: 6px; flex-shrink: 0; }

.gdm-event-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gdm-bg-subtle);
    color: var(--gdm-text-mid);
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: background .15s, color .15s, transform .1s;
}

.gdm-event-action-btn:hover           { background: var(--gdm-border); transform: scale(1.08); }
.gdm-event-action-btn--danger         { background: var(--gdm-error-bg) !important; color: var(--gdm-error) !important; }
.gdm-event-action-btn--danger:hover   { background: var(--gdm-error) !important; color: #fff !important; }
.gdm-event-action-btn svg             { width: 15px !important; height: 15px !important; display: block !important; stroke: currentColor !important; }

/* Modale suppression */
.gdm-event-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.gdm-event-modal {
    background: var(--gdm-white);
    border-radius: var(--gdm-radius-lg);
    padding: 28px;
    max-width: 360px;
    width: 100%;
    box-shadow: var(--gdm-shadow-hover);
    text-align: center;
}

.gdm-event-modal p {
    font-size: 1rem;
    color: var(--gdm-text-title);
    margin-bottom: 20px;
    font-family: var(--gdm-font-body);
}

.gdm-event-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}


/* ============================================================
   VUE DÉTAIL — single-event.php
   ============================================================ */

.gdm-single-event-wrap { max-width: 100%; }

/* Hero */
.gdm-single-event-hero     { width: 100%; max-height: 440px; overflow: hidden; }
.gdm-single-event-hero-img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Layout 2 colonnes */
.gdm-single-event-content {
    max-width: 960px;
    margin: 0 auto;
    padding: 32px 20px 48px;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    align-items: start;
}

@media (max-width: 700px) {
    .gdm-single-event-content { grid-template-columns: 1fr; }
}

/* Header main */
.gdm-single-event-date {
    font-size: 1rem;
    font-weight: 700;
    color: var(--gdm-primary);
    text-transform: capitalize;
    margin-bottom: 6px;
}

.gdm-single-event-title {
    font-size: 3rem;
    font-weight: 900;
    color: var(--gdm-text-title);
    margin: 0 0 16px;
    line-height: 1.2;
    font-family: var(--gdm-font-heading);
}

.gdm-single-event-cats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }

/* Actions sur la page single : horizontal, aéré */
.gdm-single-event-wrap .gdm-event-actions {
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 16px 0;
    border-top: 1px solid var(--gdm-border);
    border-bottom: 1px solid var(--gdm-border);
    margin: 16px 0 24px;
}

.gdm-single-event-wrap .gdm-event-avatars-row {
    flex: 1;
    min-width: 200px;
}

.gdm-single-event-wrap .gdm-event-actions-btns {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.gdm-single-event-wrap .gdm-event-action-heart {
    flex-direction: row;
    align-items: center;
    gap: 4px;
}

/* Pictos légèrement plus grands sur la page détail */
.gdm-single-event-wrap .gdm-event-picto {
    height: 48px !important;
    min-width: 48px !important;
}

.gdm-single-event-wrap .gdm-event-picto--bare .gdm-picto-icon,
.gdm-single-event-wrap .gdm-event-picto--bare .gdm-picto-icon svg {
    width: 26px !important;
    height: 26px !important;
}

.gdm-event-tag {
    display: inline-block;
    background: var(--gdm-bg-subtle);
    color: var(--gdm-text-mid);
    border-radius: var(--gdm-radius-pill);
    padding: 2px 10px;
    font-size: 0.78rem;
    font-weight: 600;
    font-family: var(--gdm-font-body);
}

.gdm-single-event-tags {
    font-size: 0.9rem;
    color: var(--gdm-text-mid);
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.gdm-single-event-tags strong { color: var(--gdm-text-title); }

/* Adresse */
.gdm-single-event-address {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    background: var(--gdm-bg-subtle);
    border-radius: var(--gdm-radius-sm);
    padding: 16px;
    margin-bottom: 20px;
}

.gdm-single-event-address > svg {
    width: 20px;
    height: 20px;
    color: var(--gdm-primary);
    flex-shrink: 0;
    margin-top: 2px;
}

.gdm-single-event-address-text {
    font-size: 0.9rem;
    color: var(--gdm-text);
    margin: 0 0 10px;
    line-height: 1.5;
}

.gdm-single-event-map-btns { display: flex; gap: 8px; flex-wrap: wrap; }

/* Récurrence prochaines dates */
.gdm-single-event-recurrence {
    background: #fff8e1;
    border-radius: var(--gdm-radius-sm);
    padding: 14px 16px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: var(--gdm-text);
}

.gdm-single-event-recurrence strong { color: var(--gdm-text-title); }

.gdm-single-event-dates-list {
    margin: 8px 0 0 0;
    padding-left: 18px;
    list-style: disc;
}

.gdm-single-event-dates-list li { margin-bottom: 4px; }

/* Description */
.gdm-single-event-description {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--gdm-text);
    margin-bottom: 24px;
}

.gdm-single-event-description p { margin-bottom: 12px; }

/* Lien modifier */
.gdm-single-event-edit-link {
    font-size: 0.85rem;
    margin-bottom: 20px;
}

.gdm-single-event-edit-link a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--gdm-text-mid);
    text-decoration: none;
}

.gdm-single-event-edit-link a:hover { color: var(--gdm-primary); }
.gdm-single-event-edit-link svg      { width: 14px; height: 14px; }

/* Sidebar */
.gdm-single-event-sidebar  { position: sticky; top: 20px; }

.gdm-sidebar-title {
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--gdm-text-title);
    margin-bottom: 14px;
    font-family: var(--gdm-font-heading);
}

.gdm-sidebar-events { display: flex; flex-direction: column; gap: 12px; }

.gdm-sidebar-event-card {
    display: flex;
    gap: 10px;
    align-items: center;
    text-decoration: none;
    background: var(--gdm-white);
    border-radius: var(--gdm-radius-sm);
    box-shadow: var(--gdm-shadow);
    padding: 8px;
    transition: transform .15s;
}

.gdm-sidebar-event-card:hover { transform: translateX(3px); }

.gdm-sidebar-event-img {
    width: 64px;
    height: 48px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}

.gdm-sidebar-event-info    { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

.gdm-sidebar-event-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--gdm-text-title);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gdm-sidebar-event-date {
    font-size: 0.75rem;
    color: var(--gdm-primary);
    font-weight: 600;
}

/* Footer CTA */
.gdm-single-event-footer {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px 48px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* Notice */
.gdm-event-notice {
    padding: 20px;
    background: var(--gdm-bg-subtle);
    border-radius: var(--gdm-radius-sm);
    color: var(--gdm-text-mid);
    font-size: 0.95rem;
    font-family: var(--gdm-font-body);
}


/* ============================================================
   EVENT STRIP — [gdm_event_strip]
   ============================================================ */

.gdm-event-strip { margin: 24px 0; }

.gdm-event-strip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
}

.gdm-event-strip-card {
    display: flex;
    flex-direction: column;
    border-radius: var(--gdm-radius-sm);
    overflow: hidden;
    text-decoration: none !important;
    box-shadow: var(--gdm-shadow);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.gdm-event-strip-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--gdm-shadow-hover);
}

/* Image 1:1 */
.gdm-event-strip-img-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--gdm-bg-subtle);
}

.gdm-event-strip-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.gdm-event-strip-card:hover .gdm-event-strip-img-wrap img { transform: scale(1.04); }

.gdm-event-strip-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gdm-event-strip-placeholder svg {
    width: 36px;
    height: 36px;
    opacity: 0.4;
}

/* Badge date */
.gdm-event-strip-date {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(255,255,255,0.92);
    border-radius: 6px;
    padding: 4px 7px;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.1;
}

.gdm-event-strip-date-day {
    font-size: 30px;
    font-weight: 600;
    color: var(--gdm-text-title);
}

.gdm-event-strip-date-month {
    font-size: 14px;
    font-weight: 600;
    color: var(--gdm-text-title);
    text-transform: uppercase;
}

/* Bandeau coloré */
.gdm-event-strip-banner {
    padding: 20px;
    min-height: 52px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.gdm-event-strip-title {
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gdm-event-strip-time {
    font-size: 0.78rem;
    font-weight: 500;
    opacity: 0.75;
    margin-top: 4px;
}

/* Card "Voir tous" */
.gdm-event-strip-more-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
}

.gdm-event-strip-more-count {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 600px) {
    .gdm-event-submit-title  { font-size: 1.4rem; }
    .gdm-event-grid          { grid-template-columns: 1fr; }
    .gdm-event-filters-row   { flex-direction: column; }
    .gdm-event-search-input  { width: 100%; }
    .gdm-my-event-row        { flex-wrap: wrap; }
    .gdm-single-event-title  { font-size: 1.5rem; }
    .gdm-single-event-footer { flex-direction: column; }
    .gdm-event-strip-grid    { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
}

/* ============================================================
   COMPOSANT EVENT-ACTIONS (partial event-actions.php)
   Basé sur .gdm-picto (gdm-base.css)
   ============================================================ */

.gdm-event-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    position: relative;
}

/* Taille réduite vs picto standard (60px → 44px) */
.gdm-event-picto {
    height: 44px !important;
    min-width: 44px !important;
    padding: 0 14px !important;
}

.gdm-event-picto .gdm-picto-icon,
.gdm-event-picto .gdm-picto-icon svg {
    width: 18px !important;
    height: 18px !important;
}

/* État liked — rose principal (comme hover gdm-picto par défaut) */
.gdm-picto.gdm-event-picto--liked {
    background: var(--gdm-primary) !important;
    color: var(--gdm-white) !important;
}

/* Groupe bouton + badge compteur */
.gdm-event-action-group {
    display: flex;
    align-items: center;
    gap: 4px;
}

.gdm-event-action-badge {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--gdm-text-mid);
    font-family: var(--gdm-font-body);
    min-width: 14px;
}

/* ── Spinner ─────────────────────────────────────────────────── */
.gdm-event-spinner {
    animation: gdm-spin .8s linear infinite;
}

@keyframes gdm-spin { to { transform: rotate(360deg); } }

/* ── Avatars participants ────────────────────────────────────── */
.gdm-event-participants-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.gdm-event-avatars-trigger {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.gdm-event-avatars-stack { display: flex; align-items: center; }

.gdm-event-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 2px solid var(--gdm-white);
    overflow: hidden;
    background: var(--gdm-bg-subtle); /* fallback si pas de color inline */
    flex-shrink: 0;
}

.gdm-event-avatar--md { width: 34px; height: 34px; }

.gdm-event-avatar-img { width: 100%; height: 100%; object-fit: cover; display: block; }

.gdm-event-avatar-initials {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--gdm-white);
    line-height: 1;
}

.gdm-event-avatar--md .gdm-event-avatar-initials { font-size: 0.8rem; }

.gdm-event-avatars-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 28px;
    padding: 0 6px;
    margin-left: -6px;
    border-radius: var(--gdm-radius-pill);
    background: var(--gdm-primary-light);
    border: 2px solid var(--gdm-white);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--gdm-primary);
}

.gdm-event-avatars-placeholder {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8rem;
    color: var(--gdm-text-mid);
    font-weight: 600;
}

.gdm-event-avatars-placeholder svg { width: 15px; height: 15px; }

/* ── Popover participants ────────────────────────────────────── */
.gdm-event-participants-popover {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 0;
    z-index: 200;
    background: var(--gdm-white);
    border-radius: var(--gdm-radius);
    box-shadow: var(--gdm-shadow-hover);
    border: 1px solid var(--gdm-border);
    min-width: 220px;
    max-width: 280px;
    overflow: hidden;
}

.gdm-event-participants-popover-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--gdm-text-title);
    border-bottom: 1px solid var(--gdm-border);
}

.gdm-event-popover-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px;
    color: var(--gdm-text-muted);
    display: flex;
}

.gdm-event-popover-close svg { width: 14px; height: 14px; }

.gdm-event-participants-list { max-height: 260px; overflow-y: auto; padding: 6px 0; }

.gdm-event-participant-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 14px;
    text-decoration: none;
    color: var(--gdm-text);
    font-size: 0.85rem;
    transition: background .1s;
}

.gdm-event-participant-row:hover { background: var(--gdm-bg-subtle); }

.gdm-event-participant-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 600;
}

.gdm-event-participant-friend { color: var(--gdm-green); display: flex; flex-shrink: 0; }
.gdm-event-participant-friend svg { width: 13px; height: 13px; }

/* ── Toast local ────────────────────────────────────────────── */
.gdm-event-action-toast {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    padding: 7px 16px;
    border-radius: var(--gdm-radius-pill);
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    z-index: 100;
    pointer-events: none;
    box-shadow: 0 3px 12px rgba(0,0,0,0.15);
}

.gdm-event-action-toast--success { background: var(--gdm-green); }
.gdm-event-action-toast--error   { background: var(--gdm-error); }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 480px) {
    .gdm-event-participants-popover { left: auto; right: 0; }
}

/* ============================================================
   NOUVEAU SYSTÈME ACTIONS (v2.4)
   ============================================================ */

/* Conteneur général actions restructuré */
.gdm-event-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

/* Rangée avatars — cliquable → popover */
.gdm-event-avatars-row {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    position: relative;
    flex-wrap: wrap;
}

.gdm-event-avatars-row--static { cursor: default; }

.gdm-event-avatars-label {
    font-size: 0.8rem;
    color: var(--gdm-text-mid);
    font-family: var(--gdm-font-body);
    white-space: nowrap;
}

.gdm-event-avatars-label strong {
    color: var(--gdm-text);
    font-weight: 700;
}

/* Ligne boutons */
.gdm-event-actions-btns {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Wrappers positionnels pour tooltip */
.gdm-event-action-heart,
.gdm-event-action-item {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

/* Cœur bare — sans background ni border */
.gdm-picto.gdm-event-picto--bare {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    min-width: 32px !important;
    padding: 4px !important;
    height: auto !important;
    color: var(--gdm-text) !important;
}

.gdm-picto.gdm-event-picto--bare:hover,
.gdm-picto.gdm-event-picto--bare:focus,
.gdm-picto.gdm-event-picto--bare:active {
    background: transparent !important;
    box-shadow: none !important;
    color: var(--gdm-primary) !important;
}

.gdm-picto.gdm-event-picto--bare.gdm-event-picto--liked {
    background: transparent !important;
    color: var(--gdm-primary) !important;
}

.gdm-picto.gdm-event-picto--bare .gdm-picto-icon,
.gdm-picto.gdm-event-picto--bare .gdm-picto-icon svg {
    width: 22px !important;
    height: 22px !important;
}

/* Compteur sous le cœur bare */
.gdm-event-heart-count {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--gdm-text-mid);
    font-family: var(--gdm-font-body);
    line-height: 1;
    text-align: center;
}

/* ── Tooltips Alpine ─────────────────────────────────────────── */
.gdm-event-tooltip {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(30, 30, 40, 0.88);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 500;
    white-space: nowrap;
    padding: 5px 10px;
    border-radius: var(--gdm-radius-sm);
    pointer-events: none;
    z-index: 300;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}

/* Petite flèche */
.gdm-event-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: rgba(30, 30, 40, 0.88);
}

/* ============================================================
   LAYOUT LISTE — [gdm_events layout="list"]
   Card horizontale : col-gauche | col-centre | col-droite(photo)
   ============================================================ */

.gdm-event-list-rows {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Row card */
.gdm-event-row {
    display: grid;
    grid-template-columns: 200px 1fr 300px;
    align-items: stretch;
    background: var(--gdm-white);
    border-radius: var(--gdm-radius-lg);
    box-shadow: var(--gdm-shadow-card);
    overflow: hidden;
    transition: box-shadow .2s, transform .2s;
    min-height: 0;
}

.gdm-event-row:hover {
    box-shadow: var(--gdm-shadow-hover);
    transform: translateY(-2px);
}

/* ── Col gauche ─────────────────────────────────────────────── */
.gdm-event-row-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    padding: 25px 16px;
    /*border-right: 1px solid var(--gdm-border);*/
}

/* Grande date typographique */
.gdm-event-row-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    line-height: 1;
}

.gdm-event-row-day {
    font-size: 6rem;
    font-weight: 800;
    color: var(--gdm-text-title);
    line-height: 1;
    font-family: var(--gdm-font-body);
}

.gdm-event-row-month {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--gdm-text-title);
    margin-top: 4px;
}

/* Actions dans col gauche : colonne centrée */
.gdm-event-row-left .gdm-event-actions {
    align-items: center;
    gap: 8px;
    width: 100%;
}

.gdm-event-row-left .gdm-event-actions-btns {
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

/* Cœur bare + compteur côte-à-côte en liste */
.gdm-event-row-left .gdm-event-action-heart {
    flex-direction: row;
    align-items: center;
    gap: 4px;
}

/* Pas d'avatars row dans la col gauche (ils sont dans le centre) */
.gdm-event-row-left .gdm-event-avatars-row { display: none; }

/* ── Col centre ─────────────────────────────────────────────── */
.gdm-event-row-body {
    padding: 36px 20px 36px 2px;
    display: flex;
    flex-direction: column;
    /*gap: 10px;*/
    justify-content: flex-start;
}

.gdm-event-row-title {
    font-size: 1.85rem;
    font-weight: 800;
    margin: 0;
    line-height: 1.2;
}

.gdm-event-row-title a {
    color: var(--gdm-text-title);
    text-decoration: none;
}

.gdm-event-row-title a:hover { color: var(--gdm-primary); }

.gdm-event-row-excerpt {
    font-size: 1rem;
    color: var(--gdm-text);
    margin: 0px !important;
    line-height: 1.62;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gdm-event-row-avatars {
    /*display: flex;*/
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 4px;
}

/* ── Col droite : photo carrée ──────────────────────────────── */
.gdm-event-row-img-link {
    display: block;
    width: 300px;
    flex-shrink: 0;
    overflow: hidden;
}

.gdm-event-row-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s;
}

.gdm-event-row:hover .gdm-event-row-img { transform: scale(1.03); }

.gdm-event-row-img-placeholder {
    width: 100%;
    height: 100%;
    min-height: 200px;
    background: var(--gdm-bg-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gdm-primary-light);
}

.gdm-event-row-img-placeholder svg {
    width: 48px !important;
    height: 48px !important;
}

/* ── Responsive : liste → grille sous 768px ─────────────────── */
@media (max-width: 768px) {
    .gdm-event-row {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }

    /* Photo remonte en haut */
    .gdm-event-row-img-link {
        width: 100%;
        height: 220px;
        order: -1;
    }

    .gdm-event-row-left {
        flex-direction: row;
        justify-content: flex-start;
        border-right: none;
        border-bottom: 1px solid var(--gdm-border);
        padding: 16px;
    }

    .gdm-event-row-left .gdm-event-actions-btns {
        flex-direction: row;
    }

    .gdm-event-row-left .gdm-event-action-heart {
        flex-direction: column;
    }

    .gdm-event-row-body { padding: 16px; }
}
