/* 쿠키 동의 배너·설정 창(2026-11-13 출시 QA SEC-01 — public/js/consent.js 가 그린다).
   토큰(tokens.css)만 쓴다 — 밝은/어두운 테마 모두 따라간다. 배너는 내용을 가리지 않도록 포인터 이벤트를 상자에만 준다. */

.vd-consent {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: var(--z-overlay);
	padding: 0 var(--gutter) calc(var(--s-3) + env(safe-area-inset-bottom));
	pointer-events: none;
}

.vd-consent__box {
	pointer-events: auto;
	max-width: var(--container);
	margin: 0 auto;
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: var(--s-4);
	background: var(--surface);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: var(--r-3);
	box-shadow: var(--sh-2);
	padding: var(--s-4);
}

.vd-consent__text {
	flex: 1 1 320px;
	margin: 0;
	font-size: var(--fs-14);
	line-height: 1.6;
	color: var(--ink-2);
}

.vd-consent__text strong { color: var(--ink); }
.vd-consent__link { color: var(--accent); }

.vd-consent__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: var(--s-2);
	margin-left: auto;
}

.vd-consent-dlg {
	position: fixed;
	inset: 0;
	z-index: calc(var(--z-overlay) + 1);
	display: grid;
	place-items: center;
	padding: var(--s-4);
	background: var(--scrim);
}

.vd-consent-dlg[hidden] { display: none; }

.vd-consent-dlg__panel {
	width: min(480px, 100%);
	max-height: calc(100vh - 2 * var(--s-4));
	overflow: auto;
	display: grid;
	gap: var(--s-3);
	background: var(--surface);
	color: var(--ink);
	border-radius: var(--r-3);
	box-shadow: var(--sh-2);
	padding: var(--s-5);
}

.vd-consent-dlg__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--s-2);
}

.vd-consent-dlg__head h2 { margin: 0; font-size: var(--fs-18); }

.vd-consent-dlg__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--s-3);
	padding: var(--s-3) 0;
	border-top: 1px solid var(--line);
	cursor: pointer;
}

/* 체크박스 20px 통일(출시 QA A11Y-01) */
.vd-consent-dlg__row input[type="checkbox"] {
	width: 20px;
	height: 20px;
	flex: none;
	accent-color: var(--accent);
}

.vd-consent-dlg__desc { display: grid; gap: 2px; }
.vd-consent-dlg__desc strong { font-size: var(--fs-14); }
.vd-consent-dlg__desc small { color: var(--muted); line-height: 1.5; }

.vd-consent-dlg__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: var(--s-2);
	margin-top: var(--s-1);
}

/* 푸터 「쿠키 설정」 — 목록 링크와 같은 모양의 단추(실행 단추라 설정 아이콘을 붙인다 — UI 지침 §7.1, 2026-11-16) */
.vd-footer__cookie {
	display: inline-flex;
	align-items: center;
	gap: var(--gap-icon, 0.5rem);
	min-height: 1.5rem; /* 터치 영역 24px 이상(화면 검사 small) */
	appearance: none;
	background: none;
	border: 0;
	padding: 0;
	font: inherit;
	color: inherit;
	text-decoration: none;
	cursor: pointer;
}

.vd-footer__cookie > svg { flex: none; width: 1em; height: 1em; }
.vd-footer__cookie > span { text-decoration: underline; text-underline-offset: 3px; }
.vd-footer__cookie:hover { color: var(--accent); }
.vd-footer__cookie:focus-visible { outline: 2px solid var(--accent-ring); outline-offset: 2px; border-radius: var(--r-1); }

/* 작은 화면: 아래 고정 메뉴(.vd-botnav, 60px) 위로 배너를 띄운다(vidia.css max-width: 800px 와 같은 판정). */
@media (max-width: 800px) {
	.vd-consent { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
	.vd-consent__box { padding: var(--s-3); gap: var(--s-3); }
	.vd-consent__actions { justify-content: stretch; }
	.vd-consent__actions .vd-btn { flex: 1; }
}
