/* =====================================================
   PITANGA JOURNAL — editorial landing + article pages
   Extends the shared Pitanga Foods design system.
   ===================================================== */

.journal-skip {
  position: fixed;
  left: 18px;
  top: -90px;
  z-index: 400;
  padding: 12px 18px;
  border-radius: 0 0 12px 12px;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
}
.journal-skip:focus { top: 0; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Landing hero */
.journal-hero {
  overflow: hidden;
  background:
    radial-gradient(circle at 88% 8%, rgba(255,255,255,.62), transparent 27rem),
    linear-gradient(135deg, #FFE4A0 0%, #F7BE27 58%, #F2A100 100%);
}
.journal-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
  align-items: center;
  gap: clamp(28px, 5vw, 74px);
  min-height: 540px;
  padding-block: clamp(54px, 7vw, 88px);
}
.journal-hero-copy { position: relative; z-index: 2; }
.journal-hero-copy .eyebrow { color: var(--green-deep); }
.journal-hero h1 {
  max-width: 10ch;
  margin-top: 17px;
  font-size: clamp(3rem, 6vw, 6.3rem);
  line-height: .96;
  letter-spacing: -.045em;
}
.journal-hero-copy > p {
  max-width: 54ch;
  margin-top: 22px;
  color: #4d3d1a;
  font-size: clamp(1rem, 1.35vw, 1.18rem);
}
.journal-search {
  display: flex;
  align-items: center;
  width: min(100%, 620px);
  min-height: 60px;
  margin-top: 30px;
  padding: 6px 8px 6px 21px;
  border: 1px solid rgba(23,23,23,.13);
  border-radius: 100px;
  background: rgba(255,255,255,.94);
  box-shadow: 0 15px 38px rgba(74,49,0,.12);
}
.journal-search i { flex: 0 0 auto; color: var(--green-deep); }
.journal-search input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  padding: 12px 14px;
  background: transparent;
  color: var(--ink);
  font: 500 1rem/1.4 var(--sans);
}
.journal-search input::placeholder { color: #7b725f; opacity: 1; }
.journal-search button {
  min-width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  transition: background .25s, transform .3s var(--ease);
}
.journal-search button:hover { background: var(--green-deep); transform: scale(1.04); }
.journal-search:focus-within { outline: 3px solid rgba(31,100,39,.3); outline-offset: 3px; }
.journal-hero-art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
  padding: clamp(22px, 3vw, 42px);
}
.journal-hero-art::before {
  content: "";
  position: absolute;
  inset: 1% 4% 5%;
  border-radius: 52% 48% 42% 58% / 46% 44% 56% 54%;
  background: rgba(255,248,232,.46);
  border: 1px solid rgba(255,255,255,.65);
}
.journal-hero-art img {
  position: relative;
  z-index: 1;
  left: auto;
  top: auto;
  bottom: auto;
  width: 100%;
  max-width: 560px;
  height: auto;
  transform: none;
  filter: drop-shadow(0 24px 24px rgba(76,48,0,.16));
}
.journal-hero-note {
  position: absolute;
  z-index: 2;
  right: 3%;
  top: 7%;
  width: 124px;
  height: 124px;
  display: grid;
  place-items: center;
  padding: 18px;
  border-radius: 50%;
  background: var(--green-deep);
  color: #fff;
  text-align: center;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
  line-height: 1.45;
  text-transform: uppercase;
  transform: rotate(7deg);
}

