/**
 * Layout: container, top bar, header, navigation, drawer, content area and
 * footer. The header switches from the drawer to the inline menu at 1024 px.
 */

.wot-container {
	width: 100%;
	max-width: calc(var(--wot-container) + 2 * var(--wot-gutter));
	margin-inline: auto;
	padding-inline: var(--wot-gutter);
}

.wot-container--text {
	max-width: calc(var(--wot-container-text) + 2 * var(--wot-gutter));
}

.wot-site {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.wot-content {
	flex: 1;
}

/* Top bar ----------------------------------------------------------------- */
.wot-topbar {
	background: var(--wot-green-950);
	color: var(--wot-ink-inverse-muted);
	font-size: var(--wot-text-sm);
}

.wot-topbar__inner {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-1) var(--wot-space-5);
	align-items: center;
	justify-content: space-between;
	min-height: 2.5rem;
	padding-block: var(--wot-space-1);
}

.wot-topbar__message {
	margin: 0;
}

.wot-topbar__contacts {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-1) var(--wot-space-5);
	margin: 0;
	padding: 0;
	list-style: none;
}

.wot-topbar a {
	display: inline-flex;
	gap: var(--wot-space-2);
	align-items: center;
	color: var(--wot-ink-inverse);
	text-decoration: none;
}

.wot-topbar a:hover {
	color: var(--wot-ink-inverse);
	text-decoration: underline;
}

.wot-topbar :focus-visible {
	outline-color: var(--wot-ink-inverse);
}

@media (max-width: 767px) {
	.wot-topbar__message {
		display: none;
	}

	.wot-topbar__contacts {
		justify-content: center;
		width: 100%;
	}

	.wot-topbar__email {
		display: none;
	}
}

/* Header ------------------------------------------------------------------ */
.wot-header {
	position: sticky;
	top: 0;
	z-index: 50;
	border-bottom: 1px solid var(--wot-line);
	background: var(--wot-surface);
}

.admin-bar .wot-header {
	top: 32px;
}

@media (max-width: 782px) {
	.admin-bar .wot-header {
		top: 0;
		position: relative;
	}
}

.wot-header__inner {
	display: flex;
	gap: var(--wot-space-4);
	align-items: center;
	min-height: var(--wot-header-height);
}

.wot-brand {
	display: inline-flex;
	flex: none;
	gap: var(--wot-space-3);
	align-items: center;
	color: var(--wot-ink);
	font-size: var(--wot-text-lg);
	font-weight: 700;
	text-decoration: none;
}

.wot-brand:hover {
	color: var(--wot-ink);
	text-decoration: none;
}

.wot-brand img,
.wot-brand .custom-logo {
	display: block;
	width: auto;
	max-height: 2.75rem;
}

.wot-brand__mark {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.5rem;
	height: 2.5rem;
	border-radius: var(--wot-radius-control);
	background: var(--wot-color-primary);
	color: var(--wot-ink-inverse);
	font-size: var(--wot-text-xl);
}

.wot-header__nav {
	display: none;
	flex: 1;
	min-width: 0;
}

.wot-header__actions {
	display: flex;
	gap: var(--wot-space-2);
	align-items: center;
	margin-left: auto;
}

.wot-header__search {
	display: none;
}

.wot-menu-button {
	position: relative;
	display: inline-flex;
	gap: var(--wot-space-2);
	align-items: center;
	min-height: var(--wot-touch);
	padding: 0 var(--wot-space-3);
	border: 1px solid var(--wot-line);
	border-radius: var(--wot-radius-control);
	background: var(--wot-surface);
	color: var(--wot-ink);
	font: inherit;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.wot-menu-button .wot-badge {
	position: absolute;
	top: -0.5rem;
	right: -0.5rem;
}

@media (min-width: 1024px) {
	.wot-header__nav {
		display: block;
	}

	.wot-menu-button {
		display: none;
	}
}

/* When the header cannot fit on one line even with "More" (large text
   settings, long names), navigation.js marks it compact and it works as
   on a phone: brand and the Menu button, everything else in the drawer
   (0.8.0). */
.wot-header--compact .wot-header__nav,
.wot-header--compact .wot-header__search,
.wot-header--compact .wot-header__profile {
	display: none;
}

.wot-header--compact .wot-menu-button {
	display: inline-flex;
}

/* Phones and tablets: a long business name shortens before the Menu
   button is pushed off the screen (0.8.0). Wide screens use "More" and,
   failing that, the compact header instead. */
@media (max-width: 1023px) {
	.wot-header .wot-brand {
		flex: 0 1 auto;
		min-width: 0;
	}

	.wot-header .wot-brand__name {
		min-width: 0;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	.wot-header .wot-brand__mark,
	.wot-header__actions {
		flex: none;
	}
}

/* Small phones (below 375px): a smaller brand name, and the Menu button
   shows its icon and count only; its name stays for screen readers. */
@media (max-width: 374px) {
	.wot-header .wot-brand__name {
		font-size: var(--wot-text-base);
	}

	.wot-menu-button > span:not(.wot-badge) {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
		white-space: nowrap;
	}
}

@media (min-width: 1280px) {
	.wot-header__search {
		display: block;
		width: 16rem;
	}
}

/* Primary navigation (desktop) -------------------------------------------- */
.wot-nav__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-1);
	align-items: center;
	margin: 0;
	padding: 0;
	list-style: none;
}

