/* ── BLOG SHARED STYLES ── */
* { box-sizing:border-box;margin:0;padding:0; }
html,body { overflow-x:hidden;max-width:100vw; }
body { font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;color:#111;background:#fff;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:transparent; }
html { scroll-behavior:smooth; }
img { max-width:100%;height:auto;display:block; }
a { color:#C94F0C;text-decoration:none;transition:opacity 0.2s; }
a:hover { opacity:0.75; }

.inner { max-width:1100px;margin:0 auto;padding:0 40px; }
.btn-green { display:inline-block;background:#22CC66;color:#fff !important;padding:14px 28px;border-radius:8px;font-size:15px;font-weight:500;text-decoration:none;transition:opacity 0.2s,transform 0.15s; }
.btn-green:hover { opacity:0.88;transform:translateY(-1px); }

.btn-outline { display:inline-block;background:transparent;color:#333 !important;padding:13px 24px;border-radius:8px;font-size:14px;font-weight:500;border:1.5px solid #C94F0C;transition:background 0.2s; }
.btn-outline:hover { background:#F0E8E0;opacity:1; }

.tag { display:inline-block;font-size:11px;font-weight:500;letter-spacing:0.08em;text-transform:uppercase;color:#C94F0C;border:0.5px solid #C94F0C;border-radius:100px;padding:4px 12px; }

/* ── NAV ── */
nav.blog-nav { position:sticky;top:0;z-index:100;background:#F5F0EB;border-bottom:0.5px solid #DDCCBB;transition:box-shadow 0.3s,background 0.3s; }
nav.blog-nav.scrolled { background:rgba(245,240,235,0.92);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);box-shadow:0 1px 20px rgba(0,0,0,0.07); }
nav.blog-nav .inner { display:flex;align-items:center;justify-content:space-between;padding-top:18px;padding-bottom:18px; }
.nav-brand { font-size:18px;font-weight:500;letter-spacing:-0.02em;color:#111; }
.nav-brand span { color:#C94F0C; }
.nav-links { display:flex;gap:28px;align-items:center; }
.nav-links a { color:#444;font-size:14px;font-weight:500; }
.nav-links a.active { color:#C94F0C; }

/* ── READING PROGRESS BAR ── */
.read-progress { position:fixed;top:0;left:0;height:3px;background:linear-gradient(90deg,#C94F0C,#FF7A50);width:0;z-index:200;transition:width 0.1s; }

/* ── BREADCRUMBS ── */
.breadcrumbs { font-size:13px;color:#888;margin-bottom:24px; }
.breadcrumbs a { color:#888; }
.breadcrumbs span { margin:0 8px;color:#ccc; }

/* ── BLOG INDEX ── */
.blog-hero { padding:80px 0 60px;background:#F5F0EB;border-bottom:0.5px solid #DDCCBB;text-align:center; }
.blog-hero h1 { font-size:48px;font-weight:500;letter-spacing:-0.03em;line-height:1.1;margin-bottom:18px; }
.blog-hero p { font-size:18px;color:#666;max-width:580px;margin:0 auto;line-height:1.6; }

.blog-categories { display:flex;gap:8px;flex-wrap:wrap;justify-content:center;margin-top:32px; }
.cat-pill { padding:8px 16px;border-radius:100px;border:0.5px solid #DDCCBB;background:#fff;font-size:13px;color:#555;cursor:pointer;transition:all 0.2s;text-decoration:none; }
.cat-pill:hover,.cat-pill.active { background:#C94F0C;color:#fff;border-color:#C94F0C;opacity:1; }

.featured-post { margin:60px auto;max-width:1100px;padding:0 40px; }
.featured-card { background:#fff;border-radius:20px;border:0.5px solid #DDCCBB;overflow:hidden;display:grid;grid-template-columns:1.1fr 1fr;gap:0;transition:transform 0.2s,box-shadow 0.2s; }
.featured-card:hover { transform:translateY(-3px);box-shadow:0 16px 40px rgba(0,0,0,0.08); }
.featured-card img { width:100%;height:100%;object-fit:cover;min-height:340px; }
.featured-text { padding:48px;display:flex;flex-direction:column;justify-content:center; }
.featured-text .tag { margin-bottom:16px;align-self:flex-start; }
.featured-text h2 { font-size:32px;font-weight:500;letter-spacing:-0.02em;line-height:1.2;margin-bottom:14px;color:#111; }
.featured-text h2 a { color:inherit; }
.featured-text p { font-size:15px;color:#666;line-height:1.7;margin-bottom:20px; }
.post-meta { display:flex;align-items:center;gap:14px;font-size:13px;color:#999; }
.post-meta strong { color:#444;font-weight:500; }

.posts-grid { max-width:1100px;margin:0 auto 80px;padding:0 40px;display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:24px; }
.post-card { background:#fff;border-radius:14px;border:0.5px solid #DDCCBB;overflow:hidden;transition:transform 0.2s,box-shadow 0.2s,border-color 0.2s;display:flex;flex-direction:column; }
.post-card:hover { transform:translateY(-4px);box-shadow:0 12px 32px rgba(0,0,0,0.08);border-color:#C94F0C; }
.post-card img { width:100%;height:200px;object-fit:cover; }
.post-card-body { padding:24px;flex:1;display:flex;flex-direction:column; }
.post-card .tag { font-size:10px;align-self:flex-start;margin-bottom:12px; }
.post-card h3 { font-size:18px;font-weight:600;letter-spacing:-0.01em;line-height:1.3;margin-bottom:10px;color:#111; }
.post-card h3 a { color:inherit; }
.post-card p { font-size:14px;color:#666;line-height:1.6;margin-bottom:16px;flex:1; }

/* ── ARTICLE PAGE ── */
.article-hero { background:#F5F0EB;border-bottom:0.5px solid #DDCCBB;padding:48px 0 64px; }
.article-hero .inner { max-width:760px; }
.article-hero .tag { margin-bottom:20px; }
.article-hero h1 { font-size:42px;font-weight:600;letter-spacing:-0.03em;line-height:1.15;margin-bottom:20px;color:#0F172A; }
.article-hero p.lede { font-size:19px;color:#555;line-height:1.55;margin-bottom:28px; }
.author-bar { display:flex;align-items:center;gap:14px;font-size:14px; }
.author-avatar { width:42px;height:42px;border-radius:50%;background:linear-gradient(135deg,#C94F0C,#FF7A50);display:flex;align-items:center;justify-content:center;color:#fff;font-weight:700;font-size:16px;flex-shrink:0; }
.author-info { line-height:1.4; }
.author-info strong { color:#111;font-weight:600; }
.author-info span { color:#888;font-size:13px; }

.article-cover { max-width:1100px;margin:-40px auto 0;padding:0 40px;position:relative;z-index:2; }
.article-cover img { width:100%;height:420px;object-fit:cover;border-radius:16px;box-shadow:0 20px 50px rgba(0,0,0,0.12); }

.article-layout { max-width:1100px;margin:60px auto;padding:0 40px;display:grid;grid-template-columns:240px 1fr;gap:60px; }

/* TOC sticky */
.toc { position:sticky;top:90px;align-self:start;font-size:13px; }
.toc h4 { font-size:11px;letter-spacing:0.1em;text-transform:uppercase;color:#999;margin-bottom:14px;font-weight:600; }
.toc ol { list-style:none;counter-reset:toc;border-left:1px solid #DDCCBB;padding:0; }
.toc li { counter-increment:toc;padding:0; }
.toc li a { display:block;padding:8px 0 8px 16px;color:#666;border-left:2px solid transparent;margin-left:-1px;transition:color 0.2s,border-color 0.2s;font-size:13px;line-height:1.4; }
.toc li a:hover,.toc li a.active { color:#C94F0C;border-left-color:#C94F0C;opacity:1; }

/* Article body */
.article-body { font-size:17px;line-height:1.75;color:#222;max-width:680px; }
.article-body h2 { font-size:28px;font-weight:600;letter-spacing:-0.02em;margin:48px 0 16px;color:#0F172A;line-height:1.25;scroll-margin-top:80px; }
.article-body h3 { font-size:21px;font-weight:600;margin:36px 0 12px;color:#111;line-height:1.3;scroll-margin-top:80px; }
.article-body p { margin-bottom:20px; }
.article-body ul,.article-body ol { margin:0 0 20px 24px; }
.article-body li { margin-bottom:8px;line-height:1.7; }
.article-body strong { color:#111;font-weight:600; }
.article-body blockquote { border-left:3px solid #C94F0C;padding:8px 0 8px 22px;margin:28px 0;font-size:18px;color:#444;font-style:italic;background:#FBF8F4;border-radius:0 6px 6px 0;padding:16px 22px; }
.article-body code { background:#F5F0EB;border:0.5px solid #DDCCBB;border-radius:4px;padding:2px 6px;font-size:14px;font-family:'SF Mono',Monaco,monospace;color:#C94F0C; }
.article-body table { width:100%;border-collapse:collapse;margin:28px 0;font-size:14px;border:0.5px solid #DDCCBB;border-radius:8px;overflow:hidden; }
.article-body th { background:#F5F0EB;text-align:left;padding:12px 16px;font-weight:600;font-size:13px;letter-spacing:0.02em;color:#444; }
.article-body td { padding:12px 16px;border-top:0.5px solid #DDCCBB; }
.article-body tr:hover td { background:#FBF8F4; }
.article-body img.inline { border-radius:10px;margin:24px 0; }

.callout {
  background:#F5F0EB;border:0.5px solid #DDCCBB;border-radius:12px;
  padding:24px 28px;margin:32px 0;display:flex;gap:16px;align-items:flex-start;
}
.callout-ico { width:36px;height:36px;border-radius:8px;background:#C94F0C;display:flex;align-items:center;justify-content:center;flex-shrink:0; }
.callout-text { font-size:15px;line-height:1.65; }
.callout-text strong { display:block;margin-bottom:4px;color:#111; }

.cta-inline {
  background:linear-gradient(135deg,#C94F0C,#A03E08);color:#fff;
  border-radius:14px;padding:32px;margin:40px 0;text-align:center;
}
.cta-inline h4 { font-size:22px;font-weight:600;margin-bottom:10px;letter-spacing:-0.02em;line-height:1.25;color:#fff; }
.cta-inline p { font-size:15px;color:rgba(255,255,255,0.85);margin-bottom:18px;line-height:1.6; }
.cta-inline a { background:#fff;color:#C94F0C !important;padding:12px 26px;border-radius:8px;font-size:14px;font-weight:600;display:inline-block; }

/* Related posts */
.related { background:#F5F0EB;padding:60px 0;border-top:0.5px solid #DDCCBB; }
.related h3 { font-size:24px;font-weight:600;letter-spacing:-0.02em;margin-bottom:28px;text-align:center; }
.related-grid { display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:20px;max-width:1100px;margin:0 auto;padding:0 40px; }

/* Newsletter */
.newsletter { background:#0F172A;color:#fff;padding:64px 32px;text-align:center;border-radius:16px;margin:60px auto;max-width:680px;position:relative;overflow:hidden; }
.newsletter::before { content:'';position:absolute;top:0;left:20%;right:20%;height:1px;background:linear-gradient(90deg,transparent,#C94F0C,transparent); }
.newsletter h3 { font-size:26px;font-weight:600;letter-spacing:-0.02em;margin-bottom:12px;color:#fff; }
.newsletter p { font-size:15px;color:rgba(255,255,255,0.7);margin-bottom:24px;line-height:1.7; }
.newsletter form { display:flex;gap:8px;max-width:420px;margin:0 auto; }
.newsletter input { flex:1;padding:14px 16px;border-radius:8px;border:1px solid rgba(255,255,255,0.15);background:rgba(255,255,255,0.05);color:#fff;font-size:14px;outline:none; }
.newsletter input::placeholder { color:rgba(255,255,255,0.4); }
.newsletter input:focus { border-color:#C94F0C; }
.newsletter button { padding:14px 24px;border-radius:8px;border:none;background:#C94F0C;color:#fff;font-weight:600;font-size:14px;cursor:pointer;transition:opacity 0.2s; }
.newsletter button:hover { opacity:0.9; }

/* Footer */
footer.blog-footer { background:#0F172A;color:rgba(255,255,255,0.6);padding:40px 32px;text-align:center;font-size:13px; }
footer.blog-footer a { color:#C94F0C; }

/* ── REVEAL ── */
.reveal { opacity:0;transform:translateY(20px);transition:opacity 0.6s ease,transform 0.6s ease; }
.reveal.visible { opacity:1;transform:translateY(0); }

/* ── MOBILE ── */
@media (max-width: 900px) {
  .article-layout { grid-template-columns:1fr;gap:32px;padding:0 24px; }
  .toc { display:none; }
  .article-cover img { height:280px; }
  .featured-card { grid-template-columns:1fr; }
  .featured-card img { min-height:240px;height:240px; }
  .featured-text { padding:32px 28px; }
  .featured-text h2 { font-size:24px; }
}
@media (max-width: 768px) {
  .inner { padding:0 20px; }
  .blog-hero { padding:48px 0 40px; }
  .blog-hero h1 { font-size:32px; }
  .blog-hero p { font-size:15px; }
  .article-hero { padding:32px 0 48px; }
  .article-hero h1 { font-size:28px; }
  .article-hero p.lede { font-size:16px; }
  .article-cover { padding:0 20px;margin-top:-30px; }
  .article-cover img { height:220px;border-radius:12px; }
  .article-body { font-size:16px; }
  .article-body h2 { font-size:23px;margin-top:36px; }
  .article-body h3 { font-size:18px; }
  .featured-post { margin:40px auto;padding:0 20px; }
  .featured-text { padding:28px 24px; }
  .featured-text h2 { font-size:22px; }
  .posts-grid { padding:0 20px;margin-bottom:48px; }
  .related-grid { padding:0 20px; }
  .nav-links { gap:16px;font-size:13px; }
  .nav-links a:not(.btn-green):not(.active) { display:none; }
  .newsletter { padding:48px 24px;border-radius:14px; }
  .newsletter h3 { font-size:22px; }
  .newsletter form { flex-direction:column; }
  .cta-inline { padding:28px 22px; }
  .cta-inline h4 { font-size:19px; }
  .article-body table { font-size:13px; }
  .article-body th,.article-body td { padding:10px 12px; }
}
