/* ============================================
   CF Cookie Consent - Frontend Banner Styles
   ============================================ */

/* Overlay */
.cfcc-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cfcc-overlay.cfcc-visible {
    opacity: 1;
}

/* Modal Banner */
.cfcc-banner.cfcc-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    z-index: 999999;
    width: 90%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 16px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.15), 0 8px 20px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

.cfcc-banner.cfcc-modal.cfcc-visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Banner Inner */
.cfcc-banner-inner {
    padding: 28px 32px;
}

/* Logo */
.cfcc-banner-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.07);
}

.cfcc-banner-logo img {
    display: block;
    width: auto;
    object-fit: contain;
}

/* Header */
.cfcc-banner-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.cfcc-banner-icon {
    font-size: 28px;
    line-height: 1;
}

.cfcc-banner-title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
    padding: 0;
}

/* Description */
.cfcc-banner-description {
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 20px 0;
    opacity: 0.8;
}

/* Categories */
.cfcc-categories {
    display: none;
    margin-bottom: 20px;
}

.cfcc-categories.cfcc-expanded {
    display: block;
}

.cfcc-category {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 10px;
    transition: border-color 0.2s ease;
}

.cfcc-category:hover {
    border-color: rgba(0, 0, 0, 0.2);
}

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

.cfcc-category-info {
    flex: 1;
}

.cfcc-category-label {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 2px 0;
}

.cfcc-category-desc {
    font-size: 12px;
    opacity: 0.65;
    margin: 0;
    line-height: 1.4;
}

/* Toggle switch */
.cfcc-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.cfcc-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.cfcc-switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.2s;
    border-radius: 24px;
}

.cfcc-switch-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.2s;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.cfcc-switch input:checked + .cfcc-switch-slider {
    background-color: var(--cfcc-primary, #2563eb);
}

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

.cfcc-switch input:disabled + .cfcc-switch-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Buttons */
.cfcc-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cfcc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    font-family: inherit;
    line-height: 1;
    text-decoration: none;
}

.cfcc-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.cfcc-btn:active {
    transform: translateY(0);
}

.cfcc-btn-accept {
    background: var(--cfcc-primary, #2563eb);
    color: #ffffff;
}

.cfcc-btn-accept:hover {
    background: var(--cfcc-primary-hover, #1d4ed8);
}

.cfcc-btn-reject {
    background: transparent;
    color: var(--cfcc-text, #1f2937);
    border: 1.5px solid rgba(0, 0, 0, 0.15);
}

.cfcc-btn-reject:hover {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.25);
}

.cfcc-btn-customize {
    background: transparent;
    color: var(--cfcc-text, #1f2937);
    opacity: 0.7;
    padding: 8px 20px;
    font-size: 13px;
}

.cfcc-btn-customize:hover {
    opacity: 1;
    box-shadow: none;
    transform: none;
}

.cfcc-btn-save {
    background: var(--cfcc-primary, #2563eb);
    color: #ffffff;
}

.cfcc-btn-save:hover {
    background: var(--cfcc-primary-hover, #1d4ed8);
}

/* Privacy link */
.cfcc-privacy {
    text-align: center;
    margin-top: 14px;
}

.cfcc-privacy a {
    font-size: 12px;
    opacity: 0.5;
    text-decoration: underline;
    transition: opacity 0.2s;
}

.cfcc-privacy a:hover {
    opacity: 0.8;
}

/* Settings button (floating) */
.cfcc-settings-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 999997;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease;
    background: var(--cfcc-primary, #2563eb);
    color: #ffffff;
}

.cfcc-settings-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.cfcc-settings-btn svg {
    width: 20px;
    height: 20px;
}

/* Responsive */
@media (max-width: 480px) {
    .cfcc-banner.cfcc-modal {
        width: 95%;
        max-height: 85vh;
    }

    .cfcc-banner-inner {
        padding: 22px 20px;
    }

    .cfcc-banner-title {
        font-size: 18px;
    }

    .cfcc-btn {
        padding: 11px 16px;
        font-size: 13px;
    }
}

/* Scrollbar styling */
.cfcc-banner::-webkit-scrollbar {
    width: 6px;
}

.cfcc-banner::-webkit-scrollbar-track {
    background: transparent;
}

.cfcc-banner::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 3px;
}
