/* Advice & Insights. Loaded after the current site stylesheet. */

.preview-site {
	--preview-sage: #dce9e5;
	--preview-cream: #f4efe7;
	min-height: 100%;
}

.preview-site * {
	box-sizing: border-box;
}

.skip-link {
	position: fixed;
	left: 16px;
	top: 12px;
	z-index: 3000;
	padding: 10px 14px;
	background: #fff;
	color: #0d3f3e;
	border-radius: 8px;
	transform: translateY(-160%);
	transition: transform 0.2s ease;
}

.skip-link:focus {
	transform: translateY(0);
}

.preview-ribbon {
	position: fixed;
	left: 18px;
	bottom: 18px;
	z-index: 1600;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 13px;
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 999px;
	background: rgba(13, 19, 19, 0.9);
	box-shadow: var(--shadow-md);
	color: #fff;
	font-family: "brandon_textregular", sans-serif;
	font-size: 0.72rem;
	line-height: 1;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	backdrop-filter: blur(10px);
}

.preview-ribbon::before {
	content: "";
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #94d4ce;
	box-shadow: 0 0 0 4px rgba(148, 212, 206, 0.14);
}

/* The live stylesheet scopes its button component to `.section`. Preview-only
   sections are deliberately independent, so give their buttons the complete
   component styling here instead of relying on that ancestor. */
.preview-site .button {
	max-width: none;
	margin: 24px 0 0;
	padding: 0;
	text-align: center;
}

.preview-site .button a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 15px 28px 16px;
	border-radius: 10px 28px 10px 28px;
	background: var(--accent);
	color: #fff;
	font-family: "brandon_textregular", sans-serif;
	font-size: var(--fs-button);
	line-height: 1;
	letter-spacing: var(--tracking-button);
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	transition: 0.3s var(--ease);
	transition-property: background-color, color, transform, box-shadow;
}

.preview-site .button a:hover {
	background: var(--accent-strong);
	color: #fff;
	transform: translateY(-1px);
}

.preview-site #nav #menu-items .wrap {
	max-width: 1500px;
}

.preview-site .article-hero {
	min-height: clamp(470px, 67vh, 650px);
	background-position: center;
}

.preview-site .article-hero .hero {
	background:
		linear-gradient(180deg, rgba(7, 28, 28, 0.35) 0%, rgba(4, 18, 18, 0.84) 100%),
		radial-gradient(ellipse at 78% 20%, rgba(93, 171, 166, 0.26), transparent 52%);
}

.preview-site .article-hero .intro {
	max-width: 900px;
}

.preview-site .article-hero h1 {
	font-size: clamp(2.25rem, 4.5vw, 4.7rem);
	line-height: 0.98;
	letter-spacing: 0.045em;
}

.preview-site .article-hero h2 {
	max-width: 720px;
	margin-left: auto;
	margin-right: auto;
	font-size: clamp(1rem, 0.7vw + 0.88rem, 1.25rem);
	line-height: 1.45;
	text-transform: none;
	letter-spacing: 0.035em;
}

.preview-site .article-hero .button {
	margin-top: 18px;
}

.preview-site .article-hero .button a {
	background: rgba(255, 255, 255, 0.9);
	box-shadow: 0 8px 22px rgba(0, 0, 0, 0.16);
	color: #102524;
}

.preview-site .article-hero .button a:hover {
	background: #fff;
	color: #102524;
}

.preview-site .article-archive-hero {
	min-height: clamp(410px, 52vh, 540px);
	padding-bottom: clamp(38px, 5vw, 54px);
	background-position: center 42%;
}

.preview-site .article-archive-hero .hero {
	background:
		linear-gradient(180deg, rgba(7, 28, 28, 0.28) 0%, rgba(4, 18, 18, 0.78) 100%),
		radial-gradient(ellipse at 78% 20%, rgba(93, 171, 166, 0.3), transparent 52%);
}

.preview-site .article-archive-hero .logo img {
	width: clamp(145px, 13vw, 180px);
}

.preview-site .article-archive-hero .intro {
	max-width: 880px;
}

