:root {
    --gallimea-primary:   #1e40af;
    --gallimea-secondary: #64748b;
}

.gag-wrap { margin: 16px 0; width: 100%; }

/* Notices */
.gag-notice { padding: 10px 14px; border-radius: 6px; margin-bottom: 16px; font-size: 14px; }
.gag-notice--success { background: #d1fae5; color: #065f46; }
.gag-notice--info    { background: #dbeafe; color: #1e40af; }
.gag-notice--error   { background: #fee2e2; color: #991b1b; }

/* Navigation */
.gag-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 16px;
}

.gag-nav__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--gallimea-primary);
    border-radius: 6px;
    color: var(--gallimea-primary);
    text-decoration: none;
    font-size: 18px;
    transition: background .15s;
}

.gag-nav__btn:hover { background: var(--gallimea-primary); color: #fff; }
.gag-nav__titre { font-size: 18px; font-weight: 600; min-width: 180px; text-align: center; }

/* Calendrier */
.gag-calendrier {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    width: 100%;
}

.gag-cal__header {
    background: var(--gallimea-primary);
    color: #fff;
    padding: 8px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    border-right: 1px solid rgba(255,255,255,.2);
}

.gag-cal__cell {
    min-height: 80px;
    padding: 6px;
    border-right: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
    font-size: 12px;
}

.gag-cal__cell--vide { background: #fafafa; }

.gag-cal__cell--today { background: #eff6ff; }
.gag-cal__cell--today .gag-cal__jour {
    background: var(--gallimea-primary);
    color: #fff;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.gag-cal__jour { display: block; font-weight: 600; margin-bottom: 3px; font-size: 12px; }

.gag-event {
    display: block;
    width: 100%;
    text-align: left;
    font-size: 11px;
    color: #fff;
    padding: 2px 5px;
    border-radius: 3px;
    margin-bottom: 2px;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: opacity .15s;
}

.gag-event:hover { opacity: .85; }
.gag-event--inscription { outline: 2px dashed rgba(255,255,255,.6); }

/* Légende */
.gag-legende {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 12px;
    font-size: 13px;
    color: var(--gallimea-secondary);
}

.gag-legende__item { display: flex; align-items: center; gap: 6px; }
.gag-legende__dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; flex-shrink: 0; }

/* Modal */
.gag-modal { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; }
.gag-modal__overlay { position: absolute; inset: 0; background: rgba(0,0,0,.5); }
.gag-modal__content {
    position: relative;
    background: #fff;
    border-radius: 8px;
    padding: 24px;
    max-width: 560px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    z-index: 1;
}

.gag-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: #64748b;
    line-height: 1;
    padding: 4px;
}

.gag-modal__title { font-size: 20px; font-weight: 700; margin-bottom: 12px; color: #1d2327; }
.gag-modal__cat { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--gallimea-secondary); margin-bottom: 12px; }
.gag-modal__meta { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; font-size: 14px; }
.gag-modal__meta-row { display: flex; gap: 8px; }
.gag-modal__meta-label { min-width: 80px; color: var(--gallimea-secondary); }
.gag-modal__description { font-size: 14px; line-height: 1.7; margin-bottom: 16px; color: #374151; }
.gag-modal__map { height: 200px; border-radius: 6px; overflow: hidden; margin-bottom: 16px; }

.gag-btn {
    display: inline-block;
    padding: 10px 20px;
    background: var(--gallimea-primary);
    color: #fff !important;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    transition: opacity .15s;
}

.gag-btn:hover { opacity: .85; }
.gag-btn--secondary { background: transparent; color: var(--gallimea-secondary) !important; border: 1px solid var(--gallimea-secondary); }
.gag-btn--danger { background: #dc2626; }

.gag-places { font-size: 13px; color: var(--gallimea-secondary); margin-bottom: 8px; }
.gag-complet { font-size: 13px; color: #dc2626; font-weight: 500; }

/* Responsive */
@media (max-width: 600px) {
    .gag-calendrier { grid-template-columns: repeat(7, 1fr); }
    .gag-cal__cell { min-height: 50px; padding: 3px; }
    .gag-event { font-size: 9px; padding: 1px 3px; }
    .gag-cal__header { font-size: 10px; padding: 4px 2px; }
}
