/*
Theme Name: ES5 Heritage
Theme URI: https://www.es5.ch/
Author: ES5
Description: A clean, native WordPress block theme for the English Speaking Swiss Sports Shooting Society.
Version: 1.2.8
Requires at least: 6.6
Requires PHP: 8.0
Text Domain: es5-heritage
*/

:root {
	--es5-paper: #f3eee2;
	--es5-paper-light: #fbf8f1;
	--es5-ink: #171814;
	--es5-red: #8f1d20;
	--es5-green: #3e4e3b;
	--es5-sage: #76816b;
	--es5-rule: rgba(143, 29, 32, 0.28);
}

html {
	scroll-behavior: smooth;
}

body {
	background-color: var(--es5-paper);
	background-image:
		radial-gradient(circle at 20% 10%, rgba(255,255,255,.58), transparent 32rem),
		repeating-linear-gradient(0deg, rgba(23,24,20,.018) 0, rgba(23,24,20,.018) 1px, transparent 1px, transparent 4px);
}

a {
	text-underline-offset: .18em;
	text-decoration-thickness: .08em;
}

:focus-visible {
	outline: 3px solid #d5a929;
	outline-offset: 4px;
}

.wp-site-blocks {
	min-height: 100vh;
}

.es5-site-header {
	border-bottom: 1px solid var(--es5-red);
	background: rgba(251, 248, 241, .96);
	position: relative;
	z-index: 20;
}

.es5-header-inner {
	min-height: 116px;
}

.es5-brand {
	gap: .85rem;
}

.es5-wordmark a {
	border: 2px solid currentColor;
	display: inline-flex;
	font-family: Georgia, 'Times New Roman', serif;
	font-size: clamp(2rem, 3vw, 3rem);
	font-weight: 700;
	letter-spacing: .02em;
	line-height: 1;
	padding: .48rem .72rem .38rem;
	position: relative;
	text-decoration: none;
}

.es5-wordmark a::after {
	align-items: center;
	background: var(--es5-red);
	bottom: -.48rem;
	color: white;
	content: '+';
	display: flex;
	font-family: Arial, sans-serif;
	font-size: .8rem;
	font-weight: 700;
	height: 1.1rem;
	justify-content: center;
	left: 50%;
	line-height: 1;
	position: absolute;
	transform: translateX(-50%);
	width: 1.1rem;
}

.es5-site-header .wp-block-navigation {
	font-size: 1.05rem;
	font-weight: 500;
	letter-spacing: 0;
	text-transform: none;
}

.es5-site-header .wp-block-navigation-item__content {
	padding: .65rem .45rem;
}

.es5-site-header .wp-block-site-tagline {
	display: none;
}

.es5-site-header .wp-block-navigation-item__content:hover {
	color: var(--es5-red);
}

.wp-block-button.is-style-outline .wp-block-button__link {
	background: transparent;
	border: 1px solid var(--es5-red);
	color: var(--es5-red);
}

.es5-hero {
	border-bottom: 1px solid var(--es5-rule);
	overflow: hidden;
	position: relative;
}

.es5-hero::before,
.es5-target-field::before {
	background: repeating-radial-gradient(circle, transparent 0 34px, rgba(143,29,32,.09) 35px 36px);
	content: '';
	height: 430px;
	pointer-events: none;
	position: absolute;
	right: -120px;
	top: -95px;
	width: 430px;
}

.es5-hero-copy {
	position: relative;
	z-index: 2;
}

.es5-eyebrow {
	color: var(--es5-red);
	font-size: .78rem;
	font-weight: 800;
	letter-spacing: .16em;
	text-transform: uppercase;
}

.es5-display {
	font-size: clamp(3.1rem, 7vw, 7.2rem) !important;
	letter-spacing: -.045em;
	line-height: .93 !important;
	max-width: 12ch;
}

.es5-display em {
	color: var(--es5-red);
	font-style: normal;
}

.es5-image-frame {
	box-shadow: 18px 18px 0 var(--es5-green);
	position: relative;
}

.es5-image-frame img {
	aspect-ratio: 3 / 2;
	display: block;
	object-fit: cover;
}

.es5-number-grid {
	border-bottom: 1px solid var(--es5-rule);
	border-top: 1px solid var(--es5-rule);
}

