/* Rośliny świata – style strony. Style samych map: assets/world-map/src/maps.css
   Motyw jasny albo ciemny – domyślnie jak w systemie; przełącznik w nagłówku (layout.php) ustawia <html data-theme="light|dark">. */

:root {
  --bg: #f5f7f2;
  --surface: #ffffff;
  --surface-2: #eef3ec;
  --ink: #1b2a1f;
  --muted: #5b6b5e;
  --line: #dde5da;
  /* Zieleń wg roli: 950 – nagłówki, 800 – wyróżnienia, 700 – linki, 500 – akcenty, 300 – podkreślenia, 100 – tła */
  --green-950: #0d2a17;
  --green-800: #1f5c36;
  --green-700: #26703f;
  --green-500: #3f9a5c;
  --green-300: #a8d5b1;
  --green-100: #e2f1e4;
  --button: #1f5c36;            /* tło przycisków (biały tekst) */
  --button-hover: #0d2a17;
  --accent: #c98a1b;            /* ciepły akcent: symbole narodowe */
  --range: #2f8a4f;             /* kolor regionów występowania */
  --header-bg: rgba(245, 247, 242, .88);
  --glass: rgba(255, 255, 255, .93);
  --shimmer: #f7faf6;
  --symbol-bg: #fbf1dc;
  --symbol-ink: #8a5a07;
  --notice-ink: #6b4605;
  --code-bg: rgba(0, 0, 0, .06);
  --danger: #b3261e;
  --danger-bg: #fdecea;
  --danger-ink: #8c1d18;
  /* Mapy */
  --map-ocean: #e7f0ea;
  --map-sphere: #d3e2d7;
  --map-land: #a9d6b3;          /* kraje z opisanymi roślinami */
  --map-land-hover: #5fae74;
  --map-inactive: #dfe4dd;
  --map-border: #ffffff;
  --map-dot: #6f9a7a;
  --map-tip-bg: rgba(13, 42, 23, .94);
  --map-tip-fg: #ffffff;
  --region-land: #edf1ea;
  --region-hover: #e2e9de;
  --region-border: #c8d2c4;
  --region-outline: #86a08c;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(13, 42, 23, .06), 0 8px 24px -12px rgba(13, 42, 23, .18);
  --header-h: 56px;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  color-scheme: light;
}
/* Ciemny motyw („nocny las”): według systemu albo wybrany przełącznikiem w nagłówku (<html data-theme>) */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #0f1511;
    --surface: #161e18;
    --surface-2: #1e2921;
    --ink: #e2ebe4;
    --muted: #97a89a;
    --line: #2b382e;
    --green-950: #e6f2e8;
    --green-800: #93d6a6;
    --green-700: #7fcb95;
    --green-500: #62b97b;
    --green-300: #3f7a52;
    --green-100: #1d3525;
    --button: #2a7a45;
    --button-hover: #33914f;
    --accent: #e3a73d;
    --range: #4aa868;
    --header-bg: rgba(15, 21, 17, .88);
    --glass: rgba(22, 30, 24, .93);
    --shimmer: #26332a;
    --symbol-bg: #3a2c12;
    --symbol-ink: #f0c77a;
    --notice-ink: #f0c77a;
    --code-bg: rgba(255, 255, 255, .08);
    --danger: #ff8a80;
    --danger-bg: #3a1a18;
    --danger-ink: #ffb4ab;
    --map-ocean: #13201a;
    --map-sphere: #1f2d24;
    --map-land: #2f6b44;
    --map-land-hover: #46955e;
    --map-inactive: #242c26;
    --map-border: #0f1511;
    --map-dot: #5d7d66;
    --map-tip-bg: rgba(230, 242, 233, .96);
    --map-tip-fg: #0d2a17;
    --region-land: #1f2822;
    --region-hover: #28342b;
    --region-border: #36463b;
    --region-outline: #577a61;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-theme='dark'] {
  --bg: #0f1511;
  --surface: #161e18;
  --surface-2: #1e2921;
  --ink: #e2ebe4;
  --muted: #97a89a;
  --line: #2b382e;
  --green-950: #e6f2e8;
  --green-800: #93d6a6;
  --green-700: #7fcb95;
  --green-500: #62b97b;
  --green-300: #3f7a52;
  --green-100: #1d3525;
  --button: #2a7a45;
  --button-hover: #33914f;
  --accent: #e3a73d;
  --range: #4aa868;
  --header-bg: rgba(15, 21, 17, .88);
  --glass: rgba(22, 30, 24, .93);
  --shimmer: #26332a;
  --symbol-bg: #3a2c12;
  --symbol-ink: #f0c77a;
  --notice-ink: #f0c77a;
  --code-bg: rgba(255, 255, 255, .08);
  --danger: #ff8a80;
  --danger-bg: #3a1a18;
  --danger-ink: #ffb4ab;
  --map-ocean: #13201a;
  --map-sphere: #1f2d24;
  --map-land: #2f6b44;
  --map-land-hover: #46955e;
  --map-inactive: #242c26;
  --map-border: #0f1511;
  --map-dot: #5d7d66;
  --map-tip-bg: rgba(230, 242, 233, .96);
  --map-tip-fg: #0d2a17;
  --region-land: #1f2822;
  --region-hover: #28342b;
  --region-border: #36463b;
  --region-outline: #577a61;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .6);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green-700); text-underline-offset: 3px; }
