/* ============================ THE COOKIE POP-UP ============================
   assets/js/shared/consent.js draws it; linked from assets/templates/shared/consent.php on every page frame.
   The same look on the shell and the old pages, light or dark: everything is set here, nothing inherited.
   Above everything the site opens, the sign-in modal included (z-index 61), and still usable over it.
   ========================================================================== */
.ck, .ck-chip, .ck-toast { --ck-g: #00FF50; --ck-ink: #0a0a0a; --ck-paper: #f5f5f3; --ck-line: #3a3a3a; --ck-mute: #9a9a95;
    box-sizing: border-box; font-family: 'Archivo', sans-serif; -webkit-font-smoothing: antialiased; text-align: left; }
.ck *, .ck *::before, .ck *::after, .ck-chip *, .ck-toast * { box-sizing: border-box; }

.ck { position: fixed; left: clamp(16px, 2.4vw, 32px); bottom: clamp(16px, 2.4vw, 32px); z-index: 2147482500;
    width: min(460px, calc(100vw - 32px)); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px);
    display: flex; flex-direction: column; margin: 0; padding: 0;
    background: var(--ck-ink); color: var(--ck-paper); border: 2px solid var(--ck-paper); border-radius: 0;
    box-shadow: 12px 12px 0 var(--ck-g); outline: none; }
.ck[hidden] { display: none; }
.ck.ck-in { animation: ck-in .5s cubic-bezier(.2, .7, .2, 1); }
@keyframes ck-in { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }

.ck-hatch { flex: none; height: 8px; background: repeating-linear-gradient(-45deg, var(--ck-g) 0 4px, var(--ck-ink) 4px 8px); }
.ck-body { flex: 1; min-height: 0; overflow: auto; padding: 20px 22px 6px; }
.ck-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 12px; }
.ck-hd { min-width: 0; flex: 1; }
.ck-kicker { font: 800 10px 'Archivo', sans-serif; letter-spacing: .18em; color: var(--ck-g); margin-bottom: 8px; text-transform: uppercase; }
.ck .ck-title { margin: 0; padding: 0; font: 900 clamp(26px, 2.6vw, 34px)/.95 'Archivo', sans-serif; letter-spacing: -.045em; color: var(--ck-paper); text-transform: none; }
.ck .ck-x { appearance: none; -webkit-appearance: none; width: 36px; height: 36px; flex: none; display: grid; place-items: center; margin: 0; padding: 0;
    background: transparent; color: var(--ck-paper); border: 1px solid var(--ck-line); border-radius: 0; cursor: pointer;
    font: 400 20px/1 'Archivo', sans-serif; box-shadow: none; }
