/* Theme-neutral layout. Shop branding belongs in the theme's shared tokens. */
.fitcom-consent {
	--fcc-background: #fff;
	--fcc-text: #202427;
	--fcc-muted: #52606a;
	--fcc-border: #dce1e5;
	--fcc-surface: #f5f7f8;
	--fcc-accent: #202427;
	--fcc-on-accent: #fff;
	--fcc-radius: 12px;
	--fcc-space: 28px;
	--fcc-width: 760px;
	--fcc-z-index: 100000;
	font-family: inherit;
	font-size: 16px;
	line-height: 1.55;
	color: var(--fcc-text);
}
.fitcom-consent *, .fitcom-consent *::before, .fitcom-consent *::after { box-sizing: border-box; }
.fitcom-consent [hidden] { display: none !important; }
.fitcom-consent dialog {
	position: fixed;
	inset: auto 0 24px;
	z-index: var(--fcc-z-index);
	width: min(var(--fcc-width), calc(100% - 48px));
	max-width: none;
	max-height: calc(100dvh - 48px);
	overflow: hidden;
	margin: 0 auto;
	padding: 0;
	border: 1px solid var(--fcc-border);
	border-radius: var(--fcc-radius);
	background: var(--fcc-background);
	color: var(--fcc-text);
	font: inherit;
	box-shadow: 0 16px 64px #0003;
}
.fitcom-consent dialog[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.fitcom-consent[data-position="center"] dialog, .fitcom-consent dialog:modal { inset: 0; margin: auto; height: fit-content; }
.fitcom-consent dialog::backdrop { background: #12151c66; }
.fitcom-consent-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: var(--fcc-space) var(--fcc-space) 16px; }
.fitcom-consent h2 { color: inherit; font: inherit; font-weight: 700; font-size: 1.5em; line-height: 1.2; margin: 0; }
.fitcom-consent h2[tabindex="-1"]:focus { outline: none; }
.fitcom-consent-body { padding: 0 var(--fcc-space) var(--fcc-space); overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.fitcom-consent p { margin: 0 0 16px; }
.fitcom-consent button {
	appearance: none;
	cursor: pointer;
	font: inherit;
	font-weight: 600;
	line-height: 1.3;
	color: var(--fcc-text);
	background: var(--fcc-background);
	border: 1px solid var(--fcc-border);
	border-radius: calc(var(--fcc-radius) / 2);
	padding: 12px 16px;
	min-height: 44px;
	box-shadow: none;
	text-transform: none;
}
.fitcom-consent :is(button, a, input, summary):focus-visible { outline: 3px solid var(--fcc-accent); outline-offset: 3px; }
.fitcom-consent .fitcom-consent-close { flex: 0 0 44px; width: 44px; padding: 0; border: 0; font-size: 28px; }
.fitcom-consent .fitcom-consent-close:hover { background: var(--fcc-surface); }
.fitcom-consent-footer { padding: 20px var(--fcc-space); border-top: 1px solid var(--fcc-border); background: var(--fcc-surface); }
.fitcom-consent [data-fitcom-status]:empty { display: none; }
.fitcom-consent-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.fitcom-consent-actions button { flex: 1 1 160px; min-height: 48px; background: var(--fcc-accent); color: var(--fcc-on-accent); border-color: var(--fcc-accent); }
.fitcom-consent-actions button:hover { filter: brightness(.9); }
.fitcom-consent-links { display: flex; align-items: center; flex-wrap: wrap; column-gap: 24px; row-gap: 4px; font-size: .875em; }
.fitcom-consent a, .fitcom-consent-links button { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.fitcom-consent-links a { display: inline-flex; align-items: center; min-height: 44px; }
.fitcom-consent-links button { font: inherit; border: 0; padding: 0; background: transparent; }
.fitcom-consent .fitcom-consent-reopen { position: fixed; inset: auto auto 12px 12px; z-index: calc(var(--fcc-z-index) - 1); font-size: 13px; padding: 8px 14px; border-radius: 24px; box-shadow: 0 2px 12px #0001; }
.fitcom-consent:has(dialog[open]) .fitcom-consent-reopen { visibility: hidden; }
.fitcom-consent [data-fitcom-details] { margin: 24px 0; }
.fitcom-consent-category { border-top: 1px solid var(--fcc-border); padding: 16px 0; }
.fitcom-consent-category:last-child { border-bottom: 1px solid var(--fcc-border); }
.fitcom-consent-category-label { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 44px; margin: 0 0 4px; font-weight: 700; cursor: pointer; }
.fitcom-consent-category-control { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.fitcom-consent-category-control small { font-size: .75em; color: var(--fcc-muted); font-weight: 400; }
.fitcom-consent input[type="checkbox"] { appearance: none; display: block; position: relative; width: 44px; height: 26px; min-width: 44px; margin: 0; padding: 0; border: 1px solid var(--fcc-muted); border-radius: 20px; background: var(--fcc-background); cursor: pointer; }
.fitcom-consent input[type="checkbox"]::before { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--fcc-muted); }
.fitcom-consent input[type="checkbox"]:checked { background: var(--fcc-accent); border-color: var(--fcc-accent); }
.fitcom-consent input[type="checkbox"]:checked::before { left: 21px; background: var(--fcc-on-accent); }
.fitcom-consent input[type="checkbox"]:disabled { opacity: .65; cursor: default; }
.fitcom-consent details { padding: 0; }
.fitcom-consent summary { cursor: pointer; padding: 10px 0; min-height: 44px; color: var(--fcc-muted); }
.fitcom-consent summary:hover { color: var(--fcc-text); }
.fitcom-consent dl { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 12px 20px; margin: 0 0 16px; padding: 16px; background: var(--fcc-surface); border-radius: calc(var(--fcc-radius) / 2); font-size: .875em; overflow-wrap: anywhere; }
.fitcom-consent dt { font-weight: 600; }
.fitcom-consent dd { margin: 0; }
.fitcom-consent-embed iframe { width: 100%; min-height: 20rem; border: 0; }
.fitcom-consent-embed [hidden] { display: none !important; }
@media (max-width: 600px) {
	.fitcom-consent { --fcc-space: 20px; }
	.fitcom-consent dialog, .fitcom-consent[data-position="center"] dialog, .fitcom-consent dialog:modal { inset: auto 0 0; margin: 0 auto; width: 100%; max-height: calc(100dvh - 16px); border-radius: var(--fcc-radius) var(--fcc-radius) 0 0; }
	.fitcom-consent h2 { font-size: 1.25em; }
	.fitcom-consent-actions { flex-direction: column; gap: 8px; }
	.fitcom-consent-actions button { flex: auto; }
	.fitcom-consent-footer { padding: 16px var(--fcc-space) max(16px, env(safe-area-inset-bottom)); }
	.fitcom-consent dl { grid-template-columns: minmax(0, 1fr); gap: 4px; }
	.fitcom-consent dd:not(:last-child) { margin-bottom: 8px; }
}