.preview-site .article-archive-hero h1 {
	font-size: var(--fs-h1);
	line-height: 1.1;
	letter-spacing: var(--tracking-heading);
}

.article-hero-summary {
	max-width: 720px;
	margin: 0 auto;
	color: rgba(221, 245, 243, 0.82);
	font-size: clamp(1rem, 0.7vw + 0.88rem, 1.25rem);
	line-height: 1.5;
	letter-spacing: 0.035em;
	text-wrap: balance;
}

.article-meta-line {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px 22px;
	margin: 0;
	color: rgba(255, 255, 255, 0.78);
	font-family: "brandon_textregular", sans-serif;
	font-size: var(--fs-small);
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.article-meta-line span + span {
	position: relative;
}

.article-meta-line span + span::before {
	content: "·";
	position: absolute;
	left: -14px;
	color: #a7ced4;
}

.article-index {
	position: relative;
	padding: clamp(34px, 4vw, 52px) var(--space-edge) var(--space-section);
	background:
		radial-gradient(circle at 6% 8%, rgba(106, 156, 155, 0.11), transparent 28%),
		linear-gradient(180deg, var(--surface-page), var(--surface-page-soft));
	scroll-margin-top: 72px;
}

.article-index-title {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.article-index-toolbar {
	max-width: 1240px;
	margin: 0 auto clamp(30px, 3.5vw, 42px);
}

.topic-filters {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 6px 10px;
	margin: 0;
}

.topic-filter {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 10px 14px;
	border: 0;
	border-radius: 8px 18px 8px 18px;
	background: transparent;
	color: var(--text-muted);
	font: inherit;
	font-family: "brandon_textregular", sans-serif;
	font-size: var(--fs-small);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: 0.25s ease;
	transition-property: color, background-color, transform;
}

.topic-filter:hover {
	background: var(--surface-tint);
	color: var(--text);
}

.topic-filter[aria-pressed="true"],
.topic-filter[aria-current="page"] {
	background: var(--green);
	color: #fff;
}

.topic-filter[aria-pressed="true"]:hover,
.topic-filter[aria-current="page"]:hover {
	background: var(--green-dark);
	color: #fff;
}

.topic-filter:active {
	transform: translateY(1px);
}

.article-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(30px, 3vw, 44px);
	max-width: 1240px;
	margin: 0 auto;
}

.article-grid.is-filtered {
	grid-template-columns: minmax(0, 580px);
	justify-content: center;
}

.article-grid.is-filtered .article-card {
	grid-column: auto;
	max-width: none;
}

.article-card {
	align-self: stretch;
	min-width: 0;
}

.article-card[hidden] {
	display: none;
}

.article-card-link {
	display: flex;
	flex-direction: column;
	height: 100%;
	overflow: visible;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	color: var(--text);
	text-decoration: none;
	transition: transform 0.35s var(--ease), color 0.3s var(--ease);
}

.article-card-link:hover {
	transform: translateY(-3px);
	color: var(--text);
}

.article-card-image {
	position: relative;
	overflow: hidden;
	aspect-ratio: 3 / 2;
	border-radius: var(--radius-lg);
	background: var(--surface-tint);
	box-shadow: var(--shadow-sm);
	transition: box-shadow 0.35s var(--ease);
}

.article-card-image::after {
	display: none;
}

.article-card-image img {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
	transition: transform 0.7s var(--ease), filter 0.7s var(--ease);
}

.article-card-link:hover .article-card-image img {
	transform: scale(1.025);
	filter: saturate(1.05);
}

.article-card-link:hover .article-card-image {
	box-shadow: var(--shadow-md);
}

.article-card-body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	padding: 20px 3px 0;
}

.preview-site .article-kicker {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	align-self: stretch;
	gap: 6px 16px;
	width: 100%;
	max-width: none;
	margin: 0 0 13px;
	padding: 0;
	color: var(--accent);
	font-family: "brandon_textregular", sans-serif;
	font-size: 0.74rem;
	line-height: 1.2;
	letter-spacing: 0.12em;
	text-align: left;
	text-transform: uppercase;
}

