/* BSK Cookie Consent — style frontowe
 * Uwaga: reguły kolorów używają !important i selektorów ze zwiększoną
 * specyficznością (#bskcc-banner .bskcc-btn...), aby wygrywać z resetami
 * przycisków narzuconymi przez motywy / page buildery (Elementor, Divi itd.).
 */
.bskcc-banner,
.bskcc-preferences,
.bskcc-floating-btn {
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: var(--bskcc-font-size, 15px);
	line-height: 1.5;
}
.bskcc-banner *,
.bskcc-preferences *,
.bskcc-floating-btn * {
	box-sizing: border-box;
}

/* Neutralizacja stylów przycisków narzucanych przez motyw (bez zerowania paddingu/rozmiaru) */
#bskcc-banner button,
#bskcc-preferences button,
#bskcc-floating-btn.bskcc-floating-btn {
	-webkit-appearance: none;
	appearance: none;
	background-image: none !important;
	box-shadow: none !important;
	text-shadow: none !important;
	outline: none !important;
	margin: 0;
	font-family: inherit;
	text-align: center;
}
#bskcc-banner button:focus-visible,
#bskcc-preferences button:focus-visible {
	outline: 2px solid currentColor !important;
	outline-offset: 2px;
}

/* ---------- Banner ---------- */
.bskcc-banner {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 999998;
	background: var(--bskcc-bg, #141414) !important;
	color: var(--bskcc-text, #fff) !important;
	box-shadow: 0 -4px 24px rgba(0,0,0,.25);
}
.bskcc-position-bottom { bottom: 0; }
.bskcc-position-top { top: 0; box-shadow: 0 4px 24px rgba(0,0,0,.25); }

.bskcc-banner-inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px 24px;
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
	position: relative;
}

/* Long banner: pełna szerokość, logo | tekst | przyciski w rzędzie */
.bskcc-layout-long_banner .bskcc-banner-inner { flex-wrap: nowrap; }
.bskcc-layout-long_banner .bskcc-banner-logo { flex: 0 0 auto; }
.bskcc-layout-long_banner .bskcc-banner-text { flex: 1 1 auto; min-width: 200px; }
.bskcc-layout-long_banner .bskcc-banner-buttons { flex: 0 0 auto; display: flex; gap: 10px; flex-wrap: wrap; }

/* Floating banner: karta w rogu ekranu */
.bskcc-layout-floating {
	left: auto;
	right: 24px;
	bottom: 24px !important;
	top: auto !important;
	max-width: 380px;
	border-radius: 14px;
	box-shadow: 0 8px 32px rgba(0,0,0,.3);
}
.bskcc-layout-floating .bskcc-banner-inner { flex-direction: column; align-items: flex-start; padding: 22px; }
.bskcc-layout-floating .bskcc-banner-buttons { width: 100%; flex-direction: column; }
.bskcc-layout-floating .bskcc-btn { width: 100%; }

/* Modal banner: wyśrodkowane okno + overlay */
.bskcc-layout-modal {
	left: 0; right: 0; top: 0; bottom: 0;
	display: flex !important;
	align-items: center;
	justify-content: center;
	background: var(--bskcc-overlay, rgba(0,0,0,.55)) !important;
}
.bskcc-layout-modal .bskcc-banner-inner {
	background: var(--bskcc-bg, #141414);
	max-width: 480px;
	width: 92%;
	border-radius: 16px;
	flex-direction: column;
	align-items: flex-start;
	box-shadow: 0 16px 48px rgba(0,0,0,.4);
}
.bskcc-layout-modal .bskcc-banner-buttons { width: 100%; flex-direction: column; }
.bskcc-layout-modal .bskcc-btn { width: 100%; }

.bskcc-banner-logo { display: flex; align-items: center; }
.bskcc-banner-logo img { max-height: 36px; width: auto; display: block; }
.bskcc-banner-text p { margin: 0; color: inherit; }

#bskcc-banner .bskcc-banner-close {
	position: absolute;
	top: 10px;
	right: 10px;
	background: transparent !important;
	border: none !important;
	color: var(--bskcc-close-icon, currentColor) !important;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	opacity: .7;
}
#bskcc-banner .bskcc-banner-close:hover { opacity: 1; }

/* ---------- Przyciski (wysoka specyficzność + !important, żeby wygrać z motywem) ---------- */
#bskcc-banner .bskcc-btn,
#bskcc-preferences .bskcc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	border-style: solid !important;
	border-width: 2px !important;
	font-weight: 600 !important;
	white-space: nowrap;
	text-decoration: none !important;
	transition: transform .15s ease, opacity .15s ease;
}
#bskcc-banner .bskcc-btn:hover,
#bskcc-preferences .bskcc-btn:hover { opacity: .9; }
#bskcc-banner .bskcc-btn:active,
#bskcc-preferences .bskcc-btn:active { transform: scale(.98); }

.bskcc-btn-small { padding: 7px 14px; font-size: 13px; }
.bskcc-btn-medium { padding: 10px 20px; font-size: 14px; }
.bskcc-btn-large { padding: 13px 26px; font-size: 15px; }

.bskcc-corner-square { border-radius: 0 !important; }
.bskcc-corner-rounded { border-radius: 8px !important; }
.bskcc-corner-pill { border-radius: 999px !important; }