a:hover { color: var(--green-950); }
h1, h2, h3 { font-family: var(--font-display); font-weight: 650; line-height: 1.15; letter-spacing: -.01em; margin: 0 0 .5em; color: var(--green-950); }
h1 { font-size: clamp(1.9rem, 1.4rem + 2vw, 2.8rem); }
h2 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--green-500); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.lead { font-size: 1.08rem; color: var(--muted); }
.kicker { margin: 0 0 .35rem; font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--green-500); }
.latin { font-style: italic; color: var(--muted); margin: 0; }

.button {
  display: inline-flex; align-items: center; gap: .4em;
  padding: .65em 1.1em; border-radius: 999px;
  background: var(--button); color: #fff; text-decoration: none; font-weight: 600; font-size: .95rem;
  transition: background .15s;
}
.button:hover { background: var(--button-hover); color: #fff; }

/* ---------- Nagłówek i menu ---------- */

.site-header {
  position: sticky; top: 0; z-index: 20;
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 clamp(16px, 3vw, 32px);
  background: var(--header-bg);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: .55rem; color: var(--green-950); text-decoration: none; font-family: var(--font-display); font-weight: 650; font-size: 1.15rem; }
.brand-mark { width: 28px; height: 28px; color: var(--green-700); }

/* Menu celowo stonowane – mapa ma grać pierwsze skrzypce. */
.site-nav { margin-left: auto; }
.site-nav ul { list-style: none; display: flex; gap: 1.25rem; margin: 0; padding: 0; }
.site-nav a { color: var(--muted); text-decoration: none; font-size: .85rem; font-weight: 500; }
.site-nav a:hover, .site-nav a[aria-current='page'] { color: var(--green-800); }
.site-nav a[aria-current='page'] { text-decoration: underline; text-decoration-color: var(--green-300); text-decoration-thickness: 2px; text-underline-offset: 6px; }
.nav-toggle { display: none; }

/* Rozwijane „Inne mapy” (selektory z .nav-more, żeby nie łapały reguł listy menu) */
.site-nav .nav-more { position: relative; }
.nav-more-toggle {
  display: inline-flex; align-items: center; gap: .25rem; padding: 0; border: 0; background: none; cursor: pointer;
  color: var(--muted); font: inherit; font-size: .85rem; font-weight: 500;
}
.nav-more-toggle:hover, .nav-more.is-open .nav-more-toggle { color: var(--green-800); }
.nav-more-toggle svg { width: 12px; height: 12px; transition: transform .15s; }
.nav-more.is-open .nav-more-toggle svg { transform: rotate(180deg); }
.site-nav .nav-more .nav-dropdown {
  display: none; position: absolute; right: -8px; top: calc(100% + 12px); min-width: 220px; z-index: 30;
  flex-direction: column; gap: 0; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
}
/* Mostek nad odstępem – menu nie znika, gdy kursor przechodzi z przycisku na listę. */
.site-nav .nav-more .nav-dropdown::before { content: ''; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.site-nav .nav-more.is-open .nav-dropdown { display: flex; }
@media (hover: hover) and (min-width: 641px) {
  .site-nav .nav-more:hover .nav-dropdown { display: flex; }
}
.site-nav .nav-dropdown a { display: block; padding: .5rem .75rem; font-size: .9rem; color: var(--ink); border-radius: 8px; white-space: nowrap; }
.site-nav .nav-dropdown a:hover { background: var(--surface-2); color: var(--green-800); }
/* Ostatnia pozycja – strona główna serii, oddzielona od map linią. */
.site-nav .nav-dropdown .nav-dropdown-home { margin-top: 4px; padding-top: 4px; border-top: 1px solid var(--line); }

/* Przełącznik motywu: słońce / auto / księżyc – moduł theme (assets/theme/theme.css), wygląd jak dotąd przez zmienne
   --theme-switch-*; na telefonie jeden przycisk bieżącego trybu wielkości przycisku menu (38 px, zaokrąglony kwadrat). */
.site-header {
  --theme-switch-gap-left: 1.25rem;
  --theme-switch-gap-left-compact: .5rem;
  --theme-switch-size: 26px;
  --theme-switch-icon: 15px;
  --theme-switch-compact-icon: 18px;
  --theme-switch-border: var(--line);
  --theme-switch-bg: var(--surface);
  --theme-switch-fg: var(--muted);
  --theme-switch-fg-active: var(--green-800);
  --theme-switch-active: var(--surface-2);
  --theme-switch-focus: var(--green-500);
}
@media (max-width: 480px) {
  .theme-switch button[aria-pressed='true'] { width: 38px; height: 38px; border-radius: 10px; }
}

/* Przełącznik języka EN / PL – obok przełącznika motywu, w tym samym stylu (obramowana grupa, wybrany – wypełniony) */
.lang-switch { display: flex; gap: 2px; margin: 0 0 0 1.25rem; padding: 2px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.lang-switch a { padding: .2em .45em; border-radius: 5px; color: var(--muted); text-decoration: none; font-size: .72rem; font-weight: 600; letter-spacing: .04em; line-height: 1.3; }
.lang-switch a:hover { color: var(--green-800); }
.lang-switch a[aria-current='true'] { background: var(--surface-2); color: var(--green-800); }
@media (max-width: 640px) { .lang-switch { margin-left: .5rem; } }

/* Pasek „Ta strona jest też po polsku / in English” (przeglądarka w innym języku niż strona; zamknięcie zapamiętane) */
.lang-hint {
  position: fixed; z-index: 50; left: 12px; right: 12px; bottom: 16px; width: max-content; max-width: calc(100% - 24px); margin: 0 auto;
  display: flex; align-items: center; gap: 12px; padding: .6em .7em .6em 1em;
  background: var(--green-950); color: #fff; border-radius: 12px; box-shadow: var(--shadow); font-size: .92rem;
}
.lang-hint[hidden] { display: none; }
.lang-hint a { color: #fff; font-weight: 600; }
.lang-hint button { background: none; border: 0; color: inherit; font-size: 1.3rem; line-height: 1; cursor: pointer; }

/* Plakietka języka przy mapie serii bez wersji polskiej (rejestr serii) */
.more-lang { margin-left: .35em; padding: 0 .35em; border: 1px solid var(--line); border-radius: 4px; font-size: .68rem; font-weight: 600; color: var(--muted); }

@media (max-width: 640px) {
  .nav-toggle {
    display: grid; place-items: center; width: 38px; height: 38px; padding: 0;
    border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--muted); cursor: pointer;
  }
  .nav-toggle svg { width: 20px; height: 20px; }
  .site-nav { position: relative; }
  .site-nav ul {
    display: none; position: absolute; right: 0; top: calc(100% + 8px); min-width: 180px;
    flex-direction: column; gap: 0; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  }
  .site-nav.is-open ul { display: flex; }
  .site-nav ul a { display: block; padding: .55rem .75rem; font-size: .95rem; border-radius: 8px; }
  .site-nav ul a:hover { background: var(--surface-2); }
  /* Na telefonie „Inne mapy” rozwijają się wewnątrz menu, z wcięciem. */
  .nav-more-toggle { width: 100%; padding: .55rem .75rem; font-size: .95rem; border-radius: 8px; justify-content: space-between; }
  .nav-more-toggle:hover { background: var(--surface-2); }
  .site-nav .nav-more .nav-dropdown {
    position: static; min-width: 0; padding: 0 0 0 .75rem; border: 0; border-radius: 0; box-shadow: none; background: none;
  }
  .site-nav .nav-more .nav-dropdown::before { display: none; }
  .site-nav .nav-dropdown a { font-size: .9rem; color: var(--muted); }
}

/* ---------- Mapy: kolory w zielonej palecie ---------- */

.world-map {
  --wm-ocean: var(--map-ocean);
  --wm-sphere-stroke: var(--map-sphere);
  --wm-land: var(--map-land);
  --wm-land-hover: var(--map-land-hover);
  --wm-land-inactive: var(--map-inactive);
  --wm-border: var(--map-border);
  --wm-selected: var(--green-800);
  --wm-selected-outline: var(--green-950);
  --wm-hover-outline: var(--green-950);
  --wm-dot-stroke: var(--map-dot);
  --wm-tooltip-bg: var(--map-tip-bg);
  --wm-tooltip-fg: var(--map-tip-fg);
  --wm-control-bg: var(--surface);
  --wm-control-fg: var(--green-950);
  --wm-control-border: var(--line);
  --wm-font: var(--font);
}

.region-map {
  --rm-land: var(--region-land);
  --rm-land-hover: var(--region-hover);
  --rm-land-inactive: var(--region-land);
  --rm-border: var(--region-border);
  --rm-outline: var(--region-outline);
  --rm-frame: var(--region-border);
  --rm-hover-outline: var(--green-950);
  --rm-dot-stroke: var(--region-outline);
  --rm-tooltip-bg: var(--map-tip-bg);
  --rm-tooltip-fg: var(--map-tip-fg);
  --rm-control-bg: var(--surface);
  --rm-control-fg: var(--green-950);
  --rm-control-border: var(--line);
  --rm-font: var(--font);
}
.region-map .rm-region[data-fill] { transition: fill .2s; }

.swatch { display: inline-block; width: .8em; height: .8em; border-radius: 3px; vertical-align: -.05em; margin: 0 .25em 0 .9em; }
.swatch:first-child { margin-left: 0; }
.swatch-active { background: var(--map-land); }
.swatch-inactive { background: var(--map-inactive); }
.swatch-range { background: var(--range); }

/* ---------- Strona główna: mapa w centrum, podgląd po prawej ---------- */

.map-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 20px;
  padding: 16px clamp(16px, 2vw, 28px) 20px;
  height: calc(100dvh - var(--header-h));
  min-height: 520px;
}
.map-area { position: relative; min-width: 0; display: flex; flex-direction: column; }
.world-map { flex: 1; min-height: 0; }
.map-hint { margin: .5rem 0 0; font-size: .8rem; color: var(--muted); text-align: center; }

.preview {
  min-height: 0; overflow: auto;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
}
.preview-intro h1 { font-size: 2rem; }
.search input {
  width: 100%; padding: .75em 1em; font: inherit; color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2);
}
.search input:focus { outline: none; border-color: var(--green-500); background: var(--surface); box-shadow: 0 0 0 3px var(--green-100); }
.stats { display: flex; gap: 1rem; margin: 1.4rem 0 0; }
.stats div { flex: 1; padding: .8rem 1rem; border-radius: var(--radius-sm); background: var(--surface-2); }
.stats dt { font-size: .8rem; color: var(--muted); order: 2; }
.stats dd { margin: 0; font-family: var(--font-display); font-size: 1.7rem; font-weight: 650; color: var(--green-800); line-height: 1.1; }
.stats div { display: flex; flex-direction: column-reverse; }
.stats-wide { max-width: 420px; margin-bottom: 2rem; }

.pv { position: relative; }
.pv h2 { font-size: 1.75rem; margin-bottom: .4rem; padding-right: 2rem; }
.pv h2 a { color: inherit; text-decoration: none; }
.pv h2 a:hover { text-decoration: underline; text-decoration-color: var(--green-300); }
.pv-close {
  position: absolute; top: -8px; right: -8px; width: 34px; height: 34px;
  border: 0; border-radius: 50%; background: transparent; color: var(--muted); font-size: 1.5rem; line-height: 1; cursor: pointer;
}
.pv-close:hover { background: var(--surface-2); color: var(--ink); }
.pv-intro { font-size: .9rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pv-list { list-style: none; margin: 0 0 1.2rem; padding: 0; display: grid; gap: 4px; }
.pv-list a {
  display: grid; grid-template-columns: 72px 1fr; gap: 12px; align-items: start;
  padding: 8px; margin: 0 -8px; border-radius: var(--radius-sm); color: inherit; text-decoration: none;
}
.pv-list a:hover { background: var(--surface-2); }
.pv-list img { width: 72px; height: 54px; object-fit: cover; border-radius: 7px; background: var(--surface-2); }
.pv-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.pv-text strong { font-size: .95rem; color: var(--green-950); }
.pv-rank { color: var(--green-500); }
.pv-text em { font-size: .8rem; color: var(--muted); }
.pv-short { font-size: .82rem; color: var(--ink); margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.is-loading li { display: grid; grid-template-columns: 72px 1fr; gap: 12px; padding: 8px 0; }
.sk-img, .sk-text { display: block; height: 54px; border-radius: 7px; background: linear-gradient(90deg, var(--surface-2), var(--shimmer), var(--surface-2)); background-size: 200% 100%; animation: shimmer 1.2s infinite linear; }
.sk-text { height: 36px; }
@keyframes shimmer { to { background-position: -200% 0; } }

@media (max-width: 900px) {
  .map-stage { grid-template-columns: 1fr; height: auto; min-height: 0; padding-top: 8px; }
  .world-map { flex: none; }
  .preview { overflow: visible; scroll-margin-top: calc(var(--header-h) + 12px); }
}

/* ---------- Podstrony ---------- */

.page { max-width: 1200px; margin: 0 auto; padding: 20px clamp(16px, 3vw, 32px) 56px; }
.crumbs { display: flex; flex-wrap: wrap; gap: .5rem; font-size: .85rem; color: var(--muted); margin-bottom: 1.25rem; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--green-800); }
.crumbs [aria-current] { color: var(--ink); }

/* Kraj */
.country-hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px; align-items: center; margin-bottom: 32px; }
.country-hero-map {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow);
  position: relative;
}
.country-hero-map .region-map { height: min(46vh, 420px); }
#map-caption { font-weight: 600; color: var(--green-800); }
.hint-inline { font-size: .85rem; color: var(--muted); }
.hint-inline::before { content: '↓ '; color: var(--green-500); }

