/* wearfits.me — site additions, imported by site.css after landing.css (tokens, reset and shell live in landing.css).
   Guides grid, article template (.ar-*), clothing size tool (.st-*), 404. Catalogue look: hairline cards, lists
   and tables (--lp-hair), rounded tiles (--lp-r-tile), black panels for the answer and CTA; controls stay square 2px ink. */
main:focus { outline: none; }

/* guides grid (home #guides + article "More guides") */
.lp-guides { padding-top: var(--lp-gap); }
.lp .lp-guides-title { margin-bottom: 32px; } /* ".lp" beats the ".lp h2" margin reset, as on the other ".lp .x" margin rules here */
.lp-guide-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.lp-guide-list a {
  display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 20px;
  border: var(--lp-hair); border-radius: var(--lp-r-tile); text-decoration: none;
}
.lp-guide-list a:hover { opacity: 1; background: var(--lp-ink); color: var(--lp-ground); }
.lp-guide-list a:hover span { color: var(--lp-muted-dark); }
.lp-guide-list b { font-stretch: 62%; font-weight: 800; text-transform: uppercase; font-size: 30px; line-height: 0.95; }
.lp-guide-list span { color: var(--lp-muted); font-size: 16px; }

/* ---------- article template (.ar-*) ---------- */
.ar-crumbs { padding-top: 20px; font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.ar-crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; }
.ar-crumbs li { display: flex; align-items: center; min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.ar-crumbs li + li::before { content: "›"; flex: none; padding: 0 10px; color: var(--lp-muted); }
.ar-crumbs a { text-decoration: none; display: inline-block; padding: 8px 0; }
.ar-crumbs [aria-current] { color: var(--lp-muted); }

.ar { font-size: 18px; line-height: 1.6; }
.ar-head { padding-top: 16px; padding-bottom: 32px; border-bottom: var(--lp-hair); }
.ar-h1 {
  font-stretch: 62%; font-weight: 800; text-transform: uppercase;
  font-size: clamp(56px, 8.4vw, 132px); line-height: 0.86; max-width: 14ch;
  overflow-wrap: break-word; hyphens: auto; /* long Polish words must not push a phone page sideways */
}
.lp .ar-h1 { margin: 12px 0 24px; }
/* Comparison guides use compact article headings and quiet, single-line breadcrumbs. */
html[data-static-locale] .ar-crumbs {
  padding-top: 16px; color: #6C6962; font-size: 12px; font-weight: 400;
  letter-spacing: 0; text-transform: none;
}
html[data-static-locale] .ar-crumbs ol { flex-wrap: nowrap; align-items: center; min-width: 0; }
html[data-static-locale] .ar-crumbs li { display: block; min-width: 0; white-space: nowrap; }
html[data-static-locale] .ar-crumbs li:not(:last-child) { flex: 0 0 auto; }
html[data-static-locale] .ar-crumbs li:last-child { overflow: hidden; text-overflow: ellipsis; }
html[data-static-locale] .ar-crumbs li + li::before { padding: 0 8px; color: inherit; }
html[data-static-locale] .ar-crumbs a { padding: 2px 0; }
html[data-static-locale] .ar-crumbs a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }
html[data-static-locale] .ar-crumbs [aria-current] { color: inherit; }
html[data-static-locale] .ar-head { padding-top: 12px; padding-bottom: 20px; }
html[data-static-locale] .ar-h1 {
  font-size: clamp(32px, 3.6vw, 56px); line-height: 1.06; max-width: 28ch;
  margin: 8px 0 14px; letter-spacing: -0.02em; overflow-wrap: break-word; text-wrap: balance;
}
html[data-static-locale] .ar-top { padding-top: 24px; }
html[data-static-locale] .ar-h2 { font-size: clamp(26px, 2.8vw, 40px); line-height: 1.06; }
html[data-static-locale] .ar-related .lp-guides-title { font-size: clamp(30px, 3.5vw, 48px); line-height: 1.06; }
.ar-meta { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--lp-muted); }

