/* Base: reset, typography, buttons, form controls, block tones, utilities. Mobile-first. */

*, *::before, *::after { box-sizing: border-box; }

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
	margin: 0;
	background: var(--c-bg);
	color: var(--c-ink);
	font-family: var(--font);
	font-size: var(--fs-body);
	font-weight: 400;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
[hidden] { display: none !important; }

:focus-visible {
	outline: 3px solid var(--c-focus);
	outline-offset: 3px;
}

/* Typography ------------------------------------------------------------- */

.display, .h1, .h2 {
	font-weight: 800;
	letter-spacing: -0.04em;
	line-height: 0.95;
	text-wrap: balance;
}
.display { font-size: var(--fs-display); }
.h1 { font-size: var(--fs-h1); }
.h2 { font-size: var(--fs-h2); }
.h3 {
	font-size: var(--fs-h3);
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.15;
}

.lead {
	font-size: var(--fs-lead);
	line-height: 1.45;
	max-width: 34ch;
}
@media (min-width: 768px) {
	.lead { max-width: 40ch; }
}

.prose { max-width: 62ch; }
.prose p + p { margin-top: 1em; }
.prose--large { font-size: var(--fs-lead); line-height: 1.45; }

.label {
	font-size: var(--fs-small);
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

.note {
	font-size: var(--fs-small);
	color: var(--c-ink-2);
}

.num, .score, .chart__score, .tip__n, .step__n, .tile__n, .phase__n { font-variant-numeric: tabular-nums; }

mark.todo {
	background: #FFE600;
	color: #0B0B0B;
	padding: 0 0.25em;
	font-weight: 600;
}

/* Layout ------------------------------------------------------------------ */

.wrap {
	width: 100%;
	max-width: var(--maxw);
	margin-inline: auto;
	padding-inline: var(--gutter);
}

.actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 16px 28px;
	margin-top: 32px;
}

/* Logo (wordmark) --- */

.logo {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	color: var(--c-ink);
	text-decoration: none;
	position: relative;
	z-index: 2;
}
.logo__svg {
	display: block;
	height: 28px;
	width: auto;
	aspect-ratio: 7805 / 4381;
	flex: none;
}
.logo__tagline {
	display: none;
	max-width: 15ch;
	font-size: 0.75rem;
	line-height: 1.25;
	color: var(--c-ink-2);
	letter-spacing: 0.01em;
}
@media (min-width: 640px) {
	.logo__tagline { display: block; max-width: none; }
}
@media (min-width: 768px) {
	.logo__svg { height: 34px; }
}
/* On black sections the logo follows the text color (white). */
.section--invert .logo, .site-footer .logo { color: #fff; }

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

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	min-height: 56px;
	padding: 0 28px;
	border: 0;
	border-radius: var(--radius);
	background: var(--c-ink);
	color: #fff;
	font-weight: 600;
	font-size: 1.0625rem;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color .2s var(--ease), color .2s var(--ease);
}
.btn .arrow { flex: none; transition: transform .25s var(--ease); }
.btn:hover, .btn:focus-visible { background: var(--c-accent); color: var(--c-accent-ink); }
.btn:hover .arrow, .btn:focus-visible .arrow { transform: translateX(4px); }
.btn[disabled] { opacity: .6; cursor: progress; }
.btn--small { min-height: 44px; padding: 0 18px; font-size: 1rem; }

.link-arrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 0;
	border: 0;
	background: none;
	font-weight: 600;
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.25em;
}
.link-arrow .arrow { transition: transform .25s var(--ease); }
.link-arrow:hover .arrow, .link-arrow:focus-visible .arrow { transform: translateX(4px); }

