/* Cookie overlay */
.cookie-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
}

/* ===== COOKIE BANNER - MOBILE FIRST ===== */
.cookie-banner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 6px;
    background: white;
    padding: 20px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    width: 95%;
    max-width: 500px;
	max-height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.cookie-banner p {
    margin: 0 0 15px 0;
    color: #666;
    line-height: 1.5;
    font-size: 1rem;
	text-align: left;
}

.cookie-banner-content {
    text-align: center;
	display: flex;
    flex-direction: column;
	flex: 1;
	min-height: 0;
}

.cookie-banner-content h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.3rem;
}

/* Scrollowalny tekst w banerze */
.cookie-banner-text {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
    padding-right: 8px;
	text-align: left;
}

.cookie-banner-text p {
    margin: 0 0 10px 0;
    color: #666;
    line-height: 1.5;
    font-size: 1rem;
	text-align: left;
}

/* (pasek jak w panelu ustawień) */
.cookie-banner-text::-webkit-scrollbar {
    width: 8px;
}
.cookie-banner-text::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}
.cookie-banner-text::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}
.cookie-banner-text::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.cookie-policy-link {
    text-decoration: underline;
}

.cookie-policy-link :hover {
    color: #333;
}

.cookie-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-direction: column;
	margin-top: 10px;
}

/* ===== SETTINGS PANEL - MOBILE FIRST ===== */
.cookie-settings-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 6px;
    width: 95%;
    max-width: 500px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* STICKY TOP - header + intro text */
.cookie-settings-top {
    flex-shrink: 0;
    background: white;
    border-bottom: 1px solid #eee;
}

.cookie-settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 15px 20px;
}

.cookie-settings-header h3 {
    font-size: 1.3rem;
    margin: 0;
    color: #333;
    line-height: 1.3;
}

.cookie-close-btn {
    background: none;
    border: none;
    font-size: 30px;
    cursor: pointer;
    color: #222;
    padding: 5px;
    line-height: 1;
    transition: color 0.2s;
}

.cookie-close-btn:hover {
    color: #666;
}

.cookie-intro-text {
    padding: 0;
    margin: 10px 0 25px 0;
    color: #666;
    line-height: 1.5;
    font-size: 1rem;
}

.cookie-intro-text p {
    padding: 0;
	margin: 0 0 10px 0;
    color: #666;
    line-height: 1.5;
    font-size: 1rem;
	text-align: left;
}

/* SCROLLABLE CONTENT - tylko kategorie */
.cookie-settings-content {
    flex: 1;
    overflow-y: auto;
    padding: 10px 20px;
    min-height: 0;
}

/* Cookie categories */
.cookie-category {
}

.cookie-category:first-child {
    border-top: none;
    padding-top: 0;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 5px;
}

.cookie-category-left {
    display: flex;
    align-items: flex-start;
    flex: 1;
    gap: 10px;
}

.cookie-category-left input[type="checkbox"] {
    margin-top: 2px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    cursor: pointer;
	accent-color: #333;
}

.cookie-category-left input[type="checkbox"]:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.cookie-category-left label {
    font-weight: 600;
    font-size: 15px;
    line-height: 1.4;
    color: #333;
    cursor: pointer;
}

.cookie-category-subtitle {
    font-size: 1rem;
    color: #666;
    margin: 0 0 10px 28px;
    line-height: 1.3;
}

.cookie-category-right {
    flex-shrink: 0;
}

.toggle-details {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 20px;
    color: #222;
    padding: 5px 10px;
    border-radius: 3px;
    transition: background-color 0.3s;
    line-height: 1;
}

.toggle-details:hover {
    background-color: #f0f0f0;
}

.cookie-category-content {
    padding-bottom: 15px;
    display: none;
    margin-left: 28px;
}

.cookie-category-content p {
    margin: 0;
    color: #666;
    line-height: 1.5;
    font-size: 1rem;
}

/* Cookie details (jeśli będą używane) */
.cookie-details {
    margin-top: 15px;
}

.cookie-detail {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.cookie-detail:last-child {
    margin-bottom: 0;
}

.cookie-detail-row {
    display: flex;
    flex-direction: column;
    margin-bottom: 5px;
}

.cookie-detail-row:last-child {
    margin-bottom: 0;
}

.cookie-detail-label {
    font-weight: 500;
    color: #666;
    font-size: 13px;
    margin-bottom: 3px;
}

.cookie-detail-value {
    color: #333;
    font-size: 13px;
    word-break: break-word;
}

/* STICKY FOOTER - buttons */
.cookie-settings-buttons {
    display: flex;
    gap: 10px;
    padding: 0 20px 20px 20px;
    justify-content: center;
    flex-direction: column;
    flex-shrink: 0;
    background: white;
}

/* ===== TABLET AND UP ===== */
@media (min-width: 768px) {
    /* Banner */
    .cookie-banner {
        width: 85%;
        min-width: 700px;
        max-width: 950px;
        padding: 30px;
    }

    .cookie-buttons {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    /* Settings Panel */
    .cookie-settings-panel {
        max-width: 950px;
        max-height: 80vh;
    }
    
    .cookie-settings-header {
        padding: 25px 25px 20px 25px;
    }
    
    .cookie-settings-content {
        padding: 25px;
    }
    
    .cookie-category {
    }
    
    .cookie-category-left label {
        font-size: 16px;
    }
    
    .cookie-category-content {
        margin-left: 28px;
    }
    
    .cookie-settings-buttons {
        flex-direction: row;
    }
    
    /* Cookie details */
    .cookie-detail-row {
        flex-direction: row;
        justify-content: space-between;
    }
    
    .cookie-detail-label {
        width: 35%;
        margin-bottom: 0;
    }
    
    .cookie-detail-value {
        width: 60%;
        text-align: right;
    }
}



/* ===== SCROLLBAR STYLING ===== */
.cookie-settings-content::-webkit-scrollbar {
    width: 8px;
}

.cookie-settings-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.cookie-settings-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.cookie-settings-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}