/*
 * Resource Hub catalog CSS: list, cards, toolbar, landing, share page, 404,
 * Organizing 101 and the login page. Every size, colour, space and shadow comes
 * from tokens.css (docs/styleguide.md). Breakpoints are written as numbers,
 * mobile first: md 769px, lg 992px (xl 1200px is not needed here).
 */

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

body.resource-hub-layout {
	background-color: var(--color-page);
}

body.resource-hub-layout #page.site.grid-container {
	max-width: 100%;
}

body.resource-hub-layout .inside-header.grid-container {
	max-width: 100%;
	padding-left: var(--gutter);
	padding-right: var(--gutter);
}

body.resource-hub-layout .site-main {
	padding-left: var(--gutter);
	padding-right: var(--gutter);
}

body.resource-hub-layout.separate-containers .site-main {
	margin-left: 0;
	margin-right: 0;
}

/* Share page, 404 and Organizing 101 sit in the 1140px container. */
.hub-share,
.hub-not-found {
	max-width: var(--container);
	margin-left: auto;
	margin-right: auto;
}

.site-logo .header-image {
	display: block;
	height: 2.25rem;
	width: auto;
	max-width: min(100%, 16rem);
}

.inside-header .site-logo {
	display: flex;
	align-items: center;
	line-height: var(--leading-none);
}

.inside-header .site-logo a {
	display: inline-flex;
	align-items: center;
}

/* ---------------------------------------------------------- Page heading */

/* Textured band with a white box, on every hub page. */
.page-header.resource-archive-header {
	position: relative;
	width: 100vw;
	max-width: 100vw;
	margin: 0 calc(50% - 50vw);
	padding: var(--section-space) var(--gutter);
	background: var(--color-texture-fallback) var(--color-texture) center center / cover no-repeat;
}

.resource-archive-header__box {
	box-sizing: border-box;
	width: fit-content;
	max-width: min(var(--measure), 100%);
	margin: 0 auto;
	padding: var(--space-5) var(--card-pad);
	border-radius: var(--radius);
	background: var(--color-surface);
}

.resource-archive-header .page-title {
	margin-bottom: 0;
}

/* Landing intro under the title: the box grows to the text measure while it is showing. */
.resource-archive-header__box:has(.resource-archive-landing-intro:not([hidden])) {
	width: 100%;
	padding: var(--space-6) var(--card-pad);
}

.resource-archive-landing-intro {
	max-width: 65ch;
	margin: var(--space-4) auto 0;
	text-align: center;
	font-size: var(--text-body);
	line-height: var(--leading-description);
}

.resource-archive-landing-intro a {
	color: var(--color-text);
	text-decoration: underline;
}

.resource-archive-landing-intro a:hover {
	color: var(--color-link-hover);
}

.resource-archive-title {
	display: block;
	text-align: center;
	font-size: var(--text-display);
	line-height: var(--leading-display);
	/* Whole words wrap; very long words hyphenate instead of breaking mid-word. */
	overflow-wrap: break-word;
	hyphens: auto;
}

/* The share page and the 404 have long titles: one step down. */
.hub-share .resource-archive-title,
.hub-not-found .resource-archive-title {
	font-size: var(--text-h2);
	line-height: var(--leading-heading);
}

/* Topic description under the title on topic views and the share page. */
.resource-archive-topic-description {
	margin: var(--space-4) 0 0;
	font-size: var(--text-lead);
	line-height: var(--leading-text);
}

.resource-archive-topic-description a {
	color: var(--color-text);
	text-decoration: underline;
}

/* --------------------------------------------------------------- Toolbar */

.resource-filter-toolbar {
	margin: 0;
	background: var(--color-page);
}

.resource-filter-toolbar__search--mobile {
	display: block;
	flex: 1 1 auto;
	min-width: 0;
	max-width: 250px;
	order: 1;
}

.resource-filter-toolbar__bar {
	position: sticky;
	top: var(--hub-filter-sticky-top, 0);
	z-index: 90;
	margin-left: calc(-1 * var(--gutter));
	margin-right: calc(-1 * var(--gutter));
	padding: var(--space-5) var(--gutter);
	background: var(--color-page);
}

.resource-filter-toolbar__controls {
	container-type: inline-size; /* as wide as the card grid below; see the column cap on .resource-topic-head */
	display: grid;
	gap: var(--space-3);
	max-width: var(--container-wide);
	margin-left: auto;
	margin-right: auto;
}

.resource-filter-toolbar__main-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-3);
	width: 100%;
}

.resource-filter-toolbar__cluster-left {
	display: flex;
	flex: 1 1 auto;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-3);
	min-width: 0;
}

.resource-filter-toolbar__cluster-right {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
}

.resource-filter-toolbar__filters {
	display: flex;
	flex-wrap: wrap;
	flex: 1 1 100%;
	align-items: flex-end;
	gap: var(--space-3);
	order: 3;
}

.resource-filter-toolbar__search-wrap {
	position: relative;
	display: block;
	flex: 1 1 auto;
	min-width: 0;
}

.resource-filter-toolbar__search-row {
	display: flex;
	align-items: stretch;
	gap: var(--space-2);
}

/* Grid / List segmented control: the active icon is a quiet raised white chip on a light grey track, the other is muted. */
.view-switch {
	display: inline-flex;
	align-items: center;
	gap: var(--space-1);
	padding: var(--space-1);
	border-radius: var(--radius-control);
	background: var(--color-surface-muted);
	box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);
}

.view-switch .view-switch__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.5rem;
	height: 1.75rem;
	padding: 0;
	border: 0;
	border-radius: var(--radius-control);
	background: transparent;
	box-shadow: none;
	color: var(--color-text-muted);
	cursor: pointer;
}

.view-switch .view-switch__btn svg {
	display: block;
	width: var(--icon-sm);
	height: var(--icon-sm);
}

.view-switch .view-switch__btn:hover,
.view-switch .view-switch__btn:focus {
	background: transparent;
	color: var(--color-text);
}

.view-switch .view-switch__btn.is-active,
.view-switch .view-switch__btn.is-active:hover,
.view-switch .view-switch__btn.is-active:focus {
	background: var(--color-surface);
	box-shadow: var(--shadow-button);
	color: var(--color-text);
}

