/* Content pages: legal, contact, about. */

/*
 * The draft banner. It has to be impossible to miss — a legal page carrying
 * [NAZWA FIRMY] must never read as finished. docs/wdrozenie.md blocks the
 * launch until every placeholder is gone.
 */
.haft-roboczy {
	background: #fff4d6;
	border-left: 4px solid var( --haft-mulina );
	padding: 16px 18px;
	margin-bottom: 32px;
	font-size: 0.95rem;
	line-height: 1.6;
}

/* Pulls the eye to a clause the customer must not skim past. */
.haft-uwaga {
	background: var( --haft-kreda );
	border-left: 4px solid var( --haft-denim );
	padding: 16px 18px;
	margin: 24px 0;
	line-height: 1.65;
}

.haft-tabela table {
	border-collapse: collapse;
	width: 100%;
	background: var( --haft-kreda );
	font-size: 0.9rem;
}

.haft-tabela th,
.haft-tabela td {
	border: 1px solid var( --haft-szew );
	padding: 10px 12px;
	text-align: left;
}

.haft-tabela th {
	font-family: var( --haft-font-display );
	font-weight: 700;
	background: var( --haft-len );
}

/*
 * Opening hours on the contact page: a two-column table with the chrome taken
 * off, so the hours line up under each other the way they do in the footer.
 * A table rather than a paragraph with line breaks because two columns are
 * what it is — and the owner can still edit every cell in the block editor.
 */
.haft-godziny,
.haft-godziny table,
.haft-godziny td {
	border: 0;
}

/*
 * Same type as the paragraph the table replaced. Blocksy sizes body copy at
 * 1.15rem and sets the table smaller; a list of hours that shrinks next to
 * the address above it reads as a footnote.
 */
.haft-godziny table {
	width: auto;
	border-collapse: collapse;
	font-size: 1.15rem;
	line-height: 1.7;
}

.haft-godziny td {
	padding: 0 20px 0 0;
}

.haft-godziny td:last-child {
	padding-right: 0;
	text-align: right;
	font-variant-numeric: tabular-nums;
}

/* Legal prose reads better narrow; the shop's own pages stay full width. */
.page .entry-content h2 {
	margin-top: 36px;
	margin-bottom: 10px;
	font-size: 1.35rem;
}

/*
 * Legal prose reads better narrow, so the whole column narrows — not the
 * paragraphs inside it.
 *
 * Blocksy gives every direct child of a constrained container
 * `width: var(--theme-block-width)`, and core then centres it with
 * `margin-left: auto !important`. Those two together are what draws the content
 * column. Capping just the paragraphs at 72ch therefore does not narrow the
 * measure in place: it shrinks each paragraph box and lets the auto margin
 * re-centre it, so the prose drifts inward while the headings stay put. Forcing
 * the margins back to zero is worse — the containing block is the full-width
 * .entry-content, so the text lands against the window edge, outside the column
 * entirely. Both were tried; both looked broken.
 *
 * Retuning Blocksy's own variable narrows every child at once, so headings and
 * paragraphs keep a shared left edge and the auto margins go on doing their job.
 * No !important, and nothing to re-tune if the theme changes its container maths.
 *
 * The width is in rem, not the ch the measure is actually reasoned in. A var()
 * is substituted at the point of use, so `ch` would resolve against each child's
 * own font: 72ch off a 1.35rem heading is far wider than 72ch off 1rem body
 * copy, and the one column would silently come out two different widths — which
 * is exactly how the first attempt failed. 44rem is roughly that measure for the
 * body text, expressed in a unit every child agrees on.
 *
 * The home page is excluded, and not out of caution: it is a page too, and a
 * custom property inherits, so narrowing the column reached down into its block
 * groups and squeezed the whole layout to 44rem — the five category tiles
 * wrapped to 3+2 and the process steps went to slivers. A reading measure is
 * right for prose and wrong for a landing page.
 *
 * The cart and the checkout are excluded for the same reason, found the same
 * way — on a screenshot. They are pages too, so they were inheriting the 44rem
 * measure, and WooCommerce's cart block lays itself out from the width it
 * measures: at 704px it decided it was narrow and stacked the order summary
 * underneath the product list on a 1440px screen. Nothing looked broken enough
 * to notice from the markup; it just looked like a cramped cart.
 */
body:not( .home ):not( .woocommerce-cart ):not( .woocommerce-checkout ) .entry-content {
	--theme-block-width: 44rem;
}

body:not( .home ) .entry-content > p {
	line-height: 1.7;
}
