/*!
 * Pekoe Cookie Consent — banner, settings dialog and persistent control.
 *
 * Scoped to .pekoe-cc* selectors only, so no broad theme/plugin button rules
 * are affected. Body text uses the site's small-text stack (theme $smallsans:
 * Tahoma, Verdana, Segoe, sans-serif); the dialog headline keeps the theme's
 * Raleway heading stack. Pekoe orange accents match the child theme. Contrast:
 * white on #C24A00 (4.6:1) in the settings bar, near-black text on white for
 * the banner (>= 7:1).
 */

.pekoe-cc {
	font-family: Tahoma, Verdana, Segoe, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	box-sizing: border-box;
}

.pekoe-cc *,
.pekoe-cc *::before,
.pekoe-cc *::after {
	box-sizing: inherit;
}

/* ------------------------------------------------------------- banner */

.pekoe-cc-banner {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 100000;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 24px;
	padding: 16px 20px;
	background: #ffffff;
	color: #222222;
	border-top: 3px solid #f26a15;
	box-shadow: 0 -2px 14px rgba(0, 0, 0, 0.18);
}

.pekoe-cc-banner[hidden],
.pekoe-cc-dialog[hidden],
.pekoe-cc-noscript[hidden] {
	display: none;
}

.pekoe-cc-banner__text {
	flex: 1 1 320px;
	margin: 0;
	max-width: 70ch;
	font-size: 14px;
	line-height: 1.4;
}

.pekoe-cc-banner__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
}

.pekoe-cc-policy-link {
	color: #b03f00;
	text-decoration: underline;
}

/* ------------------------------------------------------------ buttons */

.pekoe-cc .pekoe-cc-button {
	display: inline-block;
	min-height: 44px;
	padding: 10px 18px;
	border: 2px solid #f26a15;
	border-radius: 3px;
	background: #f26a15;
	color: #ffffff;
	font: inherit;
	font-weight: 700;
	line-height: 1.2;
	cursor: pointer;
	text-decoration: none;
}

/* Accept and reject share prominence, size and interaction count. */
.pekoe-cc .pekoe-cc-reject {
	background: #ffffff;
	color: #8a3a00;
	border-color: #8a3a00;
}

.pekoe-cc .pekoe-cc-quiet {
	background: #ffffff;
	color: #333333;
	border-color: #767676;
	font-weight: 400;
	text-decoration: underline;
}

.pekoe-cc .pekoe-cc-button:hover,
.pekoe-cc .pekoe-cc-button:focus {
	filter: brightness(0.94);
}

.pekoe-cc .pekoe-cc-button:focus-visible,
.pekoe-cc .pekoe-cc-control:focus-visible,
.pekoe-cc .pekoe-cc-option__label input:focus-visible {
	outline: 3px solid #0b5fff;
	outline-offset: 2px;
}

/* ------------------------------------------- persistent settings control */

.pekoe-cc-control {
	position: fixed;
	left: 12px;
	bottom: 12px;
	z-index: 9997;
	min-height: 40px;
	padding: 8px 14px;
	border: 1px solid #d0d0d0;
	border-radius: 999px;
	background: #ffffff;
	color: #333333;
	font: inherit;
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.16);
}

.pekoe-cc-control::before {
	content: "🍪";
	margin-right: 6px;
}

/* Keep the control clear of the banner while it is open. */
#pekoe-cc-banner:not([hidden]) ~ .pekoe-cc-control {
	bottom: 120px;
}

@media (max-width: 600px) {
	.pekoe-cc-banner {
		padding: 14px 14px 18px;
		/* Never block checkout controls: the bar is compact and scrollable. */
		max-height: 60vh;
		overflow-y: auto;
	}

	.pekoe-cc-banner__actions {
		width: 100%;
	}

	.pekoe-cc .pekoe-cc-button {
		flex: 1 1 auto;
		text-align: center;
	}

	.pekoe-cc-control {
		font-size: 12px;
		padding: 6px 10px;
	}
}

/* ------------------------------------------------------- settings dialog */

.pekoe-cc-dialog {
	position: fixed;
	inset: 0;
	z-index: 100001;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(0, 0, 0, 0.55);
}

.pekoe-cc-dialog__inner {
	width: 100%;
	max-width: 720px;
	max-height: 88vh;
	overflow-y: auto;
	padding: 22px 24px 26px;
	background: #ffffff;
	color: #222222;
	border-radius: 4px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.pekoe-cc-dialog__title {
	margin: 0 0 8px;
	/* Headline exception: keep the theme's heading stack (Raleway). */
	font-family: Raleway, "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 22px;
}

.pekoe-cc-dialog__intro {
	margin: 0 0 18px;
}

.pekoe-cc-option {
	margin: 0 0 14px;
	padding: 12px 14px;
	border: 1px solid #e2e2e2;
	border-radius: 3px;
	background: #fafafa;
}

.pekoe-cc-option__label {
	display: flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	cursor: pointer;
}

.pekoe-cc-option--locked .pekoe-cc-option__label {
	cursor: default;
}

.pekoe-cc-option__label input {
	width: 18px;
	height: 18px;
	margin: 0;
}

.pekoe-cc-option__desc {
	margin: 6px 0 0;
	font-size: 14px;
}

.pekoe-cc-signal-note {
	padding: 10px 12px;
	background: #fff4e6;
	border-left: 3px solid #f26a15;
	font-size: 14px;
}

.pekoe-cc-dialog__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 18px 0 10px;
}

.pekoe-cc-message {
	margin: 6px 0;
	padding: 8px 10px;
	background: #fff4e6;
	border-left: 3px solid #b03f00;
	font-size: 14px;
}

.pekoe-cc-dialog__policy a,
.pekoe-cc-noscript a {
	color: #b03f00;
	text-decoration: underline;
}

/* ------------------------------------------------------------ inventory */

.pekoe-cc-inventory {
	width: 100%;
	margin-top: 10px;
	border-collapse: collapse;
	font-size: 13px;
}

.pekoe-cc-inventory__caption {
	caption-side: top;
	padding-bottom: 6px;
	text-align: left;
	font-weight: 700;
}

.pekoe-cc-inventory th,
.pekoe-cc-inventory td {
	padding: 6px 8px;
	border: 1px solid #e2e2e2;
	text-align: left;
	vertical-align: top;
}

.pekoe-cc-inventory thead th {
	background: #f6f6f6;
}

/* --------------------------------------------------------------- noscript */

.pekoe-cc-noscript {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 100000;
	padding: 12px 16px;
	background: #ffffff;
	color: #222222;
	border-top: 3px solid #f26a15;
	font-size: 14px;
}

/* ---------------------------------------------------------- a11y/motion */

@media (prefers-reduced-motion: reduce) {
	.pekoe-cc,
	.pekoe-cc * {
		transition: none !important;
		animation: none !important;
	}
}

html.pekoe-cc-locked {
	overflow: hidden;
}