/* Bearius - style.css
   Fonts: IBM Plex Sans / IBM Plex Mono, SIL OFL 1.1 (see /fonts/OFL.txt) */

@font-face {
  font-family: 'Plex Sans';
  font-style: normal;
  font-weight: 100 700;
  font-stretch: 100%;
  font-display: swap;
  src: url('../fonts/plex-sans-latin.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;
}
@font-face {
  font-family: 'Plex Sans';
  font-style: normal;
  font-weight: 100 700;
  font-stretch: 100%;
  font-display: swap;
  src: url('../fonts/plex-sans-latin-ext.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: 'Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/plex-mono-400-latin.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;
}
@font-face {
  font-family: 'Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/plex-mono-400-latin-ext.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: 'Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/plex-mono-500-latin.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;
}
@font-face {
  font-family: 'Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/plex-mono-500-latin-ext.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;
}

/* ---- TOKENS ----
   Tryb jasny: ciepla baza z akcentami warsztatowymi.
   Tryb ciemny: pelny terminal. Ten sam uklad, inna osobowosc. */
:root {
  color-scheme: light;
  --bg: #f7f7f5;
  --panel: #ffffff;
  --panel-2: #eeeeeb;
  --text: #16181a;
  --muted: #5f6467;
  --faint: #8a8f92;
  --line: #e2e3e0;
  --line-strong: #c6c8c5;
  --accent: #0f5f6b;
  --accent-soft: #eef4f5;
  --accent-line: #a9c9ce;

  --grid: rgba(22, 24, 26, 0.014);
  --grid-hero: rgba(22, 24, 26, 0.05);
  --grid-size: 34px;
  --glow: 0 0 18px rgba(15, 95, 107, 0.10);
  --bracket: 0.35;

  --sans: 'Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Plex Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --radius: 10px;
  --wrap: 1080px;
  --gap: 20px;
  --step: clamp(3rem, 7vw, 5.5rem);
}

html[data-theme='dark'] {
  color-scheme: dark;
  --bg: #07090b;
  --panel: #0f1316;
  --panel-2: #0b0e11;
  --text: #d7e2dc;
  --muted: #9dada5;
  --faint: #76867f;
  --line: #1f282d;
  --line-strong: #2c3740;
  --accent: #5cf0a5;
  --accent-soft: #0a1411;
  --accent-line: #1f4d38;

  --grid: rgba(92, 240, 165, 0.045);
  --grid-hero: rgba(92, 240, 165, 0.085);
  --glow: 0 0 22px rgba(92, 240, 165, 0.10);
  --bracket: 0.6;
}

@media (prefers-color-scheme: dark) {
  html:not([data-theme='light']) {
    color-scheme: dark;
    --bg: #07090b;
    --panel: #0f1316;
    --panel-2: #0b0e11;
    --text: #d7e2dc;
    --muted: #9dada5;
    --faint: #76867f;
    --line: #1f282d;
    --line-strong: #2c3740;
    --accent: #5cf0a5;
    --accent-soft: #0a1411;
    --accent-line: #1f4d38;
    --grid: rgba(92, 240, 165, 0.045);
    --grid-hero: rgba(92, 240, 165, 0.085);
    --glow: 0 0 22px rgba(92, 240, 165, 0.10);
    --bracket: 0.6;
  }
}

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

body {
  margin: 0;
  background-color: var(--bg);
  background-image:
    repeating-linear-gradient(to right, var(--grid) 0 1px, transparent 1px var(--grid-size)),
    repeating-linear-gradient(to bottom, var(--grid) 0 1px, transparent 1px var(--grid-size));
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { font-weight: 500; line-height: 1.22; letter-spacing: -0.015em; margin: 0; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.05rem; letter-spacing: -0.005em; }
p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }
.h1--narrow { max-width: 20ch; }

a { color: inherit; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
svg { display: block; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gap); }
.measure { max-width: 62ch; }
.dim { color: var(--muted); }
.lede { color: var(--muted); max-width: 46ch; }
.lede--wide { max-width: 52ch; margin-bottom: 2.2rem; }
.about-body { margin-top: 1.4rem; color: var(--muted); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 20;
  background: var(--panel); color: var(--text);
  padding: 12px 18px; border: 1px solid var(--line);
}
.skip:focus { left: 12px; top: 12px; }

/* etykieta sekcji w nawiasach - detal z terminala */
.eyebrow {
  font-family: var(--mono); font-size: 0.75rem; font-weight: 400;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 1.4rem;
}
.eyebrow::before { content: '['; margin-right: 0.5ch; opacity: var(--bracket); }
.eyebrow::after { content: ']'; margin-left: 0.5ch; opacity: var(--bracket); }
.eyebrow--accent { color: var(--accent); }

/* migajacy kursor po tytule */
.caret {
  display: inline-block; width: 0.5em; height: 0.92em;
  margin-left: 0.14em; vertical-align: -0.06em;
  background: var(--accent); animation: blink 1.15s step-end infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* ---- HEADER ---- */
.site-head {
  border-bottom: 1px solid var(--line);
  background: var(--bg); position: sticky; top: 0; z-index: 10;
}
.head-in {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; min-height: 66px; flex-wrap: wrap; padding-block: 10px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 1.05rem; font-weight: 500; letter-spacing: -0.01em; text-decoration: none;
}
.brand .paw { color: var(--accent); transition: transform 0.18s ease; }
.brand:hover .paw { transform: rotate(-8deg); }

.nav { display: flex; align-items: center; gap: 4px 18px; flex-wrap: wrap; }
.nav-link {
  display: inline-flex; align-items: center; gap: 3px; padding: 6px 0;
  font: inherit; font-size: 0.9rem; color: var(--muted); text-decoration: none;
  background: none; border: 0; cursor: pointer;
}
.nav-link svg { transition: transform 0.15s ease; }
.nav-link:hover, .nav-link[aria-current='page'], .nav-link.is-current, .dd.is-open .nav-link { color: var(--text); }
.nav-link[aria-current='page'], .nav-link.is-current { box-shadow: inset 0 -2px 0 var(--accent); }

/* menu rozwijane - klik (JS), mysz na komputerze, a bez JS fokus klawiatury */
.dd { position: relative; }
.dd-panel {
  display: none; position: absolute; top: calc(100% + 10px); left: -14px; z-index: 30;
  width: 330px; padding: 8px;
  background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--radius);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.14);
}
.dd-panel::before { content: ''; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.dd-panel--plugins { width: 380px; }
html[data-theme='dark'] .dd-panel { box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55); }
@media (prefers-color-scheme: dark) { html:not([data-theme='light']) .dd-panel { box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55); } }
.dd.is-open .dd-panel { display: block; }
.dd.is-open .dd-btn svg { transform: rotate(180deg); }
html:not(.js) .dd:focus-within .dd-panel { display: block; }
@media (hover: hover) and (min-width: 961px) {
  .js .dd:hover .dd-panel { display: block; }
}
.dd-item {
  display: block; padding: 9px 12px; border-radius: 7px; text-decoration: none; color: var(--text);
}
.dd-item:hover, .dd-item:focus-visible { background: var(--accent-soft); }
.dd-item b { display: block; font-size: 0.9rem; font-weight: 500; }
.dd-item small { display: block; font-size: 0.8rem; color: var(--muted); line-height: 1.45; margin-top: 1px; }
.dd-plugin { display: grid; grid-template-columns: 10px 1fr auto; gap: 10px; align-items: center; }
.dd-dot { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--faint); }
.dd-dot--live { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 8px var(--accent-line); }
.dd-dot--review { background: var(--text); border-color: var(--text); }
.dd-status { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.03em; color: var(--faint); white-space: nowrap; }
.dd-status--live { color: var(--accent); }
.dd-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 6px; padding: 10px 12px 4px; border-top: 1px solid var(--line); }
.dd-foot a { font-family: var(--mono); font-size: 0.75rem; color: var(--accent); text-decoration: none; }
.dd-foot a:hover { text-decoration: underline; }