.wot-nav--measured .wot-nav__list {
	flex-wrap: nowrap;
}

.wot-nav__item {
	position: relative;
	display: flex;
	align-items: center;
}

.wot-nav__link {
	display: inline-flex;
	gap: var(--wot-space-2);
	align-items: center;
	min-height: var(--wot-touch);
	padding: 0 var(--wot-space-3);
	border-radius: var(--wot-radius-control);
	color: var(--wot-ink);
	font-weight: 500;
	text-decoration: none;
	white-space: nowrap;
}

.wot-nav__link:hover {
	background: var(--wot-green-50);
	color: var(--wot-color-primary);
	text-decoration: none;
}

.wot-nav__item.is-active > .wot-nav__link,
.wot-nav__link[aria-current="page"] {
	color: var(--wot-color-primary);
	box-shadow: inset 0 -2px 0 var(--wot-color-primary);
}

.wot-nav__item--cta {
	margin-left: var(--wot-space-2);
}

.wot-nav__item--cta > .wot-nav__link {
	min-height: 2.5rem;
	padding: 0 var(--wot-space-4);
	background: var(--wot-color-primary);
	color: var(--wot-ink-inverse);
	font-weight: 600;
	box-shadow: none;
}

.wot-nav__item--cta > .wot-nav__link:hover {
	background: var(--wot-color-primary-hover);
	color: var(--wot-ink-inverse);
}

/* The current page's button keeps white text; a bright bar under it marks
   it as current (0.4.0: the registration page is drawn by the theme). */
.wot-nav__item--cta.is-active > .wot-nav__link,
.wot-nav__item--cta > .wot-nav__link[aria-current="page"] {
	color: var(--wot-ink-inverse);
	box-shadow: inset 0 -3px 0 var(--wot-color-accent);
}

.wot-nav__toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.75rem;
	height: var(--wot-touch);
	margin-left: calc(-1 * var(--wot-space-2));
	border: 0;
	border-radius: var(--wot-radius-control);
	background: transparent;
	color: var(--wot-ink-muted);
	cursor: pointer;
}

.wot-nav__toggle:hover {
	color: var(--wot-color-primary);
}

.wot-nav__toggle[aria-expanded="true"] .wot-icon {
	transform: rotate(180deg);
}

.wot-nav__sub {
	left: 0;
	right: auto;
}

/* Without JavaScript, sub-menus open on hover and keyboard focus. */
.no-js .wot-nav__item:hover > .wot-nav__sub,
.no-js .wot-nav__item:focus-within > .wot-nav__sub {
	display: block;
}

.wot-nav__more[hidden] {
	display: none;
}

/* Profile menu -------------------------------------------------------------- */
.wot-profile__button {
	position: relative;
	display: inline-flex;
	gap: var(--wot-space-2);
	align-items: center;
	min-height: var(--wot-touch);
	padding: 0 var(--wot-space-2) 0 var(--wot-space-1);
	border: 1px solid var(--wot-line);
	border-radius: var(--wot-radius-pill);
	background: var(--wot-surface);
	color: var(--wot-ink);
	font: inherit;
	font-weight: 500;
	cursor: pointer;
}

.wot-profile__button:hover {
	border-color: var(--wot-color-primary);
}

.wot-profile__avatar {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.125rem;
	height: 2.125rem;
	border-radius: 50%;
	background: var(--wot-green-100);
	color: var(--wot-color-primary);
	font-weight: 700;
}

