/* Cookie lišta a nastavení soukromí - WeLoveIT.Education
   Barevnost i typografie vychází ze styly/style.css (#1b1a20, #4f77aa, #eee, Montserrat + IBM Plex Mono) */

/* Zámek posuvníku při otevřeném nastavení */
html.cookie-lock, html.cookie-lock body { overflow: hidden;}

/* Rozměry počítáme včetně paddingu - jen uvnitř této komponenty, zbytku webu se to netýká */
.cookie-face, .cookie-face *, .cookie-modal, .cookie-modal * { box-sizing: border-box;}

/* Společné ovládací prvky */
.cookie-btn { height: 50px; padding: 0 30px; font-family: "Montserrat", serif; font-size: 14px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; text-align: center; cursor: pointer; border: 0; border-radius: 30px; display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; transition: all .35s ease-in-out; box-shadow: 0 rgba(0,0,0,.3);}
.cookie-btn-primary { color: #fff; padding: 0 56px 0 30px; background: #4f77aa url('../themes/link.png') right 24px center no-repeat; background-size: 12px;}
.cookie-btn-primary:hover { background: #4f77aa url('../themes/link.png') right 21px center no-repeat; background-size: 18px; box-shadow: 0 5px 10px 0 rgba(0,0,0,.3);}
.cookie-btn-dark { color: #fff; padding: 0 56px 0 30px; background: #1b1a20 url('../themes/link.png') right 24px center no-repeat; background-size: 12px;}
.cookie-btn-dark:hover { background: #1b1a20 url('../themes/link.blue.png') right 21px center no-repeat; background-size: 18px; box-shadow: 0 5px 10px 0 rgba(0,0,0,.3);}
.cookie-btn-ghost { color: #fff; background: transparent; border: 2px dotted rgba(255,255,255,.35);}
.cookie-btn-ghost:hover { color: #fff; border: 2px dotted #4f77aa; background: rgba(79,119,170,.15);}
.cookie-btn-ghost-dark { color: #1b1a20; background: transparent; border: 2px dotted rgba(27,26,32,.25);}
.cookie-btn-ghost-dark:hover { color: #4f77aa; border: 2px dotted #4f77aa; background: rgba(79,119,170,.10);}
.cookie-btn-link { height: 50px; padding: 0 6px; font-family: "Montserrat", serif; font-size: 14px; font-weight: 500; color: rgba(255,255,255,.65); text-decoration: underline; text-underline-offset: 4px; background: none; border: 0; cursor: pointer; transition: all .35s ease-in-out;}
.cookie-btn-link:hover { color: #4f77aa;}
.cookie-face :focus-visible, .cookie-modal :focus-visible { outline: 2px solid #4f77aa; outline-offset: 3px;}

/* Cookie lišta */
.cookie-face { width: 100%; position: fixed; left: 0; bottom: 0; z-index: 9000; padding: 0 0 20px 0; display: flex; flex-wrap: wrap; justify-content: center; transition: opacity .35s ease-in-out, transform .35s ease-in-out, visibility .35s ease-in-out;}
.cookie-face[hidden] { display: none;}
.cookie-face.is-closed { opacity: 0; visibility: hidden; transform: translateY(30px);}
.cookie-box { width: 1300px; max-width: calc(100% - 40px); min-width: 0; padding: 30px 40px; border-radius: 18px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 30px; color: #fff; background: #1b1a20; box-shadow: 0 5px 20px 0 rgba(0,0,0,.35); animation: cookie-in .45s ease-in-out both;}

.cookie-text { width: 620px; max-width: 100%; min-width: 0; flex: 1 1 480px;}
.cookie-text h2 { width: 100%; font-family: 'IBM Plex Mono', monospace; font-size: 21px; font-weight: 300; color: #fff; margin: 0 0 10px 0;}
.cookie-text h2 strong { font-weight: 600; color: #4f77aa;}
.cookie-prompt { color: #4f77aa; font-weight: 600;}
.cookie-text p { width: 100%; font-size: 15px; font-weight: 300; line-height: 1.6; color: rgba(255,255,255,.7); margin: 0;}
.cookie-text a { color: #fff; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; transition: all .35s ease-in-out;}
.cookie-text a:hover { color: #4f77aa;}

.cookie-action { width: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px;}

/* Nastavení - překryv */
.cookie-modal { width: 100%; height: 100%; position: fixed; top: 0; left: 0; z-index: 9500; padding: 20px 0; overflow-y: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; background: rgba(27,26,32,.85); transition: opacity .35s ease-in-out, visibility .35s ease-in-out;}
.cookie-modal[hidden] { display: none;}
.cookie-modal.is-closed { opacity: 0; visibility: hidden;}
.cookie-modal-box { width: 700px; max-width: calc(100% - 40px); min-width: 0; padding: 40px; margin: auto; position: relative; border-radius: 18px; background: #eee; box-shadow: 0 5px 20px 0 rgba(0,0,0,.35); animation: cookie-in .45s ease-in-out both;}
.cookie-modal-close { width: 40px; height: 40px; position: absolute; top: 20px; right: 20px; font-size: 22px; line-height: 1; color: #1b1a20; cursor: pointer; background: transparent; border: 2px dotted rgba(27,26,32,.2); border-radius: 100%; display: flex; align-items: center; justify-content: center; transition: all .35s ease-in-out;}
.cookie-modal-close:hover { color: #4f77aa; border: 2px dotted #4f77aa;}

.cookie-modal-box h2 { width: calc(100% - 50px); font-family: 'IBM Plex Mono', monospace; font-size: 24px; font-weight: 300; color: #1b1a20; margin: 0 0 12px 0;}
.cookie-modal-box h2 strong { font-weight: 600; color: #4f77aa;}
.cookie-modal-intro { width: 100%; font-size: 15px; font-weight: 300; line-height: 1.6; color: #444; margin: 0 0 10px 0; padding: 0 0 22px 0; background: url('../themes/wave.png') bottom left no-repeat; background-size: auto 12px;}
.cookie-modal-intro a { color: #1b1a20; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; transition: all .35s ease-in-out;}
.cookie-modal-intro a:hover { color: #4f77aa;}

/* Kategorie */
.cookie-group { width: 100%; padding: 22px 25px; margin: 20px 0 0 0; border: 1px solid #cfcfcf; border-radius: 12px; display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 20px; background: rgba(255,255,255,.6); transition: all .35s ease-in-out;}
.cookie-group:hover { border: 1px solid #4f77aa;}
.cookie-group-text { flex: 1 1 340px; min-width: 0;}
.cookie-group-text h3 { width: 100%; font-size: 17px; font-weight: 600; color: #1b1a20; margin: 0 0 6px 0;}
.cookie-group-text p { width: 100%; font-size: 14px; font-weight: 300; line-height: 1.6; color: #555; margin: 0;}
.cookie-group-state { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: #4f77aa; margin: 0 0 0 8px; white-space: nowrap;}
.cookie-modal-intro span { font-weight: 600; color: #4f77aa;}

/* Přepínač */
.cookie-switch { width: 56px; height: 30px; position: relative; flex: 0 0 auto; display: block; cursor: pointer;}
.cookie-switch input { width: 100%; height: 100%; position: absolute; top: 0; left: 0; margin: 0; opacity: 0; cursor: pointer;}
.cookie-switch-track { width: 56px; height: 30px; position: absolute; top: 0; left: 0; border-radius: 30px; background: rgba(27,26,32,.18); transition: all .35s ease-in-out;}
.cookie-switch-track::after { content: ''; width: 22px; height: 22px; position: absolute; top: 4px; left: 4px; border-radius: 100%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: all .35s ease-in-out;}
.cookie-switch input:checked + .cookie-switch-track { background: #4f77aa;}
.cookie-switch input:checked + .cookie-switch-track::after { left: 30px;}
.cookie-switch input:focus-visible + .cookie-switch-track { outline: 2px solid #4f77aa; outline-offset: 3px;}
.cookie-switch input:disabled { cursor: not-allowed;}
.cookie-switch input:disabled + .cookie-switch-track { background: rgba(79,119,170,.45);}

/* Tlačítka nastavení */
.cookie-modal-action { width: 100%; margin: 30px 0 0 0; padding: 25px 0 0 0; border-top: 1px solid #cfcfcf; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px;}

/* Animace */
@keyframes cookie-in { from { opacity: 0; transform: translateY(20px);} to { opacity: 1; transform: translateY(0);}}

/* Tablety */
@media screen and (max-width: 1099px) {
    .cookie-box { width: auto; max-width: calc(100% - 40px); padding: 25px 30px; gap: 22px;}
    .cookie-action { width: 100%; justify-content: flex-start;}
}

/* Menší tablety a telefony */
@media screen and (max-width: 768px) {
    .cookie-face { padding: 0 0 12px 0;}
    .cookie-box { max-width: calc(100% - 24px); padding: 25px; border-radius: 12px; gap: 20px;}
    .cookie-text { flex-basis: 100%;}
    .cookie-text h2 { font-size: 19px;}
    .cookie-text p { font-size: 14px;}
    .cookie-group-text { flex-basis: 100%;}
    .cookie-action { gap: 10px;}
    .cookie-btn { width: 100%; height: 48px; padding: 0 24px;}
    .cookie-btn-primary, .cookie-btn-dark { padding: 0 50px 0 24px;}
    .cookie-btn-link { width: 100%; height: 40px;}
    .cookie-modal-box { max-width: calc(100% - 24px); padding: 30px 25px; border-radius: 12px;}
    .cookie-modal-box h2 { font-size: 21px;}
    .cookie-group { padding: 20px;}
    .cookie-modal-action { justify-content: center;}
}

/* Mobilní telefony */
@media screen and (max-width: 480px) {
    .cookie-box { padding: 22px 20px;}
    .cookie-text h2 { font-size: 17px;}
    .cookie-modal-close { top: 12px; right: 12px;}
    .cookie-group-text h3 { font-size: 16px;}
}

/* Omezený pohyb */
@media (prefers-reduced-motion: reduce) {
    .cookie-face, .cookie-box, .cookie-modal, .cookie-modal-box, .cookie-btn, .cookie-group, .cookie-switch-track, .cookie-switch-track::after { animation: none !important; transition: none !important;}
}
