/**
 * Free State Fly Fishers — layout details.
 *
 * Only what block settings and theme.json genuinely cannot express: the
 * eyebrow treatment, the fact chips overlapping the hero and their icons,
 * the card borders and link lists, the event agenda rows, and the responsive
 * collapse of those. Everything to do with colour, type scale and spacing is
 * a token in theme.json — do not hard-code values here.
 *
 * Two conventions worth knowing before editing:
 *
 *   - Where a rule carries !important it is answering core's own preset
 *     classes (.has-*-background-color and friends), which ship !important.
 *     It is not there to win an argument with another rule in this file.
 *   - Translucent shades are derived from a palette token with color-mix()
 *     rather than written as a new literal colour, so re-toning the palette
 *     in theme.json re-tones the hairlines with it.
 *
 * @package fsff
 */

/* -------------------------------------------------------------------------
 * Shared helpers
 * ---------------------------------------------------------------------- */

/* Small tracked capitals used for eyebrows ("Coming up", "Photos & stories"). */
.fsff-eyebrow {
	letter-spacing: 0.1em;
	text-transform: uppercase;
	font-weight: 700;
	line-height: 1.4;
}

/* Even rag on headings; no one-word last lines in running text. */
h1,
h2,
h3 {
	text-wrap: balance;
}

p {
	text-wrap: pretty;
}

/* Keyboard users must be able to see where they are (P7, §G). */
:where(a, button, input, select, textarea, [tabindex]):focus-visible {
	outline: 2px solid var(--wp--preset--color--primary);
	outline-offset: 2px;
}

/*
 * Cards — pillars, archive links, events and stories all share one shape:
 * white, a warm hairline, a small radius. A filled card (.is-dark, or any
 * card an editor gives a background colour) drops the hairline.
 */
.fsff-card {
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--radius--card);
	padding: 1.75rem;
}

.fsff-card.is-dark {
	border-color: transparent;
}

/* -------------------------------------------------------------------------
 * Header
 * ---------------------------------------------------------------------- */

.fsff-header {
	border-bottom: 1px solid var(--wp--preset--color--border);
}

.fsff-header .wp-block-site-tagline {
	margin: 0;
}

/* The default club mark (functions.php) until a logo is uploaded. */
.fsff-mark {
	display: flex;
	color: var(--wp--preset--color--primary);
	line-height: 0;
}

/* The nav must be usable by tap and keyboard, not hover alone (P7). */
.fsff-header .wp-block-navigation__submenu-container {
	border-color: var(--wp--preset--color--border);
}

/*
 * Touch ergonomics for the mobile menu (P7, P8).
 *
 * WordPress ships the open/close toggles at 24px, which clears the WCAG 2.2
 * minimum but is mean to a membership that skews older and reads outdoors.
 * The icon keeps its drawn size; only the hit area grows.
 */
.wp-block-navigation__responsive-container-open,
.wp-block-navigation__responsive-container-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
}

/* Give the open overlay room to breathe and full-width rows to tap. */
.wp-block-navigation__responsive-container.is-menu-open {
	padding-top: 5rem;
	padding-inline: var(--wp--preset--spacing--40);
}

.wp-block-navigation__responsive-container.is-menu-open
	.wp-block-navigation__responsive-container-content {
	inline-size: 100%;
}

.wp-block-navigation__responsive-container.is-menu-open
	.wp-block-navigation__container {
	align-items: stretch;
	gap: 0;
	inline-size: 100%;
}

.wp-block-navigation__responsive-container.is-menu-open
	.wp-block-navigation__responsive-container-content
	.wp-block-navigation-item {
	inline-size: 100%;
	align-items: stretch;
	border-bottom: 1px solid var(--wp--preset--color--border);
}

/*
 * Core sets padding:0 on overlay links with four classes of specificity, so
 * this selector has to match it class for class to win the cascade.
 */
.wp-block-navigation__responsive-container.is-menu-open
	.wp-block-navigation__responsive-container-content
	.wp-block-navigation-item__content {
	display: block;
	inline-size: 100%;
	padding-block: 0.9rem;
	font-size: var(--wp--preset--font-size--medium);
	text-align: start;
}