.preview-site .article-kicker span:last-child {
	color: var(--text-soft);
	font-size: 0.7rem;
}

.article-card h3 {
	margin: 0 0 11px;
	color: var(--text);
	font-size: clamp(1.3rem, 0.8vw + 1rem, 1.7rem);
	font-weight: normal;
	line-height: 1.17;
	letter-spacing: 0.025em;
	text-transform: none;
	text-align: left;
	text-wrap: balance;
}

.article-card-copy {
	margin: 0 0 18px;
	color: var(--text-muted);
	font-size: 1rem;
	line-height: 1.55;
}

.article-card-action {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	margin-top: auto;
	padding-top: 8px;
	color: var(--accent);
	font-family: "brandon_textregular", sans-serif;
	font-size: var(--fs-small);
	letter-spacing: 0.11em;
	text-transform: uppercase;
}

.article-empty {
	max-width: 720px;
	margin: 0 auto;
	color: var(--text-muted);
	text-align: center;
}

.tax-ao_topic .article-grid {
	grid-template-columns: minmax(0, 580px);
	justify-content: center;
}

.article-card-action::after {
	content: "→";
	font-size: 1.15em;
	transition: transform 0.25s ease;
}

.article-card-link:hover .article-card-action::after {
	transform: translateX(4px);
}

.editorial-note {
	padding: clamp(34px, 5vw, 64px) var(--space-edge);
	background: var(--surface-section-deep);
	color: var(--text-on-section);
}

.editorial-note-inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 28px 48px;
	align-items: center;
	max-width: 1100px;
	margin: 0 auto;
}

.editorial-note h2,
.editorial-note p {
	margin: 0;
	text-align: left;
	color: var(--text-on-section);
}

.editorial-note h2 {
	margin-bottom: 8px;
	font-size: var(--fs-h3);
}

.editorial-note p {
	max-width: 65ch;
	opacity: 0.82;
}

.editorial-note .button {
	margin: 0;
}

.editorial-note .button a {
	background: #6a9c9b;
	color: #fff;
}

.editorial-note .button a:hover {
	background: #fff;
	color: #164f4d;
}

.article-main {
	background:
		linear-gradient(90deg, rgba(106, 156, 155, 0.07), transparent 24%),
		var(--surface-page);
}

.article-layout {
	display: grid;
	grid-template-columns: 210px minmax(0, 740px);
	gap: clamp(34px, 6vw, 80px);
	justify-content: center;
	align-items: start;
	max-width: 1120px;
	margin: 0 auto;
	padding: var(--space-section) var(--space-edge);
}

.article-aside {
	position: sticky;
	top: 92px;
	padding-top: 4px;
}

.article-aside-item + .article-aside-item {
	margin-top: 22px;
}

