/*
 * A project and its dossier on the page Chi sono (site:features/dossier), as the preview approved on 2026-11-21: the
 * story on the left, the dossier on the right, held while the story runs. The pages snap one at a time and turn like
 * paper while they go (a scroll timeline along the row); the miniatures under them lead to each page. Colours from
 * the palette; the pages are white paper (the button's text colour).
 */

.axyo-site-features {
	--fe-paper: var(--color-section-dark-text);
	container-type: inline-size;
	overflow-x: clip;
	border-bottom: 1px solid var(--section-line);
}

.axyo-site-features:has(.fe-on-page) { --section-bg: var(--color-background); background-color: var(--color-background); }
.axyo-site-features .fe-lab { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 5cqi; }
.axyo-site-features .fe-side { min-width: 0; }
.axyo-site-features .fe-eyebrow { margin: 0; font: 500 0.75em ui-monospace, monospace; letter-spacing: 0.08em; color: var(--section-accent); }
.axyo-site-features .fe-title { margin: 0.25em 0 0; font: 800 clamp(2em, 4.2vw, 3.6em) / 1 var(--axyo-font-heading); letter-spacing: -0.045em; }
.axyo-site-features .fe-title em { font-style: normal; color: var(--section-accent); }
.axyo-site-features .fe-text { max-width: 46ch; margin: 1.2em 0 0; font-size: 1.0625em; line-height: 1.65; color: var(--section-muted); }
.axyo-site-features .fe-year { display: flex; align-items: baseline; gap: 1em; margin: 1.8em 0 0; padding: 1em 0; border-block: 1px solid var(--section-line); }
.axyo-site-features .fe-year b { font: 800 clamp(2.25em, 4vw, 3.25em) / 1 var(--axyo-font-heading); letter-spacing: -0.05em; color: var(--section-accent); }
.axyo-site-features .fe-year span { font-size: 0.875em; line-height: 1.45; color: var(--section-muted); }
.axyo-site-features figure { margin: 0; }
.axyo-site-features .fe-shots { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8em; margin-top: 2em; }
.axyo-site-features .fe-img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; background: var(--fe-paper); }
.axyo-site-features .is-real .fe-img { object-fit: contain; outline: 1px solid var(--section-line); outline-offset: -1px; }

/* The brand under the photographs, on a white card legible in Light and in Dark (the user, 2026-11-21). */
.axyo-site-features .fe-brand { width: min(17em, 80%); margin-top: 2.4em; padding: 1em 1.2em; background: var(--fe-paper); box-shadow: 0 1em 2em -1.3em var(--color-section-dark-bg); }
.axyo-site-features .fe-brand-img { display: block; width: 100%; height: auto; }

.axyo-site-features :is(.fe-shots, .fe-leaf) figcaption {
	margin-top: 0.6em;
	font-size: 0.75em;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--section-muted);
}

/* The dossier: the pages in a row that snaps, perspective for the turn. */
.axyo-site-features .fe-book-wrap { position: sticky; top: var(--ado-stick, 9.5em); align-self: center; min-width: 0; }
.axyo-site-features .fe-book {
	display: flex;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	perspective: 150em;
	view-timeline-axis: inline;
	overscroll-behavior-x: contain;
}

.axyo-site-features .fe-book:focus-visible { outline: 2px solid var(--section-accent); outline-offset: 0.4em; }
/* A miniature brings its page where the dossier is held: the room of the bar is the page's scroll-padding, so the leaf
   adds only the rest up to there (with more, every click moved the page again). */
.axyo-site-features .fe-leaf { flex: none; width: 100%; scroll-snap-align: center; scroll-margin-top: calc(var(--ado-stick, 9.5em) - var(--axyo-top, 0rem) - 7rem); }
.axyo-site-features .fe-page { display: block; width: 100%; height: auto; aspect-ratio: 1400 / 990; object-fit: contain; background: var(--fe-paper); box-shadow: 0 1.6em 3em -1.4em color-mix(in srgb, var(--section-fg) 45%, transparent), 0 0 0 1px var(--section-line); }
.axyo-site-features .fe-leaf figcaption { margin-top: 1.2em; }
.axyo-site-features .fe-leaf figcaption span { margin-right: 0.6em; font-family: ui-monospace, monospace; color: var(--section-accent); }

/* The pages in miniature, like the proofs of a film: all in sight, seven a row, each a click to its page (the user,
   2026-11-21: in a row that scrolled, the mouse could not move them). */
.axyo-site-features .fe-thumbs {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 0.9em 0.8em;
	margin: 1.4em 0 0;
	padding: 0.4em 0 0;
	list-style: none;
}