/* Featured story */
.journal-featured { background: #fff; }
.journal-section-head { margin-bottom: clamp(28px, 4vw, 46px); }
.journal-section-head .eyebrow { margin-bottom: 14px; }
.journal-section-head h2 { font-size: clamp(2.25rem, 4.5vw, 4.8rem); line-height: 1; letter-spacing: -.035em; }
.featured-story {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(380px, .82fr);
  min-height: 570px;
  overflow: hidden;
  border: 1px solid rgba(23,23,23,.08);
  border-radius: clamp(26px, 3.5vw, 48px);
  background: var(--cream);
}
.featured-story-media { position: relative; min-height: 480px; overflow: hidden; }
.featured-story-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .75s var(--ease); }
.featured-story:hover .featured-story-media img { transform: scale(1.025); }
.featured-story-copy { display: flex; min-width: 0; flex-direction: column; justify-content: center; padding: clamp(34px, 5vw, 68px); }
.journal-category { color: var(--green-deep); font-size: .72rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.featured-story-copy h2 { margin: 16px 0 18px; font-size: clamp(2rem, 3.5vw, 3.85rem); line-height: 1.04; }
.featured-story-copy p { color: var(--muted); font-size: 1rem; }
.journal-meta { display: flex; align-items: center; gap: 10px; margin-top: 24px; color: #666157; font-size: .82rem; font-weight: 600; }
.journal-meta i { color: var(--green); font-size: .34rem; }
.featured-story-copy .link-arrow { width: fit-content; margin-top: 26px; color: var(--green-deep); }

/* Categories */
.journal-categories { background: #F4F2E8; }
.journal-category-layout { display: grid; grid-template-columns: minmax(260px, .62fr) minmax(0, 1.38fr); gap: clamp(34px, 6vw, 90px); align-items: end; }
.journal-category-copy h2 { max-width: 10ch; margin-top: 14px; font-size: clamp(2.35rem, 4.7vw, 5rem); line-height: 1; }
.journal-category-copy p { max-width: 36ch; margin-top: 18px; color: var(--muted); }
.journal-filters { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.journal-filter {
  min-height: 48px;
  padding: 11px 18px;
  border: 1px solid #d2cec1;
  border-radius: 100px;
  background: rgba(255,255,255,.78);
  color: var(--ink);
  font-size: .86rem;
  font-weight: 700;
  transition: background .25s, color .25s, border-color .25s, transform .3s var(--ease);
}
.journal-filter:hover { border-color: var(--green); transform: translateY(-2px); }
.journal-filter.is-active { border-color: var(--green-deep); background: var(--green-deep); color: #fff; }
.journal-filter:focus-visible { outline: 3px solid rgba(44,133,53,.28); outline-offset: 3px; }

/* Latest articles */
.journal-latest { background: var(--cream); }
.journal-latest-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(30px, 4vw, 48px); }
.journal-latest-head h2 { margin-top: 14px; font-size: clamp(2.35rem, 4.4vw, 4.7rem); line-height: 1; }
.journal-results { color: var(--muted); font-size: .88rem; font-weight: 600; }
.journal-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 3vw, 44px) clamp(18px, 2.2vw, 30px); }
.journal-card { min-width: 0; }
.journal-card[hidden] { display: none; }
.journal-card-media {
  display: block;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 24px;
  background: #eee7d8;
}
.journal-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .65s var(--ease); }
.journal-card-media.is-pack { background: #fff4d8; }
.journal-card-media.is-pack img { padding: 24px; object-fit: contain; mix-blend-mode: multiply; }
.journal-card:hover .journal-card-media img { transform: scale(1.045); }
.journal-card-body { padding: 22px 4px 0; }
.journal-card-kicker { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: var(--green-deep); font-size: .69rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.journal-card-kicker span:last-child { color: #7c766c; letter-spacing: 0; text-transform: none; white-space: nowrap; }
.journal-card h3 { margin-top: 13px; font-size: clamp(1.35rem, 2vw, 1.85rem); line-height: 1.18; }
.journal-card h3 a { transition: color .2s; }
.journal-card h3 a:hover { color: var(--green-deep); }
.journal-card p { margin-top: 12px; color: var(--muted); font-size: .93rem; }
.journal-card .link-arrow { margin-top: 18px; color: var(--green-deep); font-size: .87rem; }
.journal-load-wrap { display: flex; justify-content: center; margin-top: 46px; }
.journal-load-wrap[hidden], .journal-empty[hidden] { display: none; }
.journal-empty { padding: 54px 24px; border: 1px dashed #cbc4b2; border-radius: 24px; color: var(--muted); text-align: center; }

/* Recipe spotlight */
.journal-recipe { overflow: hidden; background: #F6DCC8; }
.recipe-spotlight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .88fr);
  min-height: 590px;
  overflow: hidden;
  border-radius: clamp(28px, 4vw, 52px);
  background: #FFF2E5;
  box-shadow: 0 24px 60px rgba(80,42,20,.09);
}
.recipe-spotlight-media { position: relative; min-height: 480px; overflow: hidden; }
.recipe-spotlight-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .75s var(--ease); }
.recipe-spotlight:hover .recipe-spotlight-media img { transform: scale(1.025); }
.recipe-spotlight-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(36px, 5vw, 72px); }
.recipe-spotlight-copy h2 { max-width: 12ch; margin: 15px 0 18px; font-size: clamp(2.3rem, 4.5vw, 4.9rem); line-height: 1; }
.recipe-spotlight-copy h3 { margin-bottom: 10px; font-size: clamp(1.45rem, 2vw, 2rem); line-height: 1.2; }
.recipe-spotlight-copy > p { max-width: 42ch; color: #6d5749; }
.recipe-facts { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 30px; }
.recipe-facts span { display: inline-flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid rgba(130,63,29,.14); border-radius: 100px; background: rgba(255,255,255,.66); color: #673b25; font-size: .78rem; font-weight: 700; }

/* Final CTA */
.journal-cta { overflow: hidden; background: #fff; }
.journal-cta-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, .78fr) minmax(0, 1.22fr);
  align-items: center;
  min-height: 450px;
  overflow: hidden;
  border-radius: clamp(28px, 4vw, 52px);
  background: linear-gradient(135deg, #DDEBD1, #F9F2D9 62%, #FFD76A);
}
.journal-cta-copy { position: relative; z-index: 2; padding: clamp(38px, 5vw, 70px); }
.journal-cta-copy h2 { margin: 15px 0 18px; font-size: clamp(2.3rem, 4.5vw, 4.8rem); line-height: 1; }
.journal-cta-copy p { max-width: 40ch; color: #4c5548; }
.journal-cta-actions { display: flex; flex-wrap: wrap; gap: 11px; margin-top: 28px; }
.journal-cta-art { align-self: end; padding: 28px 24px 0 0; }
.journal-cta-art img { width: 100%; filter: drop-shadow(0 22px 20px rgba(53,44,22,.18)); }

/* Article pages */
.article-page { background: #fffdf8; }
.article-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; padding-top: 28px; color: #6e695f; font-size: .82rem; }
.article-breadcrumb a:hover { color: var(--green-deep); text-decoration: underline; }
.article-header { max-width: 980px; padding-top: clamp(52px, 8vw, 96px); padding-bottom: 44px; }
.article-header h1 { margin-top: 17px; font-size: clamp(2.65rem, 6vw, 6.5rem); line-height: .99; letter-spacing: -.045em; }
.article-deck { max-width: 720px; margin-top: 24px; color: #5e5b54; font-size: clamp(1.05rem, 1.5vw, 1.25rem); }
.article-byline { display: flex; flex-wrap: wrap; gap: 9px 16px; margin-top: 24px; color: #777168; font-size: .86rem; }
.article-byline strong { color: var(--green-deep); }
.article-hero-image { width: 100%; max-height: 760px; aspect-ratio: 16 / 8.5; object-fit: cover; border-radius: clamp(24px, 3vw, 42px); background: #f2ead8; }
.article-hero-image.is-pack { padding: clamp(24px, 5vw, 70px); object-fit: contain; mix-blend-mode: multiply; }
.article-layout { display: grid; grid-template-columns: minmax(0, 780px) minmax(240px, 320px); justify-content: center; align-items: start; gap: clamp(44px, 7vw, 92px); padding-block: clamp(52px, 8vw, 100px); }
.article-content { min-width: 0; color: #3f403c; font-size: 1.05rem; line-height: 1.82; }
.article-content > p:first-child { color: var(--ink); font-size: 1.2rem; line-height: 1.72; }
.article-content h2 { margin: 54px 0 18px; color: var(--ink); font-size: clamp(1.8rem, 3vw, 2.8rem); line-height: 1.15; }
.article-content p + p { margin-top: 18px; }
.article-content ul, .article-content ol { margin: 20px 0 0; padding-left: 1.3em; }
.article-content li { padding-left: .35em; }
.article-content li + li { margin-top: 10px; }
.article-recipe-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 30px 0 12px; }
.article-recipe-facts div { padding: 16px; border-radius: 16px; background: #FFF0DB; }
.article-recipe-facts span { display: block; color: #836a56; font-size: .7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.article-recipe-facts strong { display: block; margin-top: 5px; color: var(--ink); font-size: .94rem; }
.article-product { position: sticky; top: 124px; overflow: hidden; border: 1px solid #e1dccf; border-radius: 26px; background: var(--cream); }
.article-product-image { display: grid; place-items: center; aspect-ratio: 1; padding: 28px; background: #fff4d8; }
.article-product-image img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.article-product-copy { padding: 22px; }
.article-product-copy span { color: var(--green-deep); font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.article-product-copy h2 { margin-top: 8px; font-size: 1.3rem; line-height: 1.2; }
.article-product-copy .link-arrow { margin-top: 18px; color: var(--green-deep); font-size: .84rem; }
.article-no-product { position: sticky; top: 124px; padding: 25px; border-left: 3px solid var(--sunshine); background: var(--cream); color: #625e55; }
.article-no-product strong { display: block; margin-bottom: 6px; color: var(--ink); }
.related-reading { background: #F4F2E8; }
.related-reading .journal-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.article-end-cta { padding: 64px 0; background: var(--ink); color: #fff; }
.article-end-cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.article-end-cta h2 { max-width: 15ch; font-size: clamp(2rem, 4vw, 4rem); line-height: 1; }
.article-end-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.journal-card a:focus-visible,
.featured-story a:focus-visible,
.recipe-spotlight a:focus-visible,
.journal-cta a:focus-visible,
.article-page a:focus-visible {
  outline: 3px solid var(--green);
  outline-offset: 4px;
}

@media (max-width: 1080px) {
  .journal-hero-grid { grid-template-columns: minmax(0, 1.12fr) minmax(300px, .88fr); min-height: 500px; }
  .featured-story { grid-template-columns: 1fr 1fr; }
  .journal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout { grid-template-columns: minmax(0, 720px) minmax(220px, 280px); gap: 42px; }
}

@media (max-width: 900px) {
  .journal-hero-grid { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .journal-hero h1 { max-width: 12ch; }
  .journal-hero-art { min-height: 0; padding: 24px 0 0; }
  .journal-hero-art img { left: auto; width: min(78vw, 620px); max-width: 100%; }
  .featured-story, .recipe-spotlight { grid-template-columns: minmax(0, 1fr); }
  .featured-story-media, .recipe-spotlight-media { min-height: 440px; }
  .journal-category-layout { grid-template-columns: minmax(0, 1fr); align-items: start; }
  .journal-category-copy h2 { max-width: 14ch; }
  .journal-filters { justify-content: flex-start; }
  .journal-cta-panel { grid-template-columns: minmax(0, 1fr); }
  .journal-cta-art { padding: 0 24px; }
  .article-layout { grid-template-columns: minmax(0, 760px); }
  .article-product, .article-no-product { position: static; max-width: 520px; }
  .related-reading .journal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .journal-hero-grid { padding-block: 42px 30px; }
  .journal-hero h1 { font-size: clamp(2.65rem, 13vw, 4rem); }
  .journal-search { min-height: 56px; padding-left: 16px; }
  .journal-search input { font-size: .9rem; }
  .journal-hero-art { min-height: 0; padding-top: 18px; }
  .journal-hero-art img { width: min(100%, 390px); }
  .journal-hero-note { width: 90px; height: 90px; padding: 12px; font-size: .58rem; }
  .featured-story { min-height: 0; border-radius: 24px; }
  .featured-story-media, .recipe-spotlight-media { min-height: 290px; }
  .featured-story-copy, .recipe-spotlight-copy { padding: 28px 22px 32px; }
  .journal-filters {
    width: calc(100% + 20px);
    margin-right: -20px;
    padding: 3px 20px 8px 0;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .journal-filters::-webkit-scrollbar { display: none; }
  .journal-filter { flex: 0 0 auto; }
  .journal-latest-head { align-items: flex-start; flex-direction: column; }
  .journal-grid, .related-reading .journal-grid { grid-template-columns: minmax(0, 1fr); }
  .journal-card-media { border-radius: 20px; }
  .recipe-spotlight { min-height: 0; border-radius: 24px; }
  .journal-cta-panel { min-height: 0; border-radius: 24px; }
  .journal-cta-copy { padding: 34px 24px; }
  .journal-cta-actions, .article-end-actions { display: grid; grid-template-columns: 1fr; }
  .journal-cta-actions .btn, .article-end-actions .btn { justify-content: center; width: 100%; }
  .article-header { padding-top: 48px; }
  .article-header h1 { font-size: clamp(2.45rem, 12.5vw, 4rem); }
  .article-hero-image { aspect-ratio: 4 / 3; border-radius: 22px; }
  .article-content { font-size: 1rem; }
  .article-content > p:first-child { font-size: 1.08rem; }
  .article-recipe-facts { grid-template-columns: minmax(0, 1fr); }
  .article-end-cta-inner { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  .journal-search button,
  .journal-filter,
  .journal-card-media img,
  .featured-story-media img,
  .recipe-spotlight-media img { transition: none; }
  .journal-search button:hover,
  .journal-filter:hover,
  .journal-card:hover .journal-card-media img,
  .featured-story:hover .featured-story-media img,
  .recipe-spotlight:hover .recipe-spotlight-media img { transform: none; }
}