/* przycisk kontaktu w naglowku */
.head-cta {
  display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 13px;
  border: 1px solid var(--accent); border-radius: var(--radius);
  color: var(--accent); font-size: 0.84rem; text-decoration: none; white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.head-cta:hover { background: var(--accent); color: var(--bg); box-shadow: var(--glow); }

/* pasek nowosci nad menu */
.announce {
  display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap;
  padding: 7px var(--gap); background: var(--accent-soft); border-bottom: 1px solid var(--line);
  font-family: var(--mono); font-size: 0.74rem; color: var(--text); text-decoration: none; text-align: center;
}
.announce:hover .announce-text { text-decoration: underline; text-decoration-color: var(--accent-line); }
.announce svg { color: var(--accent); flex: 0 0 auto; }
.announce-label {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--accent); text-transform: uppercase; letter-spacing: 0.06em;
}
.announce-label::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
  animation: blink 1.15s step-end infinite;
}

.head-tools { display: flex; align-items: center; gap: 10px; }
.langs {
  display: flex; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.lang {
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.04em;
  padding: 4px 7px; color: var(--faint); text-decoration: none;
  border-right: 1px solid var(--line);
}
.lang:last-child { border-right: 0; }
.lang:hover { color: var(--text); }
.lang.is-on { color: var(--accent); background: var(--accent-soft); }

.toggle {
  display: grid; place-items: center; width: 32px; height: 32px; padding: 0;
  background: none; border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--muted); cursor: pointer;
}
.toggle:hover { color: var(--accent); border-color: var(--line-strong); }
.toggle .moon { display: none; }
html[data-theme='dark'] .toggle .moon { display: block; }
html[data-theme='dark'] .toggle .sun { display: none; }
@media (prefers-color-scheme: dark) {
  html:not([data-theme='light']) .toggle .moon { display: block; }
  html:not([data-theme='light']) .toggle .sun { display: none; }
}