.axyo-site-features .fe-thumbs li { min-width: 0; margin: 0; }
.axyo-site-features .fe-thumbs a { display: block; color: var(--section-muted); text-decoration: none; transition: translate 0.3s, color 0.3s; }
.axyo-site-features .fe-thumb { display: block; width: 100%; height: auto; aspect-ratio: 1400 / 990; object-fit: cover; background: var(--fe-paper); box-shadow: 0 0 0 1px var(--section-line); opacity: 0.6; filter: grayscale(1); transition: opacity 0.3s, filter 0.3s; }
.axyo-site-features .fe-thumbs small { display: block; margin-top: 0.35em; font: 500 0.625em ui-monospace, monospace; letter-spacing: 0.04em; }
.axyo-site-features .fe-thumbs a:is(:hover, :focus-visible) { translate: 0 -0.2em; color: var(--section-fg); }
.axyo-site-features .fe-thumbs a:is(:hover, :focus-visible) .fe-thumb { opacity: 1; filter: none; }
.axyo-site-features .fe-thumbs a:focus-visible { outline: 2px solid var(--section-accent); outline-offset: 0.2em; }

@container (max-width: 56em) {
	.axyo-site-features .fe-lab { grid-template-columns: minmax(0, 1fr); }
	.axyo-site-features .fe-book-wrap { position: static; }
	.axyo-site-features .fe-leaf { scroll-margin-top: 0; }
}

@container (max-width: 34em) {
	.axyo-site-features .fe-thumbs { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0.7em 0.5em; }
}

@media (prefers-reduced-motion: no-preference) {
	@supports (animation-timeline: view()) {
		/* Each page turns like paper while it leaves and arrives along the row. */
		.axyo-site-features .fe-page { transform-origin: 0 50%; animation: features-turn linear both; animation-timeline: view(inline); }
		.axyo-site-features :is(.fe-head, .fe-shots figure, .fe-brand) { animation: features-left linear both; animation-timeline: view(); animation-range: entry 0% exit 100%; }
		.axyo-site-features .fe-shots figure { animation-name: features-up; }
		.axyo-site-features .fe-book-wrap { animation: features-right linear both; animation-timeline: view(); animation-range: entry 0% exit 100%; }
	}
}

@media (prefers-reduced-motion: reduce) {
	.axyo-site-features * { animation: none; }
}

@keyframes features-turn { 0% { rotate: y 30deg; opacity: 0.5; } 50% { rotate: y 0deg; opacity: 1; } 100% { rotate: y -100deg; opacity: 0; } }
@keyframes features-left { 0% { opacity: 0; translate: -35% 0; } 28%, 72% { opacity: 1; translate: 0 0; } 100% { opacity: 0; translate: -35% 0; } }
@keyframes features-right { 0% { opacity: 0; translate: 35% 0; } 28%, 72% { opacity: 1; translate: 0 0; } 100% { opacity: 0; translate: 35% 0; } }
@keyframes features-up { 0% { opacity: 0; translate: 0 30%; } 28%, 72% { opacity: 1; translate: 0 0; } 100% { opacity: 0; translate: 0 -12%; } }

/* The sections of the page Officina (site:features/steps, ways, rules), as the preview approved on 2026-11-21. */
.axyo-site-features:has(.fe-on-page) { --section-bg: var(--color-background); background-color: var(--color-background); }
.axyo-site-features .fe-o-title { margin: 0.3em 0 0; font: 800 clamp(2em, 4vw, 3.4em) / 1 var(--axyo-font-heading); letter-spacing: -0.045em; }
.axyo-site-features .fe-o-title em { font-style: normal; color: var(--section-accent); }
.axyo-site-features .fe-o-lead { max-width: 46ch; margin: 0; font-size: 1.15em; line-height: 1.6; color: var(--section-muted); }
.axyo-site-features .fe-o-top { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 2em; }

.axyo-site-features .fe-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 3cqi; margin: 3em 0 0; padding: 0; list-style: none; counter-reset: fe-step; }
.axyo-site-features .fe-steps li { margin: 0; padding-top: 1.4em; border-top: 2px solid var(--section-fg); counter-increment: fe-step; }
.axyo-site-features .fe-steps li::before { content: counter(fe-step, decimal-leading-zero); display: block; font: 800 3.2em / 1 var(--axyo-font-heading); letter-spacing: -0.05em; color: var(--section-accent); }
.axyo-site-features .fe-steps h3 { margin: 1em 0 0; font: 800 1.4em / 1.15 var(--axyo-font-heading); letter-spacing: -0.03em; }
.axyo-site-features .fe-steps p { margin: 0.6em 0 0; line-height: 1.6; color: var(--section-muted); }