.ck .ck-x:hover { border-color: var(--ck-g); color: var(--ck-g); }
.ck .ck-text { margin: 0 0 14px; font: 500 14px/1.55 'Archivo', sans-serif; color: #d0d0cc; }
.ck .ck-link, .ck .ck-link:visited { color: inherit; text-decoration: underline; }
.ck .ck-link:hover { color: var(--ck-g); }

.ck-cats { border-top: 1px solid #2a2a2a; margin-bottom: 6px; }
.ck-cats[hidden] { display: none; }
.ck-cat { display: flex; align-items: flex-start; gap: 14px; padding: 13px 0; border-bottom: 1px solid #2a2a2a; }
.ck-cat-tx { min-width: 0; flex: 1; }
.ck-cat-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ck .ck-cat-t { margin: 0; font: 900 15px 'Archivo', sans-serif; color: var(--ck-paper); cursor: pointer; text-transform: none; letter-spacing: 0; }
.ck-tag { padding: 1px 6px; border: 1px solid var(--ck-line); font: 800 8.5px 'Archivo', sans-serif; letter-spacing: .12em; color: var(--ck-mute); text-transform: uppercase; }
.ck-cat-d { font: 600 12.5px/1.45 'Archivo', sans-serif; color: var(--ck-mute); margin-top: 3px; }

/* the switches: real checkboxes (role switch), drawn as the design's square toggles */
.ck-sw { position: relative; width: 40px; height: 22px; flex: none; margin-top: 2px; }
.ck .ck-sw input { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; margin: 0; padding: 0; opacity: 0; cursor: pointer; appearance: none; -webkit-appearance: none; }
.ck .ck-sw input:disabled { cursor: not-allowed; }
.ck-sw-k { position: absolute; inset: 0; background: #2a2a2a; border: 1px solid #55554f; transition: background .15s, border-color .15s; }
.ck-sw-k::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; background: var(--ck-paper); transition: left .15s, background .15s; }
.ck-sw input:checked + .ck-sw-k { background: var(--ck-g); border-color: var(--ck-g); }
.ck-sw input:checked + .ck-sw-k::after { left: 20px; background: var(--ck-ink); }
.ck-sw input:disabled + .ck-sw-k { opacity: .6; }
.ck-sw input:focus-visible + .ck-sw-k { outline: 2px solid var(--ck-g); outline-offset: 2px; }

.ck-foot { flex: none; padding: 12px 22px 20px; }
.ck-act { display: flex; align-items: center; gap: 8px; }
.ck .ck-btn { appearance: none; -webkit-appearance: none; flex: 1; margin: 0; cursor: pointer; white-space: nowrap; border-radius: 0; box-shadow: none;
    font: 800 12px 'Archivo', sans-serif; letter-spacing: .14em; text-transform: uppercase; text-align: left; line-height: normal; }
.ck .ck-btn-go { padding: 14px 16px; background: var(--ck-g); color: var(--ck-ink); border: 0; }
.ck .ck-btn-go:hover { background: var(--ck-paper); }
.ck .ck-btn-line { padding: 12px 14px; background: transparent; color: var(--ck-paper); border: 2px solid var(--ck-paper); }
.ck .ck-btn-line:hover { background: var(--ck-paper); color: var(--ck-ink); }
.ck .ck-btn-none { flex: none; }
.ck .ck-more { appearance: none; -webkit-appearance: none; display: inline-block; margin: 12px 0 0; padding: 0 0 2px; cursor: pointer;
    background: transparent; color: var(--ck-paper); border: 0; border-bottom: 2px solid var(--ck-g); border-radius: 0;
    font: 800 11.5px 'Archivo', sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.ck .ck-more:hover { color: var(--ck-g); }

.ck button:focus-visible, .ck a:focus-visible, .ck:focus-visible, .ck-chip:focus-visible { outline: 2px solid var(--ck-g); outline-offset: 2px; }

/* the chip that reopens it */
.ck-chip { appearance: none; -webkit-appearance: none; position: fixed; left: clamp(16px, 2.4vw, 32px); bottom: clamp(16px, 2.4vw, 32px); z-index: 2147482500;
    display: flex; align-items: center; gap: 9px; margin: 0; cursor: pointer; padding: 10px 13px;
    background: var(--ck-ink); color: var(--ck-paper); border: 1px solid var(--ck-line); border-radius: 0; box-shadow: none;
    font: 800 10.5px 'Archivo', sans-serif; letter-spacing: .14em; text-transform: uppercase; }
.ck-chip[hidden] { display: none; }
.ck-chip:hover { border-color: var(--ck-g); color: var(--ck-g); }
.ck-chip-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--ck-g); flex: none; }

/* the toast */
.ck-toast { position: fixed; left: 50%; bottom: 24px; z-index: 2147482600; display: flex; align-items: center; gap: 10px;
    padding: 11px 16px 11px 11px; max-width: calc(100vw - 32px); background: var(--ck-ink); color: var(--ck-paper); border: 2px solid var(--ck-g);
    font: 800 13px 'Archivo', sans-serif; transform: translate(-50%, 180%); transition: transform .3s; pointer-events: none; }
.ck-toast.is-on { transform: translate(-50%, 0); }
.ck-toast-i { width: 20px; height: 20px; flex: none; display: grid; place-items: center; background: var(--ck-g); color: var(--ck-ink); font: 900 12px 'Archivo', sans-serif; }

@media (max-width: 640px) {
    .ck { left: 0; right: 0; bottom: 0; width: auto; border-left: 0; border-right: 0; border-bottom: 0; }
    .ck-act { flex-direction: column; align-items: stretch; }
    .ck .ck-btn { text-align: center; }
    .ck-toast { bottom: 68px; }   /* above the chip */
}
@media (prefers-reduced-motion: reduce) {
    .ck.ck-in { animation: none; }
    .ck-toast, .ck-sw-k, .ck-sw-k::after { transition: none; }
}