/* ---- SECTIONS ---- */
.sec { padding-block: var(--step); border-bottom: 1px solid var(--line); }
.sec--flush { padding-block: 0; border-bottom: 1px solid var(--line); }
.sec--tint { background: var(--accent-soft); }

.hero { position: relative; padding-block: clamp(3.5rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4rem); }
.hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background-image:
    repeating-linear-gradient(to right, var(--grid-hero) 0 1px, transparent 1px var(--grid-size)),
    repeating-linear-gradient(to bottom, var(--grid-hero) 0 1px, transparent 1px var(--grid-size));
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, rgba(0,0,0,0.35) 55%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0%, rgba(0,0,0,0.35) 55%, transparent 100%);
}
.hero .wrap { position: relative; z-index: 1; }
.hero h1 { max-width: 17ch; margin-bottom: 1.1rem; }
.hero .lede { font-size: 1.05rem; margin-bottom: 2rem; }
.status { font-family: var(--mono); font-size: 0.78rem; color: var(--muted); letter-spacing: 0.03em; margin: 0 0 1.5rem; }
.status b { color: var(--accent); font-weight: 400; }

.cta-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  padding: 10px 18px; font-size: 0.92rem; text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { background: var(--panel); border-color: var(--accent); box-shadow: var(--glow); }
.mail { font-family: var(--mono); font-size: 0.92rem; color: var(--accent); text-decoration-color: var(--accent-line); }