.plant-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; }
.plant-card {
  display: flex; flex-direction: column; height: 100%;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s, border-color .15s;
}
.plant-card:hover, .plant-card.is-active { border-color: var(--green-300); box-shadow: var(--shadow); }
.plant-card:hover { transform: translateY(-2px); }
.plant-card figure { position: relative; margin: 0; aspect-ratio: 4 / 3; background: var(--surface-2); }
.plant-card img { width: 100%; height: 100%; object-fit: cover; }
.rank {
  position: absolute; top: 10px; left: 10px; width: 30px; height: 30px; display: grid; place-items: center;
  border-radius: 50%; background: var(--glass); color: var(--green-800); font-weight: 600; font-size: .9rem;
}
.plant-card-body { padding: 14px 16px 18px; display: flex; flex-direction: column; gap: 2px; }
.plant-card h2 { font-size: 1.15rem; margin: 0; }
.plant-card .meta { margin: 0 0 4px; font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.symbol { color: var(--accent); }
.plant-card .latin { font-size: .85rem; }
.plant-card .short { margin: 8px 0 0; font-size: .88rem; }

/* Roślina: zdjęcie z mapą występowania nałożoną z prawej */
.plant-hero { position: relative; margin-bottom: 32px; }
.plant-photo { margin: 0; }
.plant-photo img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; border-radius: var(--radius); background: var(--surface-2); }
.plant-photo figcaption { margin-top: .5rem; font-size: .75rem; color: var(--muted); }
.plant-photo figcaption a { color: inherit; }
.range-card {
  position: absolute; top: 20px; right: 20px; width: min(360px, 36%);
  background: var(--glass); backdrop-filter: blur(6px);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 16px 12px;
}
.range-card h2 { font-size: 1rem; margin-bottom: .5rem; }
.range-card .region-map { height: clamp(200px, 26vw, 330px); }
.legend { margin: .5rem 0 0; font-size: .8rem; color: var(--muted); }

