/*
Theme Name: Forensica
Theme URI: https://forensicentomology.online
Author: Design Waves
Description: A fast, AdSense-ready knowledge hub theme for forensic entomology: articles, a history timeline, publications, tools, and an expert directory by country. Includes required policy pages, ads.txt, structured data, and smooth page transitions.
Version: 1.0.0
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: forensica
Tags: blog, education, custom-menu, custom-logo, featured-images, threaded-comments, translation-ready, accessibility-ready
*/

/* ---------- Tokens ---------- */
:root {
	--bg: #f6f4ee;
	--bg-alt: #eeebe2;
	--surface: #ffffff;
	--ink: #14201b;
	--ink-2: #2c3a33;
	--muted: #5d6a63;
	--line: #e0dbcd;
	--accent: #c8861d;
	--accent-ink: #8d5c0c;
	--accent-soft: #f4e6cc;
	--forest: #1d3a2f;
	--forest-2: #26493b;
	--on-forest: #f3efe4;
	--shadow: 0 1px 2px rgba(20, 32, 27, .06), 0 8px 24px -12px rgba(20, 32, 27, .18);
	--shadow-lg: 0 2px 4px rgba(20, 32, 27, .06), 0 24px 48px -20px rgba(20, 32, 27, .28);
	--font-serif: "Fraunces", "Iowan Old Style", Georgia, serif;
	--font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--radius: 14px;
	--radius-sm: 8px;
	--ease: cubic-bezier(.22, .8, .24, 1);
	--ease-in-out: cubic-bezier(.65, 0, .35, 1);
	--header-h: 72px;
	--container: 1200px;
	color-scheme: light;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #0d1411;
		--bg-alt: #111a16;
		--surface: #151f1b;
		--ink: #ece8dd;
		--ink-2: #d4d0c5;
		--muted: #9aa69f;
		--line: #24322c;
		--accent: #e3a646;
		--accent-ink: #e9b25a;
		--accent-soft: #2b2416;
		--forest: #16241e;
		--forest-2: #1d3029;
		--shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .6);
		--shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 24px 48px -20px rgba(0, 0, 0, .7);
		color-scheme: dark;
	}
}
:root[data-theme="dark"] {
	--bg: #0d1411;
	--bg-alt: #111a16;
	--surface: #151f1b;
	--ink: #ece8dd;
	--ink-2: #d4d0c5;
	--muted: #9aa69f;
	--line: #24322c;
	--accent: #e3a646;
	--accent-ink: #e9b25a;
	--accent-soft: #2b2416;
	--forest: #16241e;
	--forest-2: #1d3029;
	--shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .6);
	--shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 24px 48px -20px rgba(0, 0, 0, .7);
	color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font: 400 1.0625rem/1.65 var(--font-sans);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
	transition: background-color .4s var(--ease), color .4s var(--ease);
	overflow-x: hidden;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
h1, h2, h3, h4 { font-family: var(--font-serif); font-weight: 600; line-height: 1.15; letter-spacing: -.015em; margin: 0 0 .5em; font-optical-sizing: auto; }
p { margin: 0 0 1em; }
::selection { background: var(--accent); color: #1a1205; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -100px; z-index: 1000; padding: 10px 16px; background: var(--ink); color: var(--bg); border-radius: var(--radius-sm); transition: top .2s; }
.skip-link:focus { top: 12px; }
.icon { flex: none; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 24px; }
.container--narrow { max-width: 820px; }
@media (max-width: 600px) { .container { padding-inline: 16px; } }

/* ---------- Buttons & links ---------- */
.btn {
	display: inline-flex; align-items: center; gap: .55em;
	padding: .85em 1.35em; border-radius: 999px; border: 1px solid transparent;
	font: 600 .95rem/1 var(--font-sans); text-decoration: none; cursor: pointer;
	transition: transform .3s var(--ease), background-color .3s, color .3s, border-color .3s, box-shadow .3s;
}
.btn .icon { width: 18px; height: 18px; transition: transform .35s var(--ease); }
.btn:hover .icon--arrow { transform: translateX(4px); }
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--ink); color: var(--bg); }
.btn--primary:hover { background: var(--accent); color: #1a1205; box-shadow: 0 10px 24px -10px var(--accent); }
.btn--ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn--ghost:hover { border-color: var(--ink); }
.btn--light { background: var(--on-forest); color: var(--forest); }
.btn--light:hover { background: var(--accent); color: #1a1205; }
.btn--sm { padding: .6em 1em; font-size: .875rem; }

.link-arrow { display: inline-flex; align-items: center; gap: .4em; font-weight: 600; font-size: .95rem; text-decoration: none; color: var(--ink); background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .4s var(--ease), color .3s; padding-bottom: 2px; }
.link-arrow:hover { background-size: 100% 1px; color: var(--accent-ink); }
.link-arrow .icon { width: 16px; height: 16px; transition: transform .35s var(--ease); }
.link-arrow:hover .icon--arrow { transform: translateX(4px); }
.link-arrow--muted { color: var(--muted); }

.eyebrow { font: 600 .78rem/1.3 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--accent-ink); margin-bottom: 1rem; display: flex; align-items: center; gap: .7em; }
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; transform-origin: left; transition: transform .8s var(--ease) .2s; }
.js .reveal:not(.is-in) .eyebrow::before, .js .eyebrow.reveal:not(.is-in)::before { transform: scaleX(0); }

