/*
 * eGołębnik marketing site. Brand colors as in web/src/theme/brand.ts; light and dark follow the system.
 * Layout ideas taken from the breeder's world (race result sheet, numbered index, flight route) drawn in a clean,
 * modern way. System fonts only (CSP font-src 'self'); monospace just for ring numbers and race figures.
 */
:root {
  --primary: #3563b0;
  --primary-dark: #244a8a;
  --primary-soft: #e8eefa;
  --accent: #0d9488;
  --accent-soft: #e6f6f4;
  --text: #0f172a;
  --muted: #475569;
  --bg: #ffffff;
  --bg-tint: #f6f8fc;
  --card: #ffffff;
  --border: #e2e8f0;
  --line: #cbd5e1;
  --shadow: 0 1px 2px rgb(15 23 42 / 0.05), 0 12px 32px rgb(15 23 42 / 0.08);
  --shadow-lg: 0 2px 4px rgb(15 23 42 / 0.04), 0 24px 56px rgb(36 74 138 / 0.16);
  --on-primary: #ffffff;
  --on-primary-soft: rgb(255 255 255 / 0.78);
  --danger: #b91c1c;
  --danger-line: #dc2626;
  --danger-soft: rgb(220 38 38 / 0.06);
  --radius: 14px;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Segoe UI Mono", Menlo, Consolas, monospace;
  --max: 1200px;
  --gutter: 20px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --primary: #7fa6ec;
    --primary-dark: #a7c3f3;
    --primary-soft: rgb(127 166 236 / 0.12);
    --accent: #2dd4bf;
    --accent-soft: rgb(45 212 191 / 0.12);
    --text: #f1f5f9;
    --muted: #94a3b8;
    --bg: #0b1222;
    --bg-tint: #101a2f;
    --card: #131d33;
    --border: rgb(148 163 184 / 0.16);
    --line: rgb(148 163 184 / 0.32);
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 12px 32px rgb(0 0 0 / 0.3);
    --shadow-lg: 0 2px 4px rgb(0 0 0 / 0.3), 0 24px 56px rgb(0 0 0 / 0.45);
    --on-primary: #0b1222;
    --on-primary-soft: rgb(11 18 34 / 0.75);
    --danger: #fca5a5;
    --danger-line: rgb(248 113 113 / 0.6);
    --danger-soft: rgb(248 113 113 / 0.08);
  }
}

/* ---------- Base ---------- */

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

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

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--primary);
  text-underline-offset: 0.18em;
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0 0 0.5em;
}

h1 {
  font-size: clamp(2.3rem, 5.2vw, 4rem);
  letter-spacing: -0.035em;
}

h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
}

h3 {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h1 em,
h2 em {
  font-style: normal;
  color: var(--primary);
}

p {
  margin: 0 0 1em;
}

.icon {
  width: 1.15em;
  height: 1.15em;
  fill: currentColor;
  flex-shrink: 0;
  vertical-align: -0.2em;
}

.muted {
  color: var(--muted);
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container--narrow {
  max-width: 800px;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 16px;
  top: 16px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--primary);
  color: var(--on-primary);
}

/* Section label: "01  Funkcje ———" */
.label {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary);
}

.label::after {
  content: "";
  flex: 1;
  max-width: 120px;
  height: 2px;
  border-radius: 2px;
  background: var(--primary-soft);
}

.label-number {
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  height: 24px;
  padding: 0 6px;
  border-radius: 6px;
  background: var(--primary-soft);
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

/* ---------- Buttons and links ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 20px;
  border: 0;
  border-radius: 10px;
  background: var(--primary);
  color: var(--on-primary);
  font: 650 1rem/1.2 var(--sans);
  text-decoration: none;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.1), 0 6px 16px rgb(53 99 176 / 0.25);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}

.button:hover {
  color: var(--on-primary);
  background: var(--primary-dark);
  transform: translateY(-1px);
}

.button .icon {
  transition: transform 0.15s ease;
}

.button:hover .icon {
  transform: translateX(3px);
}

.button--small {
  padding: 8px 14px;
  font-size: 0.92rem;
  box-shadow: none;
}

.button--large {
  padding: 15px 26px;
  font-size: 1.06rem;
}

/* On a brand-colored background. */
.button--light,
.button--light:hover {
  background: var(--on-primary);
  color: var(--primary-dark);
  box-shadow: 0 6px 16px rgb(0 0 0 / 0.15);
}

@media (prefers-color-scheme: dark) {
  .button--light,
  .button--light:hover {
    color: #a7c3f3;
  }
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 650;
  text-decoration: none;
  border-bottom: 2px solid var(--primary-soft);
  padding-bottom: 2px;
  transition:
    border-color 0.15s ease,
    color 0.15s ease;
}

.text-link:hover {
  color: var(--primary);
  border-color: var(--primary);
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.6) blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
}