.es5-number-card {
	border-right: 1px solid var(--es5-rule);
	min-height: 180px;
	padding: 2rem;
}

.es5-number-card:last-child {
	border-right: 0;
}

.es5-number {
	color: var(--es5-red);
	font-family: Georgia, 'Times New Roman', serif;
	font-size: 3rem;
	line-height: 1;
}

.es5-section-rule {
	border-top: 1px solid var(--es5-rule);
}

.es5-card {
	background: var(--es5-paper-light);
	border: 1px solid rgba(23,24,20,.13);
	height: 100%;
	padding: clamp(1.4rem, 3vw, 2.4rem);
}

.es5-card--green {
	background: var(--es5-green);
	border-color: var(--es5-green);
	color: var(--es5-paper-light);
}

.es5-callout {
	background: var(--es5-green);
	color: var(--es5-paper-light);
	position: relative;
}

.es5-callout a:not(.wp-element-button) {
	color: inherit;
}

/* Homepage 1.1: the Swiss Heritage mockup translated into responsive blocks. */
.es5-home {
	margin-block-start: 0;
}

.es5-home > * {
	margin-block-start: 0;
}

.es5-mockup-hero {
	display: grid;
	grid-template-columns: minmax(430px, 47%) minmax(0, 53%);
	min-height: 630px;
	padding: 0 !important;
	position: relative;
}

.es5-mockup-copy {
	align-content: center;
	background-color: var(--es5-paper-light);
	background-image:
		linear-gradient(90deg, rgba(251,248,241,.05), rgba(251,248,241,.12)),
		url("assets/images/heritage-target-field-v3.jpg");
	background-position: center, center;
	background-repeat: no-repeat;
	background-size: cover;
	display: grid;
	justify-content: start;
	padding: clamp(3rem, 5vw, 5.5rem) clamp(2rem, 4.5vw, 5rem) !important;
	position: relative;
	z-index: 2;
}

.es5-mockup-title {
	font-size: clamp(4rem, 6.2vw, 6.7rem) !important;
	letter-spacing: -.045em;
	line-height: .92 !important;
	margin: 0;
	max-width: 8.4ch;
}

.es5-mockup-title em {
	color: var(--es5-red);
	font-style: normal;
	white-space: nowrap;
}

.es5-short-rule {
	border-top: 3px solid var(--es5-red) !important;
	margin: 2.3rem 0 1.25rem !important;
	width: 7.5rem !important;
}

.es5-mockup-intro {
	font-size: clamp(1.2rem, 1.7vw, 1.65rem);
	line-height: 1.4;
	margin: 0 0 1.7rem;
}

.es5-mockup-actions {
	gap: 1.5rem;
}

.es5-mockup-actions .wp-block-button__link {
	font-size: 1rem;
	min-width: 12.2rem;
	padding: 1rem 1.4rem;
	text-align: center;
	text-transform: none;
}

.es5-photo-collage {
	display: grid;
	gap: 2px;
	grid-template-columns: 58% 42%;
	grid-template-rows: 51% 49%;
	height: 630px;
	margin: 0;
	overflow: hidden;
	padding: 0 !important;
	position: relative;
}

.es5-photo-collage .es5-tile {
	height: 100%;
	margin: 0;
	overflow: hidden;
	position: relative;
	width: 100%;
}

.es5-photo-collage .es5-tile img {
	display: block;
	filter: saturate(.78) contrast(.98);
	height: 100%;
	object-fit: cover;
	transition: transform .45s ease;
	width: 100%;
}

.es5-photo-collage .es5-tile:hover img {
	transform: scale(1.018);
}

.es5-tile-alps img {
	transform: scale(1.3);
	transform-origin: left center;
}

.es5-photo-collage .es5-tile-alps:hover img {
	transform: scale(1.32);
}

.es5-tile-alps {
	clip-path: polygon(9% 0, 100% 0, 91% 100%, 0 100%);
	grid-column: 1;
	grid-row: 1;
	margin-left: -5% !important;
	width: 110% !important;
}

.es5-tile-archive {
	grid-column: 2;
	grid-row: 1;
}

