/*
Theme Name: Ariadne
Theme URI: https://www.ariadnewealth.com/
Author: Ariadne Wealth Management
Description: Site theme for Ariadne Wealth Management. A child of Twenty Twenty-Five that recreates the original design with core blocks only. Source: Azure DevOps, AriadneWealth/Website, folder theme/ariadne.
Template: twentytwentyfive
Version: 1.0.2
Requires at least: 6.7
Requires PHP: 8.1
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ariadne
*/

/* ---------- Utilities ---------- */
.screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute !important;
	width: 1px;
	word-wrap: normal !important;
}

/* No gaps between the full-width sections that make up each page. */
.wp-site-blocks > * + *,
.ariadne-home > * + * {
	margin-block-start: 0;
}

/* ---------- Header ---------- */
.ariadne-header {
	padding-top: 28px;
	padding-bottom: 28px;
}
.ariadne-header .ariadne-logo img {
	display: block;
	height: auto;
}
.ariadne-header .wp-block-navigation a:hover,
.ariadne-header .wp-block-navigation a:focus {
	color: var(--wp--preset--color--gold);
}
.ariadne-header .wp-block-navigation__responsive-container-open {
	color: var(--wp--preset--color--gold);
}
.ariadne-header .wp-block-navigation__responsive-container.is-menu-open {
	padding: 2rem;
}
.ariadne-header .wp-block-navigation__responsive-container.is-menu-open a {
	color: var(--wp--preset--color--base);
}

/* Front page: the header sits on top of the hero video. */
.ariadne-header--overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	z-index: 20;
}
body.admin-bar .ariadne-header--overlay {
	top: 32px;
}
@media (max-width: 782px) {
	body.admin-bar .ariadne-header--overlay {
		top: 46px;
	}
}
.ariadne-header--overlay .wp-block-navigation-item__content {
	text-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}

/* ---------- Hero ---------- */
.ariadne-hero {
	background: #2f7fb4 url("assets/images/hero-poster.jpg") center / cover no-repeat;
}
.ariadne-hero .wp-block-image img {
	filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.25));
}
@media (max-width: 781px) {
	.ariadne-hero {
		min-height: 60vw !important;
	}
	.ariadne-hero .wp-block-image {
		max-width: 80%;
		margin-left: auto;
		margin-right: auto;
	}
}
@media (prefers-reduced-motion: reduce) {
	.ariadne-hero video {
		display: none;
	}
}

/* ---------- Mission cards ---------- */
.ariadne-card {
	box-shadow: 0 30px 60px rgba(0, 0, 0, 0.08);
	min-height: 290px;
	display: flex;
	flex-direction: column;
	justify-content: center;
}
.ariadne-card h3 {
	margin-bottom: 0.6rem;
}
@media (min-width: 782px) {
	.ariadne-cards-offset {
		margin-top: 37px !important;
	}
}

/* ---------- Team ---------- */
/* Three across, then two, then one; a part-filled last row sits in the middle. */
.ariadne-team-grid > .ariadne-team-member {
	flex: 0 0 calc((100% - 60px) / 3);
}
@media (max-width: 879px) {
	.ariadne-team-grid > .ariadne-team-member {
		flex-basis: calc((100% - 30px) / 2);
	}
}
@media (max-width: 589px) {
	.ariadne-team-grid > .ariadne-team-member {
		flex-basis: 100%;
	}
}
.ariadne-team-member .wp-block-image img {
	box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 3;
	object-fit: cover;
}
.ariadne-team-member h3 {
	margin-top: 1.5rem;
	margin-bottom: 0.5rem;
}
.ariadne-team-member .wp-block-details summary {
	text-align: center;
	color: var(--wp--preset--color--blue);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 600;
	cursor: pointer;
}
.ariadne-team-member .wp-block-details[open] summary {
	margin-bottom: 0.75rem;
}
.ariadne-team-member .wp-block-details p {
	font-size: var(--wp--preset--font-size--text-sm);
	line-height: 1.75;
	color: var(--wp--preset--color--muted);
}

/* ---------- Contact ---------- */
.ariadne-contact .wpforms-container {
	margin: 0 auto;
}
.ariadne-contact .wpforms-container .wpforms-field-label {
	font-weight: 600;
	color: var(--wp--preset--color--contrast);
}
.ariadne-map iframe {
	display: block;
	width: 100%;
	height: 280px;
	border: 0;
	filter: grayscale(1) contrast(0.95);
}
.ariadne-address h3 a {
	color: inherit;
}