.brand-logo {
  display: inline-flex;
}

.brand-logo img {
  display: block;
  width: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-left: auto;
}

.site-nav a:not(.button) {
  color: var(--muted);
  font-size: 0.97rem;
  font-weight: 550;
  text-decoration: none;
}

.site-nav a:not(.button):hover,
.site-nav a[aria-current="page"] {
  color: var(--text);
}

.site-nav a[aria-current="page"] {
  box-shadow: inset 0 -2px 0 var(--primary);
}

.nav-check {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.nav-button {
  display: none;
  margin-left: auto;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  cursor: pointer;
  line-height: 0;
}

.nav-button .icon {
  width: 22px;
  height: 22px;
}

.nav-check:focus-visible + .nav-button {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .nav-button {
    display: block;
  }

  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }

  .site-nav a:not(.button) {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
  }

  .site-nav a[aria-current="page"] {
    box-shadow: none;
    color: var(--primary);
  }

  .site-nav .button {
    margin-top: 16px;
  }

  .nav-check:checked ~ .site-nav {
    display: flex;
  }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 80px 0 96px;
  overflow: hidden;
  background:
    radial-gradient(60% 70% at 85% 30%, var(--primary-soft), transparent 70%),
    linear-gradient(var(--bg), var(--bg));
}

/* Faint grid, like squared paper in a breeding notebook. */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(70% 80% at 80% 40%, #000, transparent 75%);
  opacity: 0.6;
  pointer-events: none;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-grid > * {
  min-width: 0;
}

.hero-title {
  margin-bottom: 24px;
  overflow-wrap: break-word;
}

.hero-title em {
  display: block;
}

.hero-lead {
  max-width: 34em;
  font-size: 1.15rem;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 28px;
  margin: 32px 0 28px;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.92rem;
  color: var(--muted);
}

.hero-points li::before {
  content: "✓";
  margin-right: 8px;
  color: var(--accent);
  font-weight: 800;
}

/* Race result card */
.hero-art {
  position: relative;
}

.sheet {
  position: relative;
  padding: 24px 24px 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-lg);
}

.sheet-head {
  display: grid;
  gap: 2px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.sheet-kicker {
  justify-self: start;
  margin-bottom: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
}

.sheet-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.sheet-meta {
  font-size: 0.85rem;
  color: var(--muted);
}

.sheet-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  font-variant-numeric: tabular-nums;
}

.sheet-table th {
  padding: 12px 8px 8px;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 650;
  color: var(--muted);
}

.sheet-table td {
  padding: 10px 8px;
  border-top: 1px solid var(--border);
  white-space: nowrap;
}

.sheet-table td:nth-child(2) {
  font-family: var(--mono);
  font-size: 0.84rem;
}

.sheet-table th:last-child,
.sheet-table td:last-child {
  text-align: right;
  font-weight: 650;
}

.sheet-table tbody tr:first-child td {
  background: var(--primary-soft);
  font-weight: 700;
}

.sheet-table tbody tr:first-child td:first-child {
  border-radius: 8px 0 0 8px;
  color: var(--primary);
}

.sheet-table tbody tr:first-child td:last-child {
  border-radius: 0 8px 8px 0;
}

.sheet-table tbody tr:first-child td,
.sheet-table tbody tr:nth-child(2) td {
  border-top-color: transparent;
}

.sheet-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.sheet-foot .icon {
  color: var(--accent);
}

.float-badge {
  position: absolute;
  top: -22px;
  right: -22px;
  display: grid;
  padding: 12px 18px;
  border-radius: 14px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 28px rgb(13 148 136 / 0.35);
}

.float-badge strong {
  font-size: 1.5rem;
  line-height: 1.1;
}