.tag { display: inline-block; font: 600 .72rem/1 var(--font-sans); letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); margin-bottom: .7rem; }

.chips { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.5rem 0 0; padding: 0; }
.chip { display: inline-block; padding: .45em .95em; border: 1px solid var(--line); border-radius: 999px; font-size: .875rem; text-decoration: none; color: var(--ink-2); background: var(--surface); transition: border-color .25s, background-color .25s, color .25s, transform .25s var(--ease); }
.chip:hover { border-color: var(--ink); transform: translateY(-2px); }
.chip.is-active { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chips--small .chip { font-size: .8rem; }

.meta { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; font-size: .85rem; color: var(--muted); }
.meta span { display: inline-flex; align-items: center; gap: .35em; }
.meta .icon { width: 15px; height: 15px; }
.meta__dot { display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: .6; margin-inline: .5rem; vertical-align: middle; }

/* ---------- Header ---------- */
.site-header {
	position: sticky; top: 0; z-index: 50; height: var(--header-h);
	background: color-mix(in srgb, var(--bg) 0%, transparent);
	border-bottom: 1px solid transparent;
	transition: background-color .35s, border-color .35s, transform .45s var(--ease), backdrop-filter .35s;
	view-transition-name: site-header;
}
.site-header.is-scrolled { background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-color: var(--line); }
.site-header.is-hidden { transform: translateY(-100%); }
.site-header__inner { height: 100%; display: flex; align-items: center; gap: 1.5rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); flex: none; }
.brand__name { font: 600 1.15rem/1 var(--font-serif); letter-spacing: -.01em; }
.brand__logo { max-height: 44px; width: auto; }
.brand__mark { transition: transform .6s var(--ease); }
.brand:hover .brand__mark { transform: rotate(-12deg) scale(1.05); }

.nav { margin-left: auto; display: flex; align-items: center; gap: 1.25rem; }
.nav__list, .nav ul { list-style: none; display: flex; gap: .25rem; margin: 0; padding: 0; }
.nav__list a { display: block; padding: .5rem .8rem; text-decoration: none; font-size: .95rem; font-weight: 500; color: var(--ink-2); border-radius: 999px; position: relative; transition: color .25s; }
.nav__list a::after { content: ""; position: absolute; left: .8rem; right: .8rem; bottom: .3rem; height: 1.5px; background: var(--accent); transform: scaleX(0); transform-origin: right; transition: transform .4s var(--ease); }
.nav__list a:hover::after, .nav__list .current-menu-item > a::after, .nav__list .current_page_item > a::after, .nav__list .current-menu-ancestor > a::after { transform: scaleX(1); transform-origin: left; }
.nav__list a:hover, .nav__list .current-menu-item > a { color: var(--ink); }
.nav__list li { position: relative; }
.nav__list .sub-menu { position: absolute; top: 100%; left: 0; min-width: 220px; flex-direction: column; padding: .5rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .25s, transform .3s var(--ease), visibility .25s; }
.nav__list li:hover > .sub-menu, .nav__list li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }

.site-header__tools { display: flex; align-items: center; gap: .25rem; }
.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border: 0; background: transparent; color: var(--ink); border-radius: 50%; cursor: pointer; transition: background-color .25s, transform .3s var(--ease); }
.icon-btn:hover { background: var(--bg-alt); }
.icon-btn .icon { width: 20px; height: 20px; }
[data-theme-toggle] .icon--sun { display: none; }
:root[data-theme="dark"] [data-theme-toggle] .icon--sun { display: block; }
:root[data-theme="dark"] [data-theme-toggle] .icon--moon { display: none; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) [data-theme-toggle] .icon--sun { display: block; }
	:root:not([data-theme="light"]) [data-theme-toggle] .icon--moon { display: none; }
}
[data-theme-toggle]:hover .icon { animation: fe-spin .6s var(--ease); }
@keyframes fe-spin { from { transform: rotate(-60deg) scale(.7); } to { transform: none; } }

.nav-toggle { display: none; flex-direction: column; gap: 5px; }
.nav-toggle span { display: block; width: 20px; height: 1.8px; background: currentColor; border-radius: 2px; transition: transform .4s var(--ease), opacity .3s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.8px) rotate(-45deg); }