/* Inverted context: black background, white text. */
.section--invert .btn, .on-ink .btn { background: #fff; color: var(--c-ink); }
.section--invert .btn:hover, .section--invert .btn:focus-visible { background: var(--c-accent); color: var(--c-accent-ink); }
.section--invert .form-card .btn { background: var(--c-ink); color: #fff; }
.section--invert .form-card .btn:hover, .section--invert .form-card .btn:focus-visible { background: var(--c-accent); color: var(--c-accent-ink); }

/* Form controls ----------------------------------------------------------- */

.form { display: grid; gap: 24px; }

.field { display: grid; gap: 4px; }
.field label, .chips legend {
	font-size: var(--fs-small);
	font-weight: 600;
}
.field__hint { font-weight: 400; color: var(--c-ink-2); }
.field input, .field textarea {
	width: 100%;
	min-height: 56px;
	padding: 12px 0;
	border: 0;
	border-bottom: 1px solid var(--c-ink);
	border-radius: 0;
	background: transparent;
	font-size: var(--fs-body);
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus-visible, .field textarea:focus-visible {
	outline: none;
	border-bottom: 2px solid var(--c-focus);
	box-shadow: 0 1px 0 var(--c-focus);
}
.field.has-error input, .field.has-error textarea { border-bottom-width: 2px; }

.field__error, .form__error {
	position: relative;
	padding-left: 14px;
	font-size: var(--fs-small);
	font-weight: 600;
	color: var(--c-ink);
}
.field__error::before, .form__error::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.2em;
	bottom: 0.2em;
	width: 4px;
	background: var(--c-accent);
}

.chips { margin: 0; padding: 0; border: 0; min-width: 0; }
.chips legend { padding: 0; margin-bottom: 10px; }
.chips__list { display: flex; flex-wrap: wrap; gap: 8px; }
/* Days: 5 equal columns in one row. Slots: 2×2, full width. Mode: 2 columns. */
.chips--days .chips__list { display: grid; grid-template-columns: repeat(5, 1fr); }
.chips--slots .chips__list, .chips--mode .chips__list { display: grid; grid-template-columns: repeat(2, 1fr); }
.chips--days .chip span, .chips--slots .chip span, .chips--mode .chip span { width: 100%; justify-content: center; padding: 0 8px; }
.chip { position: relative; }
.chip input {
	position: absolute;
	inset: 0;
	opacity: 0;
	margin: 0;
	cursor: pointer;
}
.chip span {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0 16px;
	border: 1px solid var(--c-ink);
	border-radius: var(--radius);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	transition: background-color .15s var(--ease), color .15s var(--ease);
}
.chip input:checked + span { background: var(--c-ink); color: #fff; }
.chip input:focus-visible + span { outline: 3px solid var(--c-focus); outline-offset: 2px; }
.chip:hover span { border-color: var(--c-accent); }

/* Checkbox and radio drawn by the theme (iOS ignores native sizes): 22px box centered
   on the first 24px line of the label (1rem × 1.5). */
.checkbox { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.checkbox input {
	-webkit-appearance: none;
	appearance: none;
	flex: none;
	width: 22px;
	height: 22px;
	margin: 1px 0 0;
	border: 1.5px solid var(--c-ink);
	border-radius: var(--radius);
	background: #fff;
	cursor: pointer;
}
.checkbox input[type="checkbox"]:checked {
	background: var(--c-ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5 6.5 12 13 4.5' fill='none' stroke='%23fff' stroke-width='2.2'/%3E%3C/svg%3E") center / 15px no-repeat;
}
/* The consent checkbox sits inside .field: undo the text-input rules (56px min-height, bottom border). */
.field .checkbox input { min-height: 0; padding: 0; border: 1.5px solid var(--c-ink); }
.field .checkbox input:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; box-shadow: none; }
.checkbox input[type="radio"] { border-radius: 50%; }
.checkbox input[type="radio"]:checked { background: var(--c-ink); box-shadow: inset 0 0 0 4.5px #fff; }
.checkbox span { font-size: 1rem; line-height: 1.5; }

.choice { display: grid; gap: 12px; margin: 0; padding: 0; border: 0; }

.privacy-short { font-size: 0.8125rem; color: var(--c-ink-2); max-width: 62ch; }

/* Honeypot: off-screen, not display:none (some bots skip hidden fields). */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Block illustration tones ----------------------------------------------- */

.t-ink { fill: var(--c-ink); }
.t-acc { fill: var(--c-accent); }
.t-out { fill: #fff; stroke: var(--c-line); stroke-width: 1.5; stroke-linejoin: round; }
.t-ink, .t-acc { stroke: #fff; stroke-width: 1; stroke-linejoin: round; }

/* Utilities --------------------------------------------------------------- */

/* .screen-reader-text is WordPress's class (used by plugins such as Complianz); core CSS isn't loaded. */
.sr-only, .screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	padding: 0; margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link {
	position: absolute;
	left: 8px;
	top: -100px;
	z-index: 100;
	padding: 12px 16px;
	background: var(--c-ink);
	color: #fff;
}
.skip-link:focus { top: 8px; }

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		transition-duration: 0s !important;
		animation-duration: 0s !important;
		scroll-behavior: auto !important;
	}
}