.view-switch .view-switch__btn:focus-visible {
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

/* Phones always show tiles, so the slider is not offered there. */
@media (max-width: 768px) {
	.view-switch {
		display: none;
	}
}

.resource-filter-toolbar__search-wrap::before {
	content: "";
	position: absolute;
	top: 50%;
	left: var(--space-3);
	width: 1.1rem;
	height: 1.1rem;
	transform: translateY(-50%);
	/* The stroke colour is inside the data URI, so it cannot use a token. */
	background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
	opacity: 0.7;
	pointer-events: none;
	transition: opacity 0.15s ease;
}

.resource-filter-toolbar__search-wrap:focus-within::before {
	opacity: 0;
}

.resource-filter-toolbar__search-wrap .resource-filter-toolbar__search-input[type="search"] {
	width: 100%;
	min-height: 2.75rem;
	padding-top: var(--space-2);
	padding-right: var(--space-3);
	padding-bottom: var(--space-2);
	padding-left: 2.85rem;
	border: 1px solid var(--color-border-control);
	border-radius: var(--radius-control);
	font: inherit;
	background: var(--color-surface);
	transition: padding-left 0.15s ease;
}

.resource-filter-toolbar__search-wrap:focus-within .resource-filter-toolbar__search-input[type="search"] {
	padding-left: var(--space-3);
}

.resource-filter-toolbar__search-suggestions {
	position: absolute;
	top: calc(100% + var(--space-1));
	left: 0;
	z-index: 120;
	width: 100%;
	margin: 0;
	padding: var(--space-1) 0;
	list-style: none;
	max-height: 14rem;
	overflow-y: auto;
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	background: var(--color-surface);
	box-shadow: var(--shadow-overlay);
}

.resource-filter-toolbar__search-suggestion {
	padding: var(--space-2) var(--space-3);
	font-size: var(--text-small);
	line-height: var(--leading-ui);
	color: var(--color-text);
	cursor: pointer;
}

.resource-filter-toolbar__search-suggestion-prefix {
	font-weight: var(--weight-semibold);
	margin-right: 0.35em;
}

.resource-filter-toolbar__search-suggestion-alt {
	color: var(--color-text-muted);
}

.resource-filter-toolbar__search-suggestion.is-active,
.resource-filter-toolbar__search-suggestion:hover {
	background: var(--color-surface-muted);
}

.resource-filter-toolbar__search-suggestion--empty {
	color: var(--color-text-muted);
	cursor: default;
}

.resource-filter-toolbar__search-suggestion--empty:hover {
	background: transparent;
}

.resource-filter-toolbar__field-label {
	display: block;
	margin-bottom: var(--space-1);
	font-family: var(--font-label);
	font-size: var(--text-label);
	font-weight: var(--weight-black);
	line-height: var(--leading-ui);
	letter-spacing: var(--tracking-label);
	text-transform: uppercase;
	color: var(--color-text-muted);
}

.resource-filter-toolbar__chip-group {
	display: flex;
	flex: 1 1 100%;
	align-items: center;
	align-self: flex-end;
	gap: var(--space-3);
	min-width: 0;
	min-height: 2.75rem;
}

.resource-filter-toolbar__clear {
	flex: 0 0 auto;
	padding: 0;
	font-family: var(--font-body);
	font-weight: var(--weight-medium);
	font-size: var(--text-body);
	line-height: var(--leading-ui);
	text-decoration: none;
	cursor: pointer;
}

.resource-filter-toolbar__clear:not([hidden]) {
	display: inline-flex;
	align-items: center;
	gap: var(--space-1);
}

.resource-filter-toolbar__clear-label {
	text-decoration: underline;
	text-underline-offset: 0.15em;
}

.resource-filter-toolbar__clear-icon {
	font-size: 1em;
	font-weight: var(--weight-regular);
	line-height: var(--leading-none);
	text-decoration: none;
}

.resource-filter-toolbar__chips[hidden] {
	display: none;
}

.resource-filter-toolbar__chips {
	display: flex;
	flex-wrap: wrap;
	flex: 0 1 auto;
	gap: var(--space-2);
	align-items: center;
	min-width: 0;
}

button.resource-filter-toolbar__chip,
.resource-filter-toolbar__chip {
	display: inline-flex;
	align-items: center;
	gap: var(--space-2);
	padding: var(--space-1) var(--space-2);
	border: 0;
	border-radius: var(--radius);
	background: var(--color-surface-muted);
	color: var(--color-text);
	font-family: var(--font-body);
	font-weight: var(--weight-regular);
	font-size: var(--text-small);
	text-transform: none;
	letter-spacing: normal;
	box-shadow: none;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

button.resource-filter-toolbar__chip:hover,
button.resource-filter-toolbar__chip:focus,
.resource-filter-toolbar__chip:hover,
.resource-filter-toolbar__chip:focus {
	background: var(--color-brand);
	color: var(--color-text);
	box-shadow: none;
}

.resource-filter-toolbar__chip-remove {
	font-size: 1em;
	font-weight: var(--weight-bold);
	line-height: var(--leading-none);
	color: inherit;
}

.resource-filter-empty {
	/* Same column as the toolbar title and the card grid. */
	max-width: var(--container-wide);
	margin: 0 auto var(--space-6);
	padding: 0;
	color: var(--color-text-muted);
}

/* ---------------------------------------------------------- Landing page */

.resource-landing {
	max-width: var(--container-wide);
	margin-left: auto;
	margin-right: auto;
	padding: var(--space-2) 0 var(--space-7);
}

/* Phone: on the topic tiles the toolbar's second row (empty filter chips and the grid/list toggle) has nothing to do and leaves a blank band under the search box. It comes back as soon as a search or filter replaces the tiles. */
body.hub-landing-active .resource-filter-toolbar__filters,
body.hub-landing-active .resource-filter-toolbar__cluster-right {
	display: none;
}

.resource-landing__overview {
	display: block;
}

/* From md the toolbar is hidden on the landing, so the tiles need their own space under the band. On phone the search box already separates them. */
@media (min-width: 769px) {
	.resource-landing__overview {
		padding-top: var(--space-6);
	}
}

/* About text: a footer for the landing. Full width, in line with the tile grid, no box. */
.resource-landing__about {
	margin: var(--space-7) 0 0;
	padding-top: var(--space-6);
	border-top: 1px solid var(--color-border);
	font-size: var(--text-body);
	line-height: var(--leading-body);
}

.resource-landing__about p {
	margin: 0;
}

.resource-landing__about a {
	color: var(--color-text);
	text-decoration: underline;
}

.resource-landing__topics {
	display: grid;
	gap: var(--space-4);
	grid-template-columns: 1fr;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Topic tile: textured image area with a cutout photo, then white text below (as the Take Action cards on domesticworkers.org). */
.resource-landing__topic {
	position: relative;
	display: flex;
	flex-direction: column;
	margin: 0;
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	background: var(--color-surface);
}

.resource-landing__topic-media {
	position: relative;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	aspect-ratio: 8 / 5;
	overflow: hidden;
	background: var(--color-texture-fallback) var(--color-texture) center center / cover no-repeat;
}

/* Cutout sits on the bottom edge, centred, as large as the area allows. */
.resource-landing__topic-image {
	display: block;
	width: auto;
	max-width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: 50% 100%;
}

.resource-landing__topic-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	align-items: flex-start;
	gap: var(--space-3);
	padding: var(--card-pad);
}

.resource-landing__topic-title {
	margin: 0;
	font-size: var(--text-h3);
	line-height: var(--leading-heading);
	overflow-wrap: break-word;
	hyphens: auto;
}

.resource-landing__topic-description {
	margin: 0;
	font-size: var(--text-body);
	line-height: var(--leading-description);
}

/* Resource count under the tile title: sentence case ("17 resources"), body text at the description's size. */
.resource-landing__topic-count {
	margin: 0;
	color: var(--color-text-muted);
	font-family: var(--font-body);
	font-size: var(--text-body); /* same token as .resource-landing__topic-description */
	font-weight: var(--weight-regular);
	line-height: var(--leading-ui);
	letter-spacing: normal;
	text-transform: none;
}

/* The count hugs the description; the gap to the button is at least the tile padding. */
.resource-landing__topic-body .resource-landing__topic-count {
	margin-bottom: calc(var(--card-pad) - var(--space-3));
}

/* The tile is not a link: this button is the only link in it, and the only part with a hover look
   (the large-button hover and focus styles). Pinned to the tile bottom so the buttons line up across
   a grid row. The extra class beats .hub-button's margin reset; the colour rule keeps the global
   link hover colour off the button text. */
.resource-landing__topic-body .resource-landing__topic-cta {
	align-self: stretch;
	margin-top: auto;
}

.resource-landing__topic-body .resource-landing__topic-cta:hover,
.resource-landing__topic-body .resource-landing__topic-cta:focus-visible {
	color: var(--color-text);
}

/* "Browse all resources": centred text-only button under the tiles. */
.resource-landing__browse-all {
	margin: var(--space-6) 0 0;
	text-align: center;
}

.resource-landing__browse-all .hub-button--text,
.resource-landing__browse-all .hub-button--text:hover,
.resource-landing__browse-all .hub-button--text:focus-visible {
	background: transparent;
}

/* ------------------------------------------------- NDWA large and text buttons */

/*
 * Recreates domesticworkers.org's .button.button-large and .button.button-text
 * (ndwa2020/styles/styles.css, measured 18 Nov 2026) with our tokens. NDWA draws the arrow
 * with two bordered pseudo-elements (a 17x4 bar and a rotated 15x15 corner); here it is one
 * drawn-from-scratch SVG used as a mask, so it takes the text colour. No NDWA file is used.
 * Large: Montserrat 800 uppercase, padding 15 65 15 35 (here 16 64 16 32), arrow 35px from the right.
 * Text-only: no fill, padding 10 25 10 0, arrow flush right, text goes 70% black on hover (here --color-link-hover).
 */
.hub-button {
	--hub-button-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 16'%3E%3Cpath d='M0 8h18M11 1.5L17.5 8 11 14.5' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E");
	position: relative;
	display: inline-block;
	box-sizing: border-box;
	min-height: 2.75rem;
	margin: 0;
	border: 0;
	border-radius: var(--radius);
	background: var(--color-brand);
	color: var(--color-text);
	font-family: var(--font-label);
	font-size: var(--text-body);
	font-weight: var(--weight-black);
	line-height: var(--leading-ui);
	letter-spacing: var(--tracking-label);
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.hub-button::after {
	content: "";
	position: absolute;
	top: 50%;
	width: calc(var(--space-4) + var(--space-1));
	height: var(--space-4);
	background: currentColor;
	-webkit-mask: var(--hub-button-arrow) center / contain no-repeat;
	mask: var(--hub-button-arrow) center / contain no-repeat;
	transform: translateY(-50%);
}

.hub-button--large {
	padding: var(--space-4) var(--space-8) var(--space-4) var(--space-6);
}

.hub-button--large::after {
	right: var(--space-6);
}

.hub-button--large:hover,
.hub-button--large:focus-visible {
	background: var(--color-brand-hover);
	box-shadow: var(--shadow-button);
}

.hub-button--text {
	padding: var(--space-3) var(--space-5) var(--space-3) 0;
	background: transparent;
}

.hub-button--text::after {
	right: 0;
}

.hub-button--text:hover,
.hub-button--text:focus-visible {
	background: transparent;
	box-shadow: none;
	color: var(--color-link-hover);
}

.hub-button:focus-visible {
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

/* ---------------------------------------------------------- Card list */

.resource-list {
	display: grid;
	gap: var(--space-5);
	grid-template-columns: 1fr;
	align-items: stretch;
	max-width: var(--container-wide);
	margin: 0 auto var(--space-7);
	background: var(--color-page);
}

.resource-card__list-row,
.hub-table-head {
	display: none;
}

.resource-card--folder {
	display: flex;
	flex-direction: column;
	height: 100%;
	padding: 0;
	border: 0;
	background: transparent;
}

.resource-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: var(--card-pad);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	background: var(--color-surface);
	position: relative;
	z-index: 1;
}

/* Title on the left, the type icon in the top-right corner of the same row. */
.resource-card__head {
	display: flex;
	align-items: flex-start;
	gap: var(--space-3);
}

.resource-card__head .entry-title {
	flex: 1 1 auto;
	min-width: 0;
}

/* Resource-type icon: generic outline, light grey (decorative, aria-hidden), 36px. */
.hub-type-icon {
	display: inline-flex;
	flex: 0 0 auto;
	color: var(--color-border-control);
}

.hub-type-icon svg {
	display: block;
	width: var(--hub-type-icon-size);
	height: var(--hub-type-icon-size);
}

.hub-type-icon {
	--hub-type-icon-size: 2.25rem;
}



.resource-card .entry-title {
	margin-top: 0;
	font-size: var(--text-lead); /* one step below the topic title (--text-h3) */
	line-height: var(--leading-heading);
	overflow-wrap: break-word;
	hyphens: auto;
}

.resource-card__meta {
	margin-top: var(--space-3);
}

.resource-card__meta.resource-terms {
	margin-bottom: 0;
}

.resource-card__more {
	margin: auto 0 0;
	padding-top: var(--space-4);
}

.resource-terms {
	display: flex;
	flex-direction: column;
	gap: var(--space-1);
	margin: var(--space-3) 0 var(--space-4);
	font-size: var(--text-small);
	line-height: var(--leading-text);
}

.resource-terms__label {
	font-weight: var(--weight-regular);
}

.resource-terms__topic {
	margin-right: var(--space-2);
}

.resource-terms__topic:last-child {
	margin-right: 0;
}

.resource-terms__group--tags {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--space-1);
}

.resource-terms__group--tags .resource-terms__label {
	flex: 0 0 auto;
}

.resource-terms__group--tags .resource-terms__values,
.resource-terms__group--tags .resource-tags {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--space-1);
}

.resource-tag {
	display: inline-block;
	padding: var(--space-1) var(--space-2);
	border: 0;
	border-radius: var(--radius-control);
	background: var(--color-surface-muted);
	color: var(--color-text-muted);
	font-size: var(--text-small);
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.resource-tag:hover,
.resource-tag:focus {
	background: var(--color-brand);
	color: var(--color-text);
}

/* ---------------------------------------------------------- List view table */
/* Tablet width and up only; phones always show tiles. */

@media (min-width: 769px) {
	.resource-list--list {
		--hub-table-columns: 2.25rem minmax(0, 1.25fr) minmax(0, 1fr) 8.375rem 8.375rem;

		display: block;
		border: 1px solid var(--color-border);
		background: var(--color-surface);
	}

	.resource-list--list .hub-table-head {
		display: grid;
		grid-template-columns: var(--hub-table-columns);
		gap: var(--space-4);
		padding: var(--space-3) var(--space-4);
		border-bottom: 1px solid var(--color-border);
		background: var(--color-surface-muted);
		color: var(--color-text-muted);
		font-size: var(--text-label);
		font-weight: var(--weight-bold);
		text-transform: uppercase;
		letter-spacing: var(--tracking-label);
	}

	.resource-list--list .hub-table-head[hidden] {
		display: none;
	}

	.hub-table-head__cell--languages {
		grid-column: 4 / 6;
	}

	.resource-list--list .resource-card--folder {
		display: block;
		height: auto;
	}

	.resource-list--list .resource-card__body {
		display: none;
	}

	.resource-list--list .resource-card__list-row {
		display: grid;
		grid-template-columns: var(--hub-table-columns);
		align-items: center;
		gap: var(--space-4);
		padding: var(--space-3) var(--space-4);
		border-bottom: 1px solid var(--color-border);
	}

	.resource-list--list .resource-card:last-child .resource-card__list-row {
		border-bottom: 0;
	}

	/* The cell sets the line box (an inline link's own line-height cannot shrink its parent's). */
	.hub-row__title {
		line-height: var(--leading-tight);
	}

	.hub-row__title a,
	.hub-row__title a:hover,
	.hub-row__title a:focus {
		font-weight: var(--weight-semibold);
		line-height: var(--leading-tight);
		overflow-wrap: anywhere;
		text-decoration: none;
	}

	.hub-row__title a:hover {
		color: var(--color-link-hover);
	}

	/* Underline only for keyboard focus. */
	.hub-row__title a:focus-visible {
		text-decoration: underline;
		outline: var(--focus-ring);
		outline-offset: var(--focus-offset);
	}
}

/* Terms, title copy icon and language menus: shared by the table row and the grid card. */
.hub-row__terms {
	display: flex;
	flex-direction: column;
	gap: var(--space-1);
	font-size: var(--text-small);
	line-height: var(--leading-text);
}

/* File types under the title: small and muted, like the topic description. */
.hub-row__types {
	margin-top: var(--space-1);
	color: var(--color-text-muted);
	font-family: var(--font-body);
	font-size: var(--text-small);
	font-weight: var(--weight-regular);
	line-height: var(--leading-text);
	text-indent: 0;
}

/* Topics: plain comma-separated text; links, but underlined only for keyboard focus. */
.hub-row__topic,
.hub-row__topic:hover,
.hub-row__topic:focus {
	text-decoration: none;
}

.hub-row__topic:hover {
	color: var(--color-link-hover);
}

.hub-row__topic:focus-visible {
	text-decoration: underline;
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

.hub-row__topic:not(:last-child)::after {
	content: ",";
	color: var(--color-text);
}

.hub-row__tags {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-1);
}

.hub-row__tags .resource-tag {
	padding: 0 var(--space-2);
	font-size: var(--text-label);
}

/* Copy link flows inline right after the title's last word. The last word and the
   icon's box share a no-wrap span, so the icon never wraps alone. The icon box is
   reserved as padding on the last word, then pulled back with a negative margin. */
.hub-row__title,
.resource-card .entry-title {
	--hub-copy-box: 1.5rem;
}

.hub-row__last {
	white-space: nowrap;
	padding-right: calc(var(--hub-copy-box) + var(--space-1));
}

/* The wrapper is zero-width, so it can never wrap to a line of its own; the button
   sits in the space reserved by the last word's padding. */
.hub-row__copy {
	position: relative;
	display: inline-block;
	width: 0;
	height: 0;
	vertical-align: middle;
	line-height: 0;
}

/* Icon only; 24px hit area that does not enlarge the line (negative vertical margin). */
.hub-row__copy .hub-row__copy-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	position: absolute;
	top: 50%;
	left: calc(-1 * var(--hub-copy-box));
	width: var(--hub-copy-box);
	height: var(--hub-copy-box);
	margin: 0;
	transform: translateY(-50%);
	padding: 0;
	border: 0;
	border-radius: var(--radius-control);
	background: transparent;
	box-shadow: none;
	color: var(--color-text-muted);
	cursor: pointer;
}

.hub-row__copy .hub-row__copy-btn:hover,
.hub-row__copy .hub-row__copy-btn:focus {
	background: var(--color-surface-muted);
	color: var(--color-text);
}

.hub-row__copy .hub-row__copy-btn:focus-visible {
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

.hub-row__copy-btn svg {
	width: 0.95em;
	height: 0.95em;
}

/* The fallback field floats under the button so the column stays narrow. */
.hub-row__copy .resource-buttons__fallback {
	position: absolute;
	top: 0.75rem;
	left: calc(-1 * var(--hub-copy-box));
	z-index: 6;
	padding: var(--space-1) var(--space-2);
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-overlay);
	white-space: nowrap;
}

/* "Copied!" sits right after the icon, out of flow, so the title never shifts. */
.hub-row__copy .resource-buttons__status {
	top: 50%;
	left: var(--space-1);
	transform: translateY(-50%);
}

/* Language menus. */
.hub-menu {
	position: relative;
}

/* Same size and look as the filter toolbar's search input: height, padding, font,
   1px control border and radius. The button fills its column. */
.hub-menu__button {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-2);
	box-sizing: border-box;
	width: 100%;
	min-height: 2.5rem; /* the header search input's height on desktop */
	padding: var(--space-2) var(--space-3);
	border: 1px solid var(--color-border-control);
	border-radius: var(--radius-control);
	background: var(--color-surface);
	font: inherit;
	line-height: var(--leading-ui);
	cursor: pointer;
	list-style: none;
}

