
/* Blog-specific styles, additive on top of /assets/styles.css from the
   marketing site. We use the same CSS custom properties (--gold,
   --text-primary, --bg-card, --border, --border-hover, --bg-elevated)
   so the blog feels like an extension of elementaloracledeck.com. */

/* Skip-to-main-content link (a11y) */
.skip-link {
  position: absolute; top: -100%; left: 16px; z-index: 9999;
  padding: 12px 24px; background: var(--gold, #c9a84c);
  color: var(--bg-primary, #1a1f16);
  font-weight: 700; font-size: 0.9rem; text-decoration: none;
  border-radius: 6px; transition: top 0.2s ease;
}
.skip-link:focus { top: 16px; outline: 3px solid var(--gold, #c9a84c); outline-offset: 2px; }
#main:focus { outline: none; }

.blog-main { padding: 12px 0 64px; min-height: 60vh; }
@media (min-width: 768px) { .blog-main { padding: 16px 0 96px; } }

/* Hero / page header — override marketing-CSS `section { padding: 64px 0 }`
   which was adding huge dead space above the title */
.blog-hero { margin-bottom: 40px; text-align: center; padding: 0; }
.blog-hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--gold);
  margin: 0 0 10px;
  line-height: 1.15;
  font-weight: 600;
}
.blog-hero p.lead {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin: 0 auto;
  max-width: 60ch;
  line-height: 1.55;
}

/* Index / archive grid of post cards */
.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}
@media (min-width: 700px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .blog-grid { grid-template-columns: repeat(3, 1fr); gap: 36px; } }

.blog-card {
  display: flex; flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.blog-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);
  box-shadow: 0 12px 28px rgba(0,0,0,0.25);
}
.blog-card-image { display: block; }
.blog-card-image img {
  width: 100%; aspect-ratio: 3/2; object-fit: cover; display: block;
}
.blog-card-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 10px; }

.blog-card-categories {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-wrap: wrap; gap: 6px;
  font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase;
}
.blog-card-categories a {
  color: var(--gold);
  text-decoration: none;
  border: 1px solid var(--border-hover);
  border-radius: 999px;
  padding: 2px 10px;
}
.blog-card-categories a:hover { background: rgba(201,168,76,0.08); }

.blog-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem; line-height: 1.2;
  margin: 0; font-weight: 600;
}
.blog-card-title a { color: var(--text-primary); text-decoration: none; }
.blog-card-title a:hover { color: var(--gold); }

.blog-card-excerpt {
  font-size: 0.95rem; line-height: 1.55;
  color: var(--text-secondary);
  margin: 0;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-card-meta {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: auto 0 0;
  display: flex; gap: 10px; flex-wrap: wrap;
}
.blog-card-meta time::before { content: "· "; }

/* Pagination */
.blog-pager {
  display: flex; justify-content: space-between; gap: 16px;
  margin-top: 48px;
  font-family: 'Lato', sans-serif;
}
.blog-pager a {
  color: var(--gold); text-decoration: none;
  padding: 12px 18px;
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  min-height: 44px; display: inline-flex; align-items: center;
}
.blog-pager a:hover { background: rgba(201,168,76,0.08); }
.blog-pager-next { margin-left: auto; }

/* Empty state */
.blog-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
  font-size: 1.05rem;
}

/* Single post — mobile-first, claim most of the page real estate */
.blog-article {
  /* Mobile: edge to edge inside the container's 20px padding */
  width: 100%;
  margin: 0 auto;
}
/* Tablet: still wide, just let the container's padding do the breathing */
@media (min-width: 768px) {
  .blog-article { max-width: 100%; }
}
/* Desktop: cap so very wide screens don't make a single column feel lost,
   but use far more of the page than the old 720px did. Caps at the
   marketing site's --max-w-page (1200px) so it never exceeds the container. */
@media (min-width: 1100px) {
  .blog-article { max-width: 1100px; }
}
.blog-article-header { margin-bottom: 28px; }
@media (min-width: 768px) {
  .blog-article-header { margin-bottom: 36px; }
}

