/* Cookie consent banner & modal — design papier, indépendant de budget.css */

.bp-cc-banner,
.bp-cc-modal,
.bp-cc-modal *,
.bp-cc-banner * {
    box-sizing: border-box;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ============ Banner bas de page ============ */
.bp-cc-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9998;
    background: #f5f3ee;
    border-top: 1px solid #b8b3ab;
    box-shadow: 0 -4px 24px rgba(26, 23, 20, 0.08);
    padding: 1em 1.2em;
    color: #1a1714;
    transform: translateY(0);
    transition: transform 280ms ease;
}
.bp-cc-banner[hidden] { display: none; }
.bp-cc-banner.bp-cc-leaving { transform: translateY(100%); }

.bp-cc-inner {
    max-width: 64em;
    margin: 0 auto;
    display: flex;
    gap: 1.2em;
    align-items: flex-start;
    flex-wrap: wrap;
}
.bp-cc-text { flex: 1 1 22em; min-width: 0; }
.bp-cc-text h2 {
    margin: 0 0 0.4em;
    font-family: 'Newsreader', Georgia, serif;
    font-weight: 500;
    font-size: 1.15em;
    line-height: 1.2;
}
.bp-cc-text p {
    margin: 0 0 0.5em;
    font-size: 0.85em;
    line-height: 1.5;
    color: #3d3832;
}
.bp-cc-text a {
    font-size: 0.8em;
    color: #1a1714;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.bp-cc-text a:hover { color: #5d574e; }

.bp-cc-actions {
    display: flex;
    gap: 0.5em;
    flex-wrap: wrap;
    align-items: center;
}
.bp-cc-banner button,
.bp-cc-modal button {
    font-family: inherit;
    font-size: 0.85em;
    padding: 0.6em 1.1em;
    border-radius: 4px;
    cursor: pointer;
    border: 1px solid #1a1714;
    background: transparent;
    color: #1a1714;
    line-height: 1.2;
    transition: background 120ms, color 120ms;
    min-height: 38px;
}
.bp-cc-banner button:hover,
.bp-cc-modal button:hover {
    background: #ebe8e0;
}
.bp-cc-banner button[data-action="accept-all"],
.bp-cc-modal button[data-action="save"] {
    background: #1a1714;
    color: #f5f3ee;
}
.bp-cc-banner button[data-action="accept-all"]:hover,
.bp-cc-modal button[data-action="save"]:hover {
    background: #3d3832;
}

/* ============ Modal de personnalisation ============ */
.bp-cc-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(26, 23, 20, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1em;
    opacity: 1;
    transition: opacity 200ms ease;
}
.bp-cc-modal[hidden] { display: none; }
.bp-cc-modal.bp-cc-leaving { opacity: 0; }

.bp-cc-modal-inner {
    background: #f5f3ee;
    border: 1px solid #b8b3ab;
    border-radius: 8px;
    max-width: 32em;
    width: 100%;
    max-height: 88vh;
    overflow-y: auto;
    padding: 1.4em 1.5em;
    color: #1a1714;
    box-shadow: 0 12px 40px rgba(26, 23, 20, 0.22);
}
.bp-cc-modal-inner h2 {
    margin: 0 0 0.5em;
    font-family: 'Newsreader', Georgia, serif;
    font-weight: 500;
    font-size: 1.35em;
    line-height: 1.2;
}
.bp-cc-modal-inner > p {
    margin: 0 0 1.2em;
    font-size: 0.875em;
    line-height: 1.55;
    color: #3d3832;
}

.bp-cc-cat {
    padding: 0.8em 0;
    border-top: 1px solid #d8d3ca;
}
.bp-cc-cat:first-of-type { border-top: none; }
.bp-cc-cat label {
    display: flex;
    align-items: center;
    gap: 0.6em;
    cursor: pointer;
    margin-bottom: 0.3em;
}
.bp-cc-cat label[data-locked="1"] { cursor: default; }
.bp-cc-cat input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #1a1714;
    cursor: pointer;
}
.bp-cc-cat input[type="checkbox"]:disabled { cursor: default; opacity: 0.7; }
.bp-cc-cat-title {
    font-weight: 600;
    font-size: 0.95em;
}
.bp-cc-cat-locked {
    font-size: 0.7em;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #5d574e;
    font-weight: 500;
    margin-left: 0.3em;
}
.bp-cc-cat p {
    margin: 0;
    padding-left: 1.7em;
    font-size: 0.82em;
    line-height: 1.5;
    color: #5d574e;
}

.bp-cc-modal-actions {
    margin-top: 1.4em;
    padding-top: 1.1em;
    border-top: 1px solid #d8d3ca;
    display: flex;
    gap: 0.6em;
    justify-content: flex-end;
    flex-wrap: wrap;
}

/* ============ Mobile ============ */
@media (max-width: 540px) {
    .bp-cc-banner { padding: 0.9em 0.9em calc(0.9em + env(safe-area-inset-bottom, 0px)); }
    .bp-cc-inner { gap: 0.9em; }
    .bp-cc-actions { width: 100%; }
    .bp-cc-banner button { flex: 1 1 auto; min-width: 0; }
    .bp-cc-modal-inner { padding: 1.1em 1em; }
    .bp-cc-modal-actions button { flex: 1 1 auto; }
}