.hub-menu__button::-webkit-details-marker {
	display: none;
}

.hub-menu__button::after {
	content: "";
	width: 0.5rem;
	height: 0.5rem;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: translateY(-25%) rotate(45deg);
}

.hub-menu[open] > .hub-menu__button::after {
	transform: translateY(25%) rotate(225deg);
}

.hub-menu__button:hover,
.hub-menu[open] > .hub-menu__button {
	background: var(--color-surface-muted);
	border-color: var(--color-text);
}

.hub-menu__button:focus-visible,
.hub-menu__item:focus-visible {
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

.hub-menu__panel {
	position: absolute;
	top: calc(100% + var(--space-1));
	left: 0;
	z-index: 5;
	min-width: 100%;
	width: max-content;
	max-width: 22rem;
	padding: 0;
	border: 1px solid var(--color-border-control);
	border-radius: var(--radius-control);
	background: var(--color-surface);
	box-shadow: var(--shadow-overlay);
}

.hub-menu__heading {
	margin: 0;
	padding: var(--space-2) var(--space-3) var(--space-1);
	color: var(--color-text-muted);
	font-size: var(--text-label);
	font-weight: var(--weight-bold);
}

.hub-menu__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.hub-menu__item {
	display: block;
	padding: var(--space-2) var(--space-3);
	font-size: var(--text-small);
	text-decoration: none;
}

/* The panel has no padding, so the hovered first and last options fill to its rounded border. */
.hub-menu__panel > .hub-menu__list:first-child > li:first-child > .hub-menu__item {
	border-top-left-radius: calc(var(--radius-control) - 1px);
	border-top-right-radius: calc(var(--radius-control) - 1px);
}

.hub-menu__panel > .hub-menu__list:last-child > li:last-child > .hub-menu__item {
	border-bottom-left-radius: calc(var(--radius-control) - 1px);
	border-bottom-right-radius: calc(var(--radius-control) - 1px);
}

.hub-menu__item:hover {
	background: var(--color-surface-muted);
	color: var(--color-text);
}

/* Grid card: the same terms and language menus as the table, the menus full width and
   stacked. The open card rises above its neighbours so a panel is not covered by the next
   card, and nothing on the card clips it. */
.resource-card__terms {
	margin-top: var(--space-3);
}

.resource-card__menus {
	display: flex;
	flex-direction: column;
	gap: var(--space-2);
}

.resource-card__menus .hub-menu__panel {
	right: 0;
	left: 0;
	width: auto;
	max-width: none;
}

.resource-card__body:has([data-hub-menu][open]) {
	z-index: 3;
}

/* Table only: a bilingual menu spans both language columns; the Spanish menu opens to the left. */
@media (min-width: 769px) {
	.hub-row__lang--both {
		grid-column: span 2;
	}

	.hub-row__lang:last-of-type .hub-menu__panel,
	.hub-row__lang--both .hub-menu__panel {
		left: auto;
		right: 0;
	}

	.hub-row__lang--both .hub-menu__panel {
		left: 0;
		right: auto;
	}
}

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

.resource-buttons {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2) var(--space-4);
}