/* -------------------------------------------------------------------------
 * Hero — a rounded photograph card, words at top left.
 * ---------------------------------------------------------------------- */

.fsff-hero {
	/* The radius is here rather than in the block's border setting: a CSS
	   custom property in a block attribute does not survive wp_insert_post(),
	   which provision.php uses, and the block then fails validation. */
	border-radius: var(--wp--custom--radius--band);
	overflow: hidden;
	/* What the photograph fades into when its strength is lowered. */
	background-color: var(--wp--preset--color--night);
}

/*
 * The photograph's strength, set at Pages → Home Page Photos and printed as
 * --fsff-hero-image-opacity by inc/home-photo.php. It fades into night pine,
 * the scrim's own colour, never into the cream page, so lowering it can only
 * raise the contrast of the white words (§G).
 */
.fsff-hero > .wp-block-cover__image-background {
	opacity: var(--fsff-hero-image-opacity, 1);
}

/*
 * The scrim is the `hero-scrim` gradient token, which already carries its own
 * alpha at every stop. Core's dim classes would multiply that by a second
 * opacity, so it is pinned here instead.
 */
.fsff-hero > .wp-block-cover__background {
	opacity: 1;
}

.fsff-hero > .wp-block-cover__inner-container {
	inline-size: 100%;
}

.fsff-hero .fsff-hero__copy {
	max-inline-size: 38.75rem;
}

/* The outline button is a hairline of white, not a solid bar. */
.fsff-hero .is-style-outline .wp-block-button__link {
	border: 1.5px solid color-mix(in srgb, var(--wp--preset--color--surface) 70%, transparent);
}

.fsff-hero .is-style-outline .wp-block-button__link:hover {
	background-color: color-mix(in srgb, var(--wp--preset--color--surface) 12%, transparent);
}

/* -------------------------------------------------------------------------
 * Fact chips — overlap the bottom of the hero (§B: meeting time, place and
 * dues inside the first screen). See patterns/home-facts-band.php.
 * ---------------------------------------------------------------------- */

.fsff-facts {
	position: relative;
	z-index: 2;
	/* Half the chip's height sits on the photograph. */
	margin-block-start: -2.125rem !important;
}

.fsff-fact {
	display: grid;
	grid-template-columns: 1.625rem 1fr;
	column-gap: 0.875rem;
	align-content: center;
	padding: 1.125rem 1.5rem;
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--radius--card);
	box-shadow: var(--wp--preset--shadow--lift);
}

.fsff-fact > * {
	grid-column: 2;
	margin: 0 !important;
}

/*
 * The icon is a mask filled with the primary token, so it recolours with the
 * palette. One per chip, keyed off its fsff-fact--* class.
 */
.fsff-fact::before {
	content: "";
	grid-column: 1;
	grid-row: 1 / span 2;
	align-self: center;
	inline-size: 1.625rem;
	block-size: 1.625rem;
	background-color: var(--wp--preset--color--primary);
	-webkit-mask: var(--fsff-icon) center / contain no-repeat;
	mask: var(--fsff-icon) center / contain no-repeat;
}

.fsff-fact--meeting {
	--fsff-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E");
}

.fsff-fact--place {
	--fsff-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpath d='M12 21s-7-5.4-7-11a7 7 0 0 1 14 0c0 5.6-7 11-7 11z'/%3E%3Ccircle cx='12' cy='10' r='2.5'/%3E%3C/svg%3E");
}

/* The dollar sign's S starts top right, as a written S does (it was drawn mirrored, B6). */
.fsff-fact--dues {
	--fsff-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v10M14.5 9.5c0-1-1-1.8-2.5-1.8s-2.5.8-2.5 1.8 1 1.6 2.5 1.9 2.5.9 2.5 1.9-1 1.8-2.5 1.8-2.5-.8-2.5-1.8'/%3E%3C/svg%3E");
}

.fsff-fact__figure {
	font-weight: 700;
	line-height: 1.35;
}

.fsff-fact__figure a {
	color: inherit;
}

/*
 * A pillar card's heading links to its section (B7). It keeps the heading's
 * colour, with a green underline (mint on the dark card) so it still reads as
 * a link on touch screens, where there is no hover to give it away.
 */
