/* regulacja.ai — design system v1.1
   Jasne tło, grafit, akcent granatowy. Estetyka niezależnego medium analitycznego. */

:root {
  --bg: #FAFAF8;
  --bg-soft: #F3F2EE;
  --text: #1A1A1A;
  --text-muted: #5A574F;
  --accent: #1B2A4A;
  --accent-hover: #2E4370;
  --accent-soft: #E8EBF2;
  --border: #E2E0D9;
  --card: #FFFFFF;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow-sm: 0 1px 2px rgba(26, 26, 26, 0.05);
  --shadow-md: 0 6px 24px -8px rgba(27, 42, 74, 0.14);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  border-top: 3px solid var(--accent);
}

::selection { background: var(--accent); color: #fff; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; transition: color 0.15s ease; }
a:hover { color: var(--accent-hover); }

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

.container { max-width: 680px; margin: 0 auto; padding: 0 24px; }
.container-wide { max-width: 1000px; margin: 0 auto; padding: 0 24px; }

/* ---------- Nagłówek / nawigacja ---------- */
header.site-header {
  border-bottom: 1px solid var(--border);
  background: rgba(250, 250, 248, 0.92);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner {
  max-width: 1000px; margin: 0 auto; padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
}
.logo {
  font-family: var(--serif); font-weight: 700; font-size: 24px;
  color: var(--text); text-decoration: none; letter-spacing: -0.015em;
}
.logo:hover { color: var(--text); }
.logo .dot-ai { color: var(--accent); }
nav.main-nav { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
nav.main-nav a {
  font-size: 15px; font-weight: 500; color: var(--text);
  text-decoration: none; letter-spacing: 0.01em;
}
nav.main-nav a:hover { color: var(--accent); }
nav.main-nav a.nav-cta {
  background: var(--accent); color: #fff; padding: 9px 18px;
  border-radius: 7px; font-weight: 600; box-shadow: var(--shadow-sm);
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
nav.main-nav a.nav-cta:hover {
  background: var(--accent-hover); color: #fff;
  transform: translateY(-1px); box-shadow: var(--shadow-md);
}

/* ---------- Hero ---------- */
.hero { padding: 88px 0 64px; }
.hero h1 {
  font-family: var(--serif); font-size: clamp(34px, 5.4vw, 52px); font-weight: 700;
  line-height: 1.12; letter-spacing: -0.015em; margin-bottom: 22px;
  max-width: 620px;
}
.hero .subtitle {
  font-size: 19px; color: var(--text-muted); max-width: 580px; margin-bottom: 36px;
  line-height: 1.65;
}

/* ---------- Formularz newslettera ---------- */
form.newsletter-form { display: flex; gap: 10px; max-width: 500px; flex-wrap: wrap; }
form.newsletter-form input[type="email"] {
  flex: 1 1 250px; padding: 13px 16px; font-size: 16px; font-family: var(--sans);
  border: 1px solid var(--border); border-radius: 8px; background: var(--card);
  color: var(--text); box-shadow: var(--shadow-sm);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
form.newsletter-form input[type="email"]::placeholder { color: #9B978D; }
form.newsletter-form input[type="email"]:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
form.newsletter-form button {
  padding: 13px 24px; font-size: 16px; font-weight: 600; font-family: var(--sans);
  background: var(--accent); color: #fff; border: none; border-radius: 8px; cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
form.newsletter-form button:hover {
  background: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-md);
}
.form-note { font-size: 14px; color: var(--text-muted); margin-top: 12px; }

/* ---------- Kafle „Dlaczego teraz" ---------- */
.tiles { padding: 8px 0 72px; }
.tiles-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px;
}
.tile {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 30px 28px; box-shadow: var(--shadow-sm); position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.tile::before {
  content: ""; position: absolute; top: 0; left: 28px; width: 44px; height: 3px;
  background: var(--accent); border-radius: 0 0 3px 3px;
}
.tile h3 {
  font-family: var(--sans); font-size: 14px; font-weight: 700;
  color: var(--accent); margin-bottom: 12px;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.tile p { font-size: 16px; color: var(--text); line-height: 1.6; }

/* ---------- Sekcje ---------- */
.section-title {
  font-family: var(--serif); font-size: 29px; font-weight: 700; margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.section-title::after {
  content: ""; display: block; width: 48px; height: 3px;
  background: var(--accent); margin-top: 12px; border-radius: 2px;
}

/* ---------- Feed briefów ---------- */
.feed { padding: 16px 0 64px; }
.feed .section-title { margin-bottom: 28px; }
.feed-item { padding: 26px 0; border-bottom: 1px solid var(--border); }
.feed-item:first-of-type { border-top: 1px solid var(--border); }
.feed-meta {
  font-size: 13.5px; color: var(--text-muted); margin-bottom: 8px;
  text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500;
}
.feed-item h3 { font-family: var(--serif); font-size: 23px; line-height: 1.3; margin-bottom: 8px; letter-spacing: -0.005em; }
.feed-item h3 a { color: var(--text); text-decoration: none; transition: color 0.15s ease; }
.feed-item h3 a:hover { color: var(--accent); }
.feed-item .lead { font-size: 16.5px; color: var(--text-muted); line-height: 1.6; }
.feed-more { margin-top: 26px; font-weight: 600; font-size: 16px; }
.feed-more a { text-decoration: none; }
.feed-more a:hover { text-decoration: underline; }
.feed-empty {
  border: 1px dashed #CFCCC3; border-radius: 12px; padding: 30px 28px;
  color: var(--text-muted); font-size: 16.5px; background: var(--card);
  line-height: 1.65;
}

/* ---------- Sekcja o autorze (skrót) ---------- */
.author-blurb { padding: 8px 0 64px; }
.author-blurb .section-title { margin-bottom: 24px; }
.author-blurb blockquote {
  border-left: 3px solid var(--accent); padding: 6px 0 6px 24px;
  font-size: 17.5px; color: var(--text); line-height: 1.7;
}
.author-blurb blockquote a { font-weight: 600; text-decoration: none; }
.author-blurb blockquote a:hover { text-decoration: underline; }

/* ---------- Zamknięcie CTA ---------- */
.closing-cta {
  background: var(--accent); color: #fff; padding: 64px 0;
}
.closing-cta h2 {
  font-family: var(--serif); font-size: 32px; margin-bottom: 10px; letter-spacing: -0.01em;
}
.closing-cta p { color: rgba(255, 255, 255, 0.75); margin-bottom: 28px; font-size: 17px; }
.closing-cta form.newsletter-form input[type="email"] {
  border-color: transparent;
}
.closing-cta form.newsletter-form input[type="email"]:focus {
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.25);
}
.closing-cta form.newsletter-form button {
  background: #fff; color: var(--accent);
}
.closing-cta form.newsletter-form button:hover { background: var(--bg-soft); }
.closing-cta .form-note { color: rgba(255, 255, 255, 0.65); }

/* ---------- Treść artykułu / stron statycznych ---------- */
article.prose, .prose { padding: 64px 0 80px; }
.prose h1 {
  font-family: var(--serif); font-size: clamp(30px, 4.6vw, 40px); font-weight: 700;
  line-height: 1.18; margin-bottom: 16px; letter-spacing: -0.012em;
}
.prose h2 { font-family: var(--serif); font-size: 26px; font-weight: 700; margin: 44px 0 16px; letter-spacing: -0.008em; }
.prose h3 { font-family: var(--sans); font-size: 19px; font-weight: 700; margin: 32px 0 10px; }
.prose p, .prose ul, .prose ol { font-family: var(--serif); font-size: 19px; line-height: 1.7; margin-bottom: 20px; }
.prose ul, .prose ol { padding-left: 26px; }
.prose li { margin-bottom: 10px; }
.prose li::marker { color: var(--accent); }
.prose strong { font-weight: 700; }
.prose .article-meta {
  font-family: var(--sans); font-size: 13.5px; color: var(--text-muted); margin-bottom: 10px;
  text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500;
}
.prose .article-lead {
  font-family: var(--serif); font-size: 22px; color: var(--text-muted);
  margin-bottom: 32px; line-height: 1.55;
}

.summary-box {
  background: var(--accent-soft); border: none; border-left: 3px solid var(--accent);
  border-radius: 10px; padding: 24px 28px; margin: 32px 0;
}
.summary-box h2 {
  font-family: var(--sans); font-size: 13.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; margin: 0 0 14px; color: var(--accent);
}
.summary-box ul { font-family: var(--sans); font-size: 16px; margin-bottom: 0; line-height: 1.6; }
.summary-box li { margin-bottom: 10px; }
.summary-box li:last-child { margin-bottom: 0; }

.ops-section {
  border-top: 3px solid var(--accent); margin-top: 48px; padding-top: 8px;
}
.article-cta {
  margin-top: 40px; padding: 24px 28px; background: var(--card);
  border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow-sm);
  font-family: var(--sans) !important; font-size: 16.5px !important;
}
.article-cta a { font-weight: 600; }
.author-footer {
  margin-top: 40px; font-family: var(--sans) !important; font-size: 15px !important;
  color: var(--text-muted);
  border-top: 1px solid var(--border); padding-top: 20px;
}
.post-nav {
  display: flex; justify-content: space-between; gap: 16px; margin-top: 32px;
  font-family: var(--sans); font-size: 15.5px;
}
.post-nav a { text-decoration: none; font-weight: 500; }
.post-nav a:hover { text-decoration: underline; }

/* ---------- Archiwum ---------- */
.archive-year {
  font-family: var(--sans) !important; font-size: 14px !important; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent) !important;
  margin: 40px 0 12px !important;
}
ul.archive-list { list-style: none; padding: 0 !important; font-family: var(--sans) !important; }
ul.archive-list li {
  padding: 14px 0; border-bottom: 1px solid var(--border); font-size: 17px;
  display: flex; gap: 20px; flex-wrap: wrap; margin-bottom: 0 !important;
}
ul.archive-list time { color: var(--text-muted); font-size: 14.5px; min-width: 110px; padding-top: 2px; }
ul.archive-list a { text-decoration: none; font-weight: 500; }
ul.archive-list a:hover { text-decoration: underline; }

/* ---------- FAQ (accordion) ---------- */
details.faq {
  border: 1px solid var(--border); border-radius: 10px; background: var(--card);
  padding: 18px 22px; margin-bottom: 12px; box-shadow: var(--shadow-sm);
}
details.faq summary { font-weight: 600; cursor: pointer; font-size: 17px; font-family: var(--sans); }
details.faq summary::marker { color: var(--accent); }
details.faq p { margin-top: 12px; font-size: 16px !important; color: var(--text-muted); font-family: var(--sans) !important; margin-bottom: 0 !important; }

/* ---------- Stopka ---------- */
footer.site-footer {
  border-top: 1px solid var(--border); background: var(--bg-soft);
  padding: 40px 0 48px; margin-top: 0;
  font-size: 15px; color: var(--text-muted);
}
.footer-inner {
  max-width: 1000px; margin: 0 auto; padding: 0 24px;
  display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.footer-nav { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-nav a { color: var(--text-muted); text-decoration: none; }
.footer-nav a:hover { color: var(--accent); }
.footer-disclosure {
  max-width: 1000px; margin: 18px auto 0; padding: 0 24px;
  font-size: 13.5px; color: #8B877D; line-height: 1.6;
}

@media (max-width: 560px) {
  .hero { padding: 56px 0 44px; }
  nav.main-nav { gap: 16px; }
  .closing-cta { padding: 48px 0; }
}

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