.ar-wrap { max-width: 68ch; }
.ar-top { display: grid; grid-template-columns: minmax(0, 68ch) minmax(220px, 320px); gap: 32px clamp(32px, 5vw, 80px); padding-top: 40px; align-items: start; }
.ar-answer { border-radius: var(--lp-r-tile); background: var(--lp-ink); color: var(--lp-ground); padding: 24px clamp(20px, 3vw, 32px); }
.ar-answer h2 { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--lp-muted-dark); margin-bottom: 12px; }
.ar-answer p { font-size: 20px; line-height: 1.5; }
.ar-toc { border: var(--lp-hair); border-radius: var(--lp-r-tile); padding: 20px; }
.ar-toc h2 { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 8px; }
.ar-toc ol { counter-reset: toc; }
.ar-toc li { counter-increment: toc; border-top: var(--lp-hair); }
.ar-toc li:first-child { border-top: 0; }
.ar-toc a { display: flex; gap: 10px; padding: 10px 0; font-size: 16px; line-height: 1.35; text-decoration: none; font-weight: 600; }
.ar-toc a::before { content: counter(toc, decimal-leading-zero); font-weight: 800; font-stretch: 62%; }

.ar-body { padding-top: 16px; }
.ar-body > section { padding-top: 56px; }
.ar-h2 {
  font-stretch: 62%; font-weight: 800; text-transform: uppercase;
  font-size: clamp(40px, 4.4vw, 64px); line-height: 0.9;
}
.lp .ar-h2 { margin-bottom: 20px; } /* ".lp" beats the ".lp h2" margin reset */
.ar h3 { font-size: 20px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.01em; line-height: 1.25; margin: 32px 0 8px; }
.lp .ar-prose > * + * { margin-top: 16px; }
.lp .ar-prose > .ar-h2 + * { margin-top: 0; }
.ar-prose ul, .ar-prose ol { padding-left: 1.2em; }
.ar-prose ul { list-style: square; }
.ar-prose ol { list-style: decimal; }
.ar-prose li + li { margin-top: 6px; }
.ar-prose a { text-decoration-thickness: 2px; text-underline-offset: 3px; }
.ar-prose strong { font-weight: 700; }
.ar-note { border-left: 4px solid var(--lp-ink); padding: 4px 0 4px 16px; color: var(--lp-muted); font-size: 16px; }

/* numbered steps inside an article */
.ar-steps { counter-reset: step; list-style: none !important; padding-left: 0 !important; }
.ar-steps > li { counter-increment: step; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 0 16px; padding: 20px 0; border-top: var(--lp-hair); }
.ar-steps > li + li { margin-top: 0; }
.ar-steps > li::before { content: counter(step); font-stretch: 62%; font-weight: 800; font-size: 64px; line-height: 0.8; }
.ar-steps h3 { margin: 0 0 6px; }

