/*
 * OD MIESTNYCH – overlay page (before launch / maintenance).
 * Identity: forest green, cream, fine gold lines, Fraunces + Source Sans 3 (SIL OFL, bundled).
 * Contrast (WCAG 2.2 AA): forest #1f3d2e on cream #f7f2e8 ≈ 10.7 : 1; gold-text #7a5b22 ≈ 5.6 : 1;
 * muted #5a554c ≈ 6.6 : 1. Pure gold #b8975a is decorative only (lines, ground).
 *
 * Animation (once, CSS + SVG only, only with prefers-reduced-motion: no-preference):
 *   seed appears → stem grows → two leaves unfold → the quote → the reference → the logo → footer.
 * Without the animation class (maintenance, setting off) or with reduced motion the final state is shown.
 */

@font-face {
	font-family: "Fraunces";
	font-style: normal;
	font-weight: 380 650;
	font-display: swap;
	src: url("../fonts/fraunces-sk-normal.woff2") format("woff2");
}
@font-face {
	font-family: "Fraunces";
	font-style: italic;
	font-weight: 380 650;
	font-display: swap;
	src: url("../fonts/fraunces-sk-italic.woff2") format("woff2");
}
@font-face {
	font-family: "Source Sans 3";
	font-style: normal;
	font-weight: 200 900;
	font-display: swap;
	src: url("../fonts/source-sans-3-latin-ext-wght-normal.woff2") format("woff2");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
	font-family: "Source Sans 3";
	font-style: normal;
	font-weight: 200 900;
	font-display: swap;
	src: url("../fonts/source-sans-3-latin-wght-normal.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
	--forest: #1f3d2e;
	--forest-soft: #2c5240;
	--cream: #f7f2e8;
	--paper: #fffdf8;
	--gold: #b8975a;
	--gold-text: #7a5b22;
	--seed: #8a6a3c;
	--muted: #5a554c;
	--serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
	--sans: "Source Sans 3", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	--frame: clamp(8px, 1.6vw, 18px);
	color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
	margin: 0;
	min-height: 100vh;
	min-height: 100svh;
	display: grid;
	grid-template-rows: 1fr auto;
	justify-items: center;
	padding: calc(var(--frame) + clamp(1.5rem, 1rem + 3vw, 3.5rem)) calc(var(--frame) + clamp(1.1rem, 0.6rem + 3vw, 3rem));
	background:
		radial-gradient(ellipse 70% 55% at 50% 32%, var(--paper) 0%, rgba(255, 253, 248, 0) 70%),
		var(--cream);
	color: var(--forest);
	font: 400 1.0625rem / 1.6 var(--sans);
	overflow-x: hidden;
}

/* Fine gold frame around the page (decorative). */
body::before {
	content: "";
	position: fixed;
	inset: var(--frame);
	border: 1px solid rgba(184, 151, 90, 0.55);
	border-radius: 4px;
	pointer-events: none;
}

.odmm-main {
	align-self: center;
	width: 100%;
	max-width: 46rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
}

/* Plant ----------------------------------------------------------------- */

.odmm-plant { width: clamp(104px, 15vw, 176px); height: auto; overflow: visible; margin-bottom: clamp(0.5rem, 2vw, 1.25rem); }
.odmm-ground { fill: none; stroke: var(--gold); stroke-width: 1.2; stroke-linecap: round; }
.odmm-seed { fill: var(--seed); }
.odmm-stem { fill: none; stroke: var(--forest); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.odmm-leaf path:first-child { fill: var(--forest-soft); }
.odmm-leaf--r path:first-child { fill: var(--forest); }
.odmm-vein { fill: none; stroke: var(--cream); stroke-width: 0.9; stroke-linecap: round; opacity: 0.8; }
.odmm-leaf { transform-box: fill-box; }
.odmm-leaf--l { transform-origin: 100% 100%; }
.odmm-leaf--r { transform-origin: 0% 100%; }

/* Quote ----------------------------------------------------------------- */

.odmm-quote { margin: 0; }
.odmm-quote blockquote { margin: 0; }
.odmm-quote p {
	margin: 0;
	font: 430 clamp(1.85rem, 1.15rem + 3.2vw, 3.45rem) / 1.16 var(--serif);
	letter-spacing: -0.015em;
	color: var(--forest);
	text-wrap: balance;
	hanging-punctuation: first;
}
.odmm-ref {
	margin-top: clamp(0.9rem, 0.6rem + 1vw, 1.4rem);
	display: inline-flex;
	align-items: center;
	gap: 0.85rem;
	font: 600 1rem / 1 var(--sans);
	letter-spacing: 0.08em; /* written exactly as entered ("Iz 43,19") – no forced capitals */
	color: var(--gold-text);
}
.odmm-ref cite { font-style: normal; }
.odmm-ref::before, .odmm-ref::after { content: ""; width: 2.25rem; height: 1px; background: var(--gold); }

/* Logo ------------------------------------------------------------------ */

.odmm-logo {
	margin: clamp(2.2rem, 1.5rem + 3vw, 3.6rem) 0 0;
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	font: 600 clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem) / 1 var(--serif);
	letter-spacing: 0.14em;
	color: var(--forest);
}
.odmm-logo svg { width: clamp(2.6rem, 2.2rem + 1.5vw, 3.25rem); height: auto; flex: none; }
.odmm-logo--small { margin: 0 0 clamp(1.5rem, 1rem + 2vw, 2.5rem); font-size: 1rem; }
.odmm-logo--small svg { width: 2.4rem; }

.odmm-extra, .odmm-date { margin: 1.25rem 0 0; max-width: 34rem; color: var(--muted); }
.odmm-date { font-size: 0.95rem; letter-spacing: 0.02em; }

/* Maintenance ----------------------------------------------------------- */

.odmm-heading {
	margin: 0;
	font: 480 clamp(1.8rem, 1.2rem + 2.6vw, 3rem) / 1.15 var(--serif);
	letter-spacing: -0.015em;
	text-wrap: balance;
}
.odmm-text { margin: 1.1rem 0 0; max-width: 32rem; font-size: 1.125rem; color: var(--muted); }

/* Footer ---------------------------------------------------------------- */

.odmm-foot {
	width: 100%;
	max-width: 46rem;
	margin-top: clamp(2.5rem, 2rem + 3vw, 4.5rem);
	padding-top: 1.25rem;
	border-top: 1px solid rgba(184, 151, 90, 0.6);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.6rem;
	text-align: center;
}
.odmm-tagline { margin: 0; font: italic 400 1.05rem / 1.4 var(--serif); color: var(--gold-text); }
.odmm-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 0.25rem 1.25rem; }
.odmm-links a {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	min-height: 44px;
	padding: 0 0.25rem;
	color: var(--forest);
	font-weight: 600;
	font-size: 0.975rem;
	text-decoration: underline;
	text-decoration-color: rgba(31, 61, 46, 0.35);
	text-underline-offset: 0.22em;
	overflow-wrap: anywhere;
}
.odmm-links a:hover { text-decoration-color: currentColor; }
.odmm-links a:focus-visible { outline: 3px solid var(--gold-text); outline-offset: 2px; border-radius: 2px; }
.odmm-links svg { width: 1.15rem; height: 1.15rem; flex: none; }