@media (max-width: 960px) {
	.nav-toggle { display: flex; }
	.nav {
		position: fixed; inset: var(--header-h) 0 0 0; z-index: 40; flex-direction: column; align-items: stretch; gap: 1.5rem;
		padding: 1.5rem 24px 2rem; background: var(--bg); margin: 0;
		clip-path: inset(0 0 100% 0); visibility: hidden; transition: clip-path .55s var(--ease-in-out), visibility .55s;
		overflow-y: auto;
	}
	.nav.is-open { clip-path: inset(0); visibility: visible; }
	.nav__list { flex-direction: column; gap: 0; }
	.nav__list a { font: 500 1.6rem/1.2 var(--font-serif); padding: .7rem 0; border-bottom: 1px solid var(--line); border-radius: 0; }
	.nav__list a::after { display: none; }
	.nav__list .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0 1rem; background: none; }
	.nav__list .sub-menu a { font-size: 1.15rem; }
	.nav.is-open .nav__list > li { animation: fe-rise .6s var(--ease) both; }
	.nav.is-open .nav__list > li:nth-child(2) { animation-delay: .05s; }
	.nav.is-open .nav__list > li:nth-child(3) { animation-delay: .1s; }
	.nav.is-open .nav__list > li:nth-child(4) { animation-delay: .15s; }
	.nav.is-open .nav__list > li:nth-child(5) { animation-delay: .2s; }
	.nav.is-open .nav__list > li:nth-child(6) { animation-delay: .25s; }
	.nav.is-open .nav__list > li:nth-child(n+7) { animation-delay: .3s; }
	.nav__cta { align-self: flex-start; }
	body.nav-open { overflow: hidden; }
}
@keyframes fe-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---------- Search overlay ---------- */
.search-overlay { position: fixed; inset: 0; z-index: 100; background: color-mix(in srgb, var(--bg) 70%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); display: flex; align-items: flex-start; padding-top: 14vh; opacity: 0; transition: opacity .3s; }
.search-overlay.is-open { opacity: 1; }
.search-overlay__panel { display: flex; gap: .75rem; align-items: center; transform: translateY(-16px); transition: transform .45s var(--ease); }
.search-overlay.is-open .search-overlay__panel { transform: none; }
.search-overlay .search-form { flex: 1; box-shadow: var(--shadow-lg); }
.search-form { display: flex; align-items: center; gap: .6rem; padding: .45rem .45rem .45rem 1.1rem; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; transition: border-color .25s, box-shadow .25s; }
.search-form:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.search-form .icon { color: var(--muted); }
.search-form__input { flex: 1; min-width: 0; border: 0; background: none; font: inherit; color: var(--ink); padding: .5rem 0; outline: none; }