.axyo-site-features .fe-ways { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.8em 1.5em; margin: 2.4em 0 0; padding: 0; list-style: none; }
.axyo-site-features .fe-way { --fe-rot: -1.2deg; display: flex; flex-direction: column; margin: 0; padding: 1.4em 1.4em 1.3em; background: var(--fe-paper); color: var(--color-section-dark-bg); box-shadow: 0 1.4em 2.4em -1.5em var(--color-section-dark-bg), 0 0 0 1px color-mix(in srgb, var(--color-section-dark-bg) 12%, transparent); rotate: var(--fe-rot); }
.axyo-site-features .fe-way:nth-child(4n + 2) { --fe-rot: 1deg; }
.axyo-site-features .fe-way:nth-child(4n + 3) { --fe-rot: -0.6deg; }
.axyo-site-features .fe-way:nth-child(4n + 4) { --fe-rot: 0.8deg; }
.axyo-site-features .fe-way small { font: 500 0.66em ui-monospace, monospace; letter-spacing: 0.1em; color: color-mix(in srgb, var(--color-section-dark-bg) 60%, transparent); }
.axyo-site-features .fe-way h3 { margin: 0.9em 0 0; font: 800 1.3em / 1.15 var(--axyo-font-heading); letter-spacing: -0.03em; }
.axyo-site-features .fe-way p { margin: 0.6em 0 0; font-size: 0.95em; line-height: 1.55; color: color-mix(in srgb, var(--color-section-dark-bg) 74%, transparent); }
.axyo-site-features .fe-topics-h { margin-top: 3.2em; }
.axyo-site-features .fe-topics { display: flex; flex-wrap: wrap; gap: 0.5em; margin: 1em 0 0; padding: 0; list-style: none; }
.axyo-site-features .fe-topics li { margin: 0; padding: 0.55em 1em; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--section-line); font-size: 0.85em; font-weight: 600; }

.axyo-site-features .fe-o-rules { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 5cqi; }
.axyo-site-features .fe-rules { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--section-line); counter-reset: fe-rule; }
.axyo-site-features .fe-rules li { display: grid; grid-template-columns: 3em minmax(0, 1fr); gap: 0.4em; margin: 0; padding: 1.2em 0; border-bottom: 1px solid var(--section-line); counter-increment: fe-rule; }
.axyo-site-features .fe-rules li::before { content: counter(fe-rule, decimal-leading-zero); padding-top: 0.35em; font: 500 0.75em ui-monospace, monospace; color: var(--section-accent); }
.axyo-site-features .fe-rules b { font: 700 1.15em / 1.3 var(--axyo-font-heading); letter-spacing: -0.02em; }
.axyo-site-features .fe-rules span { display: block; margin-top: 0.25em; color: var(--section-muted); }

@container (max-width: 64em) {
	.axyo-site-features .fe-steps, .axyo-site-features .fe-ways { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2em 1.5em; }
}

@container (max-width: 40em) {
	.axyo-site-features .fe-steps, .axyo-site-features .fe-ways, .axyo-site-features .fe-o-rules { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: no-preference) {
	@supports (animation-timeline: view()) {
		.axyo-site-features .fe-o > .fe-o-head, .axyo-site-features .fe-o-top > .fe-o-head { animation: features-in-left linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
		.axyo-site-features .fe-o-lead { animation: features-in-right linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
		.axyo-site-features .fe-steps li { animation: features-in-up linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
		.axyo-site-features .fe-way { animation: features-in-print linear both; animation-timeline: view(); animation-range: entry 0% entry 75%; }
		.axyo-site-features .fe-way:nth-child(odd) { animation-name: features-in-print-left; }
		.axyo-site-features .fe-rules li { animation: features-in-right linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
	}
}

@keyframes features-in-left { from { opacity: 0; translate: -3em 0; } to { opacity: 1; translate: 0 0; } }
@keyframes features-in-right { from { opacity: 0; translate: 3em 0; } to { opacity: 1; translate: 0 0; } }
@keyframes features-in-up { from { opacity: 0; translate: 0 2.5em; } to { opacity: 1; translate: 0 0; } }
@keyframes features-in-print { from { opacity: 0; rotate: 9deg; translate: 3em 2em; } to { opacity: 1; rotate: var(--fe-rot); translate: 0 0; } }
@keyframes features-in-print-left { from { opacity: 0; rotate: -9deg; translate: -3em 2em; } to { opacity: 1; rotate: var(--fe-rot); translate: 0 0; } }

/* The theme's lists space their items; these lists keep their own gaps. */
.axyo-site-features :is(.fe-steps, .fe-ways, .fe-topics, .fe-rules) > li + li { margin-top: 0; }
