/**
 * ConsentManager CSS - Styling voor cookiebanner en settings panel
 * Centrale styling voor alle Strouwi Multisite websites
 * 
 * @version 1.0.0
 * @author Strouwi Multisite
 */

/* ==========================================================================
   Cookie Banner
   ========================================================================== */

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    z-index: 9999;
    background: #ffffff;
    border-top: 1px solid #e5e5e5;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #333333;
    display: none;
}

.cookie-banner--bottom {
    bottom: 0;
}

.cookie-banner--top {
    top: 0;
    border-top: none;
    border-bottom: 1px solid #e5e5e5;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.cookie-banner__content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
}

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

.cookie-banner__title {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
}

.cookie-banner__description {
    margin: 0;
    color: #666666;
}

.cookie-banner__actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-shrink: 0;
}

.cookie-banner__btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 100px;
    white-space: nowrap;
}

.cookie-banner__btn:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

.cookie-banner__btn--primary {
    background: #007bff;
    color: #ffffff;
}

.cookie-banner__btn--primary:hover {
    background: #0056b3;
    transform: translateY(-1px);
}

.cookie-banner__btn--primary:active {
    transform: translateY(0);
}

.cookie-banner__btn--secondary {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
}

.cookie-banner__btn--secondary:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.cookie-banner__btn--settings {
    background: transparent;
    color: #007bff;
    text-decoration: underline;
    padding: 8px 12px;
    min-width: auto;
}

.cookie-banner__btn--settings:hover {
    color: #0056b3;
    text-decoration: none;
}

.cookie-banner__close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    font-size: 20px;
    color: #999999;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: color 0.2s ease;
}

.cookie-banner__close:hover {
    color: #666666;
}

.cookie-banner__close:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* ==========================================================================
   Cookie Settings Panel
   ========================================================================== */

.cookie-settings {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: none;
}

.cookie-settings__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.cookie-settings__content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.cookie-settings__header {
    padding: 24px 24px 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 1px solid #e5e5e5;
}

.cookie-settings__title {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
}

.cookie-settings__close {
    background: none;
    border: none;
    font-size: 24px;
    color: #999999;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: color 0.2s ease;
    margin-left: 16px;
}

.cookie-settings__close:hover {
    color: #666666;
}

.cookie-settings__close:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

.cookie-settings__body {
    padding: 24px;
}

.cookie-settings__section {
    margin-bottom: 24px;
}

.cookie-settings__section:last-child {
    margin-bottom: 0;
}

.cookie-settings__section-title {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
}

.cookie-settings__section-description {
    margin: 0 0 16px 0;
    color: #666666;
    font-size: 14px;
    line-height: 1.5;
}

.cookie-settings__toggle {
    margin-top: 16px;
}

.cookie-settings__toggle-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #333333;
}

.cookie-settings__toggle-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-settings__toggle-slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: #ccc;
    border-radius: 12px;
    transition: background 0.3s ease;
    margin-right: 12px;
    flex-shrink: 0;
}

.cookie-settings__toggle-slider:before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: #ffffff;
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cookie-settings__toggle-input:checked + .cookie-settings__toggle-slider {
    background: #007bff;
}

.cookie-settings__toggle-input:checked + .cookie-settings__toggle-slider:before {
    transform: translateX(20px);
}

.cookie-settings__toggle-input:focus + .cookie-settings__toggle-slider {
    box-shadow: 0 0 0 2px #007bff;
}

.cookie-settings__toggle-text {
    flex: 1;
}

.cookie-settings__footer {
    padding: 0 24px 24px 24px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    border-top: 1px solid #e5e5e5;
    padding-top: 20px;
}

.cookie-settings__btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
}

.cookie-settings__btn:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

.cookie-settings__btn--primary {
    background: #007bff;
    color: #ffffff;
}

.cookie-settings__btn--primary:hover {
    background: #0056b3;
}

.cookie-settings__btn--secondary {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
}

.cookie-settings__btn--secondary:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    .cookie-banner__content {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        padding: 20px;
    }

    .cookie-banner__actions {
        justify-content: center;
        flex-wrap: wrap;
    }

    .cookie-banner__btn {
        flex: 1;
        min-width: 120px;
    }

    .cookie-banner__close {
        position: static;
        align-self: flex-end;
        margin-bottom: -8px;
    }

    .cookie-settings__content {
        width: 95%;
        margin: 20px;
        max-height: calc(100vh - 40px);
    }

    .cookie-settings__header {
        padding: 20px 20px 0 20px;
    }

    .cookie-settings__body {
        padding: 20px;
    }

    .cookie-settings__footer {
        padding: 0 20px 20px 20px;
        flex-direction: column;
    }

    .cookie-settings__btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .cookie-banner__content {
        padding: 16px;
    }

    .cookie-banner__title {
        font-size: 15px;
    }

    .cookie-banner__description {
        font-size: 13px;
    }

    .cookie-banner__btn {
        padding: 8px 16px;
        font-size: 13px;
        min-width: 100px;
    }

    .cookie-settings__content {
        width: 100%;
        height: 100%;
        border-radius: 0;
        margin: 0;
        max-height: 100vh;
    }

    .cookie-settings__title {
        font-size: 18px;
    }
}

/* ==========================================================================
   High Contrast Mode Support
   ========================================================================== */

@media (prefers-contrast: high) {
    .cookie-banner {
        border-top: 2px solid #000000;
    }

    .cookie-banner__btn {
        border: 2px solid currentColor;
    }

    .cookie-settings__content {
        border: 2px solid #000000;
    }

    .cookie-settings__toggle-slider {
        border: 2px solid #000000;
    }
}

/* ==========================================================================
   Reduced Motion Support
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
    .cookie-banner__btn,
    .cookie-settings__btn,
    .cookie-settings__toggle-slider,
    .cookie-settings__toggle-slider:before {
        transition: none;
    }

    .cookie-banner__btn:hover {
        transform: none;
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .cookie-banner,
    .cookie-settings {
        display: none !important;
    }
} 