/* ---------- Progress ---------- */
.progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60; pointer-events: none; }
.progress__bar { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(var(--p, 0)); }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(3rem, 7vw, 6rem) 0 clamp(2.5rem, 5vw, 4rem); margin-top: calc(var(--header-h) * -1); padding-top: calc(var(--header-h) + clamp(2.5rem, 6vw, 5rem)); overflow: hidden; }
.hero__bg { position: absolute; inset: 0; z-index: -1; mask-image: linear-gradient(#000 70%, transparent); -webkit-mask-image: linear-gradient(#000 70%, transparent); background:
	radial-gradient(60% 50% at 85% 30%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%),
	radial-gradient(50% 60% at 5% 90%, color-mix(in srgb, var(--forest-2) 14%, transparent), transparent 70%);
}
.hero__bg::after { content: ""; position: absolute; inset: 0; opacity: .5; background-image: radial-gradient(color-mix(in srgb, var(--ink) 14%, transparent) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(to bottom, #000, transparent 85%); -webkit-mask-image: linear-gradient(to bottom, #000, transparent 85%); }
.hero__inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.hero__title { font-size: clamp(2.6rem, 6.4vw, 5.2rem); font-weight: 600; line-height: 1.02; letter-spacing: -.03em; margin-bottom: 1.5rem; }
.hero__text { font-size: clamp(1.08rem, 1.6vw, 1.25rem); color: var(--ink-2); max-width: 34em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.hero__visual { margin: 0; color: var(--ink); justify-self: center; width: min(100%, 460px); }
.hero__visual svg { width: 100%; overflow: visible; }
.stage__bg { fill: var(--surface); stroke: var(--line); stroke-width: 1.2; }
.stage text { font-weight: 500; }
.cycle { transform-origin: 200px 200px; }
.cycle__ring { opacity: .35; transform-origin: 200px 200px; animation: fe-rotate 80s linear infinite; }
.cycle__track { stroke-dasharray: 100; stroke-dashoffset: 100; transform: rotate(-90deg); transform-origin: 200px 200px; }
.is-in .cycle__track { animation: fe-draw 2.6s var(--ease-in-out) .3s forwards; }
.stage { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(.6); }
.is-in .stage { animation: fe-pop .7s var(--ease) forwards; animation-delay: calc(.5s + var(--i) * .32s); }
.lens { animation: fe-float 7s ease-in-out infinite; }
@keyframes fe-draw { to { stroke-dashoffset: 0; } }
@keyframes fe-pop { to { opacity: 1; transform: none; } }
@keyframes fe-rotate { to { transform: rotate(360deg); } }
@keyframes fe-float { 0%, 100% { transform: translate(200px, 200px); } 50% { transform: translate(200px, 192px); } }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; margin: clamp(2.5rem, 5vw, 4rem) 0 0; border-top: 1px solid var(--line); }
.stats > div { padding: 1.25rem 1rem 0 0; }
.stats dt { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); order: 2; }
.stats dd { margin: 0; font: 600 clamp(2rem, 3.4vw, 2.75rem)/1 var(--font-serif); }
.stats > div { display: flex; flex-direction: column-reverse; gap: .4rem; }

@media (max-width: 900px) {
	.hero__inner { grid-template-columns: 1fr; }
	.hero__visual { width: min(80%, 360px); order: -1; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(3.5rem, 8vw, 6.5rem) 0; }
.section--tight { padding: clamp(2rem, 5vw, 3.5rem) 0; }
.section--top { padding-top: clamp(1.5rem, 3vw, 2.5rem); }
.section--alt { background: var(--bg-alt); }
.section__head { margin-bottom: clamp(1.75rem, 4vw, 2.75rem); max-width: 720px; }
.section__head--row { max-width: none; display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.section__title { font-size: clamp(1.9rem, 3.8vw, 2.9rem); margin: 0; }

.grid { display: grid; gap: clamp(1.25rem, 2.5vw, 2rem); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid__full { grid-column: 1 / -1; }
@media (max-width: 1024px) { .grid--4 { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 860px) { .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid--2, .grid--3 { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .grid--4 { grid-template-columns: 1fr; } }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

/* ---------- Pillars ---------- */
.pillars { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.pillar { position: relative; display: flex; flex-direction: column; padding: 2rem 1.75rem 4.5rem; text-decoration: none; color: var(--ink); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); overflow: hidden; isolation: isolate; transition: color .45s var(--ease); }
.pillar::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--forest); transform: translateY(101%); transition: transform .6s var(--ease); }
.pillar:hover { color: var(--on-forest); }
.pillar:hover::before { transform: none; }
.pillar__icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: var(--accent-soft); color: var(--accent-ink); margin-bottom: 2.5rem; transition: transform .6s var(--ease), background-color .45s; }
.pillar__icon .icon { width: 22px; height: 22px; }
.pillar:hover .pillar__icon { transform: rotate(-10deg) scale(1.08); background: var(--accent); color: #1a1205; }
.pillar__num { position: absolute; top: 1.75rem; right: 1.75rem; font: 500 .85rem/1 var(--font-sans); opacity: .5; }
.pillar__title { font-size: 1.45rem; margin-bottom: .6rem; }
.pillar__text { font-size: .95rem; opacity: .8; margin: 0; }
.pillar__go { position: absolute; left: 1.75rem; bottom: 1.75rem; width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid currentColor; border-radius: 50%; opacity: .5; transition: opacity .3s, transform .5s var(--ease), background-color .3s; }
.pillar:hover .pillar__go { opacity: 1; transform: translateX(6px); }
@media (max-width: 1024px) { .pillars { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .pillars { grid-template-columns: 1fr; } .pillar { padding-bottom: 4rem; } .pillar__icon { margin-bottom: 1.5rem; } }

/* ---------- Cards ---------- */
.card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .5s var(--ease), box-shadow .5s var(--ease), border-color .3s; }
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-alt); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease); }
.card:hover .card__media img, .card:hover .card__art { transform: scale(1.06); }
.card__art { display: block; width: 100%; height: 100%; transition: transform 1.1s var(--ease);
	--x: calc(30% + var(--seed, 0) * 7%); --y: calc(25% + var(--seed, 0) * 5%);
	background:
		radial-gradient(circle at var(--x) var(--y), color-mix(in srgb, var(--accent) 70%, transparent) 0 13%, transparent 14%),
		repeating-radial-gradient(circle at var(--x) var(--y), transparent 0 18px, rgba(243, 239, 228, .07) 18px 19px),
		linear-gradient(calc(120deg + var(--seed, 0) * 20deg), var(--forest), var(--forest-2));
}
.card__body { padding: 1.4rem 1.5rem 1.5rem; display: flex; flex-direction: column; flex: 1; }
.card__title { font-size: 1.3rem; margin-bottom: .55rem; }
.card__title a { text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .5s var(--ease); }
.card:hover .card__title a { background-size: 100% 1px; }
.card__title a::after { content: ""; position: absolute; inset: 0; }
.card { position: relative; }
.card__excerpt { color: var(--muted); font-size: .95rem; margin-bottom: 1.1rem; }
.card .meta { margin-top: auto; }

/* Publications */
.pub-list { display: flex; flex-direction: column; margin-bottom: 1.5rem; }
.pub { display: grid; grid-template-columns: 64px 1fr; gap: 1.25rem; padding: 1.5rem 0; border-top: 1px solid var(--line); }
.pub:last-child { border-bottom: 1px solid var(--line); }
.pub__year { font: 600 1.05rem/1 var(--font-serif); color: var(--accent-ink); padding-top: .3rem; }
.pub__title { font-size: 1.2rem; margin-bottom: .35rem; }
.pub__title a { text-decoration: none; transition: color .25s; }
.pub__title a:hover { color: var(--accent-ink); }
.pub__cite { font-size: .9rem; color: var(--muted); margin-bottom: .6rem; }
.pub__summary { font-size: .95rem; color: var(--ink-2); margin-bottom: .8rem; }
.pub__actions { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.pub__actions .link-arrow { font-size: .875rem; }
.pub-list--wide .pub { grid-template-columns: 96px 1fr; padding: 2rem 0; }
.pub-list--wide .pub__title { font-size: 1.45rem; }

/* Tools */
.tool-list { display: grid; gap: 1rem; margin-bottom: 1.5rem; }
.tool { position: relative; display: grid; grid-template-columns: 52px 1fr; gap: 1.1rem; padding: 1.25rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .3s; }
.tool:hover { transform: translateX(6px); box-shadow: var(--shadow); border-color: var(--accent); }
.tool__icon { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-ink); overflow: hidden; }
.tool__icon img { width: 100%; height: 100%; object-fit: cover; }
.tool__icon .icon { width: 24px; height: 24px; }
.tool .tag { margin-bottom: .35rem; }
.tool__title { font-size: 1.15rem; margin-bottom: .3rem; }
.tool__title a { text-decoration: none; }
.tool__title a::after { content: ""; position: absolute; inset: 0; }
.tool__text { font-size: .925rem; color: var(--muted); margin: 0; }
.tool__licence { font-size: .8rem; color: var(--muted); margin: .5rem 0 0; font-weight: 600; }

/* Experts */
.expert { position: relative; text-align: center; padding: 1.75rem 1.25rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.expert:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.expert__photo { display: block; text-decoration: none; width: 104px; height: 104px; margin: 0 auto 1.1rem; border-radius: 50%; overflow: hidden; background: var(--accent-soft); box-shadow: 0 0 0 4px var(--surface), 0 0 0 5px var(--line); transition: box-shadow .4s; }
.expert:hover .expert__photo { box-shadow: 0 0 0 4px var(--surface), 0 0 0 6px var(--accent); }
.expert__photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.expert:hover .expert__photo img { transform: scale(1.08); }
.expert__initials { width: 100%; height: 100%; display: grid; place-items: center; font: 600 1.9rem/1 var(--font-serif); color: var(--accent-ink); }
.expert__initials--lg { font-size: 3.2rem; }
.expert__name { font-size: 1.15rem; margin-bottom: .3rem; }
.expert__name a { text-decoration: none; }
.expert__name a::after { content: ""; position: absolute; inset: 0; }
.expert__aff { font-size: .9rem; color: var(--ink-2); margin-bottom: .4rem; }
.expert__country { display: inline-flex; align-items: center; gap: .35em; font-size: .82rem; color: var(--muted); margin-bottom: .5rem; }
.expert__country .icon { width: 14px; height: 14px; }
.expert__focus { font-size: .85rem; color: var(--muted); margin: 0; }

/* Timeline */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline:not(.timeline--row)::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 1px; background: var(--line); }
.timeline__item { position: relative; width: 50%; padding: 0 3rem 3rem 0; }
.timeline__item:nth-child(even) { margin-left: 50%; padding: 0 0 3rem 3rem; }
.timeline__dot { position: absolute; top: 1.5rem; right: -7px; width: 13px; height: 13px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); transition: background-color .4s, transform .5s var(--ease); }
.timeline__item:nth-child(even) .timeline__dot { right: auto; left: -6px; }
.timeline__item.is-in .timeline__dot { background: var(--accent); transform: scale(1.2); transition-delay: .3s; }
.timeline__card { position: relative; padding: 1.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: transform .45s var(--ease), box-shadow .45s; }
.timeline__card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.timeline__year { display: block; font: 600 1.7rem/1 var(--font-serif); color: var(--accent-ink); margin-bottom: .6rem; }
.timeline__title { font-size: 1.2rem; margin-bottom: .3rem; }
.timeline__title a { text-decoration: none; }
.timeline__title a::after { content: ""; position: absolute; inset: 0; }
.timeline__place { font-size: .85rem; color: var(--muted); margin-bottom: .6rem; }
.timeline__card p:last-child { margin: 0; font-size: .95rem; color: var(--ink-2); }
.timeline--row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.timeline--row::before { content: ""; position: absolute; left: 0; right: 0; top: 6px; height: 1px; background: var(--line); }
.timeline--row .timeline__item, .timeline--row .timeline__item:nth-child(even) { width: auto; margin: 0; padding: 2.2rem 0 0; }
.timeline--row .timeline__dot, .timeline--row .timeline__item:nth-child(even) .timeline__dot { top: 0; left: 0; right: auto; }
@media (max-width: 900px) {
	.timeline--row { grid-template-columns: repeat(2, 1fr); }
	.timeline:not(.timeline--row)::before { left: 6px; }
	.timeline:not(.timeline--row) .timeline__item, .timeline:not(.timeline--row) .timeline__item:nth-child(even) { width: auto; margin: 0; padding: 0 0 2rem 2.25rem; }
	.timeline:not(.timeline--row) .timeline__dot, .timeline:not(.timeline--row) .timeline__item:nth-child(even) .timeline__dot { left: 0; right: auto; }
}
@media (max-width: 560px) { .timeline--row { grid-template-columns: 1fr; } }

/* Band */
.band { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; padding: clamp(2rem, 5vw, 4rem); border-radius: calc(var(--radius) * 1.5); background: var(--forest); color: var(--on-forest); isolation: isolate; }
.band::before { content: ""; position: absolute; z-index: -1; width: 520px; height: 520px; right: -140px; top: -200px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 45%, transparent), transparent 65%); animation: fe-drift 14s ease-in-out infinite alternate; }
.band::after { content: ""; position: absolute; z-index: -1; inset: 0; background: repeating-radial-gradient(circle at 100% 0, transparent 0 34px, rgba(255, 255, 255, .04) 34px 35px); }
@keyframes fe-drift { to { transform: translate(-80px, 60px) scale(1.15); } }
.band__copy { max-width: 620px; }
.band .eyebrow { color: var(--accent); }
.band__title { font-size: clamp(1.8rem, 3.6vw, 2.7rem); }
.band p { opacity: .85; margin: 0; }