/* ---- STATS ---- */
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.stat { padding: 22px var(--gap); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat:nth-child(2n) { border-right: 0; }
.stat:nth-last-child(-n+2) { border-bottom: 0; }
@media (min-width: 760px) {
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .stat, .stat:nth-child(2n) { border-bottom: 0; border-right: 1px solid var(--line); }
  .stat:last-child { border-right: 0; }
}
/* trzy liczby w realizacjach: jedna kolumna na telefonie, trzy wyzej */
.stats.stats--tri { grid-template-columns: minmax(0, 1fr); border-top: 0; }
.stats--tri .stat, .stats--tri .stat:nth-child(2n) { border-right: 0; border-bottom: 1px solid var(--line); }
.stats--tri .stat:last-child { border-bottom: 0; }
@media (min-width: 560px) {
  .stats.stats--tri { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stats--tri .stat, .stats--tri .stat:nth-child(2n) { border-bottom: 0; border-right: 1px solid var(--line); }
  .stats--tri .stat:last-child { border-right: 0; }
}
.stat b { display: block; font-family: var(--mono); font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; color: var(--accent); }
.stat span { font-size: 0.82rem; color: var(--muted); }

/* ---- CARDS ---- */
.group-title { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; font-weight: 500; margin: 0 0 1rem; }
.group-title svg { color: var(--accent); }
.group + .group { margin-top: 2.6rem; padding-top: 2.2rem; border-top: 1px solid var(--line); }

.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
/* Siatki dobierane do liczby kafli - zawsze pelne rzedy (2x2 zamiast 3+1) */
.grid--duo, .grid--tri, .grid--quad, .grid--hex { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) {
  .grid--duo, .grid--quad, .grid--hex { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 760px) { .grid--tri { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 900px) { .grid--hex { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 960px) { .grid--quad { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.card:hover { border-color: var(--accent-line); box-shadow: var(--glow); }
.card svg { color: var(--muted); margin-bottom: 10px; }
.card:hover svg { color: var(--accent); }
.card h3 { margin-bottom: 5px; }
.card p { font-size: 0.88rem; color: var(--muted); }
.card--lead { border-left: 2px solid var(--accent); }
a.card { display: flex; flex-direction: column; text-decoration: none; color: inherit; }
a.card svg { align-self: flex-start; }
.card .go { display: inline-block; margin-top: auto; padding-top: 12px; font-family: var(--mono); font-size: 0.72rem; color: var(--accent); }

.point { display: flex; gap: 12px; align-items: flex-start; }
.point svg { color: var(--accent); flex: 0 0 auto; margin-top: 3px; }
.point h3 { font-size: 0.95rem; margin-bottom: 3px; }
.point p { font-size: 0.86rem; color: var(--muted); margin: 0; }

.work { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .work { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.work-card {
  display: block; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; text-decoration: none;
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.work-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--glow); }
.work-card svg { color: var(--accent); margin-bottom: 14px; }
.work-card h3 { margin-bottom: 6px; }
.work-card p { font-size: 0.88rem; color: var(--muted); }
.work-card .more { display: inline-block; margin-top: 12px; font-family: var(--mono); font-size: 0.75rem; color: var(--accent); }
.work-card .tags { display: block; margin-top: 10px; font-family: var(--mono); font-size: 0.72rem; color: var(--faint); }
.work-card--cta { background: transparent; border-style: dashed; border-color: var(--line-strong); }

/* ---- STACK ---- */
.stack { display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr); margin-top: 2.4rem; }
@media (min-width: 560px) { .stack { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 960px) { .stack { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stack h3 { font-size: 0.82rem; margin-bottom: 8px; }
.stack ul { list-style: none; margin: 0; padding: 0; font-family: var(--mono); font-size: 0.78rem; color: var(--muted); line-height: 1.95; }

/* ---- TIMELINE ---- */
.tl { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.tl li { display: grid; grid-template-columns: 96px 1fr; gap: 16px; align-items: start; }
.tl time { font-family: var(--mono); font-size: 0.8rem; color: var(--accent); padding-top: 2px; }
.tl h3 { font-size: 0.95rem; margin-bottom: 2px; }
.tl p { font-size: 0.86rem; color: var(--muted); margin: 0; }

/* ---- CASE / ABOUT ---- */
.portrait { width: 100%; max-width: 320px; aspect-ratio: 4 / 5; object-fit: cover; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel-2); margin-top: 1.6rem; }
.case-meta { display: flex; gap: 30px; flex-wrap: wrap; border-top: 1px solid var(--line); margin-top: 1.8rem; padding-top: 1.4rem; }
.case-meta div span { display: block; font-size: 0.75rem; color: var(--faint); }
.case-meta div b { font-family: var(--mono); font-size: 0.84rem; font-weight: 400; }
.two-col { display: grid; gap: 30px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.pager { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 0.9rem; }
.pager a { color: var(--muted); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.pager a:hover { color: var(--accent); }

/* ---- TILES ---- */
.tiles { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.tile {
  display: flex; align-items: center; gap: 14px;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; text-decoration: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.tile:hover { border-color: var(--accent); box-shadow: var(--glow); }
.tile h3 { font-size: 0.95rem; margin-bottom: 2px; }
.tile p { font-size: 0.84rem; color: var(--muted); margin: 0; }
.tile .arrow { margin-left: auto; color: var(--faint); flex: 0 0 auto; }
.tile:hover .arrow { color: var(--accent); }

/* ---- CONTACT + FOOTER ---- */
.contact { text-align: center; padding-block: var(--step); border-bottom: 1px solid var(--line); }
.contact h2 { margin-bottom: 0.6rem; }
.contact p { color: var(--muted); font-size: 0.95rem; margin-bottom: 1.4rem; }
.contact .mail { font-size: 1.25rem; }
.contact .alt { margin: 1.3rem 0 0; font-size: 0.86rem; color: var(--faint); }
.contact .alt a, .alt-line a { color: var(--accent); text-decoration-color: var(--accent-line); }

.site-foot { padding-block: 22px; font-size: 0.82rem; color: var(--faint); }
.foot-in { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }
.foot-in nav { display: flex; gap: 18px; flex-wrap: wrap; }
.foot-in a { text-decoration: none; }
.foot-in a:hover { color: var(--accent); }

/* ---- PROSE ---- */
.prose { max-width: 68ch; margin-top: 2rem; }
.prose h2 { font-size: 1.15rem; margin: 2.2rem 0 0.7rem; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--muted); font-size: 0.95rem; }
.prose ul { padding-left: 1.1rem; }
.prose li { margin-bottom: 0.4rem; }

/* ---- PODSTRONY: naglowek, sekcje, linki ---- */
.hero--page { padding-block: clamp(3rem, 7vw, 5rem) clamp(2.4rem, 5vw, 3.6rem); border-bottom: 1px solid var(--line); }
.hero--page h1 { max-width: 21ch; }
.hero--page .lede { max-width: 56ch; }
.sec-h2 { max-width: 26ch; margin-bottom: 0.9rem; }
.sec-h2 + .grid, .sec-h2 + .tl { margin-top: 1.8rem; }
.more-row { margin: 1.6rem 0 0; }
.more-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 0.8rem; color: var(--accent); text-decoration: none;
}
.more-link:hover { text-decoration: underline; text-decoration-color: var(--accent-line); }
.cta-row--top { margin-top: 1.8rem; }
.alt-line { margin: 1.4rem 0 0; font-size: 0.86rem; color: var(--faint); }
.crumb {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 1.6rem;
  font-size: 0.86rem; color: var(--muted); text-decoration: none;
}
.crumb:hover { color: var(--accent); }
.related { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 1.8rem 0 0; }
.related > span { font-size: 0.8rem; color: var(--faint); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.note {
  display: flex; gap: 12px; align-items: flex-start; max-width: 64ch;
  margin-top: 1.6rem; padding: 14px 16px;
  border: 1px dashed var(--line-strong); border-radius: var(--radius);
}
.note svg { color: var(--accent); flex: 0 0 auto; margin-top: 2px; }
.note p { color: var(--muted); font-size: 0.9rem; margin: 0; }

/* kroki numerowane - ten sam rytm co os czasu */
.tl--steps li { grid-template-columns: 56px 1fr; }
.tl .n { font-family: var(--mono); font-size: 0.8rem; color: var(--accent); padding-top: 2px; }

/* ---- BADGE ---- */
.badge {
  display: inline-flex; align-items: center; gap: 6px; vertical-align: middle;
  font-family: var(--mono); font-size: 0.66rem; font-weight: 400; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 2px 9px; border: 1px solid var(--line-strong); border-radius: 999px;
  color: var(--muted); white-space: nowrap; line-height: 1.6;
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--live { color: var(--accent); border-color: var(--accent-line); background: var(--accent-soft); }
.badge--review { color: var(--text); }
.badge--review::before { background: var(--accent); animation: blink 1.15s step-end infinite; }
.badge--soon { color: var(--faint); border-style: dashed; }

/* ---- BANER WTYCZKI ----
   Zawsze ciemny, jak konsola i grafiki w katalogu wp.org - w obu motywach strony. */
.pbanner {
  --pb-bg: #07090b; --pb-line: #1b2226; --pb-text: #d7e2dc; --pb-muted: #8b9a92;
  --pb-faint: #61706a; --pb-acc: #5cf0a5; --pb-acc-dim: #1f4d38;
  --pb-grid: rgba(92, 240, 165, 0.055); --pb-bar: rgba(13, 16, 19, 0.9); --pb-paw: 0.13;
  position: relative; overflow: hidden;
  border: 1px solid var(--pb-line); border-radius: var(--radius);
  background-color: var(--pb-bg);
  background-image:
    radial-gradient(ellipse at 85% 110%, rgba(92, 240, 165, 0.12), transparent 60%),
    repeating-linear-gradient(to right, var(--pb-grid) 0 1px, transparent 1px 26px),
    repeating-linear-gradient(to bottom, var(--pb-grid) 0 1px, transparent 1px 26px);
  color: var(--pb-text); font-family: var(--mono); font-size: 0.8rem; line-height: 1.8;
}
.pb-bar {
  display: flex; align-items: center; gap: 6px; padding: 8px 14px;
  border-bottom: 1px solid var(--pb-line); background: var(--pb-bar);
  color: var(--pb-faint); font-size: 0.7rem; letter-spacing: 0.03em;
}
.pb-bar i { width: 8px; height: 8px; border-radius: 50%; background: #2c3740; }
.pb-bar span { margin-left: 8px; }
.pb-body { position: relative; display: flex; align-items: center; gap: 30px; padding: 24px 26px; min-height: 200px; }
.pb-line { display: block; white-space: nowrap; }
.pb-i1 { padding-left: 2.5ch; }
.pb-c { color: var(--pb-faint); }
.pb-k { color: var(--pb-muted); }
.pb-v { color: var(--pb-acc); text-shadow: 0 0 12px rgba(92, 240, 165, 0.35); }
.pb-ok { color: var(--pb-acc); margin-top: 0.7em; }
.pb-paw { position: absolute; right: -14px; bottom: -30px; color: var(--pb-acc); opacity: var(--pb-paw); pointer-events: none; }
.pb-cal { display: grid; grid-template-columns: repeat(7, 16px); gap: 5px; flex: 0 0 auto; }
.pb-cal i { width: 16px; height: 16px; border: 1px solid var(--pb-acc-dim); border-radius: 3px; }
.pb-cal i.on { background: var(--pb-acc); border-color: var(--pb-acc); box-shadow: 0 0 10px rgba(92, 240, 165, 0.45); }
.pb-cal i.now { border-color: var(--pb-acc); box-shadow: inset 0 0 0 1px var(--pb-acc); }
.pb-cal i.off { opacity: 0.3; }
.pb-list b { display: inline-block; min-width: 6ch; color: var(--pb-acc); font-weight: 400; }

.pbanner--sm { border-width: 0 0 1px; border-radius: 0; font-size: 0.72rem; }
.pbanner--sm .pb-body { height: 172px; min-height: 0; padding: 16px 18px; gap: 18px; }
.pbanner--sm .pb-cal { grid-template-columns: repeat(7, 11px); gap: 4px; }
.pbanner--sm .pb-cal i { width: 11px; height: 11px; border-radius: 2px; }
.pbanner--sm .pb-paw { right: -10px; bottom: -22px; }

html[data-theme='dark'] .pbanner {
  --pb-bg: #0c1613; --pb-line: #24493a; --pb-text: #e3ece7; --pb-muted: #b0c0b8; --pb-faint: #8a9d95;
  --pb-grid: rgba(92, 240, 165, 0.09); --pb-bar: #0f1a17; --pb-paw: 0.22;
  border-color: var(--accent-line); box-shadow: var(--glow);
}
html[data-theme='dark'] .pbanner--sm { box-shadow: none; }
html[data-theme='dark'] .term { background: #0c1613; border-color: var(--accent-line); }
@media (prefers-color-scheme: dark) {
  html:not([data-theme='light']) .pbanner {
    --pb-bg: #0c1613; --pb-line: #24493a; --pb-text: #e3ece7; --pb-muted: #b0c0b8; --pb-faint: #8a9d95;
    --pb-grid: rgba(92, 240, 165, 0.09); --pb-bar: #0f1a17; --pb-paw: 0.22;
    border-color: var(--accent-line); box-shadow: var(--glow);
  }
  html:not([data-theme='light']) .pbanner--sm { box-shadow: none; }
  html:not([data-theme='light']) .term { background: #0c1613; border-color: var(--accent-line); }
}

/* ---- KARTY WTYCZEK ---- */
.pcard {
  display: flex; flex-direction: column; overflow: hidden; text-decoration: none; color: inherit;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
a.pcard:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--glow); }
.pcard-body { display: flex; flex-direction: column; gap: 8px; flex: 1; padding: 18px; }
.pcard-top { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; }
.pcard h3 { font-size: 1.02rem; }
.pcard p { font-size: 0.88rem; color: var(--muted); margin: 0; }
.pcard .more { margin-top: auto; padding-top: 8px; font-family: var(--mono); font-size: 0.75rem; color: var(--accent); }

/* ---- STRONA WTYCZKI ---- */
.phero .pbanner { margin-bottom: 0.4rem; }
.phero-grid { display: grid; gap: 30px; margin-top: 2rem; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 860px) { .phero-grid { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 48px; } }
.phero h1 { margin-bottom: 0.4rem; }
.tagline { font-size: 1.12rem; margin-bottom: 0.9rem; }
.phero .lede { max-width: 58ch; margin-bottom: 1.6rem; }

.facts { margin: 0; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.facts div { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 11px 16px; border-bottom: 1px solid var(--line); }
.facts div:last-child { border-bottom: 0; }
.facts dt { font-size: 0.84rem; color: var(--muted); }
.facts dd { margin: 0; font-family: var(--mono); font-size: 0.8rem; text-align: right; }

.term-label { margin: 1.8rem 0 0.5rem; font-size: 0.8rem; color: var(--faint); }
.term {
  display: flex; align-items: center; gap: 10px; max-width: 100%;
  padding: 9px 9px 9px 14px; border: 1px solid #1b2226; border-radius: var(--radius);
  background: #07090b; color: #d7e2dc; font-family: var(--mono); font-size: 0.82rem;
}
.term code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; font-family: inherit; scrollbar-width: thin; }
.term .pr { color: #5cf0a5; margin-right: 1ch; }
.copy {
  flex: 0 0 auto; padding: 4px 11px; cursor: pointer;
  font-family: var(--mono); font-size: 0.72rem; color: #8b9a92;
  background: none; border: 1px solid #2c3740; border-radius: 6px;
}
.copy:hover, .copy.is-done { color: #5cf0a5; border-color: #1f4d38; }
.copy[hidden] { display: none; }

.cmp-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.cmp { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.cmp th, .cmp td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.cmp tbody tr:last-child th, .cmp tbody tr:last-child td { border-bottom: 0; }
.cmp thead th { font-family: var(--mono); font-size: 0.72rem; font-weight: 400; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.cmp tbody th { font-weight: 400; }
.cmp td, .cmp thead th:not(:first-child) { width: 76px; text-align: center; }
.cmp td svg { margin: 0 auto; }
.cmp .yes { color: var(--accent); }
.cmp .no { color: var(--faint); }

.probox {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  margin-top: 1.4rem; padding: 18px 20px;
  background: var(--panel); border: 1px solid var(--accent-line); border-radius: var(--radius);
}
.probox h3 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.probox p { color: var(--muted); font-size: 0.9rem; margin: 0; max-width: 62ch; }

/* ---- RESPONSIVE ---- */
@media (max-width: 960px) {
  .head-in { position: relative; }
  .nav { order: 3; width: 100%; padding-bottom: 2px; }
  .dd { position: static; }
  .dd-panel, .dd-panel--plugins { left: var(--gap); right: var(--gap); width: auto; top: 100%; margin-top: -4px; }
}
@media (max-width: 560px) {
  .head-cta { width: 32px; padding: 0; justify-content: center; }
  .head-cta span { display: none; }
  .announce { font-size: 0.7rem; gap: 6px 8px; }
  .announce svg { display: none; }
  .dd-plugin { grid-template-columns: 10px 1fr; }
  .dd-status { grid-column: 2; }
  .pb-body { gap: 18px; padding: 18px; min-height: 170px; }
  .cmp th, .cmp td { padding: 10px 12px; }
  .cmp td, .cmp thead th:not(:first-child) { width: 56px; }
}
@media (max-width: 420px) {
  .pbanner:not(.pbanner--sm) .pb-list { display: none; }
}
@media (max-width: 560px) {
  .head-in { min-height: 0; }
  .nav { gap: 2px 14px; }
  .nav-link { font-size: 0.86rem; }
  .tl li { grid-template-columns: 1fr; gap: 2px; }
  .tl--steps li { grid-template-columns: 40px 1fr; gap: 10px; }
  .lang { padding: 4px 6px; font-size: 0.66rem; }
  .stat { padding: 18px 14px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .caret { opacity: 1; }
}