.wot-profile__name {
	max-width: 10rem;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.wot-profile__button .wot-badge {
	position: absolute;
	top: -0.375rem;
	left: 1.5rem;
}

.wot-profile__head {
	padding: var(--wot-space-2) var(--wot-space-3) var(--wot-space-3);
	border-bottom: 1px solid var(--wot-line);
	margin-bottom: var(--wot-space-1);
}

.wot-profile__head strong {
	display: block;
}

.wot-profile__head span {
	color: var(--wot-ink-muted);
	font-size: var(--wot-text-sm);
}

@media (max-width: 1023px) {
	.wot-header__profile {
		display: none;
	}
}

/* Drawer (phones and tablets) ----------------------------------------------- */
.wot-drawer {
	position: fixed;
	inset: 0;
	z-index: 100;
	display: flex;
	justify-content: flex-end;
	background: rgba(6, 69, 45, 0.55);
}

.wot-drawer[hidden] {
	display: none;
}

.wot-drawer__panel {
	display: flex;
	flex-direction: column;
	width: min(24rem, 100%);
	height: 100%;
	overflow-y: auto;
	background: var(--wot-surface);
	box-shadow: var(--wot-shadow-menu);
}

.wot-drawer__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: var(--wot-space-3) var(--wot-space-4);
	border-bottom: 1px solid var(--wot-line);
}

.wot-drawer__section {
	padding: var(--wot-space-4);
	border-bottom: 1px solid var(--wot-line);
}

.wot-drawer__section:last-child {
	border-bottom: 0;
}

.wot-drawer__heading {
	margin: 0 0 var(--wot-space-2);
	color: var(--wot-ink-muted);
	font-size: var(--wot-text-xs);
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.wot-drawer__list,
.wot-drawer__sub {
	margin: 0;
	padding: 0;
	list-style: none;
}

.wot-drawer__sub {
	margin: 0 0 var(--wot-space-2) var(--wot-space-6);
	border-left: 2px solid var(--wot-line);
}

.wot-drawer__sub[hidden] {
	display: none;
}

.wot-drawer__row {
	display: flex;
	align-items: center;
}

.wot-drawer__link {
	display: flex;
	flex: 1;
	gap: var(--wot-space-3);
	align-items: center;
	min-height: 3rem;
	padding: 0 var(--wot-space-3);
	border-radius: var(--wot-radius-control);
	color: var(--wot-ink);
	font-weight: 500;
	text-decoration: none;
}

.wot-drawer__link:hover,
.wot-drawer__link[aria-current="page"] {
	background: var(--wot-green-50);
	color: var(--wot-color-primary);
}

.wot-drawer__link .wot-badge {
	margin-left: auto;
}

.wot-drawer__toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 3rem;
	height: 3rem;
	border: 0;
	border-radius: var(--wot-radius-control);
	background: transparent;
	color: var(--wot-ink-muted);
	cursor: pointer;
}

.wot-drawer__toggle[aria-expanded="true"] .wot-icon {
	transform: rotate(180deg);
}

body.wot-drawer-open {
	overflow: hidden;
}

/* Content area -------------------------------------------------------------- */
.wot-page-header {
	padding: var(--wot-space-7) 0 var(--wot-space-6);
	border-bottom: 1px solid var(--wot-line);
	background: var(--wot-surface);
}

.wot-page-header__title {
	margin: 0;
}

.wot-page-header__lead {
	max-width: 46rem;
	margin: var(--wot-space-3) 0 0;
	color: var(--wot-ink-muted);
	font-size: var(--wot-text-lg);
}

.wot-section {
	padding-block: var(--wot-space-7);
}

@media (min-width: 1024px) {
	.wot-section {
		padding-block: var(--wot-space-8);
	}
}

.wot-prose {
	font-size: var(--wot-text-lg);
}

.wot-prose > * {
	max-width: 100%;
}

.wot-prose h2,
.wot-prose h3 {
	margin-top: var(--wot-space-6);
}

.wot-entry-meta {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-2) var(--wot-space-4);
	margin: var(--wot-space-3) 0 0;
	color: var(--wot-ink-muted);
	font-size: var(--wot-text-sm);
}

.wot-entry-thumb {
	margin-bottom: var(--wot-space-6);
	overflow: hidden;
	border-radius: var(--wot-radius-card);
}

.wot-post-list {
	display: grid;
	gap: var(--wot-space-5);
	--wot-grid-min: 18rem;
}

.wot-post-card .wot-card__title a {
	color: var(--wot-ink);
	text-decoration: none;
}

.wot-post-card .wot-card__title a:hover {
	color: var(--wot-color-primary);
}

.wot-post-card__thumb img {
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
	border-radius: var(--wot-radius-card) var(--wot-radius-card) 0 0;
}