/* Empty state */
.empty { padding: 2rem; border: 1px dashed var(--line); border-radius: var(--radius); text-align: center; color: var(--muted); }
.empty p { margin-bottom: 1rem; }
.empty p:last-child { margin: 0; }
.empty--large { padding: 4rem 2rem; }
.empty .search-form { max-width: 520px; margin: 1.5rem auto 0; }

/* ---------- Page header ---------- */
.page-head { padding: clamp(2rem, 5vw, 4rem) 0 clamp(1.25rem, 3vw, 2rem); }
.page-head__title { font-size: clamp(2.3rem, 5.2vw, 4rem); line-height: 1.05; letter-spacing: -.025em; margin-bottom: 1rem; }
.page-head__title--single { font-size: clamp(2.1rem, 4.6vw, 3.4rem); }
.page-head__intro { font-size: clamp(1.05rem, 1.5vw, 1.2rem); color: var(--ink-2); max-width: 44em; }
.page-head__cite { font-size: 1.05rem; color: var(--muted); }
.page-head__actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.25rem; }
.page-head__actions:empty { display: none; }
.byline { font-size: .875rem; color: var(--muted); margin: .5rem 0 0; }
.byline a { color: var(--ink); }

.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; padding: 0; margin: 0 0 1.5rem; font-size: .85rem; color: var(--muted); }
.crumbs li:not(:last-child)::after { content: "/"; margin-left: .4rem; opacity: .5; }
.crumbs a { text-decoration: none; transition: color .2s; }
.crumbs a:hover { color: var(--ink); }