.es5-tile-still {
	clip-path: polygon(0 0, 91% 0, 100% 100%, 0 100%);
	grid-column: 1;
	grid-row: 2;
	width: 109% !important;
}

.es5-tile-range {
	grid-column: 2;
	grid-row: 2;
}

.es5-flag-overlay {
	bottom: 0;
	height: 100%;
	margin: 0 !important;
	pointer-events: none;
	position: absolute;
	right: calc(42% - 6px);
	width: clamp(148px, 10vw, 175px);
	z-index: 7;
}

.es5-flag-overlay img {
	display: block;
	filter: drop-shadow(0 8px 7px rgba(24,22,17,.28));
	height: auto;
	position: absolute;
	right: 0;
	top: 22%;
	width: 100%;
	z-index: 1;
}

.es5-heritage-strip {
	border-bottom: 1px solid var(--es5-rule);
	border-top: 1px solid rgba(255,255,255,.85);
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(420px, 2.1fr);
	min-height: 245px;
	padding: 0 !important;
}

.es5-strip-card {
	border-right: 1px solid var(--es5-rule);
	display: block;
	padding: 2rem clamp(1.2rem, 3vw, 3rem) !important;
}

.es5-strip-card .es5-number {
	border-bottom: 2px solid var(--es5-red);
	display: inline-block;
	font-size: 3.4rem;
	margin: 0 0 .7rem;
	padding-bottom: .4rem;
}

.es5-strip-card h2 {
	font-family: var(--wp--preset--font-family--swiss-sans);
	font-size: 1.2rem;
	margin: 0;
}

.es5-strip-card h2 a {
	color: var(--es5-ink);
	text-decoration: none;
}

.es5-line-icon {
	color: var(--es5-sage);
	font-size: 3.3rem;
	font-weight: 300;
	line-height: 1;
	margin-top: .75rem;
}

.es5-strip-motto {
	align-items: center;
	background-color: var(--es5-green);
	background-image:
		linear-gradient(90deg, rgba(30,42,30,.2), rgba(30,42,30,.08)),
		url("assets/images/heritage-green-texture-v3.jpg");
	background-position: center;
	background-size: cover;
	color: var(--es5-paper-light);
	display: grid;
	grid-template-columns: 74px 1fr 160px;
	padding: 3rem !important;
	position: relative;
}

.es5-strip-motto::before {
	background: rgba(255,255,255,.3);
	content: '';
	height: 64%;
	left: 1.5rem;
	position: absolute;
	top: 18%;
	width: 1px;
}

.es5-strip-motto p {
	font-family: Georgia, 'Times New Roman', serif;
	font-size: clamp(1.35rem, 2vw, 2rem);
	line-height: 1.25;
	margin: 0;
}

.es5-swiss-mark {
	align-items: center;
	background: var(--es5-red);
	border: 1px solid white;
	display: flex;
	font-size: 2.2rem;
	font-weight: 700;
	height: 3.2rem;
	justify-content: center;
	line-height: 1;
	width: 3.2rem;
}

.es5-mountain-line {
	background:
		linear-gradient(145deg, transparent 45%, rgba(243,238,226,.6) 46% 47%, transparent 48%) 0 30%/55% 70% no-repeat,
		linear-gradient(35deg, transparent 45%, rgba(243,238,226,.6) 46% 47%, transparent 48%) 68% 30%/55% 70% no-repeat;
	display: none;
	height: 95px;
	op: .5rem;
	width: 160px;
}

.es5-below-fold {
	padding-bottom: clamp(4rem, 8vw, 7rem) !important;
	padding-top: clamp(4rem, 8vw, 7rem) !important;
}

.es5-below-fold h2 {
	font-size: clamp(2.4rem, 4vw, 4.2rem);
	margin-top: .5rem;
}

.es5-page-hero {
	border-bottom: 1px solid var(--es5-rule);
	position: relative;
}

.es5-page-title {
	font-size: clamp(2.8rem, 6vw, 6.2rem) !important;
	letter-spacing: -.04em;
	line-height: .95 !important;
}

.es5-step {
	border-top: 3px solid var(--es5-red);
	padding-top: 1.25rem;
}

.es5-fact-list {
	list-style: none;
	padding-left: 0;
}