/* Footer ------------------------------------------------------------------ */
.wot-footer {
	margin-top: var(--wot-space-8);
	background: var(--wot-green-950);
	color: var(--wot-ink-inverse-muted);
	font-size: var(--wot-text-sm);
}

.wot-footer a {
	color: var(--wot-ink-inverse);
	text-decoration: none;
}

.wot-footer a:hover {
	color: var(--wot-ink-inverse);
	text-decoration: underline;
}

.wot-footer :focus-visible {
	outline-color: var(--wot-ink-inverse);
}

.wot-footer__grid {
	display: grid;
	gap: var(--wot-space-6) var(--wot-space-5);
	padding-block: var(--wot-space-7);
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* Below 1024px the link columns sit two to a row; the brand and the
   contact details, which hold long lines, take the full width. */
@media (max-width: 1023.98px) {
	.wot-footer__brand,
	.wot-footer__contact {
		grid-column: 1 / -1;
	}
}

/* Up to six columns (1.1.0): the brand and five link columns. Three to a
   row from 1024px, all in one row from 1280px; a column with nothing to
   show is left out, so the grid fills from the left. */
@media (min-width: 1024px) {
	.wot-footer__grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (min-width: 1280px) {
	.wot-footer__grid {
		grid-template-columns: minmax(0, 1.5fr) repeat(5, minmax(0, 1fr));
	}
}

.wot-footer__brand .wot-brand {
	color: var(--wot-ink-inverse);
}

.wot-footer__brand .wot-brand__mark {
	background: var(--wot-color-accent);
	color: var(--wot-green-950);
}

.wot-footer__about {
	max-width: 24rem;
	margin: var(--wot-space-4) 0;
}

.wot-footer__heading {
	margin: 0 0 var(--wot-space-3);
	color: var(--wot-ink-inverse);
	font-size: var(--wot-text-sm);
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.wot-footer__list {
	display: grid;
	gap: var(--wot-space-2);
	margin: 0;
	padding: 0;
	list-style: none;
}

.wot-footer__list a {
	display: inline-flex;
	gap: var(--wot-space-2);
	align-items: flex-start;
	max-width: 100%;
	padding-block: var(--wot-space-1);
}

/* A long email address or street breaks rather than widening the page
   (0.8.0: at 1024px the contact column ran 7px past the screen). */
.wot-footer__list li,
.wot-footer__address {
	min-width: 0;
	overflow-wrap: anywhere;
}

.wot-footer__address {
	display: flex;
	gap: var(--wot-space-2);
	font-style: normal;
	white-space: pre-line;
}

.wot-social {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-2);
	margin: 0;
	padding: 0;
	list-style: none;
}

.wot-social a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: var(--wot-touch);
	height: var(--wot-touch);
	border: 1px solid rgba(255, 255, 255, 0.24);
	border-radius: 50%;
}

.wot-social a:hover {
	border-color: var(--wot-ink-inverse);
	background: rgba(255, 255, 255, 0.08);
	text-decoration: none;
}

.wot-footer__bottom {
	border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.wot-footer__bottom-inner {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-3) var(--wot-space-5);
	align-items: center;
	justify-content: space-between;
	padding-block: var(--wot-space-4);
}

.wot-footer__legal {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-2) var(--wot-space-4);
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Plugin-dependent page without the plugin --------------------------------- */
.wot-unavailable {
	max-width: 40rem;
	margin: var(--wot-space-7) auto;
}

.wot-nav__more-button {
	border: 0;
	background: none;
	font: inherit;
	cursor: pointer;
}

.wot-content:focus {
	outline: none;
}

/* Without JavaScript the drawer opens through its #wot-drawer address. */
.no-js .wot-drawer:target {
	display: flex;
}

.no-js .wot-drawer__sub[hidden] {
	display: block;
}

.wot-footer__copyright,
.wot-footer__credit {
	margin: 0;
}

.wot-footer__credit a {
	text-decoration: underline;
	text-underline-offset: 0.15em;
}

.wot-center {
	display: flex;
	justify-content: center;
}

/* Small layout utilities. */
.wot-cluster {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wot-space-3);
	align-items: center;
}

.wot-narrow {
	max-width: 32rem;
}

.wot-gap-below {
	margin-bottom: var(--wot-space-5);
}

.wot-gap-above {
	margin-top: var(--wot-space-6);
}

.wot-ref-section {
	padding-block: var(--wot-space-6);
	border-bottom: 1px solid var(--wot-line);
}

.wot-nav__item[hidden] {
	display: none;
}