.article-aside-label {
	margin: 0 0 8px;
	color: var(--text-soft);
	font-family: "brandon_textregular", sans-serif;
	font-size: 0.7rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.article-aside-value {
	margin: 0;
	color: var(--text);
	font-size: 0.95rem;
	line-height: 1.45;
}

.article-aside a {
	color: var(--accent);
	text-underline-offset: 3px;
}

.article-prose {
	min-width: 0;
}

.article-prose .article-lead {
	margin: 0 0 26px;
	color: var(--text);
	font-size: clamp(1.3rem, 1vw + 1rem, 1.7rem);
	line-height: 1.48;
	text-wrap: pretty;
}

.article-prose > p:not(.article-lead) {
	margin: 0 0 22px;
	color: var(--text);
	font-size: clamp(1.05rem, 0.2vw + 1rem, 1.16rem);
	line-height: 1.75;
}

.article-prose h2 {
	margin: 42px 0 15px;
	color: var(--text);
	font-size: clamp(1.35rem, 0.9vw + 1rem, 1.7rem);
	line-height: 1.2;
	letter-spacing: 0.035em;
	text-align: left;
	text-transform: none;
}

.safety-note {
	margin: 34px 0;
	padding: 24px 26px;
	border-left: 4px solid var(--accent);
	border-radius: 0 var(--radius-md) var(--radius-md) 0;
	background: var(--surface-tint-soft);
}

.safety-note h2 {
	margin-top: 0;
	font-size: 1.08rem;
	font-family: "brandon_textregular", sans-serif;
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

.safety-note p {
	margin: 0;
	color: var(--text-muted);
	font-size: 0.98rem;
	line-height: 1.6;
}

.exercise-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 14px;
	margin: 28px 0 8px;
	counter-reset: exercise;
}

.exercise-card {
	position: relative;
	padding: 24px;
	border: 1px solid var(--border-subtle);
	border-radius: var(--radius-md);
	background: var(--surface-tint-soft);
	counter-increment: exercise;
}

.exercise-card::before {
	content: "0" counter(exercise);
	display: block;
	margin-bottom: 22px;
	color: var(--accent);
	font-family: "brandon_textblack", sans-serif;
	font-size: 1.4rem;
	letter-spacing: 0.08em;
}

.exercise-card h2 {
	margin: 0 0 10px;
	font-size: 1.12rem;
	font-family: "brandon_textregular", sans-serif;
	text-transform: uppercase;
	letter-spacing: 0.07em;
}

.exercise-card p {
	margin: 0;
	color: var(--text-muted);
	font-size: 0.96rem;
	line-height: 1.58;
}

.article-sources {
	margin-top: 42px;
	padding-top: 24px;
	border-top: 1px solid var(--border-subtle);
}

.article-sources h2 {
	margin-top: 0;
	font-size: 1rem;
	font-family: "brandon_textregular", sans-serif;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.article-sources ul {
	display: grid;
	margin: 0;
	padding: 0;
	color: var(--text-muted);
	font-size: 0.92rem;
	line-height: 1.55;
	list-style: none;
	counter-reset: source;
}

.article-sources li {
	display: grid;
	grid-template-columns: 2rem minmax(0, 1fr);
	gap: 12px;
	align-items: baseline;
	margin: 0;
	padding: 12px 0;
	border-top: 1px solid var(--border-subtle);
	counter-increment: source;
}

.article-sources li:last-child {
	border-bottom: 1px solid var(--border-subtle);
}

.article-sources li::before {
	content: counter(source, decimal-leading-zero);
	color: var(--text-soft);
	font-family: "brandon_textregular", sans-serif;
	font-size: 0.72rem;
	letter-spacing: 0.08em;
}

.article-sources a {
	color: var(--accent);
	text-decoration: none;
	text-underline-offset: 3px;
}

.article-sources a:hover {
	color: var(--text);
	text-decoration: underline;
}

.article-cta {
	padding: clamp(44px, 7vw, 86px) var(--space-edge);
	background:
		radial-gradient(circle at 80% 25%, rgba(167, 206, 212, 0.23), transparent 30%),
		var(--surface-section);
	color: var(--text-on-section);
	text-align: center;
}

.article-cta-inner {
	max-width: 760px;
	margin: 0 auto;
}

.article-cta h2,
.related-section > h2 {
	padding: 0;
	font-family: "brandon_textregular", sans-serif;
	font-size: var(--fs-h2);
	font-weight: normal;
	line-height: 1.2;
	letter-spacing: var(--tracking-heading);
	text-align: center;
	text-transform: uppercase;
	text-wrap: balance;
}

.article-cta h2 {
	margin: 0 auto 14px;
	color: var(--text-on-section);
}

.article-cta p:not(.button) {
	max-width: 60ch;
	margin: 0 auto;
	color: var(--text-on-section);
	opacity: 0.85;
	font-size: var(--fs-lead);
}

.article-cta .button a {
	background: #fff;
	color: #164f4d;
}

.article-cta .button a:hover {
	background: var(--surface-section-deep);
	color: #fff;
}

.related-section {
	padding: var(--space-section) var(--space-edge);
	background: var(--surface-tint);
}

.related-section > h2 {
	margin: 0 auto 30px;
	color: var(--text);
}

.related-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px;
	max-width: 920px;
	margin: 0 auto;
}

.related-card {
	display: grid;
	grid-template-columns: 126px minmax(0, 1fr);
	min-height: 132px;
	overflow: hidden;
	border: 1px solid var(--border-subtle);
	border-radius: var(--radius-md);
	background: var(--surface-elevated);
	box-shadow: var(--shadow-sm);
	color: var(--text);
	text-decoration: none;
	transition: 0.3s var(--ease);
	transition-property: transform, box-shadow;
}

.related-card:hover {
	transform: translateY(-3px);
	box-shadow: var(--shadow-md);
	color: var(--text);
}

.related-card img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.related-card-copy {
	display: flex;
	flex-direction: column;
	justify-content: center;
	padding: 18px 20px;
}

.related-card-copy span {
	margin-bottom: 8px;
	color: var(--accent);
	font-family: "brandon_textregular", sans-serif;
	font-size: 0.7rem;
	letter-spacing: 0.11em;
	text-transform: uppercase;
}

.related-card-copy strong {
	color: var(--text);
	font-size: 1.05rem;
	font-weight: normal;
	line-height: 1.25;
}

.preview-site .footer {
	margin-top: 0;
}

@media (max-width: 980px) {
	.article-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.article-card:nth-child(odd):last-child:not(:first-child) {
		grid-column: 1 / -1;
		max-width: calc(50% - 10px);
		justify-self: center;
	}

	.article-layout {
		grid-template-columns: 1fr;
		gap: 30px;
	}

	.article-aside {
		position: static;
		display: grid;
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 8px 22px;
		padding-bottom: 24px;
		border-bottom: 1px solid var(--border-subtle);
	}

	.article-aside-item + .article-aside-item {
		margin-top: 0;
	}
}

@media (max-width: 850px) {
	.preview-site #menu-items.is-open {
		display: block !important;
	}

	.preview-site .article-hero {
		min-height: 560px;
	}

	.preview-site .article-archive-hero {
		min-height: clamp(430px, 70vh, 500px);
	}

	.article-index {
		padding-top: 36px;
	}

	.article-index-toolbar {
		margin: 0 auto 28px;
	}

	.topic-filters {
		flex-wrap: nowrap;
		justify-content: flex-start;
		overflow-x: auto;
		padding: 2px 0 8px;
		scrollbar-width: none;
		scroll-snap-type: x proximity;
		overscroll-behavior-x: contain;
	}

	.topic-filters::-webkit-scrollbar {
		display: none;
	}

	.topic-filter {
		flex: 0 0 auto;
		scroll-snap-align: start;
	}

	.editorial-note-inner {
		grid-template-columns: 1fr;
		text-align: center;
	}

	.editorial-note h2,
	.editorial-note p {
		text-align: center;
	}

	.editorial-note .button {
		text-align: center;
	}

	.related-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 640px) {
	.preview-ribbon {
		left: 12px;
		bottom: 12px;
	}

	.preview-site .article-hero h1 {
		font-size: clamp(2rem, 11vw, 3.15rem);
	}

	.article-meta-line {
		gap: 5px 12px;
	}

	.article-meta-line span + span::before {
		display: none;
	}

	.article-grid {
		grid-template-columns: 1fr;
		gap: 36px;
	}

	.article-card-body {
		padding: 17px 2px 0;
	}

	.article-card:nth-child(odd):last-child:not(:first-child) {
		grid-column: auto;
		max-width: none;
	}

	.article-aside {
		grid-template-columns: 1fr;
	}

	.article-aside-label:not(:first-child) {
		margin-top: 10px;
	}

	.exercise-grid {
		grid-template-columns: 1fr;
	}

	.article-layout {
		padding-left: 22px;
		padding-right: 22px;
	}

	.related-card {
		grid-template-columns: 98px minmax(0, 1fr);
	}
}

@media (prefers-reduced-motion: reduce) {
	.article-card-link,
	.article-card-image img,
	.article-card-action::after,
	.related-card,
	.topic-filter,
	.skip-link {
		transition: none;
	}
}

/* The Articles item is a section parent on detail/topic pages, not a disabled
   current-page control. Keep the active treatment while restoring link affordance. */
#nav #menu-items a.current.section-parent-link,
#nav #menu-items a.current.section-parent-link:hover {
	cursor: pointer;
}