.fsff-card .wp-block-heading a {
	color: inherit;
	text-decoration-line: underline;
	text-decoration-color: var(--wp--preset--color--primary);
	text-decoration-thickness: 0.12em;
	text-underline-offset: 0.18em;
}

.fsff-card.is-dark .wp-block-heading a {
	text-decoration-color: var(--wp--preset--color--mint);
}

.fsff-card .wp-block-heading a:hover,
.fsff-card .wp-block-heading a:focus-visible {
	text-decoration-color: currentColor;
}

/* -------------------------------------------------------------------------
 * Pillar cards — three links each, divided by a mint rule.
 * ---------------------------------------------------------------------- */

.fsff-card-links {
	list-style: none;
	margin: var(--wp--preset--spacing--20) 0 0;
	padding: 0;
	display: flex;
	flex-direction: column;
}

.fsff-card-links li {
	border-bottom: 1.5px solid var(--wp--preset--color--mint);
}

.fsff-card-links li:last-child {
	border-bottom: 0;
}

/* The whole row is the tap target, not just the words (P7). */
.fsff-card-links a {
	display: block;
	padding-block: 0.5rem;
	font-size: var(--wp--preset--font-size--small);
	font-weight: 700;
}

.fsff-card.is-dark .fsff-card-links li {
	border-bottom-color: color-mix(in srgb, var(--wp--preset--color--surface) 20%, transparent);
}

.fsff-card.is-dark .fsff-card-links li:last-child {
	border-bottom: 0;
}

.fsff-card.is-dark a {
	color: var(--wp--preset--color--surface);
}

/* -------------------------------------------------------------------------
 * "Link list" — the List block style the pillar landing pages use (All About
 * FSFF, Club Events, All About Fly Fishing). The card link rows above, set
 * larger for a page of their own. Registered in functions.php.
 * ---------------------------------------------------------------------- */

.wp-block-list.is-style-fsff-links {
	list-style: none;
	margin-inline: 0;
	padding: 0;
	border-top: 1.5px solid var(--wp--preset--color--mint);
}

.wp-block-list.is-style-fsff-links li {
	margin: 0;
	border-bottom: 1.5px solid var(--wp--preset--color--mint);
}

/* The whole row is the tap target, not just the words (P7). */
.wp-block-list.is-style-fsff-links a {
	display: block;
	padding-block: 0.875rem;
	font-size: var(--wp--preset--font-size--large);
	font-weight: 700;
	text-decoration: none;
}

