/* ═══════════════════════════════════════════════
   blog.css — спільні стилі для блогу drsyvak.com.ua
   ═══════════════════════════════════════════════ */
:root {
  --bg: #ffffff;
  --bg2: #f5f5f7;
  --bg3: #000000;
  --text: #1d1d1f;
  --text2: #6e6e73;
  --text3: #86868b;
  --blue: #0071e3;
  --blue-hover: #0077ed;
  --border: rgba(0,0,0,0.08);
  --radius: 18px;
  --radius-sm: 12px;
}
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-font-smoothing: antialiased; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text); background: var(--bg);
  overflow-x: hidden; line-height: 1.5;
}

/* ─── NAV ─── */
body > nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: 52px;
  background: rgba(255,255,255,0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1200px; margin: 0 auto; height: 100%;
  display: flex; align-items: center; padding: 0 2rem; gap: 2rem;
}
.nav-logo { font-size: 19px; font-weight: 600; color: var(--text); text-decoration: none; letter-spacing: -.02em; }
.nav-links { display: flex; gap: 1.75rem; list-style: none; flex: 1; }
.nav-links a { font-size: 14px; color: var(--text2); text-decoration: none; transition: color .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--text); }
.nav-book-btn {
  background: var(--blue); color: white; padding: 7px 16px;
  border-radius: 980px; font-size: 14px; font-weight: 500;
  text-decoration: none; transition: background .2s;
}
.nav-book-btn:hover { background: var(--blue-hover); }
.nav-burger { display: none; flex-direction: column; gap: 4px; background: none; border: none; cursor: pointer; }
.nav-burger span { width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: .3s; }

.mobile-menu {
  position: fixed; top: 52px; left: 0; right: 0; z-index: 999;
  background: white; border-bottom: 1px solid var(--border);
  padding: 1rem 2rem; display: none; flex-direction: column; gap: .5rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a { color: var(--text); text-decoration: none; padding: .6rem 0; font-size: 16px; border-bottom: 1px solid var(--border); }

/* ─── BLOG LIST (blog.html) ─── */
.blog-hero {
  padding: 8rem 2rem 3rem; text-align: center;
  max-width: 800px; margin: 0 auto;
}
.blog-hero .eyebrow {
  display: inline-block; font-size: 13px; font-weight: 600;
  color: var(--blue); text-transform: uppercase;
  letter-spacing: .08em; margin-bottom: 1rem;
}
.blog-hero h1 {
  font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 700;
  letter-spacing: -.03em; line-height: 1.05; margin-bottom: 1rem;
}
.blog-hero p { font-size: 19px; color: var(--text2); line-height: 1.5; }

.blog-grid {
  max-width: 1100px; margin: 0 auto; padding: 2rem 2rem 6rem;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 1.5rem;
}
.blog-card {
  background: var(--bg2); border-radius: var(--radius);
  border: 1px solid var(--border); overflow: hidden;
  text-decoration: none; color: var(--text);
  transition: all .25s; display: flex; flex-direction: column;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0,0,0,0.1); border-color: rgba(0,113,227,.2); }
.blog-card-body { padding: 1.75rem; flex: 1; display: flex; flex-direction: column; }
.blog-card .cat {
  display: inline-block; align-self: flex-start;
  font-size: 11px; font-weight: 600; color: var(--blue);
  background: rgba(0,113,227,.08); padding: 4px 12px;
  border-radius: 980px; text-transform: uppercase; letter-spacing: .04em;
  margin-bottom: 1rem;
}
.blog-card h2 { font-size: 21px; font-weight: 600; letter-spacing: -.02em; line-height: 1.25; margin-bottom: .65rem; }
.blog-card p { font-size: 15px; color: var(--text2); line-height: 1.55; flex: 1; }
.blog-card .read { font-size: 14px; color: var(--blue); font-weight: 500; margin-top: 1rem; }

/* ─── ARTICLE (стаття) ─── */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 7rem 2rem 4rem; }
.breadcrumb { position: static; height: auto; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; border: none; z-index: auto; display: block; font-size: 14px; color: var(--text3); margin-bottom: 1.5rem; }
.breadcrumb a { color: var(--text2); text-decoration: none; }
.breadcrumb a:hover { color: var(--blue); }

.article-cat {
  display: inline-block; font-size: 12px; font-weight: 600;
  color: var(--blue); background: rgba(0,113,227,.08);
  padding: 5px 14px; border-radius: 980px;
  text-transform: uppercase; letter-spacing: .05em; margin-bottom: 1.25rem;
}
.article-wrap h1 {
  font-size: clamp(1.9rem, 4.5vw, 2.75rem); font-weight: 700;
  letter-spacing: -.03em; line-height: 1.1; margin-bottom: 1rem;
}
.article-meta {
  display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
  font-size: 14px; color: var(--text3);
  padding-bottom: 1.5rem; margin-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}
.article-meta .author { color: var(--text); font-weight: 500; }

