#tlc-cookie-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    background: rgba(0,0,0,0.55);
    z-index: 9999990;
    -webkit-transform: translateZ(0);
}

.tlc-cookie-popup,
.tlc-cookie-config {
    display: none;
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 240px;
    background: #fff;
    border-radius: 16px;
    border: 0.5px solid rgba(0,0,0,0.15);
    overflow: hidden;
    z-index: 9999999;
    box-sizing: border-box;
}

.tlc-cookie-config {
    max-height: calc(100vh - 40px);
    overflow-y: auto;
}

@media (prefers-color-scheme: dark) {
    .tlc-cookie-popup,
    .tlc-cookie-config {
        background: #1a1a1a;
        border-color: rgba(255,255,255,0.12);
    }
}

.tlc-cookie-body {
    padding: 18px 18px 0;
}

.tlc-cookie-title {
    margin: 0 0 4px;
    font-size: 13px;
    font-weight: 500;
    color: #111;
}

.tlc-cookie-desc {
    margin: 0 0 10px;
    font-size: 11.5px;
    color: #666;
    line-height: 1.5;
}

.tlc-cookie-link {
    display: block;
    margin-bottom: 16px;
    font-size: 11px;
    color: #888;
    text-decoration: underline;
}

@media (prefers-color-scheme: dark) {
    .tlc-cookie-title  { color: #eee; }
    .tlc-cookie-desc   { color: #aaa; }
    .tlc-cookie-link   { color: #777; }
}

.tlc-cookie-actions {
    border-top: 0.5px solid rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
}

@media (prefers-color-scheme: dark) {
    .tlc-cookie-actions { border-color: rgba(255,255,255,0.07); }
}

.tlc-btn {
    all: unset;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 0.5px solid rgba(0,0,0,0.08);
    transition: background 0.12s;
    box-sizing: border-box;
    width: 100%;
}

@media (prefers-color-scheme: dark) {
    .tlc-btn { border-color: rgba(255,255,255,0.07); }
}

.tlc-btn:last-child {
    border-bottom: none;
}

.tlc-btn-muted {
    color: #555;
    background: transparent;
}

.tlc-btn-muted:hover {
    background: rgba(0,0,0,0.04);
}

.tlc-btn-primary {
    color: #fff;
    background: #111;
}

.tlc-btn-primary:hover {
    background: #333;
}

@media (prefers-color-scheme: dark) {
    .tlc-btn-muted        { color: #aaa; }
    .tlc-btn-muted:hover  { background: rgba(255,255,255,0.05); }
    .tlc-btn-primary      { background: #eee; color: #111; }
    .tlc-btn-primary:hover{ background: #fff; }
}

.tlc-btn-icon {
    font-size: 10px;
    opacity: 0.4;
}

.tlc-config-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 0;
    border-top: 0.5px solid rgba(0,0,0,0.08);
}

@media (prefers-color-scheme: dark) {
    .tlc-config-row { border-color: rgba(255,255,255,0.07); }
}

.tlc-config-info { flex: 1; }

.tlc-config-name {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #111;
    margin-bottom: 2px;
}

.tlc-config-desc {
    font-size: 11px;
    color: #999;
    line-height: 1.4;
}

@media (prefers-color-scheme: dark) {
    .tlc-config-name { color: #eee; }
    .tlc-config-desc { color: #666; }
}

.tlc-badge {
    font-size: 10px;
    color: #aaa;
    background: rgba(0,0,0,0.05);
    padding: 2px 7px;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}

@media (prefers-color-scheme: dark) {
    .tlc-badge { background: rgba(255,255,255,0.07); color: #666; }
}

.tlc-toggle {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 19px;
    flex-shrink: 0;
    cursor: pointer;
}

.tlc-toggle input { opacity:0; width:0; height:0; }

.tlc-slider {
    position: absolute;
    inset: 0;
    background: #ccc;
    border-radius: 19px;
    transition: background 0.2s;
}

.tlc-slider::before {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    background: #fff;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: transform 0.2s;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.tlc-toggle input:checked + .tlc-slider { background: #111; }
.tlc-toggle input:checked + .tlc-slider::before { transform: translateX(15px); }

@media (prefers-color-scheme: dark) {
    .tlc-toggle input:checked + .tlc-slider { background: #eee; }
    .tlc-toggle input:checked + .tlc-slider::before { background: #111; }
}

.tlc-toggle-disabled { opacity: 0.45; cursor: not-allowed; }

body.tlc-cookie-blocked { pointer-events: none; }
body.tlc-cookie-blocked #tlc-cookie-overlay { display: block; }
body.tlc-cookie-blocked .tlc-cookie-popup,
body.tlc-cookie-blocked .tlc-cookie-config { pointer-events: auto; }

@media (max-width: 480px) {
    .tlc-cookie-popup,
    .tlc-cookie-config {
        left: 12px;
        right: 12px;
        width: auto;
        bottom: 16px;
    }
}
