/**
 * LicenceForge Inner Page Styles
 *
 * Styles for Contact, Legal, Privacy, Terms, Returns, and Lifetime Licence pages.
 * Built on the 352 Digital Theme design system + LicenceForge brand palette.
 *
 * @package LicenceForge_Theme
 * @since 1.1.0
 */

/* ─────────────────────────────────────────────
   PAGE HERO HEADER
   ───────────────────────────────────────────── */

.lf-page-hero {
	background: linear-gradient(170deg, var(--theme-352-gray-50, #f9fafb) 0%, var(--theme-352-white, #fff) 100%);
	padding: var(--theme-352-space-12, 3rem) 0 var(--theme-352-space-8, 2rem);
	border-bottom: 1px solid var(--theme-352-gray-200, #e5e7eb);
	text-align: center;
}

.lf-page-hero__badge {
	display: inline-block;
	font-size: var(--theme-352-font-size-xs, 0.75rem);
	font-weight: 600;
	color: var(--theme-352-accent, #43895c);
	background: rgba(67, 137, 92, 0.1);
	padding: 0.3rem 0.875rem;
	border-radius: var(--theme-352-radius-full, 9999px);
	margin: 0 0 var(--theme-352-space-4, 1rem);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.lf-page-hero__title {
	font-size: clamp(1.75rem, 3.5vw, 2.75rem);
	font-weight: 800;
	line-height: var(--theme-352-line-height-tight, 1.25);
	color: var(--theme-352-gray-900, #111827);
	margin: 0 0 var(--theme-352-space-4, 1rem);
}

.lf-page-hero__desc {
	font-size: var(--theme-352-font-size-lg, 1.125rem);
	color: var(--theme-352-gray-500, #6b7280);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	max-width: 640px;
	margin: 0 auto;
}

/* ─────────────────────────────────────────────
   SHARED CONTAINERS
   ───────────────────────────────────────────── */

.lf-page-container {
	max-width: var(--theme-352-container-max, 1200px);
	margin: 0 auto;
	padding: 0 var(--theme-352-space-6, 1.5rem);
}

.lf-page-container--narrow {
	max-width: var(--theme-352-container-narrow, 800px);
}

.lf-page-container--medium {
	max-width: 960px;
}

.lf-page-section {
	padding: var(--theme-352-space-12, 3rem) 0;
}

/* ─────────────────────────────────────────────
   CONTACT PAGE
   ───────────────────────────────────────────── */

.lf-contact {
	padding: var(--theme-352-space-12, 3rem) 0 var(--theme-352-space-16, 4rem);
}

.lf-contact__grid {
	display: grid;
	grid-template-columns: 1.25fr 0.75fr;
	gap: var(--theme-352-space-12, 3rem);
	align-items: start;
}

/* Form section */
.lf-contact__form-wrap {
	background: var(--theme-352-white, #fff);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
	border-radius: var(--theme-352-radius-lg, 12px);
	padding: var(--theme-352-space-8, 2rem);
}

.lf-contact__form-title {
	font-size: var(--theme-352-font-size-xl, 1.25rem);
	font-weight: 700;
	color: var(--theme-352-gray-900, #111827);
	margin: 0 0 var(--theme-352-space-2, 0.5rem);
}

.lf-contact__form-desc {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-gray-500, #6b7280);
	margin: 0 0 var(--theme-352-space-6, 1.5rem);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
}

/* CF7 form overrides */
.lf-contact__form-wrap .wpcf7-form label {
	display: block;
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	font-weight: 600;
	color: var(--theme-352-gray-700, #374151);
	margin-bottom: var(--theme-352-space-4, 1rem);
}

.lf-contact__form-wrap .wpcf7-form input[type="text"],
.lf-contact__form-wrap .wpcf7-form input[type="email"],
.lf-contact__form-wrap .wpcf7-form textarea {
	display: block;
	width: 100%;
	margin-top: var(--theme-352-space-2, 0.5rem);
	padding: 0.625rem 0.875rem;
	font-size: var(--theme-352-font-size-base, 1rem);
	border: 1px solid var(--theme-352-gray-300, #d1d5db);
	border-radius: var(--theme-352-radius-md, 8px);
	background: var(--theme-352-white, #fff);
	color: var(--theme-352-gray-900, #111827);
	transition: border-color var(--theme-352-transition-fast, 150ms ease),
	            box-shadow var(--theme-352-transition-fast, 150ms ease);
}

.lf-contact__form-wrap .wpcf7-form input[type="text"]:focus,
.lf-contact__form-wrap .wpcf7-form input[type="email"]:focus,
.lf-contact__form-wrap .wpcf7-form textarea:focus {
	outline: none;
	border-color: var(--theme-352-accent, #43895c);
	box-shadow: 0 0 0 3px rgba(67, 137, 92, 0.15);
}

.lf-contact__form-wrap .wpcf7-form textarea {
	min-height: 140px;
	resize: vertical;
}

.lf-contact__form-wrap .wpcf7-form input[type="submit"] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-weight: 600;
	text-decoration: none;
	border-radius: var(--theme-352-radius-md, 8px);
	transition: all var(--theme-352-transition-fast, 150ms ease);
	cursor: pointer;
	border: 2px solid var(--theme-352-accent, #43895c);
	font-size: var(--theme-352-font-size-base, 1rem);
	padding: 0.75rem 2rem;
	background: var(--theme-352-accent, #43895c);
	color: var(--theme-352-white, #fff);
	margin-top: var(--theme-352-space-2, 0.5rem);
}

.lf-contact__form-wrap .wpcf7-form input[type="submit"]:hover {
	background: var(--theme-352-accent-dark, #357548);
	border-color: var(--theme-352-accent-dark, #357548);
	transform: translateY(-1px);
	box-shadow: var(--theme-352-shadow-md);
}

.lf-contact__form-wrap .wpcf7-form input[type="submit"]:focus-visible {
	outline: 3px solid var(--theme-352-primary, #1b3a55);
	outline-offset: 2px;
}

.lf-contact__form-wrap .wpcf7-form .wpcf7-not-valid-tip {
	font-size: var(--theme-352-font-size-xs, 0.75rem);
	color: var(--theme-352-error, #dc3545);
	margin-top: var(--theme-352-space-1, 0.25rem);
}

.lf-contact__form-wrap .wpcf7-form .wpcf7-response-output {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	border-radius: var(--theme-352-radius-md, 8px);
	padding: 0.75rem 1rem;
	margin: var(--theme-352-space-4, 1rem) 0 0;
}

/* Sidebar */
.lf-contact__sidebar {
	display: flex;
	flex-direction: column;
	gap: var(--theme-352-space-6, 1.5rem);
}

.lf-contact__info-card {
	background: var(--theme-352-white, #fff);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
	border-radius: var(--theme-352-radius-lg, 12px);
	padding: var(--theme-352-space-6, 1.5rem);
}

.lf-contact__info-card-header {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	margin-bottom: var(--theme-352-space-4, 1rem);
}

.lf-contact__info-icon {
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(27, 58, 85, 0.08);
	border-radius: var(--theme-352-radius-md, 8px);
	flex-shrink: 0;
}

.lf-contact__info-icon svg {
	width: 20px;
	height: 20px;
	color: var(--theme-352-primary, #1b3a55);
}

.lf-contact__info-card h3 {
	font-size: var(--theme-352-font-size-base, 1rem);
	font-weight: 700;
	color: var(--theme-352-gray-900, #111827);
	margin: 0;
}

.lf-contact__info-card p,
.lf-contact__info-card address {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-gray-600, #4b5563);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	margin: 0;
	font-style: normal;
}

.lf-contact__info-card a {
	color: var(--theme-352-accent, #43895c);
	text-decoration: none;
	transition: color var(--theme-352-transition-fast, 150ms ease);
}

.lf-contact__info-card a:hover {
	color: var(--theme-352-accent-dark, #357548);
	text-decoration: underline;
}

.lf-contact__response-note {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	padding: var(--theme-352-space-4, 1rem);
	background: rgba(67, 137, 92, 0.06);
	border: 1px solid rgba(67, 137, 92, 0.15);
	border-radius: var(--theme-352-radius-md, 8px);
}

.lf-contact__response-note svg {
	width: 20px;
	height: 20px;
	color: var(--theme-352-accent, #43895c);
	flex-shrink: 0;
	margin-top: 1px;
}

.lf-contact__response-note p {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-gray-600, #4b5563);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	margin: 0;
}

/* ─────────────────────────────────────────────
   LEGAL OVERVIEW PAGE
   ───────────────────────────────────────────── */

.lf-legal-overview {
	padding: var(--theme-352-space-12, 3rem) 0 var(--theme-352-space-16, 4rem);
}

.lf-legal-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: var(--theme-352-space-6, 1.5rem);
	margin-bottom: var(--theme-352-space-12, 3rem);
}

.lf-legal-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	background: var(--theme-352-white, #fff);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
	border-radius: var(--theme-352-radius-lg, 12px);
	padding: var(--theme-352-space-8, 2rem) var(--theme-352-space-6, 1.5rem);
	text-decoration: none;
	transition: all var(--theme-352-transition-normal, 250ms ease);
}

.lf-legal-card:hover {
	border-color: var(--theme-352-accent-light, #4f9a68);
	box-shadow: var(--theme-352-shadow-md);
	transform: translateY(-2px);
}

.lf-legal-card:focus-visible {
	outline: 3px solid var(--theme-352-primary, #1b3a55);
	outline-offset: 2px;
}

.lf-legal-card__icon {
	width: 56px;
	height: 56px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(27, 58, 85, 0.08);
	border-radius: var(--theme-352-radius-lg, 12px);
	margin-bottom: var(--theme-352-space-4, 1rem);
}

.lf-legal-card__icon svg {
	width: 28px;
	height: 28px;
	color: var(--theme-352-primary, #1b3a55);
}

.lf-legal-card__title {
	font-size: var(--theme-352-font-size-lg, 1.125rem);
	font-weight: 700;
	color: var(--theme-352-gray-900, #111827);
	margin: 0 0 var(--theme-352-space-2, 0.5rem);
}

.lf-legal-card__desc {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-gray-500, #6b7280);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	margin: 0;
}

.lf-legal-card__arrow {
	margin-top: auto;
	padding-top: var(--theme-352-space-4, 1rem);
	color: var(--theme-352-accent, #43895c);
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: 0.375rem;
	transition: gap var(--theme-352-transition-fast, 150ms ease);
}

.lf-legal-card:hover .lf-legal-card__arrow {
	gap: 0.625rem;
}

.lf-legal-card__arrow svg {
	width: 16px;
	height: 16px;
}

.lf-legal-questions {
	text-align: center;
	padding: var(--theme-352-space-8, 2rem);
	background: var(--theme-352-gray-50, #f9fafb);
	border-radius: var(--theme-352-radius-lg, 12px);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
}

.lf-legal-questions p {
	font-size: var(--theme-352-font-size-base, 1rem);
	color: var(--theme-352-gray-600, #4b5563);
	margin: 0;
}

.lf-legal-questions a {
	color: var(--theme-352-accent, #43895c);
	font-weight: 600;
	text-decoration: none;
}

.lf-legal-questions a:hover {
	text-decoration: underline;
	color: var(--theme-352-accent-dark, #357548);
}

/* ─────────────────────────────────────────────
   POLICY PAGES (Privacy, Terms, Returns, Lifetime)
   ───────────────────────────────────────────── */

.lf-policy {
	padding: var(--theme-352-space-10, 2.5rem) 0 var(--theme-352-space-16, 4rem);
}

.lf-policy__meta {
	display: flex;
	align-items: center;
	gap: var(--theme-352-space-4, 1rem);
	flex-wrap: wrap;
	margin-bottom: var(--theme-352-space-8, 2rem);
	padding-bottom: var(--theme-352-space-4, 1rem);
	border-bottom: 1px solid var(--theme-352-gray-200, #e5e7eb);
}

.lf-policy__meta-item {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-gray-500, #6b7280);
}

.lf-policy__meta-item svg {
	width: 16px;
	height: 16px;
	flex-shrink: 0;
}

.lf-policy__meta-sep {
	color: var(--theme-352-gray-300, #d1d5db);
}

.lf-policy__toc {
	background: var(--theme-352-gray-50, #f9fafb);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
	border-radius: var(--theme-352-radius-lg, 12px);
	padding: var(--theme-352-space-6, 1.5rem) var(--theme-352-space-8, 2rem);
	margin-bottom: var(--theme-352-space-10, 2.5rem);
}

.lf-policy__toc-title {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	font-weight: 700;
	color: var(--theme-352-gray-900, #111827);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	margin: 0 0 var(--theme-352-space-3, 0.75rem);
}

.lf-policy__toc-list {
	list-style: none;
	padding: 0;
	margin: 0;
	columns: 2;
	column-gap: var(--theme-352-space-8, 2rem);
}

.lf-policy__toc-list li {
	padding: var(--theme-352-space-1, 0.25rem) 0;
	break-inside: avoid;
}

.lf-policy__toc-list a {
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	color: var(--theme-352-accent, #43895c);
	text-decoration: none;
	transition: color var(--theme-352-transition-fast, 150ms ease);
}

.lf-policy__toc-list a:hover {
	color: var(--theme-352-accent-dark, #357548);
	text-decoration: underline;
}

/* Policy body content */
.lf-policy__body h2 {
	font-size: var(--theme-352-font-size-xl, 1.25rem);
	font-weight: 700;
	color: var(--theme-352-gray-900, #111827);
	margin: var(--theme-352-space-10, 2.5rem) 0 var(--theme-352-space-4, 1rem);
	padding-top: var(--theme-352-space-4, 1rem);
	border-top: 1px solid var(--theme-352-gray-100, #f3f4f6);
	scroll-margin-top: 100px;
}

.lf-policy__body h2:first-child {
	margin-top: 0;
	padding-top: 0;
	border-top: none;
}

.lf-policy__body h3 {
	font-size: var(--theme-352-font-size-lg, 1.125rem);
	font-weight: 600;
	color: var(--theme-352-gray-800, #1f2937);
	margin: var(--theme-352-space-6, 1.5rem) 0 var(--theme-352-space-3, 0.75rem);
}

.lf-policy__body p {
	font-size: var(--theme-352-font-size-base, 1rem);
	color: var(--theme-352-gray-600, #4b5563);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	margin: 0 0 var(--theme-352-space-4, 1rem);
}

.lf-policy__body ul,
.lf-policy__body ol {
	padding-left: var(--theme-352-space-6, 1.5rem);
	margin: 0 0 var(--theme-352-space-4, 1rem);
}

.lf-policy__body li {
	font-size: var(--theme-352-font-size-base, 1rem);
	color: var(--theme-352-gray-600, #4b5563);
	line-height: var(--theme-352-line-height-relaxed, 1.625);
	margin-bottom: var(--theme-352-space-2, 0.5rem);
}

.lf-policy__body strong {
	color: var(--theme-352-gray-800, #1f2937);
	font-weight: 600;
}

.lf-policy__body a {
	color: var(--theme-352-accent, #43895c);
	text-decoration: none;
}

.lf-policy__body a:hover {
	color: var(--theme-352-accent-dark, #357548);
	text-decoration: underline;
}

.lf-policy__body table {
	width: 100%;
	border-collapse: collapse;
	margin: 0 0 var(--theme-352-space-6, 1.5rem);
	font-size: var(--theme-352-font-size-sm, 0.875rem);
}

.lf-policy__body th {
	text-align: left;
	font-weight: 600;
	color: var(--theme-352-gray-900, #111827);
	background: var(--theme-352-gray-50, #f9fafb);
	padding: 0.75rem 1rem;
	border-bottom: 2px solid var(--theme-352-gray-200, #e5e7eb);
}

.lf-policy__body td {
	padding: 0.75rem 1rem;
	color: var(--theme-352-gray-600, #4b5563);
	border-bottom: 1px solid var(--theme-352-gray-100, #f3f4f6);
	vertical-align: top;
}

.lf-policy__body tr:last-child td {
	border-bottom: none;
}

/* Highlighted info box within policies */
.lf-policy__highlight {
	background: rgba(67, 137, 92, 0.06);
	border-left: 4px solid var(--theme-352-accent, #43895c);
	border-radius: 0 var(--theme-352-radius-md, 8px) var(--theme-352-radius-md, 8px) 0;
	padding: var(--theme-352-space-4, 1rem) var(--theme-352-space-6, 1.5rem);
	margin: 0 0 var(--theme-352-space-6, 1.5rem);
}

.lf-policy__highlight p {
	margin: 0;
	color: var(--theme-352-gray-700, #374151);
}

.lf-policy__highlight p + p {
	margin-top: var(--theme-352-space-2, 0.5rem);
}

/* Back to legal link */
.lf-policy__back {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-size: var(--theme-352-font-size-sm, 0.875rem);
	font-weight: 600;
	color: var(--theme-352-accent, #43895c);
	text-decoration: none;
	margin-bottom: var(--theme-352-space-6, 1.5rem);
	transition: color var(--theme-352-transition-fast, 150ms ease);
}

.lf-policy__back:hover {
	color: var(--theme-352-accent-dark, #357548);
}

.lf-policy__back svg {
	width: 16px;
	height: 16px;
}

/* Contact block at bottom of policies */
.lf-policy__contact {
	background: var(--theme-352-gray-50, #f9fafb);
	border: 1px solid var(--theme-352-gray-200, #e5e7eb);
	border-radius: var(--theme-352-radius-lg, 12px);
	padding: var(--theme-352-space-6, 1.5rem) var(--theme-352-space-8, 2rem);
	margin-top: var(--theme-352-space-10, 2.5rem);
}

.lf-policy__contact h2 {
	border-top: none;
	padding-top: 0;
	margin-top: 0;
	margin-bottom: var(--theme-352-space-3, 0.75rem);
}

/* ─────────────────────────────────────────────
   RESPONSIVE
   ───────────────────────────────────────────── */

@media (max-width: 960px) {
	.lf-contact__grid {
		grid-template-columns: 1fr;
		gap: var(--theme-352-space-8, 2rem);
	}

	.lf-legal-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.lf-policy__toc-list {
		columns: 1;
	}
}

@media (max-width: 640px) {
	.lf-page-hero {
		padding: var(--theme-352-space-8, 2rem) 0 var(--theme-352-space-6, 1.5rem);
	}

	.lf-legal-grid {
		grid-template-columns: 1fr;
	}

	.lf-contact__form-wrap {
		padding: var(--theme-352-space-6, 1.5rem);
	}

	.lf-policy__body table {
		display: block;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}
}

/* Respect user motion preferences */
@media (prefers-reduced-motion: reduce) {
	.lf-legal-card {
		transition: none;
	}
}

/* ─────────────────────────────────────────────
   SIDEBAR
   Supports both classic widgets and Gutenberg
   block widgets (wp-block-*).
   ───────────────────────────────────────────── */

@media (min-width: 1024px) {
	.sidebar {
		padding-top: var(--theme-352-space-8, 2rem);
		padding-bottom: var(--theme-352-space-8, 2rem);
	}

	/*
	 * Sticky sidebar: let the parent theme handle
	 * position: sticky. Remove any max-height / overflow
	 * so the sidebar is never internally scrollable —
	 * it simply sticks at the top of the viewport.
	 */
	.has-sticky-sidebar aside.sidebar {
		max-height: none !important;
		overflow-y: visible !important;
	}

	/* ── Widget card containers ──────────────── */

	.sidebar .widget {
		background: var(--theme-352-white, #fff);
		border: 1px solid var(--theme-352-gray-200, #e5e7eb);
		border-radius: var(--theme-352-radius-lg, 12px);
		padding: var(--theme-352-space-6, 1.5rem);
		margin-bottom: var(--theme-352-space-6, 1.5rem);
		transition: box-shadow var(--theme-352-transition-normal, 250ms ease);
	}

	.sidebar .widget:last-child {
		margin-bottom: 0;
	}

	.sidebar .widget:hover {
		box-shadow: var(--theme-352-shadow-md);
	}

	/* ── Widget titles (classic + block) ─────── */

	.sidebar .widget-title,
	.sidebar .widget h2.wp-block-heading {
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		font-weight: 700;
		color: var(--theme-352-gray-900, #111827);
		text-transform: uppercase;
		letter-spacing: 0.04em;
		margin: 0 0 var(--theme-352-space-4, 1rem);
		padding: 0 0 var(--theme-352-space-3, 0.75rem);
		border-bottom: 2px solid var(--theme-352-accent, #43895c);
	}

	/* ── List widgets (classic + block) ──────── */

	.sidebar .widget ul {
		list-style: none;
		margin: 0;
		padding: 0;
	}

	.sidebar .widget li {
		padding: var(--theme-352-space-2, 0.5rem) 0;
		border-bottom: 1px solid var(--theme-352-gray-100, #f3f4f6);
	}

	.sidebar .widget li:last-child {
		border-bottom: none;
		padding-bottom: 0;
	}

	.sidebar .widget li:first-child {
		padding-top: 0;
	}

	/* ── Links ────────────────────────────────── */

	.sidebar .widget a {
		color: var(--theme-352-accent, #43895c);
		text-decoration: none;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		transition: color var(--theme-352-transition-fast, 150ms ease);
	}

	.sidebar .widget a:hover,
	.sidebar .widget a:focus {
		color: var(--theme-352-accent-dark, #357548);
		text-decoration: underline;
	}

	/* ── Search widget (block) ───────────────── */

	.sidebar .widget_search .wp-block-search__label {
		display: block;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		font-weight: 700;
		color: var(--theme-352-gray-900, #111827);
		text-transform: uppercase;
		letter-spacing: 0.04em;
		margin: 0 0 var(--theme-352-space-4, 1rem);
		padding: 0 0 var(--theme-352-space-3, 0.75rem);
		border-bottom: 2px solid var(--theme-352-accent, #43895c);
	}

	.sidebar .widget_search .wp-block-search__inside-wrapper {
		display: flex;
	}

	.sidebar .widget_search .wp-block-search__input {
		flex: 1;
		padding: 0.625rem 0.875rem;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		border: 1px solid var(--theme-352-gray-300, #d1d5db);
		border-right: none;
		border-radius: var(--theme-352-radius-md, 8px) 0 0 var(--theme-352-radius-md, 8px);
		background: var(--theme-352-white, #fff);
		color: var(--theme-352-gray-900, #111827);
		transition: border-color var(--theme-352-transition-fast, 150ms ease),
		            box-shadow var(--theme-352-transition-fast, 150ms ease);
	}

	.sidebar .widget_search .wp-block-search__input:focus {
		outline: none;
		border-color: var(--theme-352-accent, #43895c);
		box-shadow: 0 0 0 3px rgba(67, 137, 92, 0.15);
		border-right: none;
	}

	.sidebar .widget_search .wp-block-search__button {
		padding: 0.625rem 1.25rem;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		font-weight: 600;
		background: var(--theme-352-accent, #43895c);
		color: var(--theme-352-white, #fff);
		border: 1px solid var(--theme-352-accent, #43895c);
		border-radius: 0 var(--theme-352-radius-md, 8px) var(--theme-352-radius-md, 8px) 0;
		cursor: pointer;
		transition: background-color var(--theme-352-transition-fast, 150ms ease),
		            border-color var(--theme-352-transition-fast, 150ms ease);
	}

	.sidebar .widget_search .wp-block-search__button:hover {
		background: var(--theme-352-accent-dark, #357548);
		border-color: var(--theme-352-accent-dark, #357548);
	}

	.sidebar .widget_search .wp-block-search__button:focus-visible {
		outline: 3px solid var(--theme-352-primary, #1b3a55);
		outline-offset: 2px;
	}

	/* Classic search fallback */
	.sidebar .widget_search .search-form {
		display: flex;
		max-width: 100%;
		margin: 0;
	}

	.sidebar .widget_search .search-field {
		flex: 1;
		padding: 0.625rem 0.875rem;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		border: 1px solid var(--theme-352-gray-300, #d1d5db);
		border-right: none;
		border-radius: var(--theme-352-radius-md, 8px) 0 0 var(--theme-352-radius-md, 8px);
		background: var(--theme-352-white, #fff);
		color: var(--theme-352-gray-900, #111827);
		transition: border-color var(--theme-352-transition-fast, 150ms ease),
		            box-shadow var(--theme-352-transition-fast, 150ms ease);
	}

	.sidebar .widget_search .search-field:focus {
		outline: none;
		border-color: var(--theme-352-accent, #43895c);
		box-shadow: 0 0 0 3px rgba(67, 137, 92, 0.15);
		border-right: none;
	}

	.sidebar .widget_search .search-submit {
		padding: 0.625rem 1.25rem;
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		font-weight: 600;
		background: var(--theme-352-accent, #43895c);
		color: var(--theme-352-white, #fff);
		border: 1px solid var(--theme-352-accent, #43895c);
		border-radius: 0 var(--theme-352-radius-md, 8px) var(--theme-352-radius-md, 8px) 0;
		cursor: pointer;
		transition: background-color var(--theme-352-transition-fast, 150ms ease),
		            border-color var(--theme-352-transition-fast, 150ms ease);
	}

	.sidebar .widget_search .search-submit:hover {
		background: var(--theme-352-accent-dark, #357548);
		border-color: var(--theme-352-accent-dark, #357548);
	}

	.sidebar .widget_search .search-submit:focus-visible {
		outline: 3px solid var(--theme-352-primary, #1b3a55);
		outline-offset: 2px;
	}

	/* ── Comments widget (block + classic) ───── */

	.sidebar .wp-block-latest-comments,
	.sidebar .widget_recent_comments .recentcomments {
		font-size: var(--theme-352-font-size-sm, 0.875rem);
		color: var(--theme-352-gray-600, #4b5563);
		line-height: var(--theme-352-line-height-relaxed, 1.625);
	}
}

/* Sidebar motion preferences */
@media (prefers-reduced-motion: reduce) {
	.sidebar .widget {
		transition: none;
	}
}
