/* ============================================================
   BLOG / JOURNAL — NB Origins
   Experiment file — preview only, not production
   ============================================================ */

/* --- Editorial nav: 3-column grid (trail | logo | cta) --- */

.blog-nav {
  background: transparent;
}

.blog-nav-container {
  display: grid !important;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding-left: 40px !important;
  padding-right: 40px !important;
}

/* Left: breadcrumb trail */
.blog-nav-trail {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: rgba(255, 255, 255, 0.45);
  white-space: nowrap;
}

.blog-nav-trail a {
  color: inherit;
  text-decoration: none;
  transition: color 0.25s ease;
}

.blog-nav-trail a:hover {
  color: rgba(255, 255, 255, 0.85);
  opacity: 1;
}

.trail-sep {
  opacity: 0.28;
  font-weight: 300;
}

.trail-current {
  color: rgba(255, 255, 255, 0.65);
}

/* Center: logo */
.blog-nav .nav-logo {
  display: flex;
  justify-content: center;
}

.blog-nav .nav-logo img {
  height: 28px;
  filter: brightness(0) invert(1);
  transition: filter 0.3s ease;
}

/* Right: CTA */
.blog-nav-right {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.blog-nav .nav-cta {
  color: rgba(255, 255, 255, 0.75);
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
}

.blog-nav .nav-cta:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.32);
  color: #fff;
  opacity: 1;
}

/* Mobile toggle — hidden on blog nav (no dropdown menu) */
.blog-nav .mobile-toggle {
  display: none;
}

/* Scrolled state — light nav */
nav.scrolled .blog-nav-trail {
  color: var(--text-tertiary);
}

nav.scrolled .blog-nav-trail a:hover {
  color: var(--forest);
}

nav.scrolled .trail-current {
  color: var(--text-secondary);
}

nav.scrolled .blog-nav .nav-logo img,
nav.scrolled.blog-nav .nav-logo img {
  filter: none;
}

nav.scrolled .blog-nav-trail .trail-sep {
  opacity: 0.4;
}

/* When nav loses blog-nav-dark class (via JS), reset logo */
.blog-nav:not(.blog-nav-dark) .nav-logo img {
  filter: none;
}

.blog-nav.blog-nav-dark .nav-logo img {
  filter: brightness(0) invert(1);
}

/* Also update CTA when scrolled */
nav.scrolled.blog-nav .nav-cta,
nav.scrolled .blog-nav .nav-cta {
  color: var(--forest);
  border-color: var(--forest-muted);
  background: var(--forest-pale);
}

/* --- Hero --- */

.blog-hero {
  position: relative;
  min-height: 100vh;
  background-color: var(--forest-dark);
  background-position: center center;
  background-size: auto 100%;
  background-repeat: no-repeat;
  /* background-image is set via inline style on the element in HTML
     so the path resolves relative to the HTML file, not this CSS file */
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-bottom: 80px;
  overflow: hidden;
}

/* Subtle grid pattern */
.blog-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none;
}

/* Bottom-to-top dark gradient for text legibility */
.blog-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.88) 0%,
    rgba(0, 0, 0, 0.45) 35%,
    rgba(0, 0, 0, 0.1) 60%,
    transparent 100%
  );
  pointer-events: none;
}

.blog-hero-content {
  position: relative;
  z-index: 1;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 40px;
  width: 100%;
}

.blog-hero-eyebrow {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 1.75rem;
}

.blog-hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3.2rem, 9vw, 7.5rem);
  font-weight: 400;
  line-height: 0.96;
  letter-spacing: -0.04em;
  color: #fff;
  margin-bottom: 2rem;
}

.blog-hero-standfirst {
  font-family: 'Inter', sans-serif;
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.58);
  max-width: 500px;
  line-height: 1.75;
  margin-bottom: 2.5rem;
}

.blog-hero-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.32);
  letter-spacing: 0.05em;
}

.blog-hero-meta .meta-dot {
  opacity: 0.35;
}

.blog-hero-scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 1;
}

.blog-hero-scroll .scroll-cue-label {
  color: rgba(255, 255, 255, 0.28);
}