.resource-buttons__group {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2);
}

.resource-buttons__lang {
	font-size: var(--text-small);
	font-weight: var(--weight-bold);
}

/*
 * One look for Read, PDF, Open in Google Docs and Copy link (the Copy link
 * <button> is excluded from the brand button rules in ndwa-brand.css).
 * Secondary by default: transparent with a black outline; Read is the primary.
 */
.resource-buttons__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-height: 2.75rem;
	padding: var(--space-3) var(--space-5);
	border: 2px solid var(--color-button-outline);
	border-radius: var(--radius);
	background: transparent;
	color: var(--color-text);
	font-family: var(--font-label);
	font-size: var(--text-label);
	font-weight: var(--weight-black);
	line-height: var(--leading-ui);
	letter-spacing: var(--tracking-label);
	text-decoration: none;
	text-transform: uppercase;
	cursor: pointer;
}

.resource-buttons__button--read {
	border-color: var(--color-brand);
	background: var(--color-brand);
}

.resource-buttons__button:hover,
.resource-buttons__button:focus {
	border-color: var(--color-brand);
	background: var(--color-brand);
	color: var(--color-text);
	text-decoration: none;
}

.resource-buttons__button--read:hover,
.resource-buttons__button--read:focus {
	border-color: var(--color-brand-hover);
	background: var(--color-brand-hover);
	box-shadow: var(--shadow-button);
}