.float-badge span {
  font-size: 0.82rem;
  opacity: 0.9;
}

@media (prefers-color-scheme: dark) {
  .float-badge {
    color: #062b28;
    box-shadow: 0 12px 28px rgb(0 0 0 / 0.4);
  }
}

/* ---------- Figures band ---------- */

.ledger {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg-tint);
}

.ledger-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.ledger-grid div {
  display: grid;
  gap: 2px;
  padding: 28px 24px;
  border-left: 1px solid var(--border);
}

.ledger-grid div:first-child {
  border-left: 0;
  padding-left: 0;
}

.ledger-grid strong {
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--primary);
}

.ledger-grid span {
  font-size: 0.92rem;
  color: var(--muted);
}

/* ---------- Sections ---------- */

.section {
  padding: 96px 0;
}

.section--tight {
  padding: 40px 0 96px;
}

.section--band {
  background: var(--bg-tint);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-head {
  max-width: 760px;
  margin-bottom: 48px;
}

.section-head--row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  max-width: none;
}

.section-head--row > div {
  flex: 1;
}

.section-lead,
.page-lead {
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 40em;
}

/* Features: a numbered index in two columns instead of a wall of cards. */
.index {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0 56px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: feature;
}

.index-item {
  position: relative;
  padding: 26px 0 24px 60px;
  border-top: 1px solid var(--border);
  counter-increment: feature;
}

.index-item::before {
  content: counter(feature, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 27px;
  font-size: 0.95rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--line);
  transition: color 0.15s ease;
}

.index-item:hover::before {
  color: var(--primary);
}

.index-item h3 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.index-item h3 .icon {
  order: 2;
  width: 36px;
  height: 36px;
  padding: 8px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
}

.index-item p {
  margin: 0;
  color: var(--muted);
}

/* Steps as a flight route: dashed line between stops, the home loft as the goal. */
.route {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: stop;
}

.route-stop {
  position: relative;
  padding-top: 72px;
  counter-increment: stop;
}

.route-stop::before {
  content: counter(stop);
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 2px solid var(--primary);
  border-radius: 50%;
  background: var(--card);
  color: var(--primary);
  font-size: 1.15rem;
  font-weight: 800;
}

.route-stop::after {
  content: "";
  position: absolute;
  top: 23px;
  left: 56px;
  right: -24px;
  border-top: 2px dashed var(--line);
}

.route-stop:last-child::before {
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: 0 0 0 6px var(--primary-soft);
}

.route-stop:last-child::after {
  display: none;
}

.route-stop p {
  margin: 0;
  color: var(--muted);
}

/* Comparison */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.compare-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
}

.compare-table th,
.compare-table td {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.compare-table thead th {
  border-top: 0;
  background: var(--bg-tint);
  font-size: 0.85rem;
  font-weight: 650;
  color: var(--muted);
}

.compare-table thead th:last-child {
  background: var(--primary-soft);
  color: var(--primary);
}

.compare-table tbody th {
  font-weight: 650;
}

.compare-table .old {
  color: var(--muted);
}

.compare-table .new {
  font-weight: 600;
  background: color-mix(in srgb, var(--primary-soft) 45%, transparent);
}

.compare-table .new::before {
  content: "✓";
  margin-right: 10px;
  color: var(--accent);
  font-weight: 800;
}

/* Quotes: three columns split by thin rules. */
.quotes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.quote {
  margin: 0;
  padding: 0 32px;
  border-left: 1px solid var(--border);
}

.quote:first-child {
  padding-left: 0;
  border-left: 0;
}

.quote blockquote {
  margin: 0 0 18px;
  font-size: 1.12rem;
  line-height: 1.55;
}

.quote blockquote::before {
  content: "”";
  display: block;
  height: 0.55em;
  margin-bottom: 10px;
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1;
  color: var(--primary);
}

.quote figcaption {
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--muted);
}

.quote figcaption::before {
  content: "— ";
}

/* ---------- Articles ---------- */

.articles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px 28px;
}

.article-link {
  display: block;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.article-cover {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  transition: transform 0.25s ease;
}

.article-link:hover .article-cover {
  transform: translateY(-3px);
}

.article-cover--empty {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--primary-soft), var(--accent-soft));
}

