/*
 * Snow Stream Core - cookie banner.
 *
 * A bottom sheet rather than a full-screen modal: the visitor is allowed to read
 * the page while deciding, and nothing optional runs until they have. The two
 * first-level answers sit side by side at the same size on purpose - a quiet
 * "reject" next to a loud "accept" is not a free choice.
 */

.ssc-cookie {
	position: fixed;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 99999;
	padding: var(--ssc-space-3);
	background: rgba(18, 59, 112, .18);
}

.ssc-cookie[hidden] { display: none; }

.ssc-cookie-panel {
	width: 100%;
	max-width: var(--ssc-container-narrow);
	margin: 0 auto;
	padding: var(--ssc-space-5);
	border: 1px solid var(--ssc-line);
	border-radius: var(--ssc-radius-lg);
	background: var(--ssc-surface);
	box-shadow: var(--ssc-shadow);
	max-height: 82vh;
	overflow-y: auto;
}

.ssc-cookie-title {
	margin: 0 0 var(--ssc-space-2);
	color: var(--ssc-brand-ink);
	font-size: 19px;
	font-weight: 800;
	text-transform: none;
}

.ssc-cookie-text {
	margin: 0;
	color: var(--ssc-text);
	font-size: 14px;
	line-height: 1.55;
}

.ssc-cookie-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--ssc-space-2);
	margin-top: var(--ssc-space-4);
}

/* Accept and reject are the same control at the same weight. */
.ssc-cookie-actions .ssc-button {
	flex: 0 1 auto;
	min-height: var(--ssc-tap);
}

.ssc-cookie-link {
	min-height: var(--ssc-tap);
	padding: 0 var(--ssc-space-3);
	border: 0;
	background: none;
	color: var(--ssc-brand);
	font: inherit;
	font-weight: 600;
	text-decoration: underline;
	cursor: pointer;
}

.ssc-cookie-link:hover { color: var(--ssc-brand-dark); }

/* ------------------------------------------------------------ categories - */

.ssc-cookie-prefs {
	display: grid;
	gap: var(--ssc-space-2);
	margin-top: var(--ssc-space-4);
	padding-top: var(--ssc-space-4);
	border-top: 1px solid var(--ssc-line-soft);
}

.ssc-cookie-prefs[hidden] { display: none; }

.ssc-cookie-cat {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: var(--ssc-space-3);
	align-items: start;
	margin: 0;
	padding: var(--ssc-space-3);
	border: 1px solid var(--ssc-line-soft);
	border-radius: var(--ssc-radius-sm);
	background: var(--ssc-surface-subtle);
	color: var(--ssc-text);
	font-size: 13.5px;
	font-weight: 400;
	line-height: 1.5;
	cursor: pointer;
}

.ssc-cookie-cat.is-locked {
	background: var(--ssc-surface-sunken);
	cursor: default;
}

.ssc-cookie-cat input {
	width: 18px;
	height: 18px;
	margin-top: 2px;
}

.ssc-cookie-cat strong {
	display: block;
	margin-bottom: 2px;
	color: var(--ssc-brand-ink);
	font-size: 14px;
}

/* ------------------------------------------------------- reopen the panel - */

/*
 * Consent has to stay withdrawable, and the theme's footer is edited in the
 * Customizer where a shortcode is easy to lose. This button is the guarantee:
 * small, out of the way, and present on every page. The
 * [snowstream_cookie_settings] shortcode and any link to #cookie-settings open
 * the same panel for sites that would rather place it themselves.
 */
.ssc-cookie-reopen {
	position: fixed;
	bottom: 12px;
	left: 12px;
	z-index: 9998;
	padding: 7px 13px;
	border: 1px solid var(--ssc-line);
	border-radius: var(--ssc-radius-pill);
	background: var(--ssc-surface);
	color: var(--ssc-text-muted);
	box-shadow: var(--ssc-shadow-sm);
	font-size: 12px;
	font-weight: 600;
	opacity: .72;
	cursor: pointer;
}

.ssc-cookie-reopen:hover { opacity: 1; color: var(--ssc-brand); }
.ssc-cookie-reopen[hidden] { display: none; }

/* ------------------------------------------------------- held-back embeds - */

.ssc-cookie-embed {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: var(--ssc-space-2);
	min-height: 220px;
	padding: var(--ssc-space-5);
	border: 1px dashed var(--ssc-line-dashed);
	border-radius: var(--ssc-radius);
	background: var(--ssc-surface-sunken);
	text-align: center;
}

.ssc-cookie-embed p {
	margin: 0;
	max-width: 46ch;
	color: var(--ssc-text-muted);
	font-size: 14px;
}

.ssc-cookie-embed-live iframe { max-width: 100%; }

@media (max-width: 600px) {
	.ssc-cookie-panel { padding: var(--ssc-space-4); }
	.ssc-cookie-actions .ssc-button { flex: 1 1 100%; }
	.ssc-cookie-link { width: 100%; }
}

/* ----------------------------------------------------------- legal bar - */

/*
 * Printed by SSC_Legal after the theme's own footer, because wp_footer() runs
 * last. Deliberately quiet: this is the identification a company owes its
 * visitors, not a call to action.
 */
.ssc-legal-bar {
	padding: 18px var(--ssc-space-4) 22px;
	border-top: 1px solid var(--ssc-line);
	background: var(--ssc-surface-sunken);
	color: var(--ssc-text-muted);
	font-size: 13px;
	line-height: 1.6;
	text-align: center;
}

.ssc-legal-inner {
	display: flex;
	flex-direction: column;
	gap: 6px;
	max-width: var(--ssc-container);
	margin: 0 auto;
}

.ssc-legal-bar p { margin: 0; }
.ssc-legal-id { color: var(--ssc-ink-700); }

.ssc-legal-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 6px 18px;
	margin-top: 4px;
}

.ssc-legal-bar a {
	color: var(--ssc-brand) !important;
	text-decoration: underline;
}

.ssc-legal-links a { font-weight: 600; }
.ssc-legal-bar a:hover { color: var(--ssc-brand-dark) !important; }

/* The reopen pill would sit on top of the bar on a short page. */
.ssc-legal-bar ~ .ssc-cookie-reopen { bottom: 4px; }

/* Privacy note under a Contact Form 7 form, added by SSC_Legal. */
.ssc-form-privacy {
	margin: 14px 0 0;
	color: var(--ssc-text-muted);
	font-size: 13px;
	line-height: 1.55;
}

.ssc-form-privacy a { color: var(--ssc-brand); text-decoration: underline; }
