/**
 * GOQUEER Cookie Consent
 * Passend zum Theme-Design-System.
 */

/* ========== BANNER CONTAINER ========== */
.gq-cc {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.gq-cc--visible {
    opacity: 1;
    visibility: visible;
}

.gq-cc__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 15, 0.6);
    backdrop-filter: blur(4px);
}

body.gq-cc-open {
    overflow: hidden;
}

/* ========== DIALOG ========== */
.gq-cc__dialog {
    position: relative;
    width: 100%;
    max-width: 720px;
    max-height: 90vh;
    margin: 0 20px 20px;
    overflow-y: auto;
    background: rgba(105, 98, 254, 0.92);
    backdrop-filter: blur(var(--gq-blur, 20px));
    border: 2px solid rgba(97, 255, 112, 0.4);
    border-radius: var(--gq-border-radius, 30px);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 0 20px rgba(97, 255, 112, 0.1);
    transform: translateY(40px);
    transition: transform 0.4s ease;
}

.gq-cc--visible .gq-cc__dialog {
    transform: translateY(0);
}

.gq-cc__content {
    padding: 30px 35px;
}

/* Scrollbar im Dialog */
.gq-cc__dialog::-webkit-scrollbar {
    width: 6px;
}

.gq-cc__dialog::-webkit-scrollbar-track {
    background: transparent;
}

.gq-cc__dialog::-webkit-scrollbar-thumb {
    background: rgba(97, 255, 112, 0.3);
    border-radius: 3px;
}

/* ========== TITLE & TEXT ========== */
.gq-cc__title {
    position: relative;
    display: inline-block;
    font-family: var(--gq-font-heading, 'Arvo', serif);
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 12px;
    animation: gq-cc-glitch 8s infinite;
}

.gq-cc__title::before,
.gq-cc__title::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    mix-blend-mode: screen;
}

.gq-cc__title::before {
    color: #61FF70;
    animation: gq-cc-glitch-layer1 8s infinite;
}

.gq-cc__title::after {
    color: #FF1493;
    animation: gq-cc-glitch-layer2 8s infinite 0.05s;
}

@keyframes gq-cc-glitch {
    0%, 94%, 100% {
        transform: skew(0deg) scaleX(1);
    }
    95% {
        transform: skew(-3deg) scaleX(1.05);
    }
    96% {
        transform: skew(4deg) scaleX(0.95);
    }
    97% {
        transform: skew(-2deg) scaleX(1.03);
    }
}

@keyframes gq-cc-glitch-layer1 {
    0%, 94%, 100% {
        clip-path: inset(0 0 100% 0);
        transform: translateX(0);
        opacity: 0;
    }
    95% {
        clip-path: inset(20% 0 50% 0);
        transform: translateX(-8px);
        opacity: 0.7;
    }
    96% {
        clip-path: inset(60% 0 10% 0);
        transform: translateX(6px);
        opacity: 0.8;
    }
    97% {
        clip-path: inset(35% 0 45% 0);
        transform: translateX(-4px);
        opacity: 0.5;
    }
}

@keyframes gq-cc-glitch-layer2 {
    0%, 94%, 100% {
        clip-path: inset(0 0 100% 0);
        transform: translateX(0);
        opacity: 0;
    }
    95.5% {
        clip-path: inset(40% 0 30% 0);
        transform: translateX(10px);
        opacity: 0.6;
    }
    96.5% {
        clip-path: inset(15% 0 65% 0);
        transform: translateX(-7px);
        opacity: 0.7;
    }
}

.gq-cc__text {
    font-family: var(--gq-font-body, 'Work Sans', sans-serif);
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    margin-bottom: 20px;
}