.wp-block-list.is-style-fsff-links a:hover,
.wp-block-list.is-style-fsff-links a:focus-visible {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

/*
 * Club Events (templates/archive-events.html): the heading above the calendar
 * and the links below it sit on the calendar's own grid, so their left edge
 * lines up with the calendar's at every width. The variables are the plugin's
 * (--tec-grid-*, defined on :root); the fallbacks are its current values.
 */
.fsff-events__intro,
.fsff-events__more {
	box-sizing: border-box;
	width: 100%;
	max-width: var(--tec-grid-width, 1176px);
	margin-inline: auto;
	padding-inline: var(--tec-grid-gutter-page-small, 19.5px);
}

@media (min-width: 768px) {
	.fsff-events__intro,
	.fsff-events__more {
		padding-inline: var(--tec-grid-gutter-page, 42px);
	}
}

/*
 * On a phone the plugin's list rows carry 21px gutters inside its 19.5px page
 * margin, so every event row pokes 1.5px past the screen edge and the page
 * wobbles sideways (QA of 22 Oct 2026, A6). Nothing visible sits in that
 * sliver, so it is trimmed rather than the plugin's grid restyled. clip, not
 * hidden: it makes no scroll box, so the date picker and view menu still drop
 * down.
 */
.tribe-events-l-container {
	overflow-x: clip;
}

/*
 * The plugin pads its calendar as if it had the page to itself: 160px under
 * the Subscribe button and 64px over the search bar. Here the Club Events
 * links follow straight after, and the gap made the page look finished (Rich
 * Batiuk, 22 Oct 2026, B1). Single events carried the same kind of gap above
 * the footer. Doubled classes outrank the plugin's own rules.
 */
.fsff-events .tribe-common.tribe-events .tribe-events-l-container {
	padding-block: var(--wp--preset--spacing--30) var(--wp--preset--spacing--30);
}

.fsff-events .tribe-events-single.tribe-blocks-editor {
	margin-block-end: 0;
}

/* Rich's sentence to the left of "Subscribe to calendar"; it stacks above the button on a phone (B36). */
.fsff-subscribe {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: var(--wp--preset--spacing--20) var(--wp--preset--spacing--40);
}

.fsff-subscribe__text {
	flex: 1 1 18rem;
	max-inline-size: 36rem;
	margin: 0;
	font-size: var(--wp--preset--font-size--small);
}

.fsff-subscribe .tribe-events-c-subscribe-dropdown__container {
	flex: 0 0 auto;
}

/* -------------------------------------------------------------------------
 * Coming up — the agenda from design Option 9: date | title | where & when,
 * one row per event between hairlines.
 * ---------------------------------------------------------------------- */

.fsff-agenda .wp-block-post-template {
	margin: 0;
	padding: 0;
	list-style: none;
}

.fsff-agenda__row {
	display: grid;
	/* Date | title, with where-and-when under the title. Keeping the meta out
	   of a third column is what stops long titles being squeezed into a
	   narrow middle column at tablet widths. */
	grid-template-columns: 7.5rem minmax(0, 1fr);
	align-items: baseline;
	column-gap: var(--wp--preset--spacing--40);
	row-gap: 0.25rem;
	padding-block: 1.25rem;
	border-bottom: 1px solid var(--wp--preset--color--border);
}

/* The rows are grid cells; flow spacing between them would misalign them. */
.fsff-agenda__row > * {
	margin: 0 !important;
}

.fsff-agenda > .wp-block-post-template > li:last-child .fsff-agenda__row {
	border-bottom: 0;
}

.fsff-agenda__date {
	font-size: var(--wp--preset--font-size--small);
	font-weight: 700;
}

/* A card-heading step, below the section headings — never above them. */
.fsff-agenda__title {
	font-size: var(--wp--preset--font-size--x-large);
	font-weight: 700;
	line-height: 1.3;
}

/*
 * Core makes a linked post title inline-block, whose baseline is its LAST
 * line; the date then sank to the bottom of a wrapped title. Inline puts the
 * baseline back on the first line.
 */
.fsff-agenda__title a {
	display: inline;
}

/* Keep long event titles to a readable line length on wide screens. */
.fsff-agenda__title,
.fsff-agenda__meta {
	max-inline-size: 46rem;
}

.fsff-agenda__title a,
.fsff-story .wp-block-post-title a {
	color: var(--wp--preset--color--contrast);
}

.fsff-agenda__title a:hover,
.fsff-story .wp-block-post-title a:hover {
	color: var(--wp--preset--color--primary);
}

.fsff-agenda__meta {
	grid-column: 2;
}

.fsff-agenda__meta:empty {
	display: none;
}

.fsff-agenda__empty {
	padding-block: var(--wp--preset--spacing--40);
	border-block: 1px solid var(--wp--preset--color--border);
}

/* -------------------------------------------------------------------------
 * Photos & stories — one featured card with its photograph, two beside it.
 * ---------------------------------------------------------------------- */

.fsff-stories .wp-block-post-template {
	margin: 0;
	padding: 0;
	list-style: none;
}

.fsff-story.is-featured {
	padding: 0;
	overflow: hidden;
}

.fsff-story.is-featured .fsff-story__image {
	margin: 0;
}

.fsff-story.is-featured .fsff-story__image img {
	display: block;
}

.fsff-story.is-featured .fsff-story__body {
	padding: 1.5rem 1.75rem 1.75rem;
}

.fsff-story.is-featured .wp-block-post-excerpt {
	max-inline-size: 38rem;
}

.fsff-stories--more .fsff-story {
	padding: 1.375rem 1.5rem;
}

.fsff-story .wp-block-post-excerpt__excerpt {
	margin: 0;
}

/* The lone "Browse newsletters"-style link at the foot of a card: a real tap target. */
.fsff-card > p:last-child > a:only-child {
	display: inline-block;
	padding-block: 0.5rem;
}

/* -------------------------------------------------------------------------
 * Page numbers under the story, search and category listings.
 * ---------------------------------------------------------------------- */

/*
 * Core draws each page number as a bare digit: a 9px-wide target, 13px from
 * the next, under the 24px WCAG 2.2 minimum (2.5.8) and hard to hit with a
 * thumb. Each becomes a 44px square, the size of the menu buttons (P7).
 */
.wp-block-query-pagination-numbers .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-inline-size: 2.75rem;
	min-block-size: 2.75rem;
}

