/* Cookie consent banner + preferences modal.
   Modeled on base44.com/pricing's Usercentrics-style banner: white rounded
   card, soft shadow, stacked pill buttons. Positioned bottom-left since
   Intercom's chat launcher owns bottom-right. */

.site-footer__cookie-link {
	font-size: 14px;
	color: #ffffff;
	cursor: pointer;
}
.site-footer__cookie-link:hover { opacity: 0.85; }

.cookie-consent {
	position: fixed;
	left: 24px;
	bottom: 24px;
	z-index: 9999;
	width: 380px;
	max-width: calc(100vw - 48px);
	background: #ffffff;
	border-radius: 20px;
	box-shadow: 0 32px 68px rgba(0, 0, 0, 0.25);
	padding: 24px;
	font-family: var(--font-heading);
}
.cookie-consent[hidden] { display: none; }

.cookie-consent__text {
	font-size: 14px;
	line-height: 20px;
	color: var(--color-ink);
	margin-bottom: 16px;
}
.cookie-consent__text a { color: var(--color-purple); text-decoration: underline; }

.cookie-consent__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.cookie-consent__actions .btn {
	width: 100%;
	text-align: center;
	font-size: 14px;
	padding: 12px 16px;
}
.cookie-consent__manage {
	background: none;
	border: 0;
	padding: 4px;
	font-size: 13px;
	font-weight: 600;
	color: var(--color-body);
	text-decoration: underline;
	text-align: center;
	cursor: pointer;
}
.cookie-consent__manage:hover { color: var(--color-ink); }

@media (max-width: 480px) {
	.cookie-consent { left: 12px; right: 12px; bottom: 12px; width: auto; max-width: none; padding: 20px; }
}

/* Preferences modal */
.cookie-preferences {
	position: fixed;
	inset: 0;
	z-index: 10000;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(15, 10, 40, 0.45);
	padding: 24px;
}
.cookie-preferences[hidden] { display: none; }

.cookie-preferences__panel {
	width: 100%;
	max-width: 480px;
	max-height: calc(100vh - 48px);
	overflow-y: auto;
	background: #ffffff;
	border-radius: 20px;
	box-shadow: 0 32px 68px rgba(0, 0, 0, 0.3);
	padding: 32px;
	font-family: var(--font-heading);
}

.cookie-preferences__header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 8px;
}
.cookie-preferences__header #cookie-preferences-title {
	font-size: 20px;
	font-weight: 700;
	color: var(--color-ink);
}
.cookie-preferences__close {
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 22px;
	line-height: 1;
	color: var(--color-body);
	background: #f5f5f6;
	border-radius: 50%;
	cursor: pointer;
}
.cookie-preferences__close:hover { background: #ebebed; color: var(--color-ink); }

.cookie-preferences__list {
	margin-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.cookie-preferences__item-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 4px;
}
.cookie-preferences__item-name {
	font-size: 15px;
	font-weight: 700;
	color: var(--color-ink);
}
.cookie-preferences__item-desc {
	font-size: 13px;
	line-height: 18px;
	color: var(--color-body);
}

/* Toggle switch: iOS-style pill, matches --radius-pill everywhere else on
   the site. Locked (Necessary) variant is visually identical but not
   interactive and slightly dimmed to read as disabled. */
.cookie-preferences__toggle {
	position: relative;
	flex-shrink: 0;
	width: 44px;
	height: 26px;
	background: #d5d5d8;
	border-radius: var(--radius-pill);
	cursor: pointer;
	transition: background-color 0.15s ease;
}
.cookie-preferences__toggle-dot {
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	background: #ffffff;
	border-radius: 50%;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
	transition: transform 0.15s ease;
}
.cookie-preferences__toggle--on { background: var(--color-purple); }
.cookie-preferences__toggle--on .cookie-preferences__toggle-dot { transform: translateX(18px); }
.cookie-preferences__toggle--locked { cursor: default; opacity: 0.6; }

.cookie-preferences__footer {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 28px;
}
.cookie-preferences__footer .btn {
	flex: 1;
	min-width: 140px;
	text-align: center;
	font-size: 14px;
	padding: 12px 16px;
}

@media (max-width: 480px) {
	.cookie-preferences { padding: 12px; }
	.cookie-preferences__panel { padding: 24px 20px; }
	.cookie-preferences__footer .btn { flex: 1 1 100%; }
}