.blog-article-categories {
  list-style: none; padding: 0; margin: 0 0 14px;
  display: flex; flex-wrap: wrap; gap: 8px;
  font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase;
}
.blog-article-categories a {
  color: var(--gold); text-decoration: none;
  border: 1px solid var(--border-hover);
  border-radius: 999px;
  padding: 3px 12px;
}

.blog-article-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  color: var(--gold);
  margin: 0 0 14px;
  line-height: 1.12;
  letter-spacing: -0.01em;
  font-weight: 600;
}
.blog-article-meta {
  display: flex; gap: 14px; align-items: center; flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.92rem;
}
.blog-article-meta a { color: var(--text-secondary); }
.blog-article-hero {
  margin: 0 0 32px;
  border-radius: 14px; overflow: hidden;
  border: 1px solid var(--border);
}
.blog-article-hero img { display: block; width: 100%; height: auto; }

/* Prose: fills the article width on every breakpoint. The user wants
   real estate used — not wasted on margins — so we don't cap line length.
   We compensate for longer lines by bumping line-height for comfort. */
.blog-prose {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text-primary);
}
@media (min-width: 768px) {
  .blog-prose { font-size: 1.1rem; line-height: 1.78; }
}
@media (min-width: 1100px) {
  .blog-prose { font-size: 1.15rem; line-height: 1.8; }
}
.blog-prose p,
.blog-prose ul,
.blog-prose ol,
.blog-prose blockquote { margin: 0 0 1.2em; }
.blog-prose h1, .blog-prose h2, .blog-prose h3, .blog-prose h4 {
  font-family: 'Playfair Display', serif;
  color: var(--gold);
  line-height: 1.25;
  margin: 2em 0 0.6em;
  font-weight: 600;
}
.blog-prose h1 { font-size: 1.9rem; }
.blog-prose h2 { font-size: 1.55rem; }
.blog-prose h3 { font-size: 1.3rem; }
.blog-prose h4 { font-size: 1.1rem; }
.blog-prose a {
  color: var(--gold); text-decoration: underline; text-underline-offset: 3px;
}
.blog-prose a:hover { text-decoration-thickness: 2px; }
.blog-prose blockquote {
  border-left: 3px solid var(--gold);
  padding: 4px 0 4px 18px;
  color: var(--text-secondary);
  font-style: italic;
}
.blog-prose ul, .blog-prose ol { padding-left: 1.4em; }
.blog-prose li { margin-bottom: 0.4em; }
.blog-prose .blog-figure { margin: 1.6em 0; }
.blog-prose .blog-figure img {
  width: 100%; height: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  display: block;
}
.blog-prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
  background: var(--bg-elevated);
  padding: 2px 6px; border-radius: 4px;
  color: var(--text-primary);
}

/* Hashtag chips: social-style with # prefix, no boxy border */
.blog-article-tags {
  display: flex; flex-wrap: wrap; gap: 8px 14px;
  margin: 32px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.blog-hashtag {
  color: var(--gold);
  text-decoration: none;
  font-family: 'Lato', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: 6px;
  padding: 2px 4px;
  transition: background 0.15s ease, color 0.15s ease;
}
.blog-hashtag:hover { background: rgba(201,168,76,0.10); }
.blog-hashtag:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* Author block */
.blog-article-author {
  margin: 40px 0 0;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-card);
  display: flex; gap: 18px; align-items: flex-start;
}
.blog-article-author-img {
  width: 64px; height: 64px; border-radius: 50%; overflow: hidden;
  flex-shrink: 0; border: 1px solid var(--border);
}
.blog-article-author-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-article-author-text { flex: 1; min-width: 0; }
.blog-article-author-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem; color: var(--gold);
  margin: 0 0 6px; font-weight: 600;
}
.blog-article-author-name a { color: inherit; text-decoration: none; }
.blog-article-author-name a:hover { text-decoration: underline; }
.blog-article-author-bio {
  color: var(--text-secondary); font-size: 0.95rem;
  line-height: 1.55; margin: 0;
}

/* Back link */
.blog-back {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--text-secondary);
  text-decoration: none;
  margin-bottom: 24px;
  font-size: 0.92rem;
}
.blog-back:hover { color: var(--gold); }