.expert-head { display: grid; grid-template-columns: 180px 1fr; gap: 2.5rem; align-items: center; max-width: 1000px; }
.expert-head__photo { width: 180px; height: 180px; border-radius: 50%; overflow: hidden; background: var(--accent-soft); box-shadow: 0 0 0 6px var(--surface), 0 0 0 7px var(--line); }
.expert-head__photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 640px) { .expert-head { grid-template-columns: 1fr; gap: 1.25rem; } .expert-head__photo { width: 120px; height: 120px; } }

/* ---------- Article ---------- */
.single-head > div { max-width: 860px; }
.widget a { color: var(--ink-2); text-decoration: none; transition: color .2s; }
.widget a:hover { color: var(--accent-ink); }
.widget ul { list-style: none; padding: 0; display: flex; flex-direction: column; gap: .6rem; }
.widget h2, .widget .wp-block-heading { font: 600 .75rem/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 1rem; }
.wp-block-search__label { font: 600 .75rem/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: .8rem; }
.wp-block-search__inside-wrapper { display: flex; gap: .4rem; }
.wp-block-search__input { flex: 1; min-width: 0; padding: .65rem .9rem; font: inherit; font-size: .95rem; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; }
.wp-block-search__input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.wp-block-search__button { padding: .65rem 1rem; border: 0; border-radius: 999px; background: var(--ink); color: var(--bg); font: 600 .85rem/1 var(--font-sans); cursor: pointer; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.article { min-width: 0; max-width: 760px; }
.article-aside { position: sticky; top: calc(var(--header-h) + 1.5rem); display: flex; flex-direction: column; gap: 2rem; }
@media (max-width: 1024px) { .article-layout { grid-template-columns: 1fr; } .article-aside { position: static; } .article { max-width: none; } .toc { display: none; } }

.feature-img { margin: 0 0 2.5rem; border-radius: var(--radius); overflow: hidden; }
.feature-img img { width: 100%; }
.feature-img figcaption { font-size: .85rem; color: var(--muted); padding: .75rem 0 0; }
.lead { font-size: 1.15rem; }

.prose { font-size: 1.1rem; line-height: 1.75; color: var(--ink-2); }
.prose > * { margin-block: 0 1.4em; }
.prose h2 { font-size: clamp(1.6rem, 2.6vw, 2rem); margin: 2.2em 0 .7em; color: var(--ink); }
.prose h3 { font-size: 1.35rem; margin: 1.8em 0 .6em; color: var(--ink); }
.prose a { color: var(--accent-ink); text-decoration-color: color-mix(in srgb, var(--accent-ink) 40%, transparent); transition: text-decoration-color .25s; }
.prose a:hover { text-decoration-color: currentColor; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--accent); }
.prose blockquote { margin-left: 0; padding: .4em 0 .4em 1.5em; border-left: 3px solid var(--accent); font: italic 1.3rem/1.5 var(--font-serif); color: var(--ink); }
.prose figure { margin-inline: 0; }
.prose figcaption, .prose .wp-element-caption { font-size: .85rem; color: var(--muted); margin-top: .6rem; }
.prose img { border-radius: var(--radius-sm); }
.prose table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.prose th, .prose td { padding: .7em .8em; border-bottom: 1px solid var(--line); text-align: left; }
.prose th { font-weight: 600; color: var(--ink); }
.prose code { font-size: .9em; background: var(--bg-alt); padding: .15em .4em; border-radius: 4px; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 3em 0; }
.prose .alignwide { margin-inline: calc(min(0px, (760px - 100vw) / 2 + 24px)); }
.wp-block-image.alignfull, .prose .alignfull { margin-inline: 0; }