.resource-buttons__note {
	font-size: var(--text-small);
	font-style: italic;
}

/* Copy link: the button, its status text and the fallback field. */
.resource-buttons__copy {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2);
}

/* "Copied!": plain bold pink text right after the button. No box, border, shadow or arrow.
   Out of flow (absolute), so showing it never moves anything. JS adds .is-visible for about
   1s, then removes it and the opacity fades out over 300ms. */
.resource-buttons__copy {
	position: relative;
}

.resource-buttons__status {
	position: absolute;
	top: 50%;
	left: 100%;
	margin-left: var(--space-2);
	transform: translateY(-50%);
	color: var(--color-accent-pink);
	font-size: var(--text-small);
	font-weight: var(--weight-bold);
	line-height: var(--leading-ui);
	white-space: nowrap;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.3s ease-out;
}

.resource-buttons__status.is-visible {
	opacity: 1;
	transition: none;
}

@media (prefers-reduced-motion: reduce) {
	.resource-buttons__status {
		transition: none;
	}
}

.resource-buttons__fallback {
	flex-basis: 100%;
}

.resource-buttons__fallback label {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2);
	font-size: var(--text-small);
}

.resource-buttons__fallback-input {
	min-width: min(22rem, 70vw);
	padding: var(--space-2);
	border: 1px solid var(--color-border-input);
	background: var(--color-surface);
	font: inherit;
	font-size: var(--text-body);
}

/* -------------------------------------------------- Share page and 404 */

/* The share page shows the list's grid card once, at the full content width. */
.hub-share__list {
	grid-template-columns: 1fr;
	margin-top: var(--space-6);
	margin-bottom: var(--space-6);
}