/*
 * A page's featured image, between its title and its words (Frank Bowne,
 * Nov 2026). Core stretches the image to fill the column, so a 300px logo
 * set as a featured image came out blurred at 740px. Each image now shows at
 * its own size, centred, never wider than the column. The same applies to an
 * event's featured image, which the plugin shows at full size.
 */
.fsff-page-image img,
.fsff-events .tribe-events-event-image img {
	display: block;
	inline-size: auto;
	max-inline-size: 100%;
	block-size: auto;
	margin-inline: auto;
}

/* -------------------------------------------------------------------------
 * The Events Calendar — its calendar and event pages in the club's colours.
 * ---------------------------------------------------------------------- */

/*
 * The plugin colours its links and buttons through its own custom
 * properties, in a bright blue (#334aff) and Helvetica. Those are pointed at
 * the palette here, on body rather than :root, because the plugin's own
 * :root declarations print after this file and would win. Each property is
 * set outright, even those the plugin derives from another (link accent
 * from accent primary): a var() inside a custom property is resolved where
 * it is declared, on :root, so re-pointing the source alone would not reach
 * them.
 *
 * Its text colours are left alone. The month calendar fades past events to
 * about 60%, and only the plugin's own blue-black stays above 4.5:1 through
 * that; the palette's green-black fell to 3.75:1 (§G).
 */
body {
	--tec-font-family-sans-serif: var(--wp--preset--font-family--text);
	--tec-color-accent-primary: var(--wp--preset--color--primary);
	--tec-color-accent-primary-hover: var(--wp--preset--color--primary-dark);
	--tec-color-accent-primary-active: var(--wp--preset--color--primary-dark);
	--tec-color-accent-primary-background: color-mix(in srgb, var(--wp--preset--color--primary) 7%, transparent);
	--tec-color-accent-primary-background-datepicker: color-mix(in srgb, var(--wp--preset--color--primary) 7%, transparent);
	--tec-color-background-primary-multiday: color-mix(in srgb, var(--wp--preset--color--primary) 24%, transparent);
	--tec-color-background-primary-multiday-hover: color-mix(in srgb, var(--wp--preset--color--primary) 34%, transparent);
	--tec-color-link-accent: var(--wp--preset--color--primary);
	--tec-color-link-accent-hover: var(--wp--preset--color--primary-dark);
	--tec-color-button-primary: var(--wp--preset--color--primary);
	--tec-color-button-primary-hover: var(--wp--preset--color--primary-dark);
	--tec-color-button-primary-active: var(--wp--preset--color--primary-dark);
	--tec-color-button-primary-background: color-mix(in srgb, var(--wp--preset--color--primary) 7%, transparent);
	--tec-color-background-events-bar-submit-button: var(--wp--preset--color--primary);
	--tec-color-background-events-bar-submit-button-hover: var(--wp--preset--color--primary-dark);
	--tec-color-background-events-bar-submit-button-active: var(--wp--preset--color--primary-dark);
	--tec-color-icon-focus: var(--wp--preset--color--primary);
	--tec-color-event-icon-hover: var(--wp--preset--color--primary);
}

/*
 * On a phone the plugin turns an event page's "« previous" and "next »"
 * links into grey boxes of white text, a hard-coded #666 and not a property
 * the block above can reach. They stay links, as on a computer.
 */
.tribe-events-sub-nav li a,
.tribe-events-sub-nav li a:visited {
	background: none;
	color: var(--wp--preset--color--primary);
}

.tribe-events-sub-nav li a:hover {
	color: var(--wp--preset--color--primary-dark);
}

