/* Consent Management Platform — eco-gobelets / eco-worms / jardi3d */

.egc-banner {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 2147483646;
    background: #ffffff;
    color: #1a1a1a;
    border-top: 1px solid #d0d0d0;
    box-shadow: 0 -4px 16px rgba(0,0,0,.08);
    padding: 16px 20px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.45;
}
.egc-banner-text { flex: 1 1 320px; min-width: 0; }
.egc-banner-text a { color: #2563eb; text-decoration: underline; }
.egc-banner-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    flex: 0 0 auto;
}

.egc-btn {
    appearance: none;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #1a1a1a;
    padding: 9px 16px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    line-height: 1.2;
    min-width: 110px;
    transition: background .15s, border-color .15s;
    font-family: inherit;
}
.egc-btn:hover { background: #f1f5f9; }
.egc-btn:focus-visible { outline: 2px solid #2563eb; outline-offset: 2px; }
.egc-btn-primary {
    background: #1a1a1a;
    color: #fff;
    border-color: #1a1a1a;
}
.egc-btn-primary:hover { background: #333; border-color: #333; }
.egc-btn-secondary { /* default style above */ }

/* ----- Modal preferences ----- */
.egc-modal {
    position: fixed;
    inset: 0;
    z-index: 2147483647;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.egc-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.55);
}
.egc-modal-content {
    position: relative;
    background: #fff;
    color: #1a1a1a;
    border-radius: 8px;
    padding: 24px;
    max-width: 520px;
    width: calc(100% - 32px);
    max-height: calc(100vh - 64px);
    overflow-y: auto;
    box-shadow: 0 12px 40px rgba(0,0,0,.25);
}
.egc-modal-content h2 {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: 600;
}
.egc-cat {
    border-top: 1px solid #e5e7eb;
    padding: 12px 0;
}
.egc-cat label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    cursor: pointer;
}
.egc-cat label input[disabled] { cursor: not-allowed; }
.egc-cat p {
    margin: 6px 0 0 24px;
    font-size: 13px;
    color: #555;
    line-height: 1.4;
}
.egc-tag {
    display: inline-block;
    font-size: 11px;
    padding: 2px 8px;
    background: #e5e7eb;
    border-radius: 10px;
    color: #555;
    font-weight: normal;
    margin-left: 6px;
}
.egc-modal-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

/* ----- Floating reopen button (bottom left, small) ----- */
.egc-fab {
    position: fixed;
    left: 12px;
    bottom: 12px;
    z-index: 2147483645;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #555;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,.12);
    padding: 0;
    transition: background .15s, color .15s;
}
.egc-fab:hover { background: #f1f5f9; color: #1a1a1a; }
.egc-fab:focus-visible { outline: 2px solid #2563eb; outline-offset: 2px; }

/* ----- Mobile ----- */
@media (max-width: 640px) {
    .egc-banner {
        padding: 12px 14px;
        gap: 10px;
        font-size: 13px;
    }
    .egc-banner-actions {
        width: 100%;
        flex-direction: column-reverse; /* primary en bas */
    }
    .egc-btn { width: 100%; min-width: 0; }
    .egc-modal-content { padding: 18px; }
}