.article-body {
  padding-top: 16px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin: 0 0 6px;
  font-size: 0.85rem;
  color: var(--muted);
}

.article-meta > * + *::before {
  content: "·";
  margin-right: 10px;
}

.article-title {
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.article-link:hover .article-title {
  color: var(--primary);
}

.article-lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-top: 64px;
  font-size: 0.95rem;
  color: var(--muted);
}

.pagination a {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-weight: 600;
  text-decoration: none;
}

.empty {
  padding: 48px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  text-align: center;
  color: var(--muted);
}

.empty p {
  margin: 0;
}

/* ---------- Page head (lists, documents) ---------- */

.page-head {
  padding: 64px 0 36px;
  background: linear-gradient(var(--bg-tint), var(--bg));
}

.page-head h1 {
  margin-bottom: 14px;
}

.page-head .page-lead {
  margin: 0;
}

.page-head--center {
  text-align: center;
  padding: 120px 0;
}

.page-head--center .page-lead {
  margin: 0 auto 32px;
}

/* ---------- Article page ---------- */

.post-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 72px;
  align-items: start;
  padding-top: 48px;
  padding-bottom: 96px;
}

.back {
  display: inline-block;
  margin-bottom: 24px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
}

.back:hover {
  color: var(--primary);
}

.post-head {
  padding-bottom: 28px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.post-head h1 {
  font-size: clamp(2.1rem, 4.4vw, 3.3rem);
}

.post-lead {
  margin: 18px 0 0;
  font-size: 1.25rem;
  line-height: 1.55;
  color: var(--muted);
}

.post-cover {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  margin-bottom: 36px;
  border-radius: var(--radius);
}

.prose {
  max-width: 46em;
  font-size: 1.1rem;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.prose h2 {
  margin-top: 1.8em;
  font-size: 1.65rem;
}

.prose h3 {
  margin-top: 1.6em;
  font-size: 1.3rem;
}

.prose img,
.prose iframe,
.prose video {
  display: block;
  max-width: 100%;
  margin: 1.6em auto;
  border-radius: 12px;
}

.prose iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border: 0;
}

.prose blockquote {
  margin: 1.6em 0;
  padding: 14px 22px;
  border-left: 4px solid var(--primary);
  border-radius: 0 12px 12px 0;
  background: var(--primary-soft);
}

.prose blockquote p:last-child {
  margin: 0;
}

.prose table {
  display: block;
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.prose th,
.prose td {
  padding: 8px 12px;
  border: 1px solid var(--border);
  vertical-align: top;
  text-align: left;
}

.prose th {
  background: var(--bg-tint);
}

.prose li {
  margin-bottom: 6px;
}

.prose li::marker {
  color: var(--primary);
}

.prose hr {
  margin: 2.4em 0;
  border: 0;
  border-top: 1px solid var(--border);
}

.legal {
  font-size: 1rem;
  line-height: 1.65;
}

.legal-meta {
  color: var(--muted);
}

.legal-form {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: var(--bg-tint);
}

/* Right column next to an article */
.post-aside {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 28px;
}

.aside-cta {
  position: relative;
  overflow: hidden;
  padding: 28px 26px;
  border-radius: 18px;
  background: linear-gradient(160deg, #3563b0, #244a8a);
  color: #fff;
  box-shadow: var(--shadow-lg);
}

/* Flight path drawn behind the text. */
.aside-cta::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 220px;
  height: 220px;
  border: 2px dashed rgb(255 255 255 / 0.18);
  border-radius: 50%;
  pointer-events: none;
}

.aside-cta img {
  display: block;
  margin-bottom: 22px;
}

.aside-cta h2 {
  max-width: 11em;
  font-size: 1.5rem;
  line-height: 1.2;
}

.aside-cta p {
  color: rgb(255 255 255 / 0.8);
  font-size: 0.95rem;
}

.aside-checks {
  display: grid;
  gap: 8px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
  font-size: 0.95rem;
}

.aside-checks li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.aside-checks .icon {
  color: #5eead4;
  margin-top: 0.2em;
}

.aside-cta .button--light,
.aside-cta .button--light:hover {
  background: #fff;
  color: #244a8a;
}

.aside-button {
  width: 100%;
}

.aside-login {
  margin: 16px 0 0;
  text-align: center;
}

.aside-cta .aside-login a {
  color: #fff;
  font-weight: 650;
}

.aside-card {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--card);
}

.aside-title {
  font-size: 1.15rem;
  margin-bottom: 6px;
}

.aside-features {
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.aside-features li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.aside-features .icon {
  width: 32px;
  height: 32px;
  padding: 7px;
  border-radius: 9px;
  background: var(--primary-soft);
  color: var(--primary);
}

.aside-features strong,
.aside-features li > span > span {
  display: block;
}

.aside-features li > span > span {
  font-size: 0.9rem;
  color: var(--muted);
}

.aside-stats {
  display: grid;
  grid-template-columns: repeat(3, auto);
  justify-content: space-between;
  padding: 18px 22px;
  border-radius: 18px;
  background: var(--bg-tint);
  border: 1px solid var(--border);
}

.aside-stats div {
  display: grid;
}

.aside-stats strong {
  font-size: 1.3rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--primary);
}

.aside-stats span {
  font-size: 0.82rem;
  color: var(--muted);
}

/* ---------- Contact ---------- */

.contact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.contact-card {
  display: flex;
  gap: 16px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  color: inherit;
  text-decoration: none;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.contact-card:hover {
  color: inherit;
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.contact-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 1.3rem;
}

.contact-card strong {
  display: block;
  font-size: 1.1rem;
}

.contact-card .muted {
  display: block;
  font-size: 0.95rem;
}

/* ---------- Closing call to action ---------- */

.cta {
  padding: 0 0 96px;
}

.cta-box {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  max-width: calc(var(--max) - 2 * var(--gutter));
  padding: 64px 56px;
  border-radius: 24px;
  background: linear-gradient(140deg, #3563b0, #244a8a);
  color: #fff;
}

.cta-box::after {
  content: "";
  position: absolute;
  right: -120px;
  bottom: -160px;
  width: 420px;
  height: 420px;
  border: 2px dashed rgb(255 255 255 / 0.16);
  border-radius: 50%;
  pointer-events: none;
}

.cta h2 {
  max-width: 14em;
  font-size: clamp(1.9rem, 3.8vw, 2.8rem);
}

.cta h2 em {
  color: #99f6e4;
}

.cta p {
  margin: 0;
  color: rgb(255 255 255 / 0.82);
  font-size: 1.1rem;
}

.cta .button {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  background: #fff;
  color: #244a8a;
}

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

.site-footer {
  padding: 64px 0 28px;
  border-top: 1px solid var(--border);
  background: var(--bg-tint);
  font-size: 0.95rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}

.footer-grid nav {
  display: grid;
  align-content: start;
  gap: 8px;
}

.footer-grid nav a {
  color: var(--muted);
  text-decoration: none;
}

.footer-grid nav a:hover {
  color: var(--primary);
}

.footer-title {
  margin: 0 0 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
}

.footer-motto {
  max-width: 24em;
  margin-top: 14px;
  color: var(--muted);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 0.88rem;
  color: var(--muted);
}

.footer-bottom a {
  color: inherit;
}

/* ---------- Responsive ---------- */

@media (max-width: 1000px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .hero-art {
    max-width: 560px;
  }

  .post-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 56px;
  }

  .post-aside {
    position: static;
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .aside-stats {
    grid-column: 1 / -1;
  }

  .route {
    grid-template-columns: 1fr 1fr;
    gap: 40px 32px;
  }

  .route-stop:nth-child(2)::after {
    display: none;
  }

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

  .quotes {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .quote,
  .quote:first-child {
    padding: 28px 0 0;
    border-left: 0;
    border-top: 1px solid var(--border);
  }

  .cta-box {
    padding: 48px 36px;
  }
}

@media (max-width: 760px) {
  body {
    font-size: 16px;
  }

  .hero {
    padding: 44px 0 64px;
  }

  .section {
    padding: 64px 0;
  }

  .section-head {
    margin-bottom: 32px;
  }

  .section-head--row {
    display: block;
  }

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

  .ledger-grid div,
  .ledger-grid div:first-child {
    padding: 20px 0;
    border-left: 0;
  }

  .ledger-grid div:nth-child(even) {
    padding-left: 20px;
    border-left: 1px solid var(--border);
  }

  .ledger-grid div:nth-child(n + 3) {
    border-top: 1px solid var(--border);
  }

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

  .index-item {
    padding-left: 44px;
  }

  .route {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .route-stop {
    min-height: 80px;
    padding: 0 0 32px 72px;
  }

  .route-stop::after,
  .route-stop:nth-child(2)::after {
    display: block;
    top: 56px;
    bottom: 8px;
    left: 23px;
    right: auto;
    border-top: 0;
    border-left: 2px dashed var(--line);
  }

  .route-stop:last-child::after {
    display: none;
  }

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

  .sheet {
    padding: 18px 12px 14px;
  }

  .sheet-table {
    font-size: 0.78rem;
  }

  .sheet-table td:nth-child(2) {
    font-size: 0.74rem;
  }

  .sheet-table th,
  .sheet-table td {
    padding-left: 4px;
    padding-right: 4px;
  }

  .hero-title em {
    display: inline;
  }

  .float-badge {
    top: -18px;
    right: 8px;
    padding: 8px 14px;
  }

  .float-badge strong {
    font-size: 1.2rem;
  }

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

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

  .cta {
    padding-bottom: 64px;
  }

  .cta-box {
    flex-direction: column;
    align-items: flex-start;
    padding: 40px 24px;
    border-radius: 18px;
  }

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

  .footer-grid > div:first-child {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .button,
  .button .icon,
  .contact-card,
  .article-cover {
    transition: none;
  }
}

@media print {
  .site-header,
  .site-footer,
  .post-aside,
  .cta {
    display: none;
  }

  .post-layout {
    display: block;
  }
}

/* ---------- FAQ ---------- */

.faq-group + .faq-group {
  margin-top: 48px;
}

.faq-title {
  font-size: 1.35rem;
  margin-bottom: 14px;
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
}

.faq-item + .faq-item {
  margin-top: 10px;
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  font-weight: 650;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1;
}

.faq-item[open] {
  border-color: var(--primary);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item summary:hover {
  color: var(--primary);
}

.faq-item p {
  margin: 0;
  padding: 0 20px 18px;
  color: var(--muted);
}

.faq-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 56px;
  padding: 28px;
  border-radius: 18px;
  background: var(--primary-soft);
}

.faq-cta h2 {
  font-size: 1.4rem;
  margin-bottom: 4px;
}

.faq-cta p {
  margin: 0;
  color: var(--muted);
}

/* ---------- About ---------- */

.about-figures {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-tint);
}

.about-figures div {
  display: grid;
  padding: 22px 24px;
}

.about-figures div + div {
  border-left: 1px solid var(--border);
}

.about-figures strong {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--primary);
}

.about-figures span {
  font-size: 0.92rem;
  color: var(--muted);
}

.about .prose h2:first-child {
  margin-top: 0;
}

.about-heading {
  margin: 56px 0 24px;
  font-size: 1.65rem;
}

.about-values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.about-values article {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.about-values .icon {
  width: 40px;
  height: 40px;
  margin-bottom: 14px;
  padding: 9px;
  border-radius: 11px;
  background: var(--primary-soft);
  color: var(--primary);
}

.about-values h3 {
  margin-bottom: 6px;
}

.about-values p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--muted);
}

.about-owner {
  margin-top: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

.about-owner h2 {
  font-size: 1.35rem;
}

.about-owner p {
  margin: 0;
  color: var(--muted);
}

@media (max-width: 760px) {
  .faq-cta {
    flex-direction: column;
    align-items: flex-start;
  }

  .about-figures,
  .about-values {
    grid-template-columns: 1fr;
  }

  .about-figures div + div {
    border-left: 0;
    border-top: 1px solid var(--border);
  }
}

/* ---------- Race calculators (/kalkulator-predkosci-golebi) ---------- */

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: start;
}

.calc-card {
  display: grid;
  gap: 16px;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
  scroll-margin-top: 96px;
}

.calc-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 1.35rem;
}

.calc-title .icon {
  color: var(--primary);
}

.calc-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.calc-field {
  display: grid;
  gap: 6px;
  align-content: start;
}

.calc-field label,
.calc-set legend {
  font-size: 0.95rem;
  font-weight: 650;
}

.calc-field input,
.calc-field select {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

.calc-field select {
  font-family: var(--sans);
}

.calc-field input:focus,
.calc-field select:focus {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
  border-color: var(--primary);
}

.calc-set {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}

.calc-set legend {
  padding: 0;
  margin-bottom: 10px;
  color: var(--muted);
}

.calc-hint,
.calc-note {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
}

.calc-card .button {
  justify-self: start;
}

.calc-error {
  margin: 0;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid var(--danger-line);
  color: var(--danger);
  background: var(--danger-soft);
}

.calc-result {
  display: grid;
  gap: 12px;
  padding: 20px;
  border-radius: 12px;
  background: var(--primary-soft);
}

.calc-figure {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0;
}

.calc-figure strong {
  font-family: var(--mono);
  font-size: 2.4rem;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: var(--primary-dark);
}

.calc-figure span {
  font-weight: 650;
  color: var(--muted);
}

.calc-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
  margin: 0;
}

.calc-facts dt {
  font-size: 0.82rem;
  color: var(--muted);
}

.calc-facts dd {
  margin: 0;
  font-family: var(--mono);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.calc-formula {
  padding: 14px 18px;
  border-left: 4px solid var(--primary);
  border-radius: 0 10px 10px 0;
  background: var(--card);
  font-family: var(--mono);
  font-weight: 650;
}

@media (max-width: 900px) {
  .calc-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .calc-card {
    padding: 20px;
  }

  .calc-row {
    grid-template-columns: 1fr;
  }
}

/* ---------- Calculator map (public/calculator.js, Leaflet) ---------- */

button.text-link {
  background: none;
  border-width: 0 0 2px;
  border-radius: 0;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
  padding: 0 0 2px;
}

.calc-pick {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  padding: 12px 16px;
  border: 1.5px dashed var(--primary);
  border-radius: 12px;
  background: var(--primary-soft);
  color: var(--primary-dark);
  font: inherit;
  font-weight: 650;
  text-align: left;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease;
}

.calc-pick:hover,
.calc-pick:focus-visible {
  border-style: solid;
}

.calc-pick .icon {
  flex-shrink: 0;
}

.calc-pick span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calc-pick--done {
  border-style: solid;
  background: var(--card);
  color: var(--text);
}

.calc-pick--done .icon {
  color: var(--accent);
}

.map-dialog {
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--card);
  color: var(--text);
  box-shadow: var(--shadow-lg);
}

.map-dialog[open] {
  display: flex;
  flex-direction: column;
}

.map-dialog::backdrop {
  background: rgb(15 23 42 / 0.55);
}

.map-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px 8px;
}

.map-dialog-head h2 {
  margin: 0;
  font-size: 1.3rem;
}

.map-dialog-close {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 10px;
  background: var(--bg-tint);
  color: var(--text);
  cursor: pointer;
}

.map-dialog-close:hover {
  background: var(--primary-soft);
}

.map-search {
  display: flex;
  gap: 10px;
  padding: 8px 20px;
}

.map-search input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.map-search input:focus {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

.map-results {
  margin: 0 20px 8px;
  padding: 4px;
  list-style: none;
  max-height: 180px;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.map-results button {
  display: block;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--text);
  font: inherit;
  font-size: 0.92rem;
  text-align: left;
  cursor: pointer;
}

.map-results button:hover,
.map-results button:focus-visible {
  background: var(--primary-soft);
}

.map-status {
  margin: 0 20px;
  font-size: 0.92rem;
  color: var(--muted);
}

.map-status:empty {
  display: none;
}

.map-canvas {
  flex: 1;
  min-height: 300px;
  height: 58dvh;
  margin: 8px 20px 0;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.map-dialog-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  padding: 14px 20px 18px;
}

.map-coords {
  flex: 1;
  min-width: 160px;
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--muted);
}

.map-dialog-foot .button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.map-pin {
  color: var(--primary);
  filter: drop-shadow(0 2px 3px rgb(15 23 42 / 0.35));
}

.map-pin--start {
  color: var(--accent);
}

.map-pin--faded {
  opacity: 0.5;
}

.map-bird {
  color: var(--primary-dark);
}

.map-bird-shape {
  display: block;
  filter: drop-shadow(0 3px 4px rgb(15 23 42 / 0.35));
  transform-origin: 50% 50%;
}

.leaflet-container .map-route-line {
  stroke: var(--primary);
  stroke-linecap: round;
}

.leaflet-container .map-route-ghost {
  stroke: var(--muted);
  stroke-opacity: 0.6;
}

.leaflet-tooltip.map-distance {
  padding: 4px 10px;
  border: 0;
  border-radius: 8px;
  background: var(--primary);
  color: var(--on-primary);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.95rem;
}

.leaflet-tooltip.map-distance::before {
  border-top-color: var(--primary);
}

.calc-result,
.calc-error {
  scroll-margin-top: 96px;
}

/* Map picker on: coordinates fold away until "Wpisz współrzędne ręcznie". */
.calc-card--picker:not(.calc-card--manual) .calc-coords,
.calc-card--picker:not(.calc-card--manual) .calc-manual-hint {
  display: none;
}

.calc-manual {
  justify-self: start;
  color: var(--muted);
  font-size: 0.92rem;
}

.calc-route {
  display: grid;
  gap: 10px;
}

.calc-route[hidden] {
  display: none;
}

.calc-route-map {
  height: 320px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.leaflet-container {
  font: inherit;
  font-size: 0.8rem;
}

@media (max-width: 600px) {
  .map-dialog {
    inset: 0;
    margin: 0;
    width: 100%;
    max-width: 100%;
    height: 100%;
    max-height: 100%;
    border: 0;
    border-radius: 0;
  }

  .map-canvas {
    height: auto;
  }

  .map-search,
  .map-dialog-head,
  .map-dialog-foot {
    padding-left: 16px;
    padding-right: 16px;
  }

  .map-canvas,
  .map-results,
  .map-status {
    margin-left: 16px;
    margin-right: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .calc-pick {
    transition: none;
  }
}

/* `hidden` wins over component display rules (progressive enhancement toggles it from calculator.js). */
[hidden] {
  display: none !important;
}

/* ---------- Feature landing pages (/funkcje/…) ---------- */

.feature-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 48px;
  align-items: center;
}

.feature-copy .hero-actions {
  margin-top: 28px;
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 0.88rem;
  color: var(--muted);
}

.crumbs a {
  color: var(--muted);
}

.crumbs a:hover {
  color: var(--primary);
}

.index-more {
  margin-top: 10px;
  font-size: 0.92rem;
}

/* Pedigree illustration: the pigeon on the left, ancestors fanning out to the right (sample data). */
.pd-sheet {
  margin: 0;
  padding: 22px 22px 16px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-lg);
}

.pd-head {
  display: grid;
  gap: 2px;
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.pd-title {
  font-family: var(--mono);
  font-size: 1.2rem;
  font-weight: 800;
}

.pd-tree {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 0.85fr;
  gap: 10px;
}

.pd-col {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  gap: 8px;
  position: relative;
}

/* Connector stub to the left of every ancestor column. */
.pd-col + .pd-col::before {
  content: "";
  position: absolute;
  top: 12%;
  bottom: 12%;
  left: -6px;
  border-left: 2px solid var(--line);
  border-radius: 2px;
}

.pd-card {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  min-width: 0;
}

.pd-ring {
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pd-line {
  font-size: 0.72rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pd-sex {
  font-weight: 700;
}

.pd-card--root {
  padding: 14px 10px;
  border-color: var(--primary);
  background: var(--primary-soft);
}

.pd-card--root .pd-ring {
  color: var(--primary);
}

.pd-card--father {
  border-left: 3px solid var(--primary);
}

.pd-card--mother {
  border-left: 3px solid var(--accent);
}

.pd-card--mini {
  padding: 4px 8px;
}

.pd-card--mini .pd-ring {
  font-size: 0.66rem;
  font-weight: 600;
  color: var(--muted);
}

.pd-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.pd-foot .icon {
  color: var(--accent);
}

@media (max-width: 1000px) {
  .feature-head {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

@media (max-width: 600px) {
  /* The pigeon is already in the sheet header: phones show parents and grandparents only. */
  .pd-tree {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .pd-col:first-child,
  .pd-col--far {
    display: none;
  }

  .pd-col:nth-child(2)::before {
    display: none;
  }

  .pd-sheet {
    padding: 16px 14px 12px;
  }
}