/*
 * On a phone the month calendar marks the chosen day (today, at first) with
 * an accent-coloured tile and white type, but the day number carries its own
 * dark colour, which wins: 2.99:1 on the plugin's blue, 2.21:1 on the green.
 * It takes the tile's white instead (§G).
 */
.tribe-events .tribe-events-calendar-month__day-cell--selected .tribe-events-calendar-month__day-date-daynum {
	color: inherit;
}

/* -------------------------------------------------------------------------
 * Footer
 * ---------------------------------------------------------------------- */

.fsff-footer p {
	margin: 0;
}

/*
 * When a page ends in a full-width coloured band (the home page's club
 * knowledge band), the footer's top margin would leave a strip of cream
 * between two dark bands. Close it; every other page keeps the gap.
 */
body:has(.wp-block-post-content > .alignfull.has-background:last-child) .fsff-footer,
body:has(.wp-block-post-content > .alignfull.has-background:last-child) footer.wp-block-template-part {
	margin-block-start: 0 !important;
}

.fsff-footer a {
	display: inline-block;
	padding-block: 0.375rem;
	color: var(--wp--preset--color--inverse-muted);
}

.fsff-footer a:hover {
	color: var(--wp--preset--color--surface);
}

/* -------------------------------------------------------------------------
 * Responsive — no horizontal scroll at any width (§G).
 * ---------------------------------------------------------------------- */

/*
 * Content carried over from the old site brings fixed widths the classic
 * editor wrote into it: a captioned image saved as <figure style="width:
 * 1024px">, the clubhouse map as an iframe of width="600", a video player
 * sized to 1920px, gallery photographs inserted at 1024px or even their full
 * 4928px. On a phone any one of them pushes the whole page sideways, so they
 * are capped at their column, and a photograph keeps its proportions as it
 * narrows.
 */
.wp-caption,
.wp-video,
iframe,
embed,
object,
video,
img {
	max-inline-size: 100%;
}

img {
	block-size: auto;
}

/*
 * Core's constrained layout caps each of its direct children at the content
 * width (740px) with a class selector, which outranks the element selectors
 * above. The Google Calendar and the video player sit directly in their
 * page's content, so a phone got the 740px cap, not its 342px column. min()
 * keeps both.
 */
.is-layout-constrained > :is(.wp-caption, .wp-video, iframe, embed, object, video, img) {
	max-inline-size: min(100%, var(--wp--style--global--content-size));
}

/*
 * A table from the old site that still cannot fit (the library's book list
 * needs 507px of a 342px phone column) scrolls inside the box
 * fsff_scroll_wide_tables() puts round it, as a Table block scrolls inside
 * its figure, rather than taking the whole page sideways. The box is only as
 * wide as its table, so a table the page centred before is centred still.
 */
.fsff-table-scroll {
	inline-size: fit-content;
	max-inline-size: 100%;
	overflow-x: auto;
}

/*
 * A pasted link — a Google Photos album, an article address — is one long
 * word, and would widen the page rather than wrap. break-word only breaks a
 * word that cannot otherwise fit, so ordinary text is untouched.
 */
body {
	overflow-wrap: break-word;
}

/*
 * The Events Calendar's venue box on a single event is width: 100% plus a
 * border and padding, sized content-box, so it ran 26px wider than its column
 * and the page scrolled sideways on a phone.
 */
.tribe-block__venue {
	box-sizing: border-box;
}

/*
 * Up to 1100px a third of the row is too narrow for a chip (the figures wrap
 * and each chip grows to ~175px), so the three stack into one compact
 * bordered list, still overlapping the hero's bottom edge above 781px.
 */
