/**
 * Sereneyuto block styles.
 *
 * Deliberately small and variable-driven: the theme owns colour and type, this
 * file owns structure. Every custom property below has a fallback so the blocks
 * still look intentional if they end up in another theme.
 */

/*
 * Type sizes come from the shared scale, never from an em multiplier.
 *
 * --sy-fs-* is declared twice, once per rendering context: in the theme's
 * style.css (aliasing theme.json's presets) and literally in the plugin's
 * assets/lp/lp.css, because landing pages dequeue theme.json global styles.
 * The rem fallbacks below are the same values again, so these blocks still land
 * on the scale if they are ever rendered somewhere neither file loaded.
 *
 * Every rule here used to carry its own em multiplier — 0.8, 0.85, 0.9, 0.95 —
 * which produced 12.8/13.6/14.4/15.2px and meant three different sizes all read
 * as "small print". They were rounded to the nearest tier on 2026-08-28.
 */

:root {
	--sereneyuto-block-radius: 4px;
}

/* --- Disclosure ------------------------------------------------------- */

.sereneyuto-disclosure {
	border-left: 3px solid var( --wp--preset--color--accent, #8a7f6d );
	padding: 0.75em 1em;
	margin-block: 1.5em;
	background: var( --wp--preset--color--surface, #f6f4f0 );
	font-size: var( --sy-fs-sm, 0.875rem );
}

.sereneyuto-disclosure p {
	margin: 0;
}

/* --- Safety note ------------------------------------------------------ */

.sereneyuto-safety-note {
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	border-left-width: 4px;
	border-left-color: #b98a2e;
	border-radius: var( --sereneyuto-block-radius );
	padding: 1em 1.25em;
	margin-block: 2em;
	background: #fdfaf3;
}

.sereneyuto-safety-note__title {
	margin: 0 0 0.4em;
	font-weight: 600;
	letter-spacing: 0.01em;
}

.sereneyuto-safety-note__body > :last-child {
	margin-bottom: 0;
}

/* --- Buttons ---------------------------------------------------------- */

.sereneyuto-button {
	display: inline-block;
	padding: 0.7em 1.4em;
	border-radius: var( --sereneyuto-block-radius );
	background: var( --wp--preset--color--accent, #4a5d4e );
	color: #fff;
	font-weight: 600;
	text-decoration: none;
	line-height: 1.2;
}

.sereneyuto-button:hover,
.sereneyuto-button:focus {
	opacity: 0.9;
	color: #fff;
	text-decoration: none;
}

/* --- Product card ----------------------------------------------------- */

.sereneyuto-product-card {
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	border-radius: var( --sereneyuto-block-radius );
	padding: 1.25em;
	margin-block: 2em;
}

.sereneyuto-product-card__badge {
	display: inline-block;
	margin: 0 0 0.75em;
	padding: 0.2em 0.6em;
	border-radius: 999px;
	background: var( --wp--preset--color--surface, #f6f4f0 );
	font-size: var( --sy-fs-xs, 0.75rem );
	text-transform: uppercase;
	letter-spacing: 0.06em;
}

.sereneyuto-product-card__head {
	display: grid;
	grid-template-columns: minmax( 0, 1fr );
	gap: 1em;
}

.sereneyuto-product-card__media img {
	width: 100%;
	height: auto;
	border-radius: var( --sereneyuto-block-radius );
}

.sereneyuto-product-card__brand {
	margin: 0;
	font-size: var( --sy-fs-sm, 0.875rem );
	text-transform: uppercase;
	letter-spacing: 0.08em;
	opacity: 0.7;
}

.sereneyuto-product-card__title {
	margin: 0.2em 0 0.5em;
}

.sereneyuto-product-card__best-for span,
.sereneyuto-product-card__rating {
	font-size: var( --sy-fs-sm, 0.875rem );
	opacity: 0.85;
}

.sereneyuto-product-card__best-for span {
	font-weight: 600;
	margin-right: 0.35em;
}

.sereneyuto-product-card__proscons {
	display: grid;
	grid-template-columns: minmax( 0, 1fr );
	gap: 1em;
	margin-top: 1.25em;
}

.sereneyuto-product-card__proscons h4 {
	margin: 0 0 0.4em;
	font-size: var( --sy-fs-base, 1rem );
}

.sereneyuto-product-card__proscons ul {
	margin: 0;
	padding-left: 1.1em;
}

.sereneyuto-product-card__verdict {
	margin-top: 1.25em;
	padding-top: 1em;
	border-top: 1px solid var( --wp--preset--color--border, #ded7cb );
}

.sereneyuto-product-card__verdict h4 {
	margin: 0 0 0.4em;
}

.sereneyuto-product-card__cta {
	margin: 1.25em 0 0;
}

@media ( min-width: 40rem ) {
	.sereneyuto-product-card__head {
		grid-template-columns: 220px minmax( 0, 1fr );
		align-items: start;
	}

	.sereneyuto-product-card__proscons {
		grid-template-columns: repeat( 2, minmax( 0, 1fr ) );
	}
}

/* --- Comparison table ------------------------------------------------- */

.sereneyuto-comparison {
	margin-block: 2em;
}

.sereneyuto-comparison__table {
	width: 100%;
	border-collapse: collapse;
}

.sereneyuto-comparison__table th,
.sereneyuto-comparison__table td {
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	padding: 0.6em 0.75em;
	text-align: left;
	vertical-align: top;
	font-size: var( --sy-fs-base, 1rem );
}

.sereneyuto-comparison__table ul {
	margin: 0;
	padding-left: 1.1em;
}

/* Under 48rem the table becomes a card per product — no sideways scrolling. */
@media ( max-width: 48rem ) {
	.sereneyuto-comparison__table,
	.sereneyuto-comparison__table tbody,
	.sereneyuto-comparison__table tr,
	.sereneyuto-comparison__table td {
		display: block;
		width: 100%;
	}

	.sereneyuto-comparison__table thead {
		display: none;
	}

	.sereneyuto-comparison__table tr {
		margin-bottom: 1em;
	}

	.sereneyuto-comparison__table th[ scope='row' ] {
		display: block;
		background: var( --wp--preset--color--surface, #f6f4f0 );
	}

	.sereneyuto-comparison__table td::before {
		content: attr( data-label ) ' — ';
		font-weight: 600;
		opacity: 0.75;
	}

	.sereneyuto-comparison__cta-row td::before {
		content: none;
	}
}

/* --- Byline ----------------------------------------------------------- */

.sereneyuto-byline {
	display: flex;
	gap: 0.9em;
	align-items: center;
	margin-block: 1.5em;
}

.sereneyuto-byline p {
	margin: 0;
}

.sereneyuto-byline__dates {
	font-size: var( --sy-fs-sm, 0.875rem );
	opacity: 0.8;
}

/* --- FAQ -------------------------------------------------------------- */

.sereneyuto-faq {
	margin-block: 2.5em;
}

.sereneyuto-faq__item {
	border-bottom: 1px solid var( --wp--preset--color--border, #ded7cb );
	padding: 0.75em 0;
}

.sereneyuto-faq__question {
	cursor: pointer;
	font-weight: 600;
}

.sereneyuto-faq__answer {
	padding-top: 0.5em;
}

.sereneyuto-faq__answer > :last-child {
	margin-bottom: 0;
}

/* --- Steps ------------------------------------------------------------ */

.sereneyuto-steps__list {
	list-style: none;
	counter-reset: sereneyuto-step;
	margin: 0;
	padding: 0;
}

.sereneyuto-steps__item {
	counter-increment: sereneyuto-step;
	display: grid;
	gap: 1em;
	margin-bottom: 2em;
}

.sereneyuto-steps__media {
	margin: 0;
}

.sereneyuto-steps__media img {
	width: 100%;
	height: auto;
	border-radius: var( --sereneyuto-block-radius );
}

.sereneyuto-steps__title::before {
	content: counter( sereneyuto-step ) '. ';
	opacity: 0.55;
}

.sereneyuto-steps__body > :last-child {
	margin-bottom: 0;
}

@media ( min-width: 40rem ) {
	.sereneyuto-steps__item {
		grid-template-columns: 260px minmax( 0, 1fr );
		align-items: start;
	}
}

/* --- Table of contents ------------------------------------------------ */

.sereneyuto-toc {
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	border-radius: var( --sereneyuto-block-radius );
	padding: 1em 1.25em;
	margin-block: 2em;
	background: var( --wp--preset--color--surface, #f6f4f0 );
}

.sereneyuto-toc__heading {
	margin: 0 0 0.5em;
	font-weight: 600;
	font-size: var( --sy-fs-sm, 0.875rem );
	text-transform: uppercase;
	letter-spacing: 0.06em;
}

.sereneyuto-toc__list {
	margin: 0;
	padding-left: 1.2em;
	font-size: var( --sy-fs-base, 1rem );
}

.sereneyuto-toc__item--h3 {
	margin-left: 1em;
	list-style-type: circle;
}

/* --- Opt-in ----------------------------------------------------------- */

.sereneyuto-optin {
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	border-radius: var( --sereneyuto-block-radius );
	padding: 1.5em;
	margin-block: 2.5em;
	background: var( --wp--preset--color--surface, #f6f4f0 );
}

.sereneyuto-optin__heading {
	margin-top: 0;
}

.sereneyuto-optin__label {
	display: block;
	font-size: var( --sy-fs-sm, 0.875rem );
	font-weight: 600;
	margin-bottom: 0.3em;
}

.sereneyuto-optin__email {
	width: 100%;
	max-width: 26rem;
	padding: 0.6em 0.7em;
	border: 1px solid var( --wp--preset--color--border, #ded7cb );
	border-radius: var( --sereneyuto-block-radius );
	font-size: var( --sy-fs-base, 1rem );
}

/* Visible to bots reading the DOM, never to a person. */
.sereneyuto-optin__honeypot {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.sereneyuto-optin__consent {
	display: flex;
	gap: 0.5em;
	align-items: flex-start;
	font-size: var( --sy-fs-sm, 0.875rem );
	margin: 1em 0;
}

.sereneyuto-optin__message:empty {
	display: none;
}

.sereneyuto-optin__message {
	margin: 0.75em 0 0;
	font-size: var( --sy-fs-sm, 0.875rem );
}

/* --- Editor-only ------------------------------------------------------ */

.sereneyuto-editor-placeholder {
	border: 1px dashed #a7aaad;
	border-radius: var( --sereneyuto-block-radius );
	padding: 1.25em;
	text-align: center;
	color: #50575e;
}

.sereneyuto-editor-placeholder p {
	margin: 0.4em 0 0;
	font-size: 0.9em;
}

.sereneyuto-editor-hint {
	font-size: 0.85em;
	color: #50575e;
	font-style: italic;
}

.sereneyuto-editor-warning {
	border-left: 3px solid #d63638;
	padding-left: 0.75em;
	color: #d63638;
}

.sereneyuto-repeater__row {
	border: 1px solid #e0e0e0;
	border-radius: var( --sereneyuto-block-radius );
	padding: 0.75em;
	margin-bottom: 0.75em;
}

.sereneyuto-repeater__actions {
	display: flex;
	gap: 0.25em;
	justify-content: flex-end;
}

.sereneyuto-list-control__label {
	font-size: 11px;
	font-weight: 500;
	text-transform: uppercase;
	margin-bottom: 0.4em;
}
