/* [KH-P07K-SMART-GARAGE-PRIVACY-SETTINGS:BEGIN] */
.kh-garage-privacy {
    margin: 0 0 14px;
    border: 1px solid rgba(120, 150, 180, 0.24);
    border-radius: 18px;
    background: linear-gradient(145deg, rgba(29, 42, 57, 0.96), rgba(20, 31, 43, 0.96));
    box-shadow: 0 10px 28px rgba(5, 12, 20, 0.18);
    overflow: hidden;
}

.kh-garage-privacy__toggle {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 28px;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 60px;
    padding: 10px 14px;
    border: 0;
    color: var(--tg-theme-text-color, #f5f5f5);
    background: transparent;
    text-align: left;
    cursor: pointer;
}

.kh-garage-privacy__toggle-icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(82, 136, 193, 0.18);
    font-size: 21px;
}

.kh-garage-privacy__toggle-copy,
.kh-garage-privacy__setting-copy {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.kh-garage-privacy__toggle-copy strong,
.kh-garage-privacy__setting-copy strong,
.kh-garage-privacy__retention strong {
    font-size: 14px;
    line-height: 1.3;
}

.kh-garage-privacy__toggle-copy span,
.kh-garage-privacy__setting-copy span,
.kh-garage-privacy__retention span {
    color: var(--tg-theme-hint-color, #91a0b0);
    font-size: 12px;
    line-height: 1.35;
}

.kh-garage-privacy__chevron {
    font-size: 22px;
    transition: transform 160ms ease;
}

.kh-garage-privacy[data-expanded="true"] .kh-garage-privacy__chevron {
    transform: rotate(180deg);
}

.kh-garage-privacy__panel {
    padding: 0 14px 14px;
    border-top: 1px solid rgba(120, 150, 180, 0.16);
}

.kh-garage-privacy__panel[hidden],
.kh-garage-privacy__state[hidden],
#kh-garage-privacy-content[hidden] {
    display: none !important;
}

.kh-garage-privacy__state {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 52px;
    color: var(--tg-theme-hint-color, #91a0b0);
    font-size: 13px;
}

.kh-garage-privacy__state--error {
    color: var(--tg-theme-destructive-text-color, #f06767);
}

.kh-garage-privacy__setting {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 52px;
    align-items: center;
    gap: 12px;
    min-height: 66px;
    border-bottom: 1px solid rgba(120, 150, 180, 0.13);
    cursor: pointer;
}

.kh-garage-privacy__switch {
    appearance: none;
    position: relative;
    width: 48px;
    height: 28px;
    margin: 0;
    border: 1px solid rgba(145, 160, 176, 0.42);
    border-radius: 999px;
    background: rgba(83, 99, 116, 0.5);
    cursor: pointer;
    transition: background 150ms ease, border-color 150ms ease;
}

.kh-garage-privacy__switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    transition: transform 150ms ease;
}

.kh-garage-privacy__switch:checked {
    border-color: var(--tg-theme-button-color, #5288c1);
    background: var(--tg-theme-button-color, #5288c1);
}

.kh-garage-privacy__switch:checked::after {
    transform: translateX(20px);
}

.kh-garage-privacy__switch:disabled {
    opacity: 0.55;
    cursor: wait;
}

.kh-garage-privacy__retention {
    display: grid;
    gap: 3px;
    padding: 14px 0;
}

.kh-garage-privacy__secondary,
.kh-garage-privacy__danger {
    min-height: 44px;
    border-radius: 12px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.kh-garage-privacy__secondary {
    padding: 0 14px;
    border: 1px solid rgba(82, 136, 193, 0.5);
    color: var(--tg-theme-link-color, #6ab3f3);
    background: rgba(82, 136, 193, 0.1);
}

.kh-garage-privacy__danger {
    width: 100%;
    border: 1px solid rgba(236, 57, 66, 0.42);
    color: var(--tg-theme-destructive-text-color, #ec3942);
    background: rgba(236, 57, 66, 0.1);
}

.kh-garage-privacy__toggle:focus-visible,
.kh-garage-privacy__switch:focus-visible,
.kh-garage-privacy__secondary:focus-visible,
.kh-garage-privacy__danger:focus-visible {
    outline: 3px solid rgba(106, 179, 243, 0.62);
    outline-offset: 2px;
}

.kh-garage-privacy__live {
    min-height: 18px;
    margin: 10px 0 0;
    color: var(--tg-theme-hint-color, #91a0b0);
    font-size: 12px;
}

.kh-garage-sensitive-identifiers-hidden [data-kh-garage-sensitive-identifier] {
    display: none !important;
}

@media (max-width: 480px) {
    .kh-garage-privacy {
        border-radius: 16px;
    }

    .kh-garage-privacy__toggle {
        grid-template-columns: 44px minmax(0, 1fr) 24px;
        padding-inline: 12px;
    }

    .kh-garage-privacy__panel {
        padding-inline: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .kh-garage-privacy__chevron,
    .kh-garage-privacy__switch,
    .kh-garage-privacy__switch::after {
        transition: none;
    }
}
/* [KH-P07K-SMART-GARAGE-PRIVACY-SETTINGS:END] */

/* [KH-P07M5-EFFECTIVE-SCHEME-GARAGE-PRIVACY:BEGIN] */
html[data-kh-scheme="dark"] .kh-garage-privacy {
    --kh-p07m5-garage-scheme: dark;
}

html[data-kh-scheme="light"] .kh-garage-privacy {
    --kh-p07m5-garage-scheme: light;
    border-color: rgba(112, 132, 153, 0.20);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.99), rgba(240, 246, 252, 0.98));
    background-color: #f7fbff;
    box-shadow: 0 10px 28px rgba(20, 46, 86, 0.10);
}

html[data-kh-scheme="light"] .kh-garage-privacy__toggle {
    color: var(--tg-theme-text-color, #17212b);
}

html[data-kh-scheme="light"] .kh-garage-privacy__toggle-icon {
    background: rgba(36, 129, 204, 0.10);
}

html[data-kh-scheme="light"] .kh-garage-privacy__panel {
    border-top-color: rgba(112, 132, 153, 0.16);
}

html[data-kh-scheme="light"] .kh-garage-privacy__setting {
    border-bottom-color: rgba(112, 132, 153, 0.13);
}

html[data-kh-scheme="light"] .kh-garage-privacy__switch {
    border-color: rgba(112, 132, 153, 0.38);
    background: rgba(112, 132, 153, 0.30);
}

html[data-kh-scheme="light"] .kh-garage-privacy__secondary {
    color: var(--tg-theme-link-color, #2481cc);
    background: rgba(36, 129, 204, 0.08);
}
/* [KH-P07M5-EFFECTIVE-SCHEME-GARAGE-PRIVACY:END] */