.blog-hero-scroll .scroll-chevron {
  border-right-color: rgba(255, 255, 255, 0.28);
  border-bottom-color: rgba(255, 255, 255, 0.28);
  animation: chevronPulse 2.4s ease-in-out infinite;
}

/* --- Breadcrumb (article body) --- */

.article-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  color: var(--text-tertiary);
  margin-bottom: 3.5rem;
  letter-spacing: 0.02em;
}

.article-breadcrumb a {
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.article-breadcrumb a:hover {
  color: var(--forest);
  opacity: 1;
}

.article-breadcrumb span {
  opacity: 0.4;
}

.breadcrumb-current {
  color: var(--text-secondary);
  opacity: 1 !important;
}

/* --- Article body --- */

.blog-article {
  background: var(--surface);
  padding: 80px 0 60px;
}

.article-column {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

.article-lead {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  font-style: italic;
  font-weight: 400;
  color: var(--text);
  line-height: 1.72;
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}

.blog-article p {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  line-height: 1.88;
  color: var(--text-secondary);
  font-weight: 300;
  margin-bottom: 1.5rem;
}

.blog-article p em {
  font-style: italic;
  color: var(--text);
}

/* --- Ingredient header: title left, illustration right --- */

.ingredient-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 2rem;
}

.ingredient-header-text {
  flex: 1;
  min-width: 0;
}

.ingredient-illustration {
  width: auto;
  height: auto;
  max-width: 280px;
  max-height: 160px;
  flex-shrink: 0;
  object-fit: contain;
  object-position: top center;
  opacity: 0.88;
}

@media (max-width: 600px) {
  .ingredient-header {
    flex-direction: column;
    gap: 1rem;
  }
  .ingredient-illustration {
    width: 160px;
    height: 160px;
  }
}

/* --- Ingredient sections --- */

.ingredient-section {
  padding: 64px 0 24px;
  border-top: 1px solid var(--border);
  margin-top: 48px;
}

.ingredient-number {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--forest);
  margin-bottom: 1.25rem;
}

.ingredient-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.0;
  color: var(--text);
  margin-bottom: 0;
}

.ingredient-title-sub {
  display: block;
  color: var(--text-tertiary);
  font-style: italic;
}

/* Metadata strip */
.ingredient-meta-grid {
  display: flex;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 2.5rem;
  background: var(--bg-alt);
}

.meta-item {
  flex: 1;
  padding: 14px 16px;
  border-right: 1px solid var(--border);
}

.meta-item:last-child {
  border-right: none;
}

.meta-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.56rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 5px;
}

.meta-value {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text);
  line-height: 1.35;
}

/* Pull quotes */
.pull-quote {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-style: italic;
  font-weight: 400;
  color: var(--forest-dark);
  line-height: 1.65;
  padding: 1.75rem 0 1.75rem 2rem;
  border-left: 2px solid var(--forest);
  margin: 2.75rem 0;
  quotes: none;
}

/* --- Closing --- */

.article-closing {
  padding: 48px 0 0;
  border-top: 1px solid var(--border);
  margin-top: 48px;
}

/* --- CTA section --- */

.blog-cta-section {
  background: var(--bg-alt);
  padding: 80px 0;
}

.blog-cta-section .cta-note {
  margin-top: 2rem;
}

/* --- Responsive --- */

@media (max-width: 900px) {
  .blog-nav-container {
    padding-left: 24px !important;
    padding-right: 24px !important;
  }

  .blog-nav-right {
    display: none;
  }

  .blog-nav-container {
    grid-template-columns: 1fr auto !important;
  }

  .blog-nav-trail {
    font-size: 0.65rem;
    gap: 0.35rem;
  }
}

@media (max-width: 600px) {
  .ingredient-meta-grid {
    flex-direction: column;
  }

  .meta-item {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .meta-item:last-child {
    border-bottom: none;
  }

  .blog-hero-scroll {
    display: none;
  }

  .blog-hero {
    padding-bottom: 60px;
  }

  .blog-hero-content {
    padding: 0 24px;
  }
}