#bskcc-banner .bskcc-btn-accept,
#bskcc-preferences .bskcc-btn-accept {
	background-color: var(--bskcc-accept-bg, #D6FF00) !important;
	color: var(--bskcc-accept-font, #141414) !important;
	border-color: var(--bskcc-accept-bg, #D6FF00) !important;
}
#bskcc-banner .bskcc-btn-reject,
#bskcc-preferences .bskcc-btn-reject {
	background-color: var(--bskcc-reject-bg, #232323) !important;
	color: var(--bskcc-reject-font, #fff) !important;
	border-color: var(--bskcc-reject-bg, #232323) !important;
}
#bskcc-banner .bskcc-btn-settings {
	background-color: var(--bskcc-settings-bg, transparent) !important;
	color: var(--bskcc-settings-font, #D6FF00) !important;
	border-color: var(--bskcc-settings-border, #D6FF00) !important;
}

.bskcc-powered-by {
	text-align: center;
	font-size: 11px;
	opacity: .55;
	padding: 4px 0 10px;
}
.bskcc-powered-by a { color: inherit; }

/* ---------- Panel preferencji ---------- */
.bskcc-preferences { position: fixed; inset: 0; z-index: 999999; display: flex; align-items: center; justify-content: center; }
.bskcc-preferences-overlay { position: absolute; inset: 0; background: var(--bskcc-overlay, rgba(0,0,0,.55)) !important; }
.bskcc-preferences-panel {
	position: relative;
	background: var(--bskcc-pref-bg, #fff) !important;
	color: var(--bskcc-pref-text, #1a1a1a) !important;
	width: 92%;
	max-width: 560px;
	max-height: 86vh;
	overflow-y: auto;
	border-radius: 16px;
	box-shadow: 0 20px 60px rgba(0,0,0,.35);
}
.bskcc-preferences-header {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 20px 24px;
	border-bottom: 1px solid rgba(128,128,128,.2);
	position: sticky;
	top: 0;
	background: var(--bskcc-pref-bg, #fff) !important;
}
.bskcc-preferences-logo { max-height: 28px; }
.bskcc-preferences-header h2 { flex: 1; margin: 0; font-size: 18px; color: var(--bskcc-pref-heading, #141414) !important; }
#bskcc-preferences .bskcc-preferences-close {
	background: none !important;
	border: none !important;
	font-size: 22px;
	cursor: pointer;
	color: var(--bskcc-pref-text, #888) !important;
	opacity: .6;
}
#bskcc-preferences .bskcc-preferences-close:hover { opacity: 1; }
.bskcc-preferences-body { padding: 20px 24px; }
.bskcc-category { padding: 14px 0; border-bottom: 1px solid rgba(128,128,128,.15); }
.bskcc-category:last-of-type { border-bottom: none; }
.bskcc-category-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.bskcc-category-title { font-weight: 600; color: var(--bskcc-pref-heading, #141414) !important; }
.bskcc-category-desc { margin: 6px 0 0; font-size: 13px; opacity: .7; }
.bskcc-policy-links { font-size: 13px; opacity: .7; margin-top: 16px; }
.bskcc-policy-links a { color: var(--bskcc-switch-on, #0066cc); }

.bskcc-preferences-footer {
	display: flex;
	gap: 10px;
	padding: 16px 24px;
	border-top: 1px solid rgba(128,128,128,.2);
	position: sticky;
	bottom: 0;
	background: var(--bskcc-pref-bg, #fff) !important;
}
.bskcc-preferences-footer .bskcc-btn { flex: 1; }

/* Przełącznik (switch) */
.bskcc-switch { position: relative; display: inline-block; width: 42px; height: 24px; flex: 0 0 auto; }
.bskcc-switch input { opacity: 0; width: 0; height: 0; }
.bskcc-switch-slider {
	position: absolute; cursor: pointer; inset: 0;
	background-color: #ccc; transition: .2s; border-radius: 999px;
}
.bskcc-switch-slider:before {
	position: absolute; content: ""; height: 18px; width: 18px; left: 3px; bottom: 3px;
	background-color: white; transition: .2s; border-radius: 50%;
}
.bskcc-switch input:checked + .bskcc-switch-slider { background-color: var(--bskcc-switch-on, #D6FF00) !important; }
.bskcc-switch input:checked + .bskcc-switch-slider:before { transform: translateX(18px); }
.bskcc-switch input:disabled + .bskcc-switch-slider { opacity: .5; cursor: not-allowed; }

/* ---------- Przycisk pływający ---------- */
#bskcc-floating-btn.bskcc-floating-btn {
	position: fixed;
	bottom: 20px;
	left: 20px;
	z-index: 999997;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: var(--bskcc-floating-bg, #141414) !important;
	color: var(--bskcc-floating-icon, #D6FF00) !important;
	border: none !important;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 4px 16px rgba(0,0,0,.25);
}
#bskcc-floating-btn.bskcc-floating-btn svg { fill: currentColor; }

@media (max-width: 640px) {
	.bskcc-layout-long_banner .bskcc-banner-inner { flex-direction: column; align-items: stretch; }
	.bskcc-layout-long_banner .bskcc-banner-buttons { flex-direction: column; }
	.bskcc-layout-floating { left: 12px; right: 12px; max-width: none; }
}