/* Eksport mapy do PNG (moduł export: assets/export/export.css) – przycisk w rogu mapy świata albo obok legendy mapy kraju */
:root { --export-ink-2: var(--muted); --export-line: var(--line); --export-hover: var(--surface-2); }
.map-export-wrap { position: relative; }
.map-export-home { position: absolute; z-index: 4; top: 10px; left: 10px; }
.map-foot { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-top: .5rem; }
.map-foot .legend { margin: 0; }
.map-foot .map-export-wrap { flex: none; }
/* Eksport mapy kraju przekolorowuje regiony – bez płynnego przejścia, żeby kopia miała już nowe kolory */
.region-map.no-transition .rm-region { transition: none !important; }

.plant-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; }
.plant-head h1 { margin-bottom: .2rem; }
.plant-head .latin { font-size: 1.1rem; margin-bottom: 1.2rem; }
.local { font-style: normal; font-size: .95rem; }
.plant-body { max-width: 68ch; }
.plant-body h2 { margin-top: 1.8rem; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: .8rem; }
.badge { padding: .25em .7em; border-radius: 999px; background: var(--surface-2); color: var(--green-800); font-size: .78rem; font-weight: 500; }
.badge-rank { background: var(--button); color: #fff; }
.badge-symbol { background: var(--symbol-bg); color: var(--symbol-ink); }
.region-list { columns: 2 200px; padding-left: 1.1rem; font-size: .9rem; color: var(--muted); }
.more a { margin-right: .8rem; }

.plant-side h2 { font-size: 1.05rem; }
.sibling-list { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; gap: 2px; }
.sibling-list a { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; padding: 6px; border-radius: var(--radius-sm); color: inherit; text-decoration: none; }
.sibling-list a:hover { background: var(--surface-2); }
.sibling-list a[aria-current] { background: var(--green-100); }
.sibling-list img { width: 64px; height: 48px; object-fit: cover; border-radius: 6px; }
.sibling-list span { display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
.sibling-list strong { font-size: .92rem; font-weight: 600; color: var(--green-950); }
.sibling-list em { font-size: .78rem; color: var(--muted); }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.chips a { display: inline-block; padding: .3em .8em; border: 1px solid var(--line); border-radius: 999px; font-size: .85rem; text-decoration: none; color: var(--green-800); background: var(--surface); }
.chips a:hover { border-color: var(--green-300); background: var(--green-100); }

.prose-page { max-width: 760px; }
.prose-page h2 { margin-top: 2rem; }
.error-page { padding-top: 12vh; text-align: center; }

.site-footer { border-top: 1px solid var(--line); padding: 20px clamp(16px, 3vw, 32px); font-size: .8rem; color: var(--muted); text-align: center; }
.site-footer p { margin: 0 0 .35em; }
.site-footer p:last-child { margin-bottom: 0; }
.site-footer a { color: inherit; }
/* Ikonki kanałów marki w stopce (Series::socialLinks, moduł series): kolor tekstu stopki, przy najechaniu i fokusie jaśniej */
.series-social-link { transition: opacity .15s; }
.series-social-link:hover, .series-social-link:focus-visible { opacity: .7; }

/* ---------- Kontakt ---------- */

.contact-form { display: grid; gap: 1.1rem; margin: 1.5rem 0 1.25rem; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.field { display: grid; gap: .35rem; }
.field label { font-weight: 600; font-size: .92rem; color: var(--green-950); }
.field input, .field textarea {
  width: 100%; padding: .7em .9em; font: inherit; color: var(--ink);
  border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2);
}
.field textarea { min-height: 10rem; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--green-500); background: var(--surface); box-shadow: 0 0 0 3px var(--green-100); }
.field [aria-invalid='true'] { border-color: var(--danger); }
.field-error { margin: 0; font-size: .85rem; color: var(--danger); }
.field-consent label { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; font-size: .9rem; color: var(--ink); }
.field-consent input { width: 1.1rem; height: 1.1rem; margin-top: .2rem; flex: none; accent-color: var(--green-800); }
.req { color: var(--danger); }
.form-note, .contact-clause { font-size: .85rem; color: var(--muted); }
.form-note { margin: 0; }
.contact-form .button { justify-self: start; border: 0; cursor: pointer; font-family: inherit; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: .8rem 1rem; border-radius: var(--radius-sm); font-size: .95rem; }
.alert-error { background: var(--danger-bg); color: var(--danger-ink); }
.alert-success { background: var(--green-100); color: var(--green-950); }

@media (max-width: 960px) {
  .country-hero { grid-template-columns: 1fr; gap: 20px; }
  .range-card { position: static; width: auto; margin-top: 16px; background: var(--surface); border: 1px solid var(--line); }
  .range-card .region-map { height: 280px; }
  .plant-photo img { aspect-ratio: 4 / 3; }
  .plant-layout { grid-template-columns: 1fr; gap: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media (hover: none) {
  .hint-inline { display: none; }
}

.notice { padding: .8rem 1rem; border-radius: var(--radius-sm); background: var(--symbol-bg); color: var(--notice-ink); font-size: .9rem; }
.notice code { font-size: .85em; background: var(--code-bg); padding: .1em .35em; border-radius: 4px; }

/* ---------- Quiz (/quiz – moduł quiz z assets; mapa – kolory .world-map) ---------- */
.quiz-page-wrap.prose-page { max-width: 1100px; }
.quiz-stage { margin: 1.2rem 0 2rem; }
.quiz-stage .quiz { --quiz-accent: var(--button); --quiz-surface: var(--surface); --quiz-ok: var(--green-700); --quiz-bad: var(--danger); --quiz-target: var(--green-300); }
.quiz-map { position: relative; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
