/*
Theme Name: Nexus
Author: Nexus
Description: A lightweight custom WordPress theme for the Nexus store.
Version: 0.3.2
Requires at least: 6.4
Requires PHP: 8.3
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nexus
*/

/* Fonts are served from this theme rather than an external font service. */
@font-face {
	font-family: "Manrope";
	src: url("assets/fonts/manrope-regular.ttf") format("truetype");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Manrope";
	src: url("assets/fonts/manrope-medium.ttf") format("truetype");
	font-weight: 500;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Italiana";
	src: url("assets/fonts/italiana.ttf") format("truetype");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

:root {
	--nexus-background: #090a08;
	--nexus-text: #f0ede4;
	--nexus-muted: #b8b7af;
	--nexus-paper: #efeade;
	--nexus-border: #3b3c35;
	--nexus-accent: #d9c396;
	--nexus-width: 1350px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 2rem; }
body.nexus-site {
	margin: 0;
	padding: 0;
	background: var(--nexus-background);
	color: var(--nexus-text);
	font-family: "Manrope", sans-serif;
	font-size: 17px;
	line-height: 1.65;
	overflow-wrap: break-word;
}
a { color: inherit; text-underline-offset: .25em; }
/* The imported Elementor page has its own padding; the coded homepage owns its gutters. */
body.nexus-site.home { padding: 0; }
a:hover { color: var(--nexus-accent); }
:focus-visible { outline: 2px solid var(--nexus-accent); outline-offset: 5px; }
img, video { max-width: 100%; height: auto; }
iframe { max-width: 100%; }
button, input, select, textarea { font: inherit; }
.nexus-container { width: min(var(--nexus-width), calc(100% - 6.1vw)); margin-inline: auto; }
.nexus-header {
	min-height: 60px;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	flex-wrap: wrap;
	gap: 70px;
	padding-block: 8px;
	border-bottom: 1px solid var(--nexus-border);
}
.nexus-wordmark { font-size: 17px; letter-spacing: .72em; text-decoration: none; }
.nexus-wordmark.nexus-brandmark { display: inline-flex; align-items: center; min-height: 44px; flex-shrink: 0; letter-spacing: 0; line-height: 1; }
.nexus-logo-frame { position: relative; display: block; width: 172px; height: 46px; overflow: hidden; flex-shrink: 0; }
.nexus-brandmark .nexus-logo { position: absolute; display: block; width: 137%; max-width: none; height: auto; left: -19%; top: 50%; transform: translateY(-50%); }
.nexus-brandmark--footer .nexus-logo-frame { width: 148px; height: 40px; }
@media (max-width: 600px) {
	.nexus-logo-frame { width: 144px; height: 40px; }
	.nexus-brandmark--footer .nexus-logo-frame { width: 140px; height: 38px; }
}
body.nexus-site .nexus-wordmark,
body.nexus-site .nexus-menu a { color: var(--nexus-text); }
body.nexus-site .nexus-wordmark:hover,
body.nexus-site .nexus-menu a:hover { color: var(--nexus-accent); }
.nexus-menu { display: flex; flex-wrap: wrap; gap: 14px 48px; padding: 0; margin: 0; list-style: none; font-size: 14px; }
.nexus-menu a { text-decoration: none; }
.nexus-menu .current-menu-item > a { text-decoration: underline; }
.nexus-header a { min-height: 44px; display: inline-flex; align-items: center; }
body.nexus-site .nexus-utility-navigation a { color: var(--nexus-text); text-decoration: none; }
body.nexus-site .nexus-utility-navigation a:hover { color: var(--nexus-accent); text-decoration: underline; }
.nexus-utility-navigation { display: flex; align-items: center; gap: 36px; margin-left: auto; font-size: 14px; }

/* Opening section: the artwork is decorative; the wordmark and note are live text. */
.nexus-home-main { padding-bottom: 36px; }
.nexus-home-main:focus { outline: none; }
.nexus-masthead { position: relative; display: grid; grid-template-columns: 68% 32%; align-items: center; min-height: 254px; isolation: isolate; background: var(--nexus-background); }
.nexus-masthead::before {
	content: "";
	position: absolute;
	inset: 0 30% 0 0;
	background: url("assets/images/masthead-background.webp") no-repeat;
	background-size: 142.86% auto;
	background-position: 56px calc(50% - 15px);
	opacity: .6;
	mix-blend-mode: lighten;
	pointer-events: none;
}
body.nexus-site .nexus-masthead-title {
	position: relative;
	z-index: 1;
	margin: 0 0 0 -.065em;
	font-family: "Italiana", Georgia, serif;
	font-size: clamp(100px, 16.45vw, 236px);
	font-weight: 400;
	line-height: 1;
	letter-spacing: .075em;
	color: var(--nexus-text);
	width: max-content;
	transform: scaleX(1.13);
	transform-origin: left center;
}
body.nexus-site .nexus-masthead-note {
	position: relative;
	z-index: 1;
	align-self: center;
	margin: 56px 0 0 0;
	font-family: "Consolas", "Liberation Mono", monospace;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.6;
	letter-spacing: .025em;
	color: var(--nexus-text);
}
.nexus-masthead-art { position: absolute; right: -19px; top: 19px; width: 235px; height: 207px; object-fit: contain; pointer-events: none; z-index: 0; mix-blend-mode: lighten; }
.nexus-main { min-height: 65vh; padding-block: 64px 80px; }
.nexus-entry + .nexus-entry { margin-top: 48px; }
.nexus-page-title { margin: 0 0 32px; font-weight: 400; font-size: clamp(36px, 5vw, 64px); line-height: 1.12; letter-spacing: -.035em; }
.nexus-content > :first-child { margin-top: 0; }
.nexus-content > :last-child { margin-bottom: 0; }
.nexus-content p { max-width: 70ch; }
.nexus-content .alignwide { max-width: 100%; }
.nexus-content .alignfull { width: 100%; margin-inline: 0; }
.nexus-footer { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 24px; padding-block: 28px; border-top: 1px solid var(--nexus-border); }
.nexus-footer small { color: var(--nexus-muted); font-size: 12px; }
.nexus-skip-link { position: absolute; left: 20px; top: 12px; z-index: 100000; padding: 10px 16px; background: var(--nexus-paper); color: #11120e; transform: translateY(-200%); }
.nexus-skip-link:focus { transform: translateY(0); }
.screen-reader-text { border: 0; clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; white-space: nowrap; }

@media (min-width: 1680px) {
	.nexus-masthead { min-height: 280px; }
}

@media (max-width: 1200px) {
	.nexus-header { gap: 32px; }
	.nexus-menu { column-gap: 30px; }
	.nexus-utility-navigation { gap: 20px; }
	.nexus-masthead { min-height: 225px; }
	.nexus-masthead-art { width: 210px; height: 156px; top: 0; right: -8px; }
	body.nexus-site .nexus-masthead-note { align-self: end; margin: 0 0 18px; font-size: 12px; }
}

@media (max-width: 600px) {
	body.nexus-site { font-size: 16px; }
	.nexus-container { width: calc(100% - 40px); }
	.nexus-main { padding-block: 40px 56px; }
	.nexus-header { display: grid; grid-template-columns: auto 1fr; gap: 0 18px; }
	.nexus-primary-navigation { grid-row: 2; grid-column: 1 / -1; }
	.nexus-utility-navigation { grid-column: 2; grid-row: 1; gap: 20px; font-size: 12px; }
	.nexus-menu { gap: 10px 20px; }
	.nexus-masthead::before { display: none; }
	.nexus-masthead { min-height: 205px; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; padding-top: 24px; }
	body.nexus-site .nexus-masthead-title { margin-left: -.015em; font-size: clamp(76px, 22.5vw, 135px); letter-spacing: .075em; line-height: 1.05; transform: none; }
	body.nexus-site .nexus-masthead-note { align-self: flex-start; margin: 18px 0 0; font-size: 12px; line-height: 1.6; }
	.nexus-masthead-art { width: 126px; height: 126px; top: 78px; right: -6px; opacity: .8; }
	.nexus-home-main { padding-bottom: 24px; }
	.nexus-footer { align-items: flex-start; }
}

/* Collection: the journal and worksheet meet like an opened book. */
.nexus-home-main { padding-bottom: 0; }
.nexus-collection { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); gap: 46px; align-items: start; }
.nexus-product-visuals { display: grid; grid-template-columns: 355fr 303fr 317fr; min-width: 0; align-items: start; }
body.nexus-site .nexus-cover-button { display: block; min-width: 0; padding: 0; margin: 0; border: 0; border-radius: 0; background: none; line-height: 0; text-decoration: none; transition: filter .2s; }
body.nexus-site .nexus-cover-button:hover { filter: brightness(1.06); }
body.nexus-site .nexus-guide-art { margin-right: 19px; margin-top: 1px; }
.nexus-cover-button img { display: block; width: 100%; height: auto; }
body.nexus-site .nexus-page-art { margin-top: 17px; aspect-ratio: 316 / 506; overflow: hidden; }
.nexus-page-art img { height: 100%; object-fit: cover; object-position: center; }
body.nexus-site .nexus-eyebrow { margin: 0 0 10px; font-family: "Consolas", "Liberation Mono", monospace; font-size: 11px; font-weight: 400; letter-spacing: .26em; line-height: 18px; text-transform: uppercase; color: var(--nexus-text); }
body.nexus-site .nexus-collection-copy h2 { margin: 0 0 20px; font-family: "Manrope", sans-serif; font-size: clamp(38px, 3.78vw, 56px); font-weight: 400; line-height: 1.08; letter-spacing: -.05em; color: var(--nexus-text); }
.nexus-short-rule { display: block; width: 20px; height: 1px; margin-bottom: 16px; background: var(--nexus-text); }
body.nexus-site .nexus-collection-description { margin: 0 0 16px; font-family: "Manrope", sans-serif; font-size: 17px; line-height: 1.55; font-weight: 400; color: var(--nexus-text); }
.nexus-collection-contents { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--nexus-border); }
.nexus-collection-contents li { display: grid; grid-template-columns: 32px minmax(0, 1fr); column-gap: 26px; align-items: center; min-height: 48px; padding-block: 10px; border-bottom: 1px solid var(--nexus-border); font-size: 15px; line-height: 1.5; }
.nexus-collection-contents li > :first-child { font-family: "Consolas", "Liberation Mono", monospace; font-size: 16px; letter-spacing: .06em; }
body.nexus-site .nexus-collection-meta { display: flex; justify-content: space-between; gap: 10px; margin: 15px 0 24px; font-size: 14px; line-height: 22px; letter-spacing: .02em; color: var(--nexus-muted); }
body.nexus-site .nexus-collection-cta { display: flex; min-height: 56px; width: 100%; align-items: center; justify-content: center; gap: 10px; padding: 13px 18px; border: 1px solid var(--nexus-paper); background: var(--nexus-paper); color: #11120e; font-size: 15px; font-weight: 500; line-height: 1.6; letter-spacing: -.02em; text-decoration: none; transition: background .2s; }
body.nexus-site .nexus-collection-cta:hover { background: #fffaf0; }
.nexus-collection-cta img { flex: 0 0 18px; }
body.nexus-site .nexus-sample-link { display: block; width: max-content; max-width: 100%; margin: 18px auto 0; font-size: 15px; line-height: 22px; text-decoration: none; border-bottom: 1px solid currentColor; color: var(--nexus-text); }
body.nexus-site .nexus-sample-link:hover { color: var(--nexus-accent); }

/* Reflect / Choose / Practice. Illustrations are individual raster assets. */
.nexus-practice-strip { display: grid; grid-template-columns: 480fr 480fr 387fr; margin-top: 43px; min-height: 124px; border-top: 1px solid var(--nexus-border); }
.nexus-practice-step { position: relative; display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 22px; align-items: center; padding-left: 30px; padding-bottom: 14px; }
.nexus-practice-icon { display: block; width: 86px; height: 86px; object-fit: contain; mix-blend-mode: lighten; }
.nexus-practice-step:first-child .nexus-practice-icon { transform: translateX(4px); }
.nexus-practice-step:last-child .nexus-practice-icon { transform: translateX(-9px); }
body.nexus-site .nexus-practice-step h2 { margin: 0 0 1px; font-family: "Manrope", sans-serif; font-size: 21px; font-weight: 500; line-height: 1.4; letter-spacing: -.025em; color: var(--nexus-text); }
body.nexus-site .nexus-practice-step p { margin: 0; font-size: 14px; font-weight: 400; line-height: 1.6; letter-spacing: .015em; color: var(--nexus-text); }
.nexus-step-connector { position: absolute; right: -5px; top: 50%; width: 94px; height: 1px; border-top: 1px solid var(--nexus-border); }
.nexus-step-connector img { position: absolute; right: -1px; top: -2px; width: 3px; height: 3px; }
.nexus-practice-step:nth-child(2) .nexus-step-connector { right: 17px; width: 144px; }

/* Shared minimal footer. */
.nexus-footer { min-height: 83px; align-items: flex-start; padding-block: 22px 28px; }
.nexus-footer .nexus-wordmark { font-size: 14px; letter-spacing: .6em; line-height: 22px; }
.nexus-footer .nexus-menu { column-gap: 34px; font-size: 12px; line-height: 22px; }
body.nexus-site .nexus-footer .nexus-menu a, body.nexus-site .nexus-footer .nexus-wordmark { color: var(--nexus-muted); }
body.nexus-site .nexus-footer-link { display: inline; padding: 0; margin: 0; border: 0; border-radius: 0; background: none; color: var(--nexus-muted); font: inherit; cursor: pointer; }
body.nexus-site .nexus-footer-link:hover { color: var(--nexus-accent); }

/* Native dialogs keep focus inside the preview and support Escape to close. */
body.nexus-modal-open { overflow: hidden; }
.nexus-dialog { width: min(850px, calc(100% - 48px)); max-width: none; max-height: calc(100dvh - 48px); padding: 28px 32px; border: 1px solid var(--nexus-border); background: var(--nexus-background); color: var(--nexus-text); overscroll-behavior: contain; }
.nexus-dialog::backdrop { background: rgb(0 0 0 / .82); }
.nexus-dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
body.nexus-site .nexus-dialog h2 { margin: 0 0 20px; font-family: "Italiana", Georgia, serif; font-size: 42px; font-weight: 400; line-height: 1.15; letter-spacing: -.02em; color: var(--nexus-text); }
body.nexus-site .nexus-dialog-close { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 44px; width: 44px; height: 44px; padding: 10px; margin: -8px -10px 0 0; border: 0; border-radius: 0; background: none; color: var(--nexus-text); cursor: pointer; }
.nexus-preview-tabs { display: flex; gap: 28px; border-bottom: 1px solid var(--nexus-border); margin-bottom: 22px; }
body.nexus-site .nexus-preview-tabs button { min-height: 44px; padding: 10px 0; border: 0; border-bottom: 1px solid transparent; border-radius: 0; background: none; color: var(--nexus-muted); font-family: "Manrope", sans-serif; font-size: 14px; font-weight: 400; cursor: pointer; }
body.nexus-site .nexus-preview-tabs button[aria-selected="true"] { border-bottom-color: var(--nexus-text); color: var(--nexus-text); }
.nexus-preview-panel { text-align: center; }
.nexus-preview-panel[hidden] { display: none; }
.nexus-preview-panel img { display: block; width: auto; height: min(61dvh, 650px); max-width: 100%; object-fit: contain; margin-inline: auto; }
.nexus-terms-dialog { width: min(540px, calc(100% - 48px)); }
.nexus-terms-dialog p { margin: 0 0 20px; color: var(--nexus-muted); }

@media (max-width: 1200px) {
	.nexus-collection { grid-template-columns: minmax(0, 2.5fr) minmax(260px, 1fr); gap: 28px; }
	body.nexus-site .nexus-guide-art { margin-right: 12px; }
	body.nexus-site .nexus-page-art { margin-top: 12px; }
	body.nexus-site .nexus-collection-copy h2 { font-size: 42px; }
	body.nexus-site .nexus-collection-description { font-size: 15px; }
	.nexus-collection-contents li { font-size: 13px; column-gap: 12px; }
	body.nexus-site .nexus-collection-meta { font-size: 12px; gap: 6px; }
	.nexus-practice-strip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.nexus-practice-step { grid-template-columns: 65px minmax(0, 1fr); gap: 12px; padding-left: 0; }
	.nexus-practice-icon { width: 65px; height: 65px; }
	.nexus-practice-step:first-child .nexus-practice-icon, .nexus-practice-step:last-child .nexus-practice-icon { transform: none; }
	.nexus-step-connector { display: none; }
	body.nexus-site .nexus-practice-step h2 { font-size: 19px; }
	body.nexus-site .nexus-practice-step p { font-size: 12px; }
}

@media (max-width: 900px) {
	.nexus-collection { grid-template-columns: minmax(0, 1fr); gap: 32px; }
	.nexus-collection-copy { max-width: 620px; }
	body.nexus-site .nexus-collection-copy h2 { font-size: 48px; }
	body.nexus-site .nexus-collection-description { max-width: 42ch; font-size: 17px; }
	body.nexus-site .nexus-collection-meta { justify-content: flex-start; gap: 18px; font-size: 14px; }
	.nexus-collection-contents li { font-size: 15px; }
	.nexus-practice-step { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; padding-block: 18px; }
	.nexus-practice-strip { gap: 20px; }
}

@media (max-width: 600px) {
	.nexus-collection { gap: 28px; }
	body.nexus-site .nexus-guide-art { margin-right: 7px; }
	body.nexus-site .nexus-page-art { margin-top: 6px; }
	body.nexus-site .nexus-eyebrow { font-size: 10px; }
	body.nexus-site .nexus-collection-copy h2 { font-size: 44px; }
	body.nexus-site .nexus-collection-description { font-size: 16px; }
	.nexus-collection-contents li { font-size: 13px; column-gap: 18px; }
	body.nexus-site .nexus-collection-meta { justify-content: space-between; font-size: 12px; gap: 8px; }
	.nexus-practice-strip { grid-template-columns: minmax(0, 1fr); gap: 0; margin-top: 36px; padding-block: 10px; }
	.nexus-practice-step { flex-direction: row; align-items: center; justify-content: flex-start; gap: 22px; padding-block: 14px; }
	.nexus-practice-icon { width: 65px; height: 65px; }
	body.nexus-site .nexus-practice-step h2 { font-size: 20px; }
	body.nexus-site .nexus-practice-step p { font-size: 13px; }
	.nexus-footer { flex-direction: column; gap: 20px; padding-block: 24px; }
	.nexus-footer nav { width: 100%; }
	.nexus-footer .nexus-menu { justify-content: space-between; column-gap: 12px; }
	.nexus-dialog { width: calc(100% - 24px); max-height: calc(100dvh - 24px); padding: 22px; }
	body.nexus-site .nexus-dialog h2 { font-size: 34px; }
	.nexus-preview-tabs { gap: 24px; }
	body.nexus-site .nexus-preview-tabs button { font-size: 12px; }
	.nexus-preview-panel img { height: min(58dvh, 650px); }
}

@media (prefers-reduced-motion: reduce) {
	.nexus-cover-button, .nexus-collection-cta { transition: none; }
}