@media (max-width: 1100px) {
	.fsff-facts .wp-block-columns {
		flex-wrap: wrap !important;
	}

	.fsff-facts .wp-block-columns > .wp-block-column {
		flex-basis: 100% !important;
	}

	/* Stacked, the chips become one bordered list rather than three cards. */
	.fsff-facts .wp-block-columns {
		gap: 0 !important;
	}

	.fsff-fact {
		grid-template-columns: 1.625rem 1fr;
		padding: 0.5rem 1rem;
		border-radius: 0;
		box-shadow: none;
	}

	.fsff-facts .wp-block-column + .wp-block-column {
		border-top: 0;
	}

	.fsff-facts .wp-block-column:first-child {
		border-radius: var(--wp--custom--radius--card) var(--wp--custom--radius--card) 0 0;
	}

	.fsff-facts .wp-block-column:last-child {
		border-radius: 0 0 var(--wp--custom--radius--card) var(--wp--custom--radius--card);
	}

	.fsff-fact p:not(.fsff-fact__figure) {
		line-height: 1.4;
	}

	/*
	 * Below 1100px the hero's words run most of the way across the card, into
	 * the part of the photograph the scrim leaves bright, and the lead and the
	 * mint eyebrow fell to 3.7:1 against sky and water (§G asks 4.5:1 over
	 * photos). This scrim's stops are lengths, not percentages: it stays dark
	 * as far as the words can reach (the copy is at most 38.75rem wide) and
	 * fades only beyond them, so a tablet still shows bright water at the right.
	 */
	.fsff-hero > .wp-block-cover__background {
		background: var(--wp--custom--hero--scrim-narrow) !important;
	}
}

/*
 * Tablet (782–1100px). Three columns of 18px copy are 19–24 characters wide
 * here, so the pillar, knowledge and story rows stack; and the header's three
 * links plus the Join button cannot share a row with the club name, so the
 * menu button takes over from 600px up to 1100px, as it does on a phone.
 */
@media (min-width: 782px) and (max-width: 1100px) {
	.wp-block-columns.fsff-stack-tablet {
		flex-wrap: wrap !important;
	}

	.wp-block-columns.fsff-stack-tablet > .wp-block-column {
		flex-basis: 100% !important;
	}
}

@media (min-width: 600px) and (max-width: 1100px) {
	.fsff-header .wp-block-navigation__responsive-container-open:not(.always-shown) {
		display: flex;
	}

	.fsff-header .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) {
		display: none;
	}

	.fsff-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
		display: flex;
	}
}

@media (max-width: 781px) {
	/*
	 * On a phone the chips stack under the photograph rather than on it: three
	 * stacked chips overlapping a short hero would cover most of the picture.
	 */
	.fsff-facts {
		margin-block-start: var(--wp--preset--spacing--30) !important;
		padding-inline: 0 !important;
	}

	/* Let the hero be as tall as its words, so the facts reach the first screen (§B). */
	.fsff-hero {
		min-height: 0 !important;
		margin-block-start: var(--wp--preset--spacing--30) !important;
		padding: var(--wp--preset--spacing--40) !important;
	}

	.fsff-card {
		padding: 1.375rem;
	}

	/* Date over title over where-and-when, still one event per rule. */
	.fsff-agenda__row {
		grid-template-columns: minmax(0, 1fr);
	}

	.fsff-agenda__meta {
		grid-column: 1;
	}
}

/*
 * Phone header on one row: the tagline goes, and on the home page so does the
 * header's Join button — the hero's "Become a Member" is directly beneath it.
 * Inner pages keep the button (the header wraps there instead), so the path
 * to membership is never more than a tap away (§B).
 */
@media (max-width: 600px) {
	.fsff-header .wp-block-site-tagline {
		display: none;
	}

	.home .fsff-header .wp-block-buttons {
		display: none;
	}

	/* The calendar is the next section down; one clear call to action is enough here. */
	.fsff-hero .wp-block-button.is-style-outline {
		display: none;
	}

	/*
	 * Wider screens get Frank Bowne's 1.5 times (B3). Here the logo grows by a
	 * third, from 36px to 48px: at 54px the club's name and the menu button no
	 * longer fit beside it on a 375px phone, and the header broke onto two rows.
	 */
	.fsff-header .wp-block-site-logo svg,
	.fsff-header .wp-block-site-logo img {
		inline-size: 3rem;
		block-size: auto;
	}

	/*
	 * An old table's width="565" gives way, so one that can fit a phone
	 * column does. Only on phones: from 600px up it already fits, and
	 * releasing its widths there only squeezed its columns.
	 */
	.fsff-table-scroll table {
		inline-size: auto;
		max-inline-size: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}
