/* ============================================================
   Dozzo Marketing & Design — Blog styles
   Uses the same design tokens as home.css / pages.css.
   Included only on /blog/* pages, after pages.css.
   ============================================================ */

/* --- Blog index (hub) --- */
.blog-listing { padding: 1.75rem 0 4.5rem; }

/* Tighten the space between the blog hero copy and the latest post banner */
.blog-hero { padding-bottom: 2.5rem; }

/* Featured / latest post banner on the blog main page */
.blog-latest {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 0;
  align-items: stretch;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
  margin: 1.6rem 0 2.8rem;
  text-decoration: none;
  color: var(--text);
  transition: box-shadow 0.25s ease;
}
.blog-latest:hover { box-shadow: var(--shadow-red); }
.blog-latest-media { position: relative; min-height: 100%; }
.blog-latest-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-latest-body { padding: 1.8rem 1.9rem; display: flex; flex-direction: column; justify-content: center; }
.blog-latest-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--red);
  margin-bottom: 0.7rem;
}
.blog-latest-body h2 { font-size: 1.55rem; line-height: 1.3; margin-bottom: 0.65rem; color: var(--text); }
.blog-latest-body p { font-size: 0.98rem; color: var(--text-dim); line-height: 1.6; margin-bottom: 1.1rem; }
.blog-latest-body .blog-card-meta { margin-top: auto; }
@media (max-width: 720px) {
  .blog-latest { grid-template-columns: 1fr; }
  .blog-latest-media { aspect-ratio: 16 / 9; }
}
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.6rem;
}
.blog-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
  box-shadow: var(--shadow);
}
.blog-card:hover { box-shadow: var(--shadow-red); transform: translateY(-4px); }
.blog-card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--warm);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.blog-card-thumb .thumb-mark {
  font-size: 2.4rem;
  color: var(--red);
  opacity: 0.85;
}
.blog-card-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.blog-card:hover .blog-card-thumb img { transform: scale(1.04); }
.blog-card-body { padding: 1.4rem 1.5rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.blog-card-cat {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: var(--red);
  margin-bottom: 0.6rem;
}
.blog-card-title { font-size: 1.15rem; line-height: 1.35; margin-bottom: 0.6rem; color: var(--text); }
.blog-card-excerpt { font-size: 0.92rem; color: var(--text-dim); line-height: 1.55; margin-bottom: 1rem; flex: 1; }
.blog-card-meta { font-size: 0.78rem; color: var(--text-muted); display: flex; gap: 0.6rem; align-items: center; }

/* --- Blog article page --- */
.blog-post { padding: 3rem 0 4.5rem; }
.blog-article { max-width: 760px; }
.blog-article-head { margin-bottom: 2rem; }
.blog-article-title { font-size: clamp(1.7rem, 3.2vw, 2.4rem); line-height: 1.25; color: var(--text); margin: 0.6rem 0; }
.blog-article-deck { font-size: 1.08rem; color: var(--text-dim); line-height: 1.6; margin-bottom: 1.4rem; }
.blog-article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.2rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  align-items: center;
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}
.blog-article-meta .author { display: inline-flex; align-items: center; gap: 0.5rem; }
.blog-article-meta .avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--warm); color: var(--red);
  display: inline-grid; place-items: center;
  font-weight: 700; font-size: 0.8rem;
}
.blog-article-meta a { color: var(--red); font-weight: 600; }

/* Featured / lead image on article pages */
.blog-featured {
  margin: 1.8rem 0 2.2rem;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--warm);
}
.blog-featured img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }

/* Table of contents */
.blog-toc {
  background: var(--paper);
  border: 1px solid var(--line);
  border-left: 3px solid var(--red);
  border-radius: 12px;
  padding: 1.2rem 1.4rem;
  margin: 1.8rem 0 2.2rem;
  font-size: 0.92rem;
}
.blog-toc strong { display: block; margin-bottom: 0.5rem; color: var(--text); }
.blog-toc ol { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.35rem; }
.blog-toc a { color: var(--text-dim); text-decoration: none; }
.blog-toc a:hover { color: var(--red); }

/* Article prose */
.blog-prose { font-size: 1.02rem; line-height: 1.78; color: var(--text); }
.blog-prose h2 {
  font-size: 1.5rem;
  line-height: 1.3;
  margin: 2.4rem 0 1rem;
  padding-top: 0.2rem;
  color: var(--text);
}
.blog-prose h3 { font-size: 1.18rem; margin: 1.8rem 0 0.7rem; color: var(--text); }
.blog-prose p { margin: 0 0 1.1rem; }
.blog-prose ul, .blog-prose ol { margin: 0 0 1.2rem; padding-left: 1.4rem; }
.blog-prose li { margin-bottom: 0.45rem; }
.blog-prose strong { color: var(--text); }
.blog-prose a { color: var(--red); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.blog-prose a:hover { color: var(--red-bright); }

/* Callout / note */
.blog-callout {
  background: var(--warm);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1.1rem 1.3rem;
  margin: 1.6rem 0;
  font-size: 0.95rem;
  color: var(--text-dim);
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
}
.blog-callout .callout-ico { color: var(--red); font-size: 1.1rem; margin-top: 0.15rem; }

/* Small comparison table */
.blog-table-wrap { overflow-x: auto; margin: 1.6rem 0; }
.blog-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
}
.blog-table table { width: 100%; }
.blog-table th, .blog-table td {
  border: 1px solid var(--line);
  padding: 0.75rem 0.9rem;
  text-align: left;
  vertical-align: top;
}
.blog-table th {
  background: var(--paper);
  font-weight: 700;
  color: var(--text);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.blog-table td { color: var(--text-dim); line-height: 1.55; }

/* Step list */
.blog-steps { counter-reset: bstep; margin: 1.4rem 0 1.6rem; padding: 0; list-style: none; }
.blog-steps li {
  position: relative;
  padding: 0 0 1.2rem 2.8rem;
  margin-bottom: 1.2rem;
  border-left: 2px solid var(--line);
}
.blog-steps li::before {
  counter-increment: bstep;
  content: counter(bstep, decimal-leading-zero);
  position: absolute;
  left: -1.15rem;
  top: 0;
  width: 2.3rem; height: 2.3rem;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  display: grid;
  place-items: center;
}
.blog-steps li:last-child { border-left-color: transparent; }

/* Article footer nav */
.blog-post-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2.6rem;
  padding-top: 1.6rem;
  border-top: 1px solid var(--line);
  font-size: 0.92rem;
}
.blog-post-nav a { color: var(--red); font-weight: 600; text-decoration: none; }
.blog-post-nav a:hover { text-decoration: underline; }

/* Author / about strip */
.blog-author {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.2rem 1.4rem;
  margin-top: 2.2rem;
}
.blog-author .avatar {
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--warm); color: var(--red);
  display: grid; place-items: center;
  font-weight: 700; font-size: 1.05rem;
  flex: 0 0 auto;
}
.blog-author strong { display: block; color: var(--text); margin-bottom: 0.25rem; }
.blog-author p { font-size: 0.9rem; color: var(--text-dim); line-height: 1.55; margin: 0; }

/* Responsive */
@media (max-width: 640px) {
  .blog-grid { grid-template-columns: 1fr; }
  .blog-prose { font-size: 1rem; }
}
