/* SD Cookies — banner e modal de preferências. */

.sdck-banner,
.sdck-modal,
.sdck-float-icon {
	--sdck-primary: #1d2327;
	--sdck-accent: #2271b1;
	--sdck-text: #ffffff;
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
}

.sdck-banner *,
.sdck-modal *,
.sdck-float-icon * {
	box-sizing: border-box;
}

.sdck-banner {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 999999;
	background: var(--sdck-primary);
	color: var(--sdck-text);
	padding: 20px;
	box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.25);
}

.sdck-banner[hidden] {
	display: none;
}

.sdck-banner--bottom { bottom: 0; }
.sdck-banner--top { top: 0; box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25); }

.sdck-banner--modal {
	left: 50%;
	top: 50%;
	bottom: auto;
	right: auto;
	transform: translate(-50%, -50%);
	max-width: 520px;
	width: calc(100% - 40px);
	border-radius: 8px;
}

.sdck-banner__content {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 16px;
	max-width: 1200px;
	margin: 0 auto;
}

.sdck-banner__text {
	flex: 1 1 320px;
	margin: 0;
}

.sdck-banner__text a {
	color: inherit;
	text-decoration: underline;
}

.sdck-banner__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

/* Aceitar e Recusar têm de ter sempre o mesmo tamanho/destaque — não personalizável. */
.sdck-btn {
	appearance: none;
	border: 2px solid transparent;
	border-radius: 4px;
	padding: 10px 20px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	min-width: 130px;
}

.sdck-btn--accept {
	background: var(--sdck-accent);
	color: #fff;
}

.sdck-btn--reject {
	background: transparent;
	border-color: var(--sdck-text);
	color: var(--sdck-text);
}

.sdck-btn--preferences {
	background: transparent;
	border-color: transparent;
	color: var(--sdck-text);
	text-decoration: underline;
	min-width: 0;
}

.sdck-modal {
	position: fixed;
	inset: 0;
	z-index: 1000000;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.5);
}

.sdck-modal[hidden] {
	display: none;
}

.sdck-modal__dialog {
	background: #fff;
	color: #1d2327;
	max-width: 560px;
	width: calc(100% - 40px);
	max-height: calc(100vh - 80px);
	overflow-y: auto;
	border-radius: 8px;
	padding: 24px;
}

.sdck-modal__title {
	margin: 0 0 12px;
	font-size: 18px;
	font-weight: 700;
}

.sdck-modal__category {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 16px;
	padding: 14px 0;
	border-bottom: 1px solid #e2e4e7;
}

.sdck-modal__category:last-of-type {
	border-bottom: none;
}

.sdck-modal__category-title {
	font-weight: 600;
	margin: 0 0 4px;
}

.sdck-modal__category-desc {
	margin: 0;
	font-size: 13px;
	color: #50575e;
}

.sdck-switch {
	position: relative;
	display: inline-block;
	width: 42px;
	height: 24px;
	flex: 0 0 auto;
}

.sdck-switch input {
	opacity: 0;
	width: 0;
	height: 0;
}

.sdck-switch__track {
	position: absolute;
	inset: 0;
	background: #c3c4c7;
	border-radius: 999px;
	transition: background 0.15s;
}

.sdck-switch__track::before {
	content: "";
	position: absolute;
	left: 3px;
	top: 3px;
	width: 18px;
	height: 18px;
	background: #fff;
	border-radius: 50%;
	transition: transform 0.15s;
}

.sdck-switch input:checked + .sdck-switch__track {
	background: var(--sdck-accent);
}

.sdck-switch input:checked + .sdck-switch__track::before {
	transform: translateX(18px);
}

.sdck-switch input:disabled + .sdck-switch__track {
	opacity: 0.6;
}

.sdck-modal__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 20px;
}

.sdck-modal__actions .sdck-btn {
	flex: 1 1 140px;
}

.sdck-float-icon {
	position: fixed;
	left: 16px;
	bottom: 16px;
	z-index: 999998;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	border: none;
	background: var(--sdck-primary);
	color: var(--sdck-text);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
	padding: 0;
}

.sdck-float-icon[hidden] {
	display: none;
}

.sdck-float-icon svg {
	width: 24px;
	height: 24px;
	fill: currentColor;
}