@media (min-width: 769px) {
	.resource-list.hub-share__list:not(.resource-list--list) {
		grid-template-columns: 1fr;
	}
}

/* Share page only: the resource title is the page's h1, so it takes the topic title's type
   (.resource-topic-head__title) at every breakpoint. List cards stay at --text-lead. */
.hub-share__list .resource-card .entry-title {
	font-family: var(--font-heading);
	font-size: var(--text-h3);
	line-height: var(--leading-heading);
	--hub-copy-box: 1.75rem;
}

/* Tablet and up: the language menus sit side by side, each at most 200px. Phones stay stacked. */
@media (min-width: 769px) {
	.hub-share__list .resource-card__menus {
		flex-direction: row;
		align-items: flex-start;
	}

	.hub-share__list .resource-card__menus .hub-menu {
		flex: 1 1 0;
		min-width: 0;
		max-width: 200px;
	}

	/* A bilingual file's single "English / Spanish" menu is as wide as the pair. */
	.hub-share__list .resource-card__menus .hub-menu--both {
		max-width: calc(400px + var(--space-2));
	}
}

/* Top strip of every hub sub-page: the back link, or on a topic page the breadcrumb. A 45px bar
   (the height of the breadcrumb on domesticworkers.org) on the same textured band as the topic
   tiles, full width, with black 14px Rubik text. The text starts at the content column's edge. */
.hub-back-link,
.hub-crumbs {
	position: relative;
	isolation: isolate;
	display: flex;
	align-items: center;
	box-sizing: border-box;
	max-width: var(--container);
	height: 2.8125rem;
	margin: 0 auto;
	color: var(--color-text);
	font-family: var(--font-body);
	font-size: var(--text-label);
	font-weight: var(--weight-regular);
	line-height: var(--leading-ui);
	white-space: nowrap;
}

.hub-back-link::before,
.hub-crumbs::before {
	content: "";
	position: absolute;
	z-index: -1;
	top: 0;
	bottom: 0;
	left: calc(50% - 50vw);
	width: 100vw;
	background: var(--color-texture-fallback) var(--color-texture) center center / cover no-repeat;
}

.hub-back-link[hidden],
.hub-crumbs[hidden] {
	display: none;
}

/* The list's content (toolbar, table, tiles) starts at the page gutter, so the strip does too. */
.hub-crumbs {
	max-width: none;
}

/* Each crumb (and the back link) is its own small white box so it reads on the texture. Semibold
   (600), the heaviest Rubik weight this theme loads below bold. The first box's edge, not its text,
   lines up with the table. */
.hub-back-link a,
.hub-crumbs a,
.hub-crumbs__current {
	display: inline-block;
	padding: 2px 0.5rem;
	border-radius: var(--radius-control);
	background: var(--color-surface);
	color: var(--color-text);
	font-weight: var(--weight-semibold);
	text-decoration: none;
}

/* Hover and keyboard focus invert a link box: white text on black. The focus ring sits outside it. */
.hub-back-link a:hover,
.hub-crumbs a:hover,
.hub-back-link a:focus-visible,
.hub-crumbs a:focus-visible {
	background: var(--color-text);
	color: var(--color-surface);
	text-decoration: none;
}

.hub-back-link a:focus-visible,
.hub-crumbs a:focus-visible {
	outline: var(--focus-ring);
	outline-offset: var(--focus-offset);
}

.hub-back-link__chevron {
	display: inline-block;
	margin-right: 0.5rem;
}

.hub-crumbs__sep {
	margin: 0 0.5rem;
	font-weight: var(--weight-bold);
}