/* ---------- Policy pages ---------- */
.ariadne-legal > * {
	max-width: 800px;
	margin-left: 0 !important;
}
.ariadne-legal :is(h2, h3, h4, h5) + * {
	margin-block-start: 0.3rem !important;
}
.ariadne-legal p,
.ariadne-legal li {
	font-size: var(--wp--preset--font-size--text-sm);
	line-height: 1.6;
}

/* ---------- Newsletters ---------- */
/* Paragraph rhythm close to the original site. */
.wp-block-post-content.is-layout-constrained > * + *,
.wp-block-post-content :where(.is-layout-constrained, .is-layout-flow) > * + * {
	margin-block-start: 1.2rem;
}
/* A block set to no bottom margin keeps the next block tight against it, as on the original
   site (this theme spaces blocks with a top margin on the next one instead). */
.wp-block-post-content :is([style*="margin-bottom:0;"], [style*="margin-bottom:0px"], [style$="margin-bottom:0"]) + * {
	margin-block-start: 0;
}

/* On phones, 50px padding in newsletter boxes drops to 20px so the text isn't squeezed
   (the original did this for some boxes). The padding is set inline, hence !important. */
@media (max-width: 599px) {
	.wp-block-post-content [style*="padding-top:50px"] {
		padding-top: 20px !important;
	}
	.wp-block-post-content [style*="padding-right:50px"] {
		padding-right: 20px !important;
	}
	.wp-block-post-content [style*="padding-bottom:50px"] {
		padding-bottom: 20px !important;
	}
	.wp-block-post-content [style*="padding-left:50px"] {
		padding-left: 20px !important;
	}
}

/* Charts drawn twice in the original, wide for larger screens and narrow for phones. */
@media (max-width: 599px) {
	.ariadne-hide-mobile {
		display: none;
	}
}
@media (min-width: 600px) {
	.ariadne-hide-desktop {
		display: none;
	}
}

/* Divider lines stay at text width unless set wide. */
.wp-block-post-content .wp-block-separator.is-style-wide:not(.alignwide):not(.alignfull) {
	max-width: var(--wp--style--global--content-size) !important; /* overrides Twenty Twenty-Five's wide style */
}

/* Pull quotes: serif italic with soft blue quotation marks, as on the original site. */
.wp-block-post-content .wp-block-quote {
	position: relative;
	border: 0;
	margin-left: 0;
	margin-right: 0;
	padding: 0.4em 2.4rem 1.2em;
	font-style: normal;
}
.wp-block-post-content .wp-block-quote p {
	font-family: var(--wp--preset--font-family--amiri);
	font-style: italic;
	font-weight: 400;
	line-height: 1.2;
	opacity: 0.8;
}
.wp-block-post-content .wp-block-quote::before,
.wp-block-post-content .wp-block-quote::after {
	position: absolute;
	font-family: var(--wp--preset--font-family--amiri);
	font-size: 4rem;
	line-height: 1;
	color: rgba(0, 82, 150, 0.4);
}
.wp-block-post-content .wp-block-quote::before {
	content: "\201C";
	left: 0;
	top: -0.1em;
}
.wp-block-post-content .wp-block-quote::after {
	content: "\201D";
	right: 0.4rem;
	bottom: -0.45em;
}

/* Lists converted from the old Otter "icon list" blocks: blue square bullets. */
.ariadne-square-list {
	list-style: square;
	padding-left: 1.25em;
}
.ariadne-square-list li {
	margin-bottom: 0.6em;
}
.ariadne-square-list li::marker {
	color: #219ddc;
	font-size: 1.1em;
}

/* ---------- Footer ---------- */
.ariadne-footer p {
	margin: 0;
	color: #e6e6e6;
}
.ariadne-footer .wp-block-navigation a {
	color: #cfcfcf;
}
.ariadne-footer .wp-block-navigation a:hover,
.ariadne-footer .wp-block-navigation a:focus {
	color: var(--wp--preset--color--gold);
}

/* ---------- Behaviours (assets/js/site.js) ---------- */
html {
	scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}
/* Anchor jumps land below the sticky header. */
#about,
#services,
#team,
#contact {
	scroll-margin-top: 70px;
}

