:root {
    --cc-primary: #0865c6;
    --cc-primary-hover: #0052a8;
    --cc-text: #213247;
    --cc-muted: #667587;
    --cc-border: #d7dde4;
    --cc-background: #ffffff;
    --cc-section-background: #f4f5f7;
    --cc-overlay: rgba(12, 23, 36, 0.65);
    --cc-switch-off: #9aa7b5;
    --cc-shadow: 0 10px 35px rgba(0, 0, 0, 0.2);
}

.cc-scroll-lock {
    overflow: hidden;
}

#cc-root,
#cc-root * {
    box-sizing: border-box;
}

#cc-root {
    font-family: Arial, Helvetica, sans-serif;
    color: var(--cc-text);
}

#cc-root [hidden] {
    display: none !important;
}

/* Překrytí stránky */

.cc-overlay {
    position: fixed;
    z-index: 999998;
    inset: 0;
    background: var(--cc-overlay);
}

/* První informační okno */

.cc-banner {
    position: fixed;
    z-index: 999999;
    left: 16px;
    bottom: 16px;
    width: calc(100% - 32px);
    max-width: 430px;
    padding: 22px 16px 18px;
    background: var(--cc-background);
    border: 1px solid var(--cc-border);
    border-radius: 4px;
    box-shadow: var(--cc-shadow);
}

.cc-banner__title {
    margin: 0 0 12px;
    font-size: 21px;
    line-height: 1.25;
    font-weight: 700;
    color: var(--cc-text);
}

.cc-banner__text {
    margin: 0 0 16px;
    font-size: 17px;
    line-height: 1.48;
    color: var(--cc-muted);
}

.cc-banner__actions {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.cc-settings-link {
    display: inline-block;
    margin-top: 14px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--cc-primary);
    font-family: inherit;
    font-size: 15px;
    line-height: 1.4;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.cc-settings-link:hover,
.cc-settings-link:focus {
    color: var(--cc-primary-hover);
}

/* Tlačítka */

.cc-button {
    min-height: 46px;
    padding: 10px 18px;
    border: 1px solid var(--cc-primary);
    border-radius: 5px;
    background: var(--cc-background);
    color: var(--cc-primary);
    font-family: inherit;
    font-size: 17px;
    line-height: 1.2;
    font-weight: 600;
    cursor: pointer;
    transition:
        background-color 0.15s ease,
        color 0.15s ease,
        border-color 0.15s ease;
}

.cc-button:hover,
.cc-button:focus {
    border-color: var(--cc-primary-hover);
    color: var(--cc-primary-hover);
}

.cc-button--primary:hover,
.cc-button--primary:focus {
    background: var(--cc-primary);
    color: #ffffff;
}

.cc-button--secondary {
    background: var(--cc-background);
}

.cc-banner__actions .cc-button {
    flex: 1 1 0;
}

/* Detailní nastavení */

.cc-modal {
    position: fixed;
    z-index: 999999;
    top: 50%;
    left: 50%;
    width: calc(100% - 32px);
    max-width: 600px;
    max-height: calc(100vh - 36px);
    transform: translate(-50%, -50%);
    overflow: hidden;
    background: var(--cc-background);
    border-radius: 10px;
    box-shadow: var(--cc-shadow);
}

.cc-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 66px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--cc-border);
}

.cc-modal__title {
    margin: 0;
    padding-right: 16px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 700;
    color: var(--cc-text);
}

.cc-modal__close {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--cc-muted);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 38px;
    line-height: 36px;
    font-weight: 300;
    cursor: pointer;
}

.cc-modal__close:hover,
.cc-modal__close:focus {
    color: var(--cc-text);
}

.cc-modal__body {
    max-height: calc(100vh - 102px);
    padding: 20px;
    overflow-y: auto;
}

.cc-modal__intro {
    margin: 0 0 14px;
    font-size: 17px;
    line-height: 1.5;
    color: var(--cc-muted);
}

.cc-privacy-row {
    margin: 12px 0;
}

.cc-link {
    color: var(--cc-primary);
    text-decoration: none;
}

.cc-link:hover,
.cc-link:focus {
    color: var(--cc-primary-hover);
    text-decoration: underline;
}

.cc-modal__top-actions {
    display: flex;
    gap: 18px;
    margin: 20px 0;
}

.cc-modal__top-actions .cc-button {
    flex: 1 1 0;
}

/* Kategorie */

.cc-category {
    margin-top: 12px;
    padding: 18px 20px;
    background: var(--cc-section-background);
    border-radius: 6px;
}

.cc-category__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.cc-category__title {
    margin: 0;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 400;
    color: var(--cc-text);
}

.cc-category__status {
    flex: 0 0 auto;
    font-size: 14px;
    font-weight: 600;
    color: #9aa3ad;
}

.cc-category__description {
    margin: 14px 0 0;
    padding-top: 14px;
    border-top: 1px solid var(--cc-border);
    font-size: 15px;
    line-height: 1.4;
    color: var(--cc-muted);
}

/* Seznam služeb */

.cc-service-list {
    margin-top: 14px;
    padding-top: 2px;
}

.cc-service {
    margin-top: 12px;
    padding: 12px 14px;
    background: #ffffff;
    border: 1px solid var(--cc-border);
    border-radius: 5px;
}

.cc-service__title {
    display: block;
    margin-bottom: 4px;
    font-size: 15px;
    color: var(--cc-text);
}

.cc-service__description {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
    color: var(--cc-muted);
}

/* Přepínač */

.cc-switch {
    position: relative;
    display: inline-block;
    flex: 0 0 auto;
    width: 50px;
    height: 28px;
}

.cc-switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.cc-switch__slider {
    position: absolute;
    inset: 0;
    background: var(--cc-switch-off);
    border-radius: 28px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.cc-switch__slider::before {
    position: absolute;
    content: "";
    left: 3px;
    bottom: 3px;
    width: 22px;
    height: 22px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
    transition: transform 0.2s ease;
}

.cc-switch input:checked + .cc-switch__slider {
    background: var(--cc-primary);
}

.cc-switch input:checked + .cc-switch__slider::before {
    transform: translateX(22px);
}

.cc-switch input:focus-visible + .cc-switch__slider {
    outline: 3px solid rgba(8, 101, 198, 0.25);
    outline-offset: 2px;
}

.cc-save-button {
    width: 100%;
    margin-top: 20px;
}

/* Skrytý text pro čtečky */

.cc-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Mobil */

@media (max-width: 640px) {
    .cc-banner {
        left: 8px;
        bottom: 8px;
        width: calc(100% - 16px);
        max-width: none;
        padding: 18px 14px;
    }

    .cc-banner__title {
        font-size: 19px;
    }

    .cc-banner__text {
        font-size: 15px;
    }

    .cc-banner__actions,
    .cc-modal__top-actions {
        flex-direction: column-reverse;
        gap: 10px;
    }

    .cc-button {
        width: 100%;
        font-size: 16px;
    }

    .cc-modal {
        top: 8px;
        left: 8px;
        width: calc(100% - 16px);
        max-height: calc(100vh - 16px);
        transform: none;
        border-radius: 8px;
    }

    .cc-modal__header {
        min-height: 60px;
        padding: 10px 14px;
    }

    .cc-modal__body {
        max-height: calc(100vh - 76px);
        padding: 16px;
    }

    .cc-modal__intro {
        font-size: 15px;
    }

    .cc-category {
        padding: 16px;
    }

    .cc-category__header {
        gap: 12px;
    }
}