.odmm-preview {
	position: fixed;
	top: calc(var(--frame) + 0.5rem);
	left: 50%;
	transform: translateX(-50%);
	margin: 0;
	padding: 0.35rem 0.9rem;
	border-radius: 999px;
	background: var(--forest);
	color: var(--cream);
	font-size: 0.85rem;
	font-weight: 600;
	z-index: 2;
}

/* Germination – once, only when motion is welcome ------------------------ */

@media (prefers-reduced-motion: no-preference) {
	.odmm--animate .odmm-seed { animation: odmm-seed 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.3s both; transform-box: fill-box; transform-origin: 50% 100%; }
	.odmm--animate .odmm-ground { animation: odmm-fade 1.2s ease-out 0.1s both; }
	.odmm--animate .odmm-stem { animation: odmm-grow 2.2s cubic-bezier(0.45, 0.05, 0.3, 1) 1.2s both; }
	.odmm--animate .odmm-leaf--l { animation: odmm-unfold-l 1.6s cubic-bezier(0.2, 0.7, 0.2, 1) 3s both; }
	.odmm--animate .odmm-leaf--r { animation: odmm-unfold-r 1.6s cubic-bezier(0.2, 0.7, 0.2, 1) 3.35s both; }
	.odmm--animate .odmm-quote p { animation: odmm-rise 1.8s ease-out 4.3s both; }
	.odmm--animate .odmm-ref { animation: odmm-fade 1.4s ease-out 5.4s both; }
	.odmm--animate .odmm-logo,
	.odmm--animate .odmm-extra,
	.odmm--animate .odmm-date { animation: odmm-rise 1.6s ease-out 6s both; }
	.odmm--animate .odmm-foot { animation: odmm-fade 1.6s ease-out 6.7s both; }
}

@keyframes odmm-seed {
	from { opacity: 0; transform: translateY(5px) scale(0.55); }
	to { opacity: 1; transform: none; }
}
@keyframes odmm-grow {
	from { stroke-dashoffset: 1; }
	to { stroke-dashoffset: 0; }
}
@keyframes odmm-unfold-l {
	from { opacity: 0; transform: rotate(28deg) scale(0.15); }
	to { opacity: 1; transform: none; }
}
@keyframes odmm-unfold-r {
	from { opacity: 0; transform: rotate(-28deg) scale(0.15); }
	to { opacity: 1; transform: none; }
}
@keyframes odmm-rise {
	from { opacity: 0; transform: translateY(12px); }
	to { opacity: 1; transform: none; }
}
@keyframes odmm-fade {
	from { opacity: 0; }
	to { opacity: 1; }
}

@media (forced-colors: active) {
	body::before { border-color: CanvasText; }
	.odmm-stem, .odmm-ground { stroke: CanvasText; }
	.odmm-leaf path:first-child, .odmm-seed { fill: CanvasText; }
}
