/* ---------------------------------------------------------------------------
   Arsan Kimya - KVKK / cerez onay bileseni
   Tema degiskenleri (--base-color, --dark-gray) corporate.css tarafindan
   tanimlanir; yuklenmemesi ihtimaline karsi fallback degerler kullanilir.
   --------------------------------------------------------------------------- */

.ck-banner,
.ck-modal {
    --ck-accent: var(--base-color, #3C2FC0);
    --ck-dark: var(--dark-gray, #242E45);
    font-family: inherit;
    color: var(--ck-dark);
}

/* --- Alt bant --- */
.ck-banner {
    position: fixed;
    left: 20px;
    right: 20px;
    bottom: 20px;
    z-index: 10000;
    max-width: 1140px;
    margin: 0 auto;
    padding: 24px 28px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 18px 45px rgba(36, 46, 69, .22);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 20px;
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .35s ease, transform .35s ease;
}

.ck-banner.ck-visible {
    opacity: 1;
    transform: translateY(0);
}

.ck-banner__text {
    flex: 1 1 420px;
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
    color: #5b6273;
}

.ck-banner__title {
    display: block;
    font-size: 17px;
    font-weight: 600;
    color: var(--ck-dark);
    margin-bottom: 6px;
}

.ck-banner__text a,
.ck-modal__intro a {
    color: var(--ck-accent);
    text-decoration: underline;
}

.ck-banner__actions {
    flex: 0 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* --- Butonlar --- */
.ck-btn {
    display: inline-block;
    border: 1px solid transparent;
    border-radius: 4px;
    padding: 11px 22px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: .3px;
    line-height: 1.2;
    cursor: pointer;
    background: none;
    transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}

.ck-btn--accept {
    background: var(--ck-accent);
    color: #fff;
}

.ck-btn--accept:hover {
    background: var(--ck-dark);
    color: #fff;
}

.ck-btn--reject,
.ck-btn--settings {
    border-color: #d7dae2;
    color: var(--ck-dark);
}

.ck-btn--reject:hover,
.ck-btn--settings:hover {
    border-color: var(--ck-dark);
    background: var(--ck-dark);
    color: #fff;
}

/* --- Tercih penceresi --- */
.ck-modal {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(36, 46, 69, .55);
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
}

.ck-modal.ck-visible {
    opacity: 1;
    visibility: visible;
}

.ck-modal__dialog {
    background: #fff;
    border-radius: 8px;
    width: 100%;
    max-width: 640px;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 60px rgba(36, 46, 69, .3);
}

.ck-modal__header,
.ck-modal__footer {
    padding: 22px 28px;
}

.ck-modal__header {
    border-bottom: 1px solid #eceef3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.ck-modal__header h2 {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
    color: var(--ck-dark);
}

.ck-modal__close {
    background: none;
    border: 0;
    font-size: 26px;
    line-height: 1;
    color: #8a90a0;
    cursor: pointer;
    padding: 0 4px;
}

.ck-modal__close:hover {
    color: var(--ck-dark);
}

.ck-modal__body {
    padding: 8px 28px 20px;
    overflow-y: auto;
}

.ck-modal__intro {
    font-size: 14px;
    line-height: 1.7;
    color: #5b6273;
    margin: 16px 0 4px;
}

.ck-group {
    border-bottom: 1px solid #eceef3;
    padding: 18px 0;
}

.ck-group:last-child {
    border-bottom: 0;
}

.ck-group__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.ck-group__name {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    color: var(--ck-dark);
}

.ck-group__desc {
    font-size: 14px;
    line-height: 1.7;
    color: #5b6273;
    margin: 8px 0 0;
}

.ck-group__always {
    font-size: 13px;
    font-weight: 600;
    color: var(--ck-accent);
    white-space: nowrap;
}

/* Switch */
.ck-switch {
    position: relative;
    flex: 0 0 auto;
    width: 46px;
    height: 26px;
}

.ck-switch input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    cursor: pointer;
    z-index: 2;
}

.ck-switch__track {
    position: absolute;
    inset: 0;
    background: #ccd0da;
    border-radius: 26px;
    transition: background-color .25s ease;
    pointer-events: none;
}

.ck-switch__track::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    transition: transform .25s ease;
}

.ck-switch input:checked + .ck-switch__track {
    background: var(--ck-accent);
}

.ck-switch input:checked + .ck-switch__track::after {
    transform: translateX(20px);
}

.ck-switch input:focus-visible + .ck-switch__track {
    outline: 2px solid var(--ck-dark);
    outline-offset: 2px;
}

.ck-modal__footer {
    border-top: 1px solid #eceef3;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

/* display:flex tanimlarinin [hidden] ozniteligini ezmemesi icin */
.ck-banner[hidden],
.ck-modal[hidden] {
    display: none;
}

@media (max-width: 767px) {
    .ck-banner {
        left: 12px;
        right: 12px;
        bottom: 12px;
        padding: 20px;
    }

    .ck-banner__actions,
    .ck-modal__footer {
        width: 100%;
    }

    .ck-banner__actions .ck-btn,
    .ck-modal__footer .ck-btn {
        flex: 1 1 100%;
        text-align: center;
    }
}
