/* Cookie Consent Banner & Modal – devdoit.pl */

.cc-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: #0b1114;
    border-top: 1px solid rgba(147, 228, 1, 0.2);
    padding: 1rem 1.5rem;
    box-shadow: 0 -4px 32px rgba(0, 0, 0, 0.6);
    max-height: 20vh;
    overflow-y: auto;
}

.cc-banner__inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.cc-banner__text {
    flex: 1;
    min-width: 200px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.875rem;
    line-height: 1.55;
    margin: 0;
}

.cc-link {
    color: #93e401;
    text-decoration: underline;
    white-space: nowrap;
}

.cc-link:hover {
    color: #c8f566;
}

.cc-banner__buttons {
    display: flex;
    gap: 0.625rem;
    flex-wrap: wrap;
    flex-shrink: 0;
}

/* Buttons */
.cc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1.125rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: transform 150ms ease, box-shadow 150ms ease, opacity 150ms ease;
    white-space: nowrap;
    font-family: inherit;
    line-height: 1;
}

.cc-btn--primary {
    background: linear-gradient(90deg, #c8f566 0%, #93e401 100%);
    color: #000000;
    border: 1px solid transparent;
}

.cc-btn--primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(147, 228, 1, 0.35);
}

.cc-btn--secondary {
    background: transparent;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.cc-btn--secondary:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.3);
}

.cc-btn--outline {
    background: transparent;
    color: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.cc-btn--outline:hover {
    color: rgba(255, 255, 255, 0.8);
    border-color: rgba(255, 255, 255, 0.25);
}

/* Modal */
.cc-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cc-modal[hidden] {
    display: none;
}

.cc-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
}

.cc-modal__box {
    position: relative;
    background: #111820;
    border: 1px solid rgba(147, 228, 1, 0.15);
    border-radius: 12px;
    padding: 2rem;
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(147, 228, 1, 0.05);
}

.cc-modal__title {
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 1.25rem;
}

.cc-modal__categories {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 1.5rem;
}

.cc-category {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 8px;
    padding: 0.875rem 1rem;
}

.cc-category__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.35rem;
}

.cc-category__name {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.875rem;
}

.cc-category__always {
    font-size: 0.72rem;
    color: #93e401;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.cc-category__desc {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.78rem;
    margin: 0;
    line-height: 1.45;
}

/* Toggle switch */
.cc-switch {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
    width: 100%;
    justify-content: space-between;
    margin: 0;
}

.cc-switch input {
    display: none;
}

.cc-switch__slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    transition: background 0.2s;
    flex-shrink: 0;
}

.cc-switch__slider::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    transition: transform 0.2s, background 0.2s;
}

.cc-switch input:checked + .cc-switch__slider {
    background: rgba(147, 228, 1, 0.25);
    border: 1px solid rgba(147, 228, 1, 0.5);
}

.cc-switch input:checked + .cc-switch__slider::after {
    transform: translateX(20px);
    background: #93e401;
}

.cc-modal__footer {
    display: flex;
    gap: 0.625rem;
    justify-content: flex-end;
}

/* Footer link */
.cc-footer-link {
    color: inherit;
    text-decoration: none;
    opacity: 0.55;
    font-size: 0.75rem;
    transition: opacity 150ms ease;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
}

.cc-footer-link:hover {
    opacity: 1;
    text-decoration: underline;
}

/* Mobile */
@media (max-width: 640px) {
    .cc-banner {
        padding: 0.875rem 1rem;
    }

    .cc-banner__inner {
        flex-direction: column;
        align-items: stretch;
        gap: 0.625rem;
    }

    .cc-banner__buttons {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .cc-banner__buttons .cc-btn:last-child {
        grid-column: 1 / -1;
    }

    .cc-modal__box {
        padding: 1.25rem;
    }

    .cc-modal__footer {
        flex-direction: column-reverse;
    }
}