/* Sticky header: a dark translucent bar once you scroll past the top. */
body.ariadne-stuck .ariadne-header {
	position: fixed;
	top: var(--wp-admin--admin-bar--height, 0px);
	left: 0;
	right: 0;
	z-index: 50;
	padding-top: 10px;
	padding-bottom: 10px;
	background-color: rgba(12, 12, 12, 0.75) !important;
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	animation: ariadne-drop 0.25s ease-out;
}
body.ariadne-stuck .ariadne-header .wp-block-navigation-item__content {
	color: #ffffff;
	text-shadow: none;
}
body.ariadne-stuck .ariadne-header .ariadne-logo img {
	width: 140px !important;
	content: url("assets/images/logo-reverse.png");
}
@keyframes ariadne-drop {
	from { transform: translateY(-100%); }
	to { transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
	body.ariadne-stuck .ariadne-header {
		animation: none;
	}
}

/* Current section or page in the menu: gold outline, as on the original site. */
.ariadne-header .wp-block-navigation-item.is-current > .wp-block-navigation-item__content {
	outline: 1px solid var(--wp--preset--color--gold);
	outline-offset: 4px;
	color: var(--wp--preset--color--gold);
}

/* Team bios: the name and photo open a full-screen panel. */
.ariadne-bio-trigger {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	letter-spacing: inherit;
	color: inherit;
	text-align: inherit;
	cursor: pointer;
}
.ariadne-bio-trigger:focus-visible {
	outline: 2px solid var(--wp--preset--color--gold);
	outline-offset: 3px;
}
.ariadne-bio-photo {
	cursor: pointer;
}
.ariadne-bio {
	width: 100vw;
	height: 100vh;
	max-width: none;
	max-height: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: var(--wp--preset--color--base);
	overflow-y: auto;
}
.ariadne-bio::backdrop {
	background: rgba(255, 255, 255, 0.96);
}
.ariadne-bio[open] {
	animation: ariadne-fade 0.3s ease-out;
}
@keyframes ariadne-fade {
	from { opacity: 0; }
	to { opacity: 1; }
}
.ariadne-bio__inner {
	position: relative;
	max-width: 420px;
	margin: 12vh auto 8vh;
	padding: 0 24px;
}
.ariadne-bio__inner h2 {
	font-size: 1.375rem;
	margin: 0 0 1rem;
}
.ariadne-bio__inner p {
	font-size: var(--wp--preset--font-size--text-sm);
	line-height: 1.75;
	color: var(--wp--preset--color--muted);
}
.ariadne-bio__close {
	position: absolute;
	top: -0.4rem;
	right: 0;
	width: 36px;
	height: 36px;
	border: 0;
	background: transparent;
	font-size: 28px;
	line-height: 1;
	color: var(--wp--preset--color--contrast);
	cursor: pointer;
}
html.ariadne-modal-open {
	overflow: hidden;
}

/* Back-to-top button. */
.ariadne-to-top {
	position: fixed;
	right: 24px;
	bottom: 24px;
	z-index: 40;
	width: 48px;
	height: 48px;
	display: grid;
	place-items: center;
	border: 0;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--gold);
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
	cursor: pointer;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s, visibility 0.25s;
}
.ariadne-to-top.is-visible {
	opacity: 1;
	visibility: visible;
}

/* Introduction: elements fade in and drift up as they scroll into view. */
.ariadne-fade {
	opacity: 0;
	transform: translateY(30px);
	transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}
.ariadne-fade.is-in {
	opacity: 1;
	transform: none;
}

/* Mission cards: a block of colour sweeps in, then away to reveal the card. */
.ariadne-card.ariadne-reveal {
	position: relative;
	overflow: hidden;
}
.ariadne-card.ariadne-reveal:not(.is-revealed) {
	background-color: transparent !important;
	box-shadow: none;
}
.ariadne-card.ariadne-reveal > * {
	opacity: 0;
}
.ariadne-card.ariadne-reveal.is-revealed {
	transition: background-color 0s 0.55s, box-shadow 0.4s 0.6s;
}
.ariadne-card.ariadne-reveal.is-revealed > * {
	opacity: 1;
	transition: opacity 0.3s 0.6s;
}
.ariadne-card.ariadne-reveal::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 2;
	transform: scaleX(0);
	transform-origin: left center;
	background: var(--wp--preset--color--sand);
}
.ariadne-card.ariadne-reveal--blue::after {
	background: var(--wp--preset--color--blue);
}
.ariadne-card.ariadne-reveal.is-revealed::after {
	animation: ariadne-wipe 1.1s cubic-bezier(0.77, 0, 0.18, 1) forwards;
}
@keyframes ariadne-wipe {
	0% { transform: scaleX(0); transform-origin: left center; }
	50% { transform: scaleX(1); transform-origin: left center; }
	50.01% { transform: scaleX(1); transform-origin: right center; }
	100% { transform: scaleX(0); transform-origin: right center; }
}