/* figures */
.lp .ar-fig { margin: 32px 0 0; background: #fff; max-width: 440px; border-radius: var(--lp-r-tile); overflow: hidden; }
.ar-fig img { aspect-ratio: 4 / 5; border-radius: 0; }
.ar-fig figcaption { padding: 10px 14px; background: var(--lp-tone); font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }

/* Examples gallery (/demos): the home "You add → You get" cards inside the article width; 2 across from 700px, 4 from 1200px, stacked on phones. */
.ar-gallery { padding-top: 8px; }
.lp .ar-gallery .lp-eq-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 24px; padding: 0; }
.ar-gallery .lp-eq-item { flex: none; }
.lp .ar-gallery-cta { margin-top: 20px; }
@media (min-width: 700px) { .lp .ar-gallery .lp-eq-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .lp .ar-gallery-cta { display: inline-block; padding-left: 36px; padding-right: 36px; } }
@media (min-width: 1200px) { .lp .ar-gallery .lp-eq-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* tables: hairline box and rows, black head, horizontal scroll on narrow screens */
.ar-table { margin-top: 24px; border: var(--lp-hair); border-radius: var(--lp-r-tile); overflow-x: auto; -webkit-overflow-scrolling: touch; }
.ar-table table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.4; }
.ar-table th, .ar-table td { text-align: left; padding: 12px 14px; vertical-align: top; }
.ar-table thead th { background: var(--lp-ink); color: var(--lp-ground); font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.ar-table tbody tr + tr td, .ar-table tbody tr + tr th { border-top: var(--lp-hair); }
.ar-table caption { caption-side: top; text-align: left; padding: 12px 14px; font-weight: 700; border-bottom: var(--lp-hair); }

/* inline CTA block (link form → app) */
.ar-cta {
  margin-top: 56px; border-radius: var(--lp-r-tile); background: var(--lp-ink); color: var(--lp-ground); padding: clamp(24px, 4vw, 48px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 48px; align-items: end;
}
.ar-cta-title { font-stretch: 62%; font-weight: 800; text-transform: uppercase; font-size: clamp(44px, 5vw, 72px); line-height: 0.88; }
.lp .ar-cta-lead { margin-top: 12px; font-size: 18px; line-height: 1.5; color: var(--lp-muted-dark); }

/* FAQ + sources */
/* The glossary's A–Z term list (#terms) shares the FAQ look. */
.ar-faq dl > div, #terms dl > div { border-top: var(--lp-hair); padding: 20px 0; }
.ar-faq dt, #terms dt { font-size: 20px; font-weight: 700; line-height: 1.3; }
.lp .ar-faq dd, .lp #terms dd { margin-top: 8px; }
.ar-sources ol { list-style: decimal; padding-left: 1.4em; font-size: 16px; }
.ar-sources li + li { margin-top: 6px; }
.ar-sources a { word-break: break-word; }
.ar-related { padding-bottom: var(--lp-gap); }

/* ---------- clothing size tool (.st-*) ---------- */
.st { margin-top: 32px; border: var(--lp-hair); border-radius: var(--lp-r-tile); background: #fff; padding: clamp(16px, 3vw, 28px); font-size: 16px; line-height: 1.45; }
.st-controls { display: flex; flex-wrap: wrap; gap: 12px 16px; margin-bottom: 20px; }
.st-seg { display: inline-flex; gap: 2px; background: var(--lp-ink); border: 2px solid var(--lp-ink); }
.st-seg button {
  min-height: 44px; padding: 0 14px; border: 0; background: #fff; color: var(--lp-ink); cursor: pointer;
  font: inherit; font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
}
.st-seg button[aria-pressed="true"] { background: var(--lp-ink); color: var(--lp-ground); }
.st-fields { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; }
.st-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.st-field label { font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.st input, .st select {
  height: 48px; padding: 0 12px; border: 2px solid var(--lp-ink); border-radius: 0; background: #fff; color: var(--lp-ink);
  font: inherit; font-size: 17px; min-width: 0;
}
.st input { width: 9em; }
.st-help { max-width: 30em; color: var(--lp-muted); font-size: 15px; }
.st-out { margin-top: 20px; }
.st-out > p { margin-bottom: 10px; }
.st-error { border-left: 4px solid var(--lp-ink); padding-left: 10px; font-weight: 700; }
.lp .st-note { margin-top: 16px; color: var(--lp-muted); font-size: 14px; }
.st-tag { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--lp-muted); }
.st-match { display: inline-block; padding: 2px 8px; border: 2px solid var(--lp-ink); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; white-space: nowrap; }
.st-match-spot { background: var(--lp-ink); color: var(--lp-ground); }
.st-match-approx { border-style: dashed; }
.st-ref details { border: var(--lp-hair); border-radius: var(--lp-r-tile); overflow: hidden; background: #fff; }
.st-ref details + details { margin-top: 12px; }
.st-ref summary { cursor: pointer; padding: 12px 14px; font-weight: 700; display: flex; justify-content: space-between; gap: 12px; }
.st-ref .ar-table { margin-top: 0; border: 0; border-top: var(--lp-hair); border-radius: 0; }

/* ---------- 404 ---------- */
.lp-404 { padding-bottom: var(--lp-gap); }
section.lp-404 { padding-top: clamp(32px, 5vw, 64px); }
.lp-404 p { margin-top: 24px; font-size: 19px; max-width: 34em; }
.lp-404 .lp-btn { display: inline-block; margin-top: 32px; padding: 18px 28px; }

@media (max-width: 899px) {
  .lp .lp-guides-title { margin-bottom: 20px; }
  .lp-guide-list { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .lp-guide-list b { font-size: 26px; }
  .ar { font-size: 17px; }
  .ar-h1 { font-size: min(64px, 16.4vw); }
  .lp .ar-h1 { margin: 8px 0 16px; }
  .ar-head { padding-bottom: 24px; }
  .ar-top { display: flex; flex-direction: column; gap: 20px; padding-top: 24px; }
  .ar-answer p { font-size: 18px; }
  .ar-toc { width: 100%; }
  .ar-body > section { padding-top: 44px; }
  .ar-h2 { font-size: min(44px, 11.6vw); }
  .ar-steps > li { grid-template-columns: 44px minmax(0, 1fr); gap: 0 12px; }
  .ar-steps > li::before { font-size: 48px; }
  .ar-cta { grid-template-columns: minmax(0, 1fr); padding: 24px 16px; margin-left: -16px; margin-right: -16px; border-radius: 0; }
  .ar-cta-title { font-size: min(48px, 12.8vw); }
  .lp .ar-fig { max-width: none; }
  .st-seg { flex: 1 1 100%; }
  .st-seg button { flex: 1 1 0; padding: 0 8px; }
  .st-ref .st-seg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .st-field, .st input, .st select { width: 100%; }
}