.hub-crumbs__current {
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Share page: three crumbs on one line. The title crumb gives way first (ellipsis, full title in its
   title attribute); on a phone the middle crumb may shorten too. */
.hub-crumbs--share {
	min-width: 0;
}

.hub-crumbs--share > a,
.hub-crumbs--share > .hub-crumbs__sep {
	flex: 0 0 auto;
}

.hub-crumbs--share > a[data-crumb-middle] {
	flex: 0 1 auto;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

.hub-crumbs--share > .hub-crumbs__current {
	flex: 0 1 auto;
	min-width: 0;
	max-width: 32rem;
}

@media (max-width: 600px) {
	.hub-crumbs--share > a[data-crumb-middle] {
		min-width: 4.5rem;
	}

	.hub-crumbs--share > .hub-crumbs__current {
		flex-shrink: 6;
		min-width: 5rem;
	}

	.hub-crumbs--share .hub-crumbs__sep {
		margin: 0 0.25rem;
	}
}

.page-header.resource-archive-header[hidden] {
	display: none;
}

/* Under the textured strip the title band is plain, so the two read as separate pieces. The landing
   and the all-resources list have no strip and keep the textured band. */
.hub-back-link:not([hidden]) ~ .page-header.resource-archive-header,
.hub-back-link:not([hidden]) ~ * .page-header.resource-archive-header {
	background: var(--color-surface-muted);
}

/* Compact header: the title with its description stacked under it, in the toolbar row where Clear
   filters was. The toggle sits at the far right, centred against this block. */
.resource-topic-head {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	align-items: flex-start;
	gap: var(--space-1);
	min-width: 0;
	order: 0;
}

.resource-topic-head[hidden] {
	display: none;
}

.resource-topic-head__title {
	max-width: 100%;
	margin: 0;
	font-family: var(--font-heading);
	font-size: var(--text-h3);
	line-height: var(--leading-heading);
	overflow-wrap: break-word;
}

/* Same size as the topics and tags text in the table view. */
.resource-topic-head__description {
	max-width: 100%;
	margin: 0;
	color: var(--color-text-muted);
	font-family: var(--font-body);
	font-size: var(--text-small);
	line-height: var(--leading-description);
}

.resource-topic-head__description[hidden] {
	display: none;
}

.resource-topic-head__description a {
	color: inherit;
	text-decoration: underline;
}

/*
 * The title block (topic pages) and the Build Your Base intro are at most two grid columns wide:
 * two card widths plus the gap, from the grid's own column count and gap (1 / 2 / 3 columns at
 * the breakpoints below; on a phone, one column, so the cap is looser than the screen). 100cqw is
 * the width of the toolbar controls, as wide as the grid.
 */
.resource-topic-head {
	--hub-grid-cols: 1;
	--hub-grid-gap: var(--space-5);
	max-width: calc((100cqw - (var(--hub-grid-cols) - 1) * var(--hub-grid-gap)) / var(--hub-grid-cols) * 2 + var(--hub-grid-gap));
}

@media (min-width: 769px) {
	.resource-topic-head {
		--hub-grid-cols: 2;
		--hub-grid-gap: var(--space-6);
	}
}

@media (min-width: 992px) {
	.resource-topic-head {
		--hub-grid-cols: 3;
	}
}

/*
 * Equal space (--space-3) above and below Clear filters / the chips row, at every width. The
 * empty filters row would add its gap to the bottom only, so the space exists only while it shows.
 */
body.hub-compact-head .resource-filter-toolbar__cluster-left {
	row-gap: 0;
}

body.hub-compact-head .resource-filter-toolbar__chip-group {
	min-height: 0;
}

body.hub-compact-head .resource-filter-toolbar__filters:has([data-filter-chips]:not([hidden]), [data-filter-clear]:not([hidden])) {
	margin-top: var(--space-3);
}

body.hub-compact-head .resource-filter-toolbar__bar:has([data-filter-chips]:not([hidden]), [data-filter-clear]:not([hidden])) {
	padding-bottom: var(--space-3);
}

/* Phone: the taller bar scrolls away instead of sticking, and has no chips to hold the row open. */
@media (max-width: 768px) {
	.resource-topic-head {
		flex: 1 1 100%;
	}

	body.hub-compact-head .resource-filter-toolbar__bar {
		position: static;
	}

}

.hub-not-found > p {
	margin: var(--space-6) 0 0;
}

.hub-not-found > p + p {
	margin-top: var(--space-4);
}

/* ------------------------------------------------------- Organizing 101 */

.organizing-101 {
	/* Same width as the list pages (the card grid and table), and a size container so the intro can be capped in grid columns. */
	container-type: inline-size;
	max-width: var(--container-wide);
	margin: var(--space-6) auto var(--space-7);
}

/* The grid/list toggle, on the right above the starter resources (hidden on phones). */
.organizing-101__head {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: var(--space-4);
	margin-bottom: var(--space-5);
}


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

/*
 * Header nav search. Shown where GeneratePress shows the full menu (901px and
 * up); at 900px and below the mobile menu applies and the search sits in the nav bar
 * (hub-nav-search.js); the toolbar search takes over on narrow phones.
 */
.main-navigation .main-nav ul li.hub-nav-search-item {
	display: none;
}

/* ------------------------------------------------ md: 769px and up */

@media (min-width: 769px) {
	.resource-list {
		gap: var(--space-6);
	}

	.resource-list:not(.resource-list--list) {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.resource-landing__topics {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	/* Toolbar: the title block on the first row, Clear filters and chips on their own row under
	   it (the view toggle stays at the far right of the title row). */
	.resource-filter-toolbar__cluster-left {
		flex-wrap: wrap;
	}

	.resource-filter-toolbar__filters {
		flex: 1 1 100%;
		flex-wrap: nowrap;
		order: 2;
	}

	.resource-filter-toolbar__chip-group {
		flex: 1 1 100%;
	}

	.resource-filter-toolbar__chips {
		flex: 0 1 auto;
	}

	/* With the filters row showing, the toggle lines up with the title row, not the whole block. */
	.resource-filter-toolbar__main-row:has([data-filter-chips]:not([hidden]), [data-filter-clear]:not([hidden])) {
		align-items: flex-start;
	}

	/* Nothing to filter or toggle on the topic tiles; search lives in the nav. */
	body.hub-landing-active .resource-filter-toolbar {
		display: none;
	}
}

/* Desktop header (901px and up): header search in the menu row. */
@media (min-width: 901px) {
	/* Search moves to the header. */
	.resource-filter-toolbar__search--mobile {
		display: none;
	}

	.main-navigation .main-nav ul li.hub-nav-search-item {
		display: flex;
		align-items: center;
		margin-right: var(--space-3);
	}

	.hub-nav-search {
		width: clamp(7rem, calc(100vw - 52rem), 22rem);
		max-width: 250px;
		margin: 0;
	}

	.hub-nav-search .resource-filter-toolbar__search-input[type="search"] {
		min-height: 2.5rem;
		line-height: var(--leading-ui);
	}

	.hub-nav-search .resource-filter-toolbar__search-suggestions {
		left: auto;
		right: 0;
		width: min(32rem, calc(100vw - (2 * var(--gutter))));
		z-index: 1000;
	}

	/* Keep GeneratePress menu link styles off the suggestion rows. */
	.main-navigation .main-nav ul li.hub-nav-search-item ul.resource-filter-toolbar__search-suggestions {
		position: absolute;
		display: block;
		float: none;
		height: auto;
		opacity: 1;
		pointer-events: auto;
		left: auto;
		right: 0;
		box-shadow: var(--shadow-overlay);
	}

	.main-navigation .main-nav ul li.hub-nav-search-item ul.resource-filter-toolbar__search-suggestions[hidden] {
		display: none;
	}

	.main-navigation .main-nav ul li.hub-nav-search-item ul.resource-filter-toolbar__search-suggestions li {
		float: none;
		width: 100%;
	}
}

/* Tablet widths: tighten menu spacing so search, Resources, Organizing 101 and language fit on one line. */
@media (min-width: 901px) and (max-width: 991px) {
	.main-navigation .main-nav ul li:not(.hub-nav-search-item) > a {
		padding-left: var(--space-2);
		padding-right: var(--space-2);
	}

	.main-navigation .main-nav ul li.menu-item-has-children > a {
		padding-right: 0;
	}

	.main-navigation .main-nav ul li .dropdown-menu-toggle {
		padding-left: var(--space-1);
		padding-right: var(--space-2);
	}

	.main-navigation .main-nav ul li.hub-nav-search-item {
		margin-right: var(--space-1);
	}
}

/* ------------------------------------------------ lg: 992px and up */

@media (min-width: 992px) {
	.resource-list:not(.resource-list--list) {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* ------------------------------------------------ xl: 1200px and up */

@media (min-width: 1200px) {
	.resource-landing__topics {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* ----------------------------------------------------------- Login page */

/* White behind the texture (never coral), and the page is full height (ndwa-brand.css), so nothing shows below the footer. */
body.hub-login-page.resource-hub-layout {
	background: var(--color-surface) var(--color-texture) center center / cover no-repeat;
}

/* The card is centred in whatever height is left between the header and the footer. */
body.hub-login-page #page,
body.hub-login-page #content,
body.hub-login-page #primary {
	display: flex;
	flex-direction: column;
	flex: 1 0 auto;
}

body.hub-login-page.resource-hub-layout .site-main {
	display: flex;
	flex: 1 0 auto;
	align-items: center;
	justify-content: center;
	min-height: 28rem;
	padding-top: var(--space-6);
	padding-bottom: var(--space-6);
	background: transparent;
}

body.hub-login-page .site-main > article {
	width: 100%;
	max-width: 900px;
	margin: 0 auto;
}

body.hub-login-page.separate-containers .site-main > article {
	margin-bottom: 0;
}

body.hub-login-page.separate-containers .inside-article {
	padding: 0;
	background: transparent;
}

body.hub-login-page .entry-content:empty {
	display: none;
	margin: 0;
	padding: 0;
}

body.hub-login-page .resource-custom-script-gateway {
	width: 100%;
	max-width: 900px;
	margin: 0 auto;
	padding: var(--card-pad);
	background: var(--color-surface);
	border-radius: var(--radius);
	box-shadow: var(--shadow-overlay);
}

body.hub-login-page .resource-custom-script-gateway .ngp-form,
body.hub-login-page .resource-custom-script-gateway .at-form,
body.hub-login-page .resource-custom-script-gateway form {
	max-width: none;
	margin: 0;
}

body.hub-login-page .resource-custom-script-gateway .at-field,
body.hub-login-page .resource-custom-script-gateway .at-row {
	margin-bottom: 0;
}

body.hub-login-page .resource-custom-script-gateway .at-form-submit,
body.hub-login-page .resource-custom-script-gateway .SubmitButton,
body.hub-login-page .resource-custom-script-gateway .at-field.at-submit {
	text-align: center;
}

body.hub-login-page .resource-custom-script-gateway .at-form-submit .at-submit {
	float: none;
}

/*
 * !important is used only below, and only for two reasons:
 * 1. [hidden] must win over the display: flex / grid rules above.
 * 2. The EveryAction login form ships its own stylesheets after ours and styles
 *    its title, labels, fields and submit button with high-specificity rules.
 */
.resource-card[hidden],
.resource-list[hidden],
.resource-landing[hidden],
.resource-archive-topic-description[hidden] {
	display: none !important;
}

body.hub-login-page .resource-custom-script-gateway .at-title {
	font-family: var(--font-heading) !important;
	font-weight: var(--weight-black) !important;
	font-size: var(--text-h3) !important;
	line-height: var(--leading-heading) !important;
	color: var(--color-text) !important;
	margin: 0 !important;
	text-align: center;
}

body.hub-login-page .resource-custom-script-gateway label,
body.hub-login-page .resource-custom-script-gateway .LabelText,
body.hub-login-page .resource-custom-script-gateway .at-label,
body.hub-login-page .resource-custom-script-gateway .at-markup p {
	font-family: var(--font-body) !important;
	font-size: var(--text-body) !important;
	font-weight: var(--weight-medium) !important;
	line-height: var(--leading-text) !important;
	color: var(--color-text) !important;
}

/* The email opt-in ("Yes, sign me up…") and the consent footer ("By providing your…"):
   small print, 11pt and regular weight; the footer is grey. */
body.hub-login-page .resource-custom-script-gateway label.at-check,
body.hub-login-page .resource-custom-script-gateway label.at-check .at-checkbox-title,
body.hub-login-page .resource-custom-script-gateway .at-markup.FooterHtml,
body.hub-login-page .resource-custom-script-gateway .at-markup.FooterHtml p {
	font-size: 11pt !important;
	font-weight: var(--weight-regular) !important;
}

body.hub-login-page .resource-custom-script-gateway .at-markup.FooterHtml,
body.hub-login-page .resource-custom-script-gateway .at-markup.FooterHtml p {
	color: var(--color-text-muted) !important;
}

body.hub-login-page .resource-custom-script-gateway input[type="text"],
body.hub-login-page .resource-custom-script-gateway input[type="email"],
body.hub-login-page .resource-custom-script-gateway input[type="tel"],
body.hub-login-page .resource-custom-script-gateway input[type="password"],
body.hub-login-page .resource-custom-script-gateway input[type="number"],
body.hub-login-page .resource-custom-script-gateway input[type="search"],
body.hub-login-page .resource-custom-script-gateway select,
body.hub-login-page .resource-custom-script-gateway textarea,
body.hub-login-page .resource-custom-script-gateway .at-text,
body.hub-login-page .resource-custom-script-gateway .at-email {
	font-family: var(--font-body) !important;
	font-size: var(--text-body) !important;
	font-weight: var(--weight-regular) !important;
	line-height: var(--leading-text) !important;
	color: var(--color-text) !important;
	border-radius: var(--radius);
}

body.hub-login-page .resource-custom-script-gateway .btn-at-primary,
body.hub-login-page .resource-custom-script-gateway .at-submit,
body.hub-login-page .resource-custom-script-gateway input[type="submit"],
body.hub-login-page .resource-custom-script-gateway button[type="submit"] {
	/* Matches .hub-button--large. An <input> can't take ::after, so the same arrow SVG is a
	   background image, placed where .hub-button--large::after sits. */
	display: block !important;
	width: auto !important;
	min-height: 2.75rem !important;
	margin-left: auto !important;
	margin-right: auto !important;
	font-family: var(--font-label) !important;
	font-weight: var(--weight-black) !important;
	font-size: var(--text-body) !important;
	line-height: var(--leading-ui) !important;
	text-transform: uppercase !important;
	letter-spacing: var(--tracking-label) !important;
	border-radius: var(--radius) !important;
	background: var(--color-brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 16'%3E%3Cpath d='M0 8h18M11 1.5L17.5 8 11 14.5' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E") no-repeat right var(--space-6) center / calc(var(--space-4) + var(--space-1)) var(--space-4) !important;
	color: var(--color-text) !important;
	border: 0 !important;
	padding: var(--space-4) var(--space-8) var(--space-4) var(--space-6) !important;
	cursor: pointer;
	transition: background-color 0.15s ease, box-shadow 0.15s ease;
}

body.hub-login-page .resource-custom-script-gateway .btn-at-primary:hover,
body.hub-login-page .resource-custom-script-gateway .btn-at-primary:focus,
body.hub-login-page .resource-custom-script-gateway .at-submit:hover,
body.hub-login-page .resource-custom-script-gateway .at-submit:focus,
body.hub-login-page .resource-custom-script-gateway input[type="submit"]:hover,
body.hub-login-page .resource-custom-script-gateway input[type="submit"]:focus,
body.hub-login-page .resource-custom-script-gateway button[type="submit"]:hover,
body.hub-login-page .resource-custom-script-gateway button[type="submit"]:focus {
	background-color: var(--color-brand-hover) !important;
	color: var(--color-text) !important;
	box-shadow: var(--shadow-button);
}