.article-lede {
  font-size: 20px; line-height: 1.6; color: var(--text);
  margin-bottom: 2rem; font-weight: 400;
}
.article-body { font-size: 17px; line-height: 1.75; color: #2c2c2e; }
.article-body h2 {
  font-size: 26px; font-weight: 700; letter-spacing: -.02em;
  margin: 2.5rem 0 1rem; line-height: 1.2;
}
.article-body h3 {
  font-size: 20px; font-weight: 600; letter-spacing: -.01em;
  margin: 1.75rem 0 .75rem;
}
.article-body p { margin-bottom: 1.25rem; }
.article-body ul, .article-body ol { margin: 0 0 1.5rem 1.5rem; }
.article-body li { margin-bottom: .65rem; }
.article-body strong { font-weight: 600; color: var(--text); }
.article-body a { color: var(--blue); text-decoration: none; border-bottom: 1px solid rgba(0,113,227,.3); }
.article-body a:hover { border-bottom-color: var(--blue); }
.article-img { width: 100%; border-radius: var(--radius); margin: 2rem 0; box-shadow: 0 10px 40px rgba(0,0,0,0.1); }
.article-figure { margin: 2rem auto; max-width: 640px; }
.article-figure img {
  display: block; margin: 0 auto;
  width: 100%; height: auto;
  border-radius: var(--radius);
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}
.article-figure figcaption { text-align: center; font-size: 0.875rem; color: var(--text2); margin-top: 0.75rem; font-style: italic; }

/* виноска / важливо */
.callout {
  background: var(--bg2); border-left: 4px solid var(--blue);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 1.25rem 1.5rem; margin: 1.75rem 0;
}
.callout.warning { border-left-color: #ff9500; background: #fff8ec; }
.callout.success { border-left-color: #34c759; background: #f0faf2; }
.callout p { margin: 0; font-size: 16px; }
.callout strong { display: block; margin-bottom: .35rem; }

/* FAQ блок */
.article-faq { margin: 3rem 0 0; }
.article-faq h2 { font-size: 26px; margin-bottom: 1.25rem; }
.faq-q {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  margin-bottom: .75rem; overflow: hidden; background: white;
}
.faq-q summary {
  padding: 1.1rem 1.35rem; font-size: 17px; font-weight: 600;
  cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center;
}
.faq-q summary::-webkit-details-marker { display: none; }
.faq-q summary::after { content: '+'; font-size: 22px; color: var(--blue); font-weight: 400; }
.faq-q[open] summary::after { content: '−'; }
.faq-q .faq-a { padding: 0 1.35rem 1.2rem; font-size: 16px; line-height: 1.65; color: var(--text2); }

/* CTA в кінці статті */
.article-cta {
  background: linear-gradient(135deg, #0071e3, #0077ed);
  border-radius: var(--radius); padding: 2.5rem; text-align: center;
  margin: 3rem 0 0; color: white;
}
.article-cta h3 { font-size: 24px; font-weight: 700; letter-spacing: -.02em; margin-bottom: .65rem; }
.article-cta p { font-size: 16px; opacity: .9; margin-bottom: 1.5rem; }
.article-cta a {
  display: inline-block; background: white; color: var(--blue);
  padding: 13px 32px; border-radius: 980px; font-weight: 600;
  text-decoration: none; font-size: 16px; transition: transform .2s;
}
.article-cta a:hover { transform: scale(1.04); }

/* зв'язані статті */
.related { max-width: 760px; margin: 3rem auto 0; padding: 0 2rem; }
.related h2 { font-size: 22px; font-weight: 700; margin-bottom: 1.25rem; }
.related-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.related-card {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 1.25rem;
  text-decoration: none; color: var(--text); transition: all .2s;
}
.related-card:hover { border-color: rgba(0,113,227,.25); transform: translateY(-2px); }
.related-card .rc-cat { font-size: 11px; color: var(--blue); font-weight: 600; text-transform: uppercase; }
.related-card h3 { font-size: 16px; font-weight: 600; margin-top: .35rem; line-height: 1.3; }

/* ─── FOOTER ─── */
.footer {
  background: var(--bg2); border-top: 1px solid var(--border);
  padding: 3rem 2rem; margin-top: 4rem;
}
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 2rem;
}
.footer-col h4 { font-size: 13px; color: var(--text3); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 1rem; }
.footer-col a, .footer-col p { display: block; font-size: 15px; color: var(--text2); text-decoration: none; margin-bottom: .5rem; }
.footer-col a:hover { color: var(--blue); }
.footer-bottom { max-width: 1100px; margin: 2rem auto 0; padding-top: 1.5rem; border-top: 1px solid var(--border); font-size: 13px; color: var(--text3); }

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-burger { display: flex; }
  .nav-inner { padding: 0 1.25rem; }
  .blog-grid { grid-template-columns: 1fr; padding: 1.5rem 1.25rem 4rem; }
  .article-wrap { padding: 6rem 1.25rem 3rem; }
  .related-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; gap: 1.5rem; }
}

/* ─── BLOG: групи статей по суглобах ─── */
.blog-list { padding-bottom: 4rem; }
.blog-section { max-width: 1100px; margin: 0 auto; padding: 0 2rem; }
.blog-section-title {
  font-size: 28px; font-weight: 700; letter-spacing: -.02em;
  margin: 2.75rem 0 1.25rem; padding-bottom: .65rem;
  border-bottom: 1px solid var(--border);
}
.blog-section .blog-grid {
  max-width: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 1.5rem;
}
@media (max-width: 768px) {
  .blog-section { padding: 0 1.25rem; }
  .blog-section .blog-grid { grid-template-columns: 1fr; }
  .blog-section-title { font-size: 24px; margin: 2rem 0 1rem; }
}