.toc { padding-left: 1.25rem; border-left: 1px solid var(--line); }
.toc__title { font: 600 .75rem/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 1rem; }
.toc ol { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .6rem; counter-reset: toc; }
.toc a { position: relative; display: block; font-size: .9rem; line-height: 1.4; text-decoration: none; color: var(--muted); transition: color .25s; }
.toc a::before { content: ""; position: absolute; left: calc(-1.25rem - 1px); top: 0; bottom: 0; width: 2px; background: var(--accent); transform: scaleY(0); transition: transform .35s var(--ease); }
.toc a:hover, .toc a.is-active { color: var(--ink); }
.toc a.is-active::before { transform: none; }

.share { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem; margin: 2.5rem 0; padding: 1.25rem 0; border-block: 1px solid var(--line); font-size: .9rem; }
.share > span { font-weight: 600; color: var(--muted); }
.share a { text-decoration: none; color: var(--ink-2); transition: color .2s; }
.share a:hover { color: var(--accent-ink); }
.share__copy { display: inline-flex; align-items: center; gap: .35rem; border: 0; background: none; font: inherit; color: var(--ink-2); cursor: pointer; padding: 0; }
.share__copy .icon { width: 16px; height: 16px; }
.share__copy.is-done { color: var(--accent-ink); }

.author-box { display: flex; gap: 1rem; padding: 1.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 2.5rem; }
.author-box img { border-radius: 50%; flex: none; }
.author-box__name { font-weight: 600; margin-bottom: .3rem; }
.author-box p:last-child { margin: 0; font-size: .95rem; color: var(--muted); }

.post-navigation .nav-links { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 2.5rem 0; }
.post-navigation a { display: block; height: 100%; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; transition: border-color .25s, transform .4s var(--ease); }
.post-navigation a:hover { border-color: var(--ink); transform: translateY(-3px); }
.post-navigation .nav-next { text-align: right; grid-column: 2; }
.post-nav__label { display: block; font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: .35rem; }
.post-nav__title { font: 600 1.05rem/1.3 var(--font-serif); }

.widget { font-size: .95rem; }
.widget__title { font: 600 .75rem/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 1rem; }
.widget ul { padding-left: 1.1em; }

/* Comments */
.comments { margin-top: 3rem; }
.comments__title { font-size: 1.5rem; }
.comment-list { list-style: none; padding: 0; }
.comment-list .comment-body { padding: 1.25rem 0; border-bottom: 1px solid var(--line); }
.comment-list .children { list-style: none; padding-left: 1.5rem; }
.comment-author img { float: left; margin-right: .75rem; border-radius: 50%; }
.comment-metadata { font-size: .8rem; color: var(--muted); }
.comment-form input:not([type="checkbox"]):not([type="submit"]), .comment-form textarea { width: 100%; }

