/* ============================================
   Abielu.ee Cookie Consent Styles
   ============================================ */

/* ─── Banner ──────────────────────────────── */

.acc-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 99998;
    background: var(--white, #fff);
    border-top: 1px solid var(--light-gray, #f3f2f1);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);
    font-family: var(--font-secondary, 'Inter', sans-serif);
}

.acc-banner__inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.acc-banner__text {
    flex: 1;
    min-width: 0;
}

.acc-banner__text p {
    margin: 0;
    font-size: var(--text-sm, 0.875rem);
    line-height: 1.5;
    color: var(--text-body, #323232);
}

.acc-banner__actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

/* ─── Buttons ─────────────────────────────── */

.acc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-family: var(--font-secondary, 'Inter', sans-serif);
    font-size: var(--text-sm, 0.875rem);
    font-weight: 600;
    line-height: 1;
    border-radius: var(--radius-md, 8px);
    border: 2px solid transparent;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
}

.acc-btn--primary {
    background: var(--pulmad-blue-accent, #325289);
    color: var(--white, #fff);
    border-color: var(--pulmad-blue-accent, #325289);
}

.acc-btn--primary:hover {
    background: var(--pulmad-blue, #0F1D33);
    border-color: var(--pulmad-blue, #0F1D33);
}

.acc-btn--outline {
    background: transparent;
    color: var(--text-body, #323232);
    border-color: var(--text-body, #323232);
}

.acc-btn--outline:hover {
    background: var(--light-gray, #f3f2f1);
}

.acc-btn--secondary {
    background: transparent;
    color: var(--pulmad-blue-accent, #325289);
    border-color: var(--pulmad-blue-accent, #325289);
}

.acc-btn--secondary:hover {
    background: var(--pulmad-blue-light, #DBE8F7);
}

/* ─── Modal ───────────────────────────────── */

.acc-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.acc-modal__panel {
    position: relative;
    width: 94%;
    max-width: 520px;
    max-height: 90vh;
    background: var(--white, #fff);
    border-radius: var(--radius-lg, 12px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.16);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.acc-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 12px;
}

.acc-modal__title {
    margin: 0;
    font-family: var(--font-primary, 'Playfair Display', serif);
    font-size: var(--text-xl, 1.375rem);
    font-weight: 700;
    color: var(--pulmad-blue, #0F1D33);
}

.acc-modal__close {
    background: none;
    border: none;
    font-size: 28px;
    line-height: 1;
    color: #9CA3AF;
    cursor: pointer;
    padding: 4px;
}

.acc-modal__close:hover {
    color: var(--text-body, #323232);
}

.acc-modal__body {
    padding: 0 24px;
    overflow-y: auto;
    flex: 1;
}

.acc-modal__intro {
    font-size: var(--text-sm, 0.875rem);
    color: #666;
    margin: 0 0 16px;
    line-height: 1.5;
}

.acc-modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 16px 24px;
    border-top: 1px solid var(--light-gray, #f3f2f1);
}

/* ─── Category rows ───────────────────────── */

.acc-category {
    border-bottom: 1px solid var(--light-gray, #f3f2f1);
    padding: 12px 0;
}

.acc-category:last-child {
    border-bottom: none;
}

.acc-category__header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.acc-category__info {
    flex: 1;
    min-width: 0;
}

.acc-category__name {
    margin: 0 0 2px;
    font-size: var(--text-sm, 0.875rem);
    font-weight: 600;
    color: var(--pulmad-blue, #0F1D33);
}

.acc-category__desc {
    margin: 0;
    font-size: var(--text-xs, 0.75rem);
    color: #666;
    line-height: 1.5;
}

.acc-badge--always {
    display: inline-block;
    padding: 4px 10px;
    font-size: var(--text-xs, 0.75rem);
    font-weight: 500;
    color: var(--success, #10B981);
    background: #ecfdf5;
    border-radius: 100px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ─── Toggle switch ───────────────────────── */

.acc-toggle {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
    cursor: pointer;
}

.acc-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.acc-toggle__slider {
    position: absolute;
    inset: 0;
    background: #9CA3AF;
    border-radius: 12px;
    transition: background 0.15s ease;
}

.acc-toggle__slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: var(--white, #fff);
    border-radius: 50%;
    transition: transform 0.15s ease;
}

.acc-toggle input:checked + .acc-toggle__slider {
    background: var(--pulmad-blue-accent, #325289);
}

.acc-toggle input:checked + .acc-toggle__slider::after {
    transform: translateX(20px);
}

.acc-toggle input:focus-visible + .acc-toggle__slider {
    outline: 2px solid var(--pulmad-blue-accent, #325289);
    outline-offset: 2px;
}

/* ─── Re-open button ──────────────────────── */

.acc-reopen {
    position: fixed;
    bottom: 16px;
    left: 16px;
    z-index: 99997;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--white, #fff);
    color: var(--pulmad-blue-accent, #325289);
    border: 1px solid var(--light-gray, #f3f2f1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.acc-reopen:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transform: scale(1.05);
}

.acc-reopen svg {
    display: block;
}

/* ─── Responsive ──────────────────────────── */

@media (max-width: 768px) {
    .acc-banner__inner {
        flex-direction: column;
        align-items: stretch;
        padding: 16px;
        gap: 12px;
    }

    .acc-banner__actions {
        flex-direction: column;
    }

    .acc-banner__actions .acc-btn {
        width: 100%;
    }

    .acc-modal__panel {
        width: 100%;
        max-width: none;
        max-height: 100vh;
        border-radius: 0;
    }

    .acc-modal__footer {
        flex-direction: column;
    }

    .acc-modal__footer .acc-btn {
        width: 100%;
    }

    .acc-category__header {
        gap: 12px;
    }
}
