/* Souhlas s cookies (partials/analytics.html, static/js/cookie-consent.js).
   Vlastní CSS, protože souhlas musí vypadat stejně i v konfigurátoru v2,
   který Bootstrap CSS nenačítá. Tokeny podle grafického manuálu
   (analysis/redesign/_tokens.css): jedna plná oranžová akce, tlačítka 44 px
   s poloměrem 8 px, karty 16 px, stín e-xl jen u modálního okna.
   Maskot a jeho silnice: static/css/hn-mascot.css. */

.tkcc {
    --tkcc-brand: #d9772c;
    --tkcc-brand-dark: #b35d1d;
    --tkcc-navy: #1e3a5f;
    --tkcc-navy-deep: #16293f;
    --tkcc-ink: #1a1a2e;
    --tkcc-slate: #475569;
    --tkcc-line: #e2e8f0;
    --tkcc-success: #16a34a;
    --tkcc-e-md: 0 6px 16px rgba(16,32,52,.10);
    --tkcc-e-xl: 0 18px 44px rgba(16,32,52,.16);
    --tkcc-ease: cubic-bezier(.2,.7,.2,1);
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--tkcc-ink);
    line-height: 1.55;
}
.tkcc[hidden], .tkcc [hidden] { display: none !important; }
.tkcc *, .tkcc *::before, .tkcc *::after { box-sizing: border-box; }
html.tkcc-lock { overflow: hidden; }
.tkcc-sr {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.tkcc-dim {
    position: fixed; inset: 0; z-index: 1080;
    background: rgba(10,12,16,.45);
    opacity: 0; pointer-events: none;
    transition: opacity .3s ease;
}
.tkcc-dim.is-on { opacity: 1; pointer-events: auto; }

/* ---------- Karta (F) a výbava (G) ---------- */
.tkcc-card, .tkcc-panel {
    position: fixed; z-index: 1081; left: 50%; top: 50%;
    width: min(460px, calc(100% - 32px));
    max-height: calc(100% - 32px);
    background: #fff; border-radius: 16px; box-shadow: var(--tkcc-e-xl);
    overflow: hidden;
    opacity: 0; transform: translate(-50%, -46%);
    transition: opacity .3s ease, transform .4s var(--tkcc-ease);
    outline: none;
}
.tkcc-panel { width: min(560px, calc(100% - 32px)); display: flex; flex-direction: column; }
.tkcc-card.is-on, .tkcc-panel.is-on { opacity: 1; transform: translate(-50%, -50%); }
/* Po volbě už okno nic nedrží, maskot jen dojede. */
.tkcc-card.is-leaving, .tkcc-panel.is-leaving { pointer-events: none; }

.tkcc-road { height: 150px; overflow: hidden; }
.tkcc-road--sm { height: 100px; flex: none; }
.tkcc-body { padding: 20px 24px 22px; }
.tkcc-h {
    margin: 2px 0 8px; font-family: inherit; font-size: 1.4rem; font-weight: 800;
    line-height: 1.2; letter-spacing: -.02em; color: var(--tkcc-ink);
}
.tkcc-h--sm { font-size: 1.2rem; margin: 0; }
.tkcc-word { letter-spacing: .1em; white-space: nowrap; }
.tkcc-word i { font-style: normal; transition: opacity .25s ease; }
.tkcc-word i.is-gone { opacity: .15; }
.tkcc-text { margin: 0; color: var(--tkcc-slate); font-size: .95rem; }

.tkcc-actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.tkcc-actions .tkcc-btn { flex: 1 1 0; }
.tkcc-actions--panel { margin: 0; padding: 16px 22px; border-top: 1px solid var(--tkcc-line); flex: none; }
.tkcc-actions--panel .tkcc-btn { flex: 1 1 auto; }
.tkcc-foot {
    margin-top: 14px; font-size: .8125rem; color: var(--tkcc-slate);
    display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
}
.tkcc-foot a { color: var(--tkcc-slate); text-decoration: underline; text-underline-offset: 3px; }

.tkcc-btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px; padding: 12px 20px; margin: 0;
    border-radius: 8px; border: 1px solid transparent;
    font: inherit; font-size: .95rem; font-weight: 700; line-height: 1;
    white-space: nowrap; cursor: pointer; text-decoration: none;
    transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.tkcc-btn--primary { background: var(--tkcc-brand); color: #fff; }
.tkcc-btn--primary:hover { background: var(--tkcc-brand-dark); color: #fff; }
.tkcc-btn--outline { background: transparent; color: var(--tkcc-navy); border-color: var(--tkcc-navy); }
.tkcc-btn--outline:hover { background: var(--tkcc-navy); color: #fff; }
.tkcc-btn--sm { min-height: 40px; padding: 10px 16px; font-size: .875rem; }
.tkcc-link {
    background: none; border: 0; padding: 0; font: inherit; font-weight: 700;
    color: var(--tkcc-brand-dark); cursor: pointer;
}
.tkcc-link:hover { text-decoration: underline; }
.tkcc-btn:focus-visible, .tkcc-link:focus-visible, .tkcc-close:focus-visible,
.tkcc-corner-btn:focus-visible, .tkcc-foot a:focus-visible {
    outline: 3px solid rgba(2,132,199,.55); outline-offset: 2px;
}

/* Výbava */
.tkcc-top { display: flex; align-items: center; gap: 16px; padding: 16px 22px; border-bottom: 1px solid var(--tkcc-line); flex: none; }
.tkcc-load { margin-left: auto; text-align: right; }
.tkcc-mono { font-family: 'JetBrains Mono', ui-monospace, monospace; font-feature-settings: 'tnum' 1; font-size: .9rem; }
.tkcc-mono b { font-weight: 600; }
.tkcc-meter { display: flex; gap: 3px; margin-top: 4px; justify-content: flex-end; }
.tkcc-meter i { display: block; width: 22px; height: 6px; border-radius: 2px; background: var(--tkcc-line); transition: background .25s; }
.tkcc-meter i.is-on { background: var(--tkcc-navy); }
.tkcc-close {
    flex: none; width: 36px; height: 36px; border: 0; border-radius: 8px; background: transparent;
    color: var(--tkcc-slate); font-size: 1.1rem; cursor: pointer;
}
.tkcc-close:hover { background: #f1f5f9; color: var(--tkcc-ink); }
.tkcc-list { overflow: auto; padding: 0 22px; }
.tkcc-row {
    display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: start;
    padding: 14px 0; border-bottom: 1px solid var(--tkcc-line);
}
.tkcc-row:last-child { border-bottom: 0; }
.tkcc-row strong { display: block; font-size: .95rem; }
.tkcc-row small { display: block; color: var(--tkcc-slate); font-size: .8125rem; line-height: 1.45; margin-top: 2px; }
.tkcc-who { display: block; font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: .72rem; color: var(--tkcc-slate); margin-top: 2px; }
.tkcc-always { font-size: .75rem; font-weight: 700; color: var(--tkcc-success); white-space: nowrap; padding-top: 3px; }
.tkcc-sw { position: relative; display: block; width: 46px; height: 26px; flex: none; margin: 2px 0 0; }
.tkcc-sw input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.tkcc-sw span { position: absolute; inset: 0; border-radius: 999px; background: var(--tkcc-line); transition: background .2s; }
.tkcc-sw span::after {
    content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%;
    background: #fff; box-shadow: 0 1px 3px rgba(16,32,52,.2); transition: transform .25s var(--tkcc-ease);
}
.tkcc-sw input:checked + span { background: var(--tkcc-navy); }
.tkcc-sw input:checked + span::after { transform: translateX(20px); }
.tkcc-sw input:focus-visible + span { outline: 3px solid rgba(2,132,199,.55); outline-offset: 2px; }

/* ---------- Maskot v rohu (H) ---------- */
.tkcc-corner { position: fixed; left: 16px; bottom: 16px; z-index: 1070; }
.tkcc-corner-btn {
    display: block; width: 150px; height: 74px; padding: 0; border: 0; border-radius: 16px;
    background: var(--tkcc-navy-deep); box-shadow: var(--tkcc-e-md); cursor: pointer; overflow: hidden;
    opacity: 0; transform: translateY(12px); transition: opacity .3s ease, transform .4s var(--tkcc-ease);
}
.tkcc-corner.is-on .tkcc-corner-btn { opacity: 1; transform: none; }
.tkcc-road--corner { display: block; width: 100%; height: 100%; background: transparent; }
.tkcc-pop {
    position: absolute; left: 0; bottom: 86px; width: 260px;
    background: #fff; border-radius: 12px; box-shadow: var(--tkcc-e-xl); padding: 14px 16px;
    opacity: 0; transform: translateY(8px); pointer-events: none;
    transition: opacity .2s ease, transform .3s var(--tkcc-ease);
}
.tkcc-pop.is-on { opacity: 1; transform: none; pointer-events: auto; }
.tkcc-pop-t { margin: 0; font-weight: 700; font-size: .95rem; }
.tkcc-pop-act { display: flex; gap: 14px; align-items: center; margin-top: 10px; }

/* ---------- Mobil: spodní panel ---------- */
@media (max-width: 575.98px) {
    .tkcc-card, .tkcc-panel {
        left: 0; right: 0; top: auto; bottom: 0; width: 100%;
        max-height: 92%;
        border-radius: 16px 16px 0 0;
        transform: translateY(40px);
    }
    .tkcc-card.is-on, .tkcc-panel.is-on { transform: none; }
    .tkcc-road { height: 128px; }
    .tkcc-road--sm { height: 84px; }
    .tkcc-body { padding: 18px 18px 20px; }
    .tkcc-actions--panel { padding: 14px 18px; }
    .tkcc-list { padding: 0 18px; }
    .tkcc-top { padding: 14px 18px; }
    .tkcc-corner { left: 12px; bottom: 12px; }
    .tkcc-corner-btn { width: 128px; height: 66px; }
    .tkcc-pop { bottom: 78px; }
}

@media (prefers-reduced-motion: reduce) {
    .tkcc-dim, .tkcc-card, .tkcc-panel, .tkcc-corner-btn, .tkcc-pop, .tkcc-word i { transition: none; }
}