.es5-fact-list li {
	border-bottom: 1px solid rgba(23,24,20,.14);
	padding: .8rem 0;
}

.es5-site-footer {
	background: var(--es5-green);
	color: var(--es5-paper-light);
	margin-block-start: 0;
}

.es5-site-footer a {
	color: inherit;
}

.es5-meta {
	font-size: .82rem;
	letter-spacing: .04em;
}

.es5-edit-note {
	background: #fff6d6;
	border-left: 4px solid #b68400;
	color: #4d3b00;
	font-size: .9rem;
	padding: 1rem 1.2rem;
}

.wpcf7-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 1rem;
}

.wpcf7-form input:not([type="checkbox"]):not([type="submit"]),
.wpcf7-form select,
.wpcf7-form textarea {
  box-sizing: border-box;
  width: 100%;
  min-height: 48px;
  margin-top: .4rem;
  padding: .8rem .9rem;
  border: 2px solid var(--wp--preset--color--ink);
  border-radius: 2px;
  background: var(--wp--preset--color--paper);
  color: var(--wp--preset--color--ink);
  font: inherit;
}

.wpcf7-form textarea { min-height: 10rem; resize: vertical; }
.wpcf7-form input[type="checkbox"] { width: 1.25rem; height: 1.25rem; margin-right: .5rem; }
.wpcf7-form input[type="submit"] {
  min-height: 48px;
  padding: .8rem 1.4rem;
  border: 2px solid var(--wp--preset--color--ink);
  background: var(--wp--preset--color--red);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.wpcf7-form input:focus-visible,
.wpcf7-form select:focus-visible,
.wpcf7-form textarea:focus-visible,
.wpcf7-form input[type="submit"]:focus-visible {
  outline: 3px solid var(--wp--preset--color--gold);
  outline-offset: 3px;
}

.tribe-events .tribe-events-c-top-bar__datepicker-button,
.tribe-events .tribe-events-calendar-list__event-title-link,
.tribe-common a {
	color: var(--es5-red);
}

.tribe-common .tribe-common-c-btn,
.tribe-common a.tribe-common-c-btn {
	background: var(--es5-red);
}

@media (max-width: 900px) {
	.es5-site-header .wp-block-site-tagline {
		display: none;
	}

	.es5-number-card {
		border-bottom: 1px solid var(--es5-rule);
		border-right: 0;
		min-height: 0;
	}

	.es5-image-frame {
		box-shadow: 10px 10px 0 var(--es5-green);
	}

	.es5-mockup-hero {
		grid-template-columns: 1fr;
	}

	.es5-mockup-copy {
		min-height: 560px;
	}

	.es5-photo-collage {
		height: 70vw;
		min-height: 430px;
	}

	.es5-heritage-strip {
		grid-template-columns: repeat(3, 1fr);
	}

	.es5-strip-motto {
		grid-column: 1 / -1;
		min-height: 220px;
	}
}

@media (max-width: 620px) {
	.es5-header-inner {
		min-height: 74px;
	}

	.es5-mockup-copy {
		min-height: 485px;
		padding: 3rem 1.4rem !important;
	}

	.es5-mockup-title {
		font-size: clamp(3.25rem, 16vw, 4.7rem) !important;
	}

	.es5-mockup-title em {
		white-space: normal;
	}

	.es5-mockup-actions .wp-block-button,
	.es5-mockup-actions .wp-block-button__link {
		width: 100%;
	}

	.es5-photo-collage {
		grid-template-columns: 1fr 1fr;
		height: 115vw;
		min-height: 540px;
	}

	.es5-flag-overlay {
		bottom: 0;
		height: 100%;
		right: calc(50% - 6px);
		width: clamp(148px, 42vw, 185px);
	}

	.es5-tile-alps,
	.es5-tile-still {
		clip-path: none;
		margin-left: 0 !important;
		width: 100% !important;
	}

	.es5-heritage-strip {
		grid-template-columns: 1fr;
	}

	.es5-strip-card {
		border-bottom: 1px solid var(--es5-rule);
		border-right: 0;
		min-height: 170px;
	}

	.es5-strip-motto {
		grid-column: auto;
		grid-template-columns: 64px 1fr;
		padding: 2.2rem 1.8rem !important;
	}

	.es5-mountain-line {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}