.gq-cc__link {
    color: var(--gq-green, #61FF70);
    text-decoration: none;
    transition: color 0.3s;
}

.gq-cc__link:hover {
    text-decoration: underline;
    color: #fff;
}

/* ========== BUTTONS ========== */
.gq-cc__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.gq-cc__btn {
    padding: 12px 24px;
    font-family: var(--gq-font-body, 'Work Sans', sans-serif);
    font-weight: 700;
    font-size: 0.9rem;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    letter-spacing: 0.5px;
    text-decoration: none;
    display: inline-block;
    line-height: 1.2;
}

.gq-cc__btn:focus-visible {
    outline: 3px solid var(--gq-green, #61FF70);
    outline-offset: 2px;
}

/* Alle akzeptieren — Primary */
.gq-cc__btn--accept-all {
    background: var(--gq-green, #61FF70);
    color: var(--gq-purple, #6962FE);
    border: 2px solid rgba(97, 255, 112, 0.8);
    box-shadow: 0 4px 15px rgba(97, 255, 112, 0.3);
}

.gq-cc__btn--accept-all:hover {
    background: #52EE61;
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(97, 255, 112, 0.5);
}

/* Alle ablehnen — gleich prominent wie akzeptieren (DSGVO) */
.gq-cc__btn--reject-all {
    background: rgba(255, 255, 255, 0.95);
    color: var(--gq-purple, #6962FE);
    border: 2px solid rgba(97, 255, 112, 0.5);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.gq-cc__btn--reject-all:hover {
    background: #fff;
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(97, 255, 112, 0.3);
}

/* Einstellungen / Details toggle */
.gq-cc__btn--toggle-details {
    background: transparent;
    color: rgba(255, 255, 255, 0.85);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.gq-cc__btn--toggle-details:hover {
    border-color: rgba(97, 255, 112, 0.6);
    color: #fff;
}

/* Speichern */
.gq-cc__btn--save {
    background: var(--gq-green, #61FF70);
    color: var(--gq-purple, #6962FE);
    border: 2px solid rgba(97, 255, 112, 0.8);
    box-shadow: 0 4px 15px rgba(97, 255, 112, 0.3);
}

.gq-cc__btn--save:hover {
    background: #52EE61;
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(97, 255, 112, 0.5);
}

/* ========== LEGAL LINKS ========== */
.gq-cc__legal {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.gq-cc__legal .gq-cc__link {
    font-size: 0.8rem;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.gq-cc__legal .gq-cc__link:hover {
    opacity: 1;
}

/* ========== DETAILS PANEL ========== */
.gq-cc__details {
    margin-bottom: 20px;
}

.gq-cc__category {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(97, 255, 112, 0.2);
    border-radius: 16px;
    padding: 16px 20px;
    margin-bottom: 10px;
}

.gq-cc__category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.gq-cc__toggle-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    flex: 1;
}

.gq-cc__category-name {
    font-family: var(--gq-font-heading, 'Arvo', serif);
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
}

.gq-cc__badge {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--gq-green, #61FF70);
    background: rgba(97, 255, 112, 0.15);
    border: 1px solid rgba(97, 255, 112, 0.3);
    border-radius: 12px;
    padding: 2px 10px;
    white-space: nowrap;
}

.gq-cc__category-desc {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    margin-top: 8px;
    margin-bottom: 0;
}

/* ========== TOGGLE SWITCH ========== */
.gq-cc__toggle {
    appearance: none;
    -webkit-appearance: none;
    width: 48px;
    height: 26px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 13px;
    position: relative;
    cursor: pointer;
    transition: background 0.3s;
    flex-shrink: 0;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.gq-cc__toggle::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.3s, background 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.gq-cc__toggle:checked {
    background: var(--gq-green, #61FF70);
    border-color: rgba(97, 255, 112, 0.6);
}

.gq-cc__toggle:checked::after {
    transform: translateX(22px);
    background: var(--gq-purple, #6962FE);
}

.gq-cc__toggle:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.gq-cc__toggle:focus-visible {
    outline: 3px solid var(--gq-green, #61FF70);
    outline-offset: 2px;
}

/* ========== DIENSTE (Service-Level Toggles) ========== */
.gq-cc__service-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0;
}

.gq-cc__service-item {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 6px;
    font-size: 0.8rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
}

.gq-cc__service-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.gq-cc__service-label {
    cursor: pointer;
    flex: 1;
}

.gq-cc__service-item strong {
    color: #fff;
}

.gq-cc__service-provider {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
}

.gq-cc__service-desc {
    display: block;
    margin-top: 4px;
    color: rgba(255, 255, 255, 0.7);
}

.gq-cc__service-cookies {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
    font-family: monospace;
}

/* Service-Toggle (kleiner als Kategorie-Toggle) */
.gq-cc__service-toggle {
    appearance: none;
    -webkit-appearance: none;
    width: 38px;
    height: 22px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 11px;
    position: relative;
    cursor: pointer;
    transition: background 0.3s;
    flex-shrink: 0;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.gq-cc__service-toggle::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.3s, background 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.gq-cc__service-toggle:checked {
    background: var(--gq-green, #61FF70);
    border-color: rgba(97, 255, 112, 0.6);
}

.gq-cc__service-toggle:checked::after {
    transform: translateX(16px);
    background: var(--gq-purple, #6962FE);
}

.gq-cc__service-toggle:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.gq-cc__service-toggle:focus-visible {
    outline: 3px solid var(--gq-green, #61FF70);
    outline-offset: 2px;
}

/* ========== FLOATING BADGE (Tab am unteren Rand) ========== */
.gq-cc-badge {
    position: fixed;
    bottom: 0;
    left: 30px;
    z-index: 9999;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(105, 98, 254, 0.92);
    backdrop-filter: blur(var(--gq-blur, 20px));
    border: 2px solid rgba(97, 255, 112, 0.4);
    border-bottom: none;
    border-radius: 14px 14px 0 0;
    color: #fff;
    font-family: var(--gq-font-body, 'Work Sans', sans-serif);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 -2px 15px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transform: translateY(100%);
    transition: opacity 0.4s ease, transform 0.4s ease, background 0.3s, box-shadow 0.3s;
}

.gq-cc-badge--visible {
    opacity: 1;
    transform: translateY(0);
}

.gq-cc-badge:hover {
    background: rgba(105, 98, 254, 1);
    border-color: rgba(97, 255, 112, 0.7);
    box-shadow: 0 -4px 20px rgba(97, 255, 112, 0.25);
}

.gq-cc-badge:focus-visible {
    outline: 3px solid var(--gq-green, #61FF70);
    outline-offset: 2px;
}

.gq-cc-badge svg {
    flex-shrink: 0;
}

/* ========== RESPONSIVE ========== */

/* Tablet */
@media (max-width: 1024px) {
    .gq-cc__dialog {
        max-width: 600px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .gq-cc {
        align-items: flex-end;
    }

    .gq-cc__dialog {
        max-width: none;
        margin: 0;
        border-radius: 20px 20px 0 0;
        max-height: 85vh;
    }

    .gq-cc__content {
        padding: 24px 20px;
    }

    .gq-cc__title {
        font-size: 1.3rem;
    }

    .gq-cc__actions {
        flex-direction: column;
    }

    .gq-cc__btn {
        width: 100%;
        text-align: center;
    }
}

/* Mobile Badge */
@media (max-width: 768px) {
    .gq-cc-badge {
        left: 15px;
        padding: 6px 14px;
        font-size: 0.7rem;
    }

    .gq-cc-badge span {
        display: none;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .gq-cc__content {
        padding: 20px 15px;
    }

    .gq-cc__title {
        font-size: 1.15rem;
    }

    .gq-cc__text {
        font-size: 0.85rem;
    }

    .gq-cc__btn {
        padding: 12px 20px;
        font-size: 0.85rem;
    }

    .gq-cc__category {
        padding: 12px 14px;
    }
}

/* ========== PLACEHOLDER (blockierte Inhalte) ========== */
.gq-cc-placeholder {
    position: relative;
    width: 100%;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(105, 98, 254, 0.06);
    border: 2px dashed rgba(105, 98, 254, 0.25);
    border-radius: 16px;
    overflow: hidden;
}

.gq-cc-placeholder iframe {
    display: none !important;
}

.gq-cc-placeholder__inner {
    text-align: center;
    padding: 30px 20px;
}

.gq-cc-placeholder__icon {
    color: rgba(105, 98, 254, 0.4);
    margin-bottom: 12px;
}

.gq-cc-placeholder__text {
    font-family: var(--gq-font-heading, 'Arvo', serif);
    font-size: 1.1rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 6px;
}

.gq-cc-placeholder__info {
    font-family: var(--gq-font-body, 'Work Sans', sans-serif);
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    margin: 0 0 16px;
}

.gq-cc-placeholder__btn {
    display: inline-block;
    padding: 10px 24px;
    background: var(--gq-purple, #6962FE);
    color: #fff;
    border: none;
    border-radius: 25px;
    font-family: var(--gq-font-body, 'Work Sans', sans-serif);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
    letter-spacing: 0.5px;
}

.gq-cc-placeholder__btn:hover {
    background: #5a54e0;
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(105, 98, 254, 0.4);
}

.gq-cc-placeholder__btn:focus-visible {
    outline: 3px solid var(--gq-green, #61FF70);
    outline-offset: 2px;
}

@media (max-width: 480px) {
    .gq-cc-placeholder {
        min-height: 150px;
    }

    .gq-cc-placeholder__inner {
        padding: 20px 15px;
    }

    .gq-cc-placeholder__text {
        font-size: 1rem;
    }

    .gq-cc-placeholder__btn {
        padding: 8px 20px;
        font-size: 0.85rem;
    }
}
