/* Cookie banner and settings dialog (see /js/cookie-consent.js). Own tokens: the page may or may not load the UI kit. */
:root {
    --ck-navy: #163156;
    --ck-blue: #1f7cb2;
    --ck-ink: #1b2430;
    --ck-muted: #5d6b7c;
    --ck-line: #c3ccd7;
    --ck-bg: #ffffff;
    --ck-radius: 3px;
}

.ck-banner, .ck-dialog { font-family: Roboto, Helvetica, Arial, sans-serif; color: var(--ck-ink); }

/* The banner sits at the bottom and does not cover the page: it can be read, and the page used, while it is there. */
.ck-banner {
    position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 10000;
    max-width: 880px; margin: 0 auto; padding: 12px 16px;
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px;
    background: var(--ck-bg); border: 1px solid var(--ck-line); border-radius: var(--ck-radius);
    box-shadow: 0 2px 4px rgba(22, 49, 86, .08), 0 10px 30px rgba(22, 49, 86, .18);
}
.ck-banner__text { flex: 1 1 340px; margin: 0; font-size: 14px; line-height: 1.45; }
.ck-banner a, .ck-dialog a { color: var(--ck-blue); text-decoration: underline; }
.ck-banner__actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* Accept and Reject look the same on purpose: refusing must be as easy as accepting. */
.ck-btn {
    min-height: 40px; padding: 0 16px; border-radius: var(--ck-radius); border: 2px solid var(--ck-navy);
    font: 500 14px/1 Roboto, Helvetica, Arial, sans-serif; letter-spacing: .02em; cursor: pointer;
}
.ck-btn--small { flex: none; min-height: 36px; padding: 0 14px; font-size: 13px; white-space: nowrap; }
.ck-cat--static { cursor: default; }
.ck-btn--solid { background: var(--ck-navy); color: #fff; }
.ck-btn--line { background: transparent; color: var(--ck-navy); }
.ck-btn:hover { filter: brightness(1.15); }
.ck-btn--line:hover { background: #e8f3fa; filter: none; }
.ck-btn:focus-visible, .ck-switch input:focus-visible + .ck-switch__track { outline: 3px solid var(--ck-blue); outline-offset: 2px; }

.ck-dialog { width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 24px); padding: 0; border: 0; border-radius: var(--ck-radius); background: var(--ck-bg); box-shadow: 0 20px 60px rgba(0, 0, 0, .35); }
.ck-dialog::backdrop { background: rgba(22, 49, 86, .55); }
.ck-dialog__form { margin: 0; padding: 24px; }
.ck-dialog__title { margin: 0 0 8px; font: 600 20px/1.3 Montserrat, Helvetica, Arial, sans-serif; color: var(--ck-navy); }
.ck-dialog__intro { margin: 0 0 16px; font-size: 14px; line-height: 1.5; color: var(--ck-muted); }
.ck-dialog__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }

.ck-cat { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-top: 1px solid var(--ck-line); cursor: pointer; }
.ck-cat__body { display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.45; }
.ck-cat__body strong { font-size: 15px; color: var(--ck-navy); }
.ck-cat__body span { color: var(--ck-muted); }
.ck-always { flex: none; font-size: 13px; font-weight: 500; color: var(--ck-muted); }
.ck-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* A real checkbox drawn as a switch, so it works with the keyboard and screen readers. */
.ck-switch { position: relative; flex: none; width: 48px; height: 28px; }
.ck-switch input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.ck-switch__track { position: absolute; inset: 0; border-radius: 14px; background: #8a96a6; transition: background .15s; pointer-events: none; }
.ck-switch__track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .15s; }
.ck-switch input:checked + .ck-switch__track { background: var(--ck-navy); }
.ck-switch input:checked + .ck-switch__track::after { transform: translateX(20px); }

@media (max-width: 600px) {
    .ck-banner { left: 8px; right: 8px; bottom: 8px; padding: 14px; max-height: 70vh; overflow: auto; }
    .ck-banner__actions { width: 100%; }
    .ck-banner__actions .ck-btn { flex: 1 1 100%; }
    .ck-dialog__form { padding: 18px; }
    .ck-dialog__actions .ck-btn { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .ck-switch__track, .ck-switch__track::after { transition: none; }
}