/* ---------- Forms ---------- */
.form-wrap { margin-top: 2rem; }
.form { padding: clamp(1.25rem, 3vw, 2rem); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1.25rem; }
.field--full { grid-column: 1 / -1; }
@media (max-width: 600px) { .form__grid { grid-template-columns: 1fr; } }
.field label { display: block; font-size: .875rem; font-weight: 600; margin-bottom: .4rem; color: var(--ink); }
.field input, .field select, .field textarea, .comment-form input:not([type="checkbox"]):not([type="submit"]), .comment-form textarea {
	width: 100%; padding: .8rem 1rem; font: inherit; font-size: 1rem; color: var(--ink);
	background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm);
	transition: border-color .25s, box-shadow .25s, background-color .25s;
}
.field input:focus, .field select:focus, .field textarea:focus, .comment-form input:focus, .comment-form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); background: var(--surface); }
.field--check label { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; font-size: .9rem; color: var(--ink-2); }
.field--check input { margin-top: .3rem; accent-color: var(--accent); }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notice { padding: 1rem 1.25rem; border-radius: var(--radius-sm); margin-bottom: 1.25rem; font-size: .95rem; animation: fe-rise .5s var(--ease); }
.notice--ok { background: color-mix(in srgb, #2f8f5b 14%, var(--surface)); border: 1px solid color-mix(in srgb, #2f8f5b 40%, transparent); }
.notice--error { background: color-mix(in srgb, #c0392b 12%, var(--surface)); border: 1px solid color-mix(in srgb, #c0392b 40%, transparent); }

/* ---------- Pagination ---------- */
.pagination { margin-top: 3rem; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: .4rem; justify-content: center; }
.pagination .page-numbers { min-width: 44px; height: 44px; padding: 0 .9rem; display: inline-grid; place-items: center; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-size: .9rem; transition: background-color .25s, color .25s, border-color .25s; }
.pagination a.page-numbers:hover { border-color: var(--ink); }
.pagination .current { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ---------- Ads ---------- */
.ad { margin: 2.5rem 0; text-align: center; min-height: 120px; clear: both; }
.ad__label { display: block; font: 500 .68rem/1 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: .6rem; }
.ad--sidebar { margin: 0; min-height: 250px; }
.ad--archive { margin: .5rem 0; }
.ad--placeholder .ad__box { display: grid; place-items: center; min-height: 120px; border: 1px dashed var(--line); border-radius: var(--radius-sm); color: var(--muted); font-size: .85rem; }
.ad--sidebar.ad--placeholder .ad__box { min-height: 250px; }
.prose .ad { font-size: 1rem; }

/* ---------- 404 ---------- */
.notfound { padding: clamp(3rem, 10vw, 8rem) 0; text-align: center; }
.notfound .container { display: flex; flex-direction: column; align-items: center; }
.notfound__code { font: 600 clamp(5rem, 16vw, 10rem)/1 var(--font-serif); color: var(--accent); margin-bottom: .2em; letter-spacing: -.04em; }
.notfound .search-form { width: min(520px, 100%); margin: 1.5rem 0; }
.notfound .hero__actions { justify-content: center; margin-top: 0; }

/* ---------- Footer ---------- */
.site-footer { margin-top: clamp(2rem, 5vw, 4rem); padding: clamp(3rem, 6vw, 5rem) 0 1.5rem; background: var(--forest); color: var(--on-forest); }
.site-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 2.5rem; }
.site-footer .brand { color: var(--on-forest); margin-bottom: 1rem; }
.site-footer p { opacity: .75; font-size: .95rem; }
.site-footer__title { font: 600 .75rem/1 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 1.1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .55rem; }
.site-footer ul a { text-decoration: none; opacity: .8; font-size: .95rem; transition: opacity .2s, padding-left .3s var(--ease); }
.site-footer ul a:hover { opacity: 1; padding-left: 4px; }
.site-footer .btn--ghost { color: var(--on-forest); border-color: rgba(255, 255, 255, .25); }
.site-footer .btn--ghost:hover { border-color: var(--on-forest); }
.social { flex-direction: row !important; flex-wrap: wrap; gap: .5rem 1rem !important; }
.site-footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, .12); font-size: .85rem; }
.site-footer__bottom p { margin: 0; opacity: .6; }
.to-top { text-decoration: none; }
@media (max-width: 900px) { .site-footer__grid { grid-template-columns: 1fr 1fr; } .site-footer__about { grid-column: 1 / -1; } }
@media (max-width: 520px) { .site-footer__grid { grid-template-columns: 1fr; } }

/* ---------- WordPress core ---------- */
.alignleft { float: left; margin: 0 1.5em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.5em; }
.aligncenter { margin-inline: auto; }
.wp-caption-text, .gallery-caption { font-size: .85rem; color: var(--muted); }
.sticky .card__title::before { content: "★ "; color: var(--accent); }
.bypostauthor > .comment-body .fn::after { content: " · author"; font-size: .8em; color: var(--muted); }
.wp-block-button__link { border-radius: 999px; }

/* ---------- Motion: scroll reveals ---------- */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--d, 0) * 90ms); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .card.reveal.is-in:hover, .js .expert.reveal.is-in:hover { transform: translateY(-6px); transition-delay: 0s; }
.js .tool.reveal.is-in:hover { transform: translateX(6px); transition-delay: 0s; }

/* Split headings: words slide up from a mask */
[data-split] .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
[data-split] .w > span { display: inline-block; transform: translateY(105%); transition: transform 1s var(--ease); transition-delay: calc(var(--wi) * 70ms + 80ms); }
[data-split].is-in .w > span { transform: none; }
.js [data-split]:not(.is-split) { opacity: 0; }

/* ---------- Page-to-page transitions (View Transitions API, progressive) ---------- */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: fe-vt-out .32s var(--ease-in-out) both; }
::view-transition-new(root) { animation: fe-vt-in .5s var(--ease) both; }
::view-transition-group(site-header) { animation-duration: 0s; }
@keyframes fe-vt-out { to { opacity: 0; transform: translateY(-12px); } }
@keyframes fe-vt-in { from { opacity: 0; transform: translateY(16px); } }

/* Fallback page fade for browsers without view transitions */
.js body.is-leaving .site-main { opacity: 0; transform: translateY(-8px); transition: opacity .25s, transform .25s; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
	.js .reveal, [data-split] .w > span { opacity: 1 !important; transform: none !important; }
	.js [data-split]:not(.is-split) { opacity: 1; }
	.stage { opacity: 1; transform: none; }
	.cycle__track { stroke-dashoffset: 0; }
	@view-transition { navigation: none; }
}

/* ---------- Print ---------- */
@media print {
	.site-header, .site-footer, .ad, .share, .article-aside, .post-navigation, .progress, .comments { display: none !important; }
	body { background: #fff; color: #000; }
	.js .reveal { opacity: 1; transform: none; }
}
