/* Shared blog styling for both languages.
   Extend this file for new article sections; do not add per-article stylesheets.
   Article rules are scoped to .blog-detail. Cards are reused on home and index pages. */
:root {
  --article-ink: #1a1a1d;
  --article-cream: #fff2e0;
  --article-paper: #fff2e0;
  --article-teal: #34656d;
  --article-teal-soft: #e7f3ef;
  --article-coral: #ffb3a7;
  --article-line: rgba(26, 26, 29, 0.15);
  --blog-coral: #ff6575;
}

html.lenis,
html.lenis body {
  height: auto;
}

html.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

html.lenis.lenis-stopped {
  overflow: hidden;
}

.lenis.lenis-smooth iframe {
  pointer-events: none;
}

.blog-detail {
  background: var(--article-paper);
  overflow-x: hidden;
}

:where(.blog-detail) .reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1200;
  width: 100%;
  height: 3px;
  background: var(--article-coral);
  transform: scaleX(0);
  transform-origin: left center;
  pointer-events: none;
}

.blog-detail main {
  margin-top: -50px;
}

.blog-detail main .hero,
.blog-detail main .img-container {
  height: min(820px, 78svh);
  min-height: 620px;
}

.blog-detail main .img-container::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(14, 25, 25, 0.84) 0%, rgba(14, 25, 25, 0.5) 50%, rgba(14, 25, 25, 0.1) 82%),
    linear-gradient(0deg, rgba(12, 20, 20, 0.58), transparent 55%);
  pointer-events: none;
}

.blog-detail main .scroll-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none;
  transform: scale(1.035);
}

.blog-detail .quick-navigation,
.blog-detail .hero-text {
  z-index: 2;
}

.blog-detail .quick-navigation {
  top: 12rem;
  left: clamp(1.5rem, 6vw, 7rem);
}

.blog-detail .quick-navigation a {
  font-size: 0.95rem;
}

.blog-detail .hero-text {
  left: clamp(1.5rem, 6vw, 7rem);
  right: clamp(1.5rem, 6vw, 7rem);
  bottom: clamp(2.5rem, 6vh, 5rem);
  max-width: none;
}

.blog-detail .hero-text .article-eyebrow {
  width: auto;
  margin: 0 0 1rem;
  color: var(--article-cream);
  font-size: 0.73rem;
  font-weight: 300;
  letter-spacing: 0;
  line-height: 1.2;
  text-transform: uppercase;
}

.blog-detail .hero-text h1 {
  width: min(1120px, 100%);
  margin: 0;
  color: var(--article-cream);
  font-size: clamp(2.5rem, 3.6vw, 3.5rem);
  line-height: 1.04;
  letter-spacing: 0;
  text-wrap: balance;
}

.blog-detail .hero-text > p:not(.article-eyebrow) {
  width: min(900px, 100%);
  margin: 1.25rem 0 0;
  color: rgba(255, 242, 224, 0.84);
  font-size: clamp(1.04rem, 1.3vw, 1.24rem);
  font-weight: 200;
  line-height: 1.55;
}

:where(.blog-detail) .article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.85rem;
  align-items: center;
  margin-top: 1.6rem;
  color: rgba(255, 242, 224, 0.8);
  font-size: 0.72rem;
  font-weight: 300;
  letter-spacing: 0;
  line-height: 1.4;
  text-transform: uppercase;
}

:where(.blog-detail) .article-meta > :not(:last-child)::after {
  content: "";
  display: inline-block;
  width: 3px;
  height: 3px;
  margin-left: 0.85rem;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
  opacity: 0.7;
}

:where(.blog-detail) .article-meta > * {
  flex: 0 1 auto;
}

:where(.blog-detail) .blog-article {
  width: 100%;
  max-width: 1760px;
  margin: 0 auto;
  padding: clamp(2.5rem, 4vw, 4rem) clamp(1rem, 2vw, 2rem) clamp(3rem, 4vw, 4rem);
}

:where(.blog-detail) .article-layout {
  display: grid;
  grid-template-columns: minmax(210px, 240px) minmax(0, 1120px);
  gap: clamp(1.5rem, 2.5vw, 2.5rem);
  justify-content: center;
  align-items: start;
}

:where(.blog-detail) .article-content {
  min-width: 0;
}

:where(.blog-detail) .article-toc {
  position: sticky;
  top: 7rem;
  padding-top: 0.2rem;
  max-height: calc(100svh - 8rem);
  overflow-y: auto;
}

:where(.blog-detail) .article-toc__label {
  display: block;
  margin-bottom: 1.2rem;
  color: var(--article-teal);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0;
  list-style: none;
  text-transform: uppercase;
  cursor: pointer;
}

:where(.blog-detail) .article-toc__label::-webkit-details-marker {
  display: none;
}

:where(.blog-detail) .article-toc__label::after {
  content: "";
  float: right;
  width: 0.9rem;
  height: 0.9rem;
  background-color: var(--article-teal);
  -webkit-mask: url("/assets/icons/arrow-down.svg") center / contain no-repeat;
  mask: url("/assets/icons/arrow-down.svg") center / contain no-repeat;
}

:where(.blog-detail) .article-toc[open] .article-toc__label::after {
  transform: rotate(180deg);
}

:where(.blog-detail) .article-toc:not([open]) .article-toc__label {
  margin-bottom: 0;
}

:where(.blog-detail) .article-toc ol {
  margin: 0;
  padding: 0;
  border-left: 1px solid var(--article-line);
  list-style: none;
}

:where(.blog-detail) .article-toc li {
  margin: 0;
  padding: 0;
}

:where(.blog-detail) .article-toc a {
  display: block;
  margin-left: -1px;
  padding: 0.5rem 0.6rem 0.5rem 0.85rem;
  border-left: 3px solid transparent;
  color: var(--article-ink);
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.35;
  text-decoration: none;
  transition: color 180ms ease, border-color 180ms ease, background-color 180ms ease;
}

:where(.blog-detail) .article-toc a:hover,
:where(.blog-detail) .article-toc a:focus-visible,
:where(.blog-detail) .article-toc a.is-active {
  border-left-color: var(--article-teal);
  background-color: var(--article-teal-soft);
  color: #244f54;
}

:where(.blog-detail) .article-toc a.is-active {
  font-weight: 600;
}

:where(.blog-detail) .blog-article .article-toc a:focus-visible,
:where(.blog-detail) .article-toc__label:focus-visible {
  outline: 2px solid var(--article-teal);
  outline-offset: 2px;
}

:where(.blog-detail) .blog-article .article-block {
  max-width: none;
  margin: 0 0 clamp(2.5rem, 4vw, 4rem);
}

:where(.blog-detail) .blog-article .article-block:last-child {
  margin-bottom: 0;
}

:where(.blog-detail) .blog-article .article-content > .article-block:first-child {
  margin-bottom: clamp(3rem, 4vw, 4rem);
  padding: 0 0 2rem clamp(1.25rem, 2.5vw, 2.2rem);
  border-bottom: 1px solid var(--article-line);
  border-left: 3px solid var(--article-teal);
}

:where(.blog-detail) .blog-article .article-content > .article-block:first-child > p:first-child {
  margin-top: 0;
  font-family: "PPNeueCorp", sans-serif;
  font-weight: 500;
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  line-height: 1.35;
}

:where(.blog-detail) .blog-article h2 {
  scroll-margin-top: 7rem;
  margin: 0 0 1.25rem;
  color: var(--article-ink);
  font-size: clamp(1.65rem, 2vw, 2.15rem);
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.08;
  text-wrap: balance;
}

:where(.blog-detail) .blog-article h3 {
  scroll-margin-top: 7rem;
  margin: 2.5rem 0 0.8rem;
  color: var(--article-ink);
  font-size: clamp(1.2rem, 1.35vw, 1.45rem);
  font-weight: 500;
  line-height: 1.15;
}

:where(.blog-detail) .article-content p,
:where(.blog-detail) .article-content li {
  color: var(--article-ink);
  font-size: clamp(1.06rem, 1.25vw, 1.16rem);
  font-weight: 200;
  line-height: 1.78;
}

:where(.blog-detail) .article-content p {
  margin: 1rem 0 0;
}

:where(.blog-detail) .article-content strong {
  color: var(--article-ink);
  font-weight: 400;
}

:where(.blog-detail) .article-content ul,
:where(.blog-detail) .article-content ol {
  margin: 1.25rem 0 0;
  padding-left: 1.4rem;
}

:where(.blog-detail) .article-content li {
  padding-left: 0.35rem;
}

:where(.blog-detail) .article-content li + li {
  margin-top: 0.6rem;
}

:where(.blog-detail) .article-content li::marker {
  color: var(--article-coral);
  font-weight: 400;
}

:where(.blog-detail) .article-content a {
  color: var(--article-teal);
  font-size: inherit;
  font-weight: 300;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

:where(.blog-detail) .article-content a:hover {
  color: var(--article-ink);
}

:where(.blog-detail) .blog-article a:focus-visible,
:where(.blog-detail) .article-toc a:focus-visible,
:where(.blog-detail) .quick-navigation a:focus-visible {
  outline: 2px solid var(--article-coral);
  outline-offset: 4px;
}

:where(.blog-detail) .blog-article .images-layout,
:where(.blog-detail) .blog-article .split-layout {
  gap: clamp(1.25rem, 3vw, 2.5rem);
}

:where(.blog-detail) .blog-article .images-layout img,
:where(.blog-detail) .blog-article .split-img img,
:where(.blog-detail) .blog-article .article-img-wrapper img {
  box-shadow: none;
}

:where(.blog-detail) .blog-article .hero-btn-layout {
  margin-top: 2rem;
}

:where(.blog-detail) .blog-article .hero-btn {
  border-radius: 999px;
  box-shadow: none;
}

:where(.blog-detail) .article-note,
:where(.blog-detail) .article-rule,
:where(.blog-detail) .medical-note {
  margin-top: 1.75rem;
  padding: clamp(1.35rem, 3vw, 2rem);
  border: 1px solid rgba(52, 101, 109, 0.24);
  background: rgba(231, 243, 239, 0.52);
}

:where(.blog-detail) .article-note__label {
  display: block;
  margin-bottom: 0.55rem;
  color: var(--article-teal);
  font-size: 0.68rem;
  font-weight: 300;
  letter-spacing: 0;
  text-transform: uppercase;
}

:where(.blog-detail) .article-note p,
:where(.blog-detail) .article-rule p,
:where(.blog-detail) .medical-note p {
  margin: 0;
}

:where(.blog-detail) .article-rule {
  border-color: rgba(255, 179, 167, 0.64);
  background: rgba(255, 179, 167, 0.16);
}

:where(.blog-detail) .step-grid,
:where(.blog-detail) .decision-grid,
:where(.blog-detail) .routine-grid,
:where(.blog-detail) .dos-donts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}

:where(.blog-detail) .step-card,
:where(.blog-detail) .decision-card,
:where(.blog-detail) .routine-card,
:where(.blog-detail) .dos-donts > div {
  padding: clamp(1.25rem, 2.5vw, 1.8rem);
  border: 1px solid var(--article-line);
  background: rgba(255, 242, 224, 0.46);
}

:where(.blog-detail) .step-card {
  counter-increment: summer-step;
}

:where(.blog-detail) .step-grid {
  counter-reset: summer-step;
}

:where(.blog-detail) .step-card::before {
  content: "0" counter(summer-step);
  display: block;
  margin-bottom: 1rem;
  color: var(--article-coral);
  font-family: "PPNeueCorp", sans-serif;
  font-size: 1.6rem;
}

:where(.blog-detail) .step-card h3,
:where(.blog-detail) .decision-card h3,
:where(.blog-detail) .routine-card h3,
:where(.blog-detail) .dos-donts h3 {
  margin: 0;
  font-size: clamp(1.2rem, 1.35vw, 1.45rem);
  line-height: 1.15;
}

:where(.blog-detail) .step-card p,
:where(.blog-detail) .decision-card p,
:where(.blog-detail) .routine-card p {
  font-size: 1rem;
  line-height: 1.65;
}

:where(.blog-detail) .decision-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

:where(.blog-detail) .decision-card__label {
  display: block;
  margin-bottom: 0.8rem;
  color: var(--article-coral);
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

:where(.blog-detail) .article-faq > h2 {
  margin-bottom: 0.8rem;
}

:where(.blog-detail) .article-faq__intro {
  max-width: 760px;
  margin: 0 !important;
  color: rgba(26, 26, 29, 0.7) !important;
}

:where(.blog-detail) .faq-list {
  margin-top: clamp(2rem, 4vw, 3rem);
  border-top: 1px solid rgba(26, 26, 29, 0.48);
}

:where(.blog-detail) .faq-list details {
  border-bottom: 1px solid rgba(26, 26, 29, 0.48);
}

:where(.blog-detail) .faq-list summary {
  position: relative;
  padding: clamp(1.8rem, 3vw, 2.7rem) 4rem clamp(1.8rem, 3vw, 2.7rem) 0;
  color: var(--article-ink);
  font-family: "Roboto", sans-serif;
  font-size: clamp(1.1rem, 1.25vw, 1.3rem);
  font-weight: 200;
  line-height: 1.35;
  list-style: none;
  cursor: pointer;
  transition: color 220ms ease;
}

:where(.blog-detail) .faq-list summary:hover {
  color: var(--article-teal);
}

:where(.blog-detail) .faq-list summary::-webkit-details-marker {
  display: none;
}

:where(.blog-detail) .faq-list summary::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0.65rem;
  width: 20px;
  height: 20px;
  background: url("/assets/icons/dark-plus.svg") center / contain no-repeat;
  transform: translateY(-50%);
  transform-origin: center;
  transition: transform 350ms ease;
}

:where(.blog-detail) .faq-list details[open] summary::after {
  transform: translateY(-50%) rotate(405deg);
}

:where(.blog-detail) .faq-list details > div {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition:
    grid-template-rows 400ms cubic-bezier(0.215, 0.61, 0.355, 1),
    opacity 300ms ease;
}

:where(.blog-detail) .faq-list details[open] > div {
  grid-template-rows: 1fr;
  opacity: 1;
}

:where(.blog-detail) .faq-list details > div > p {
  min-height: 0;
  margin: 0;
  padding: 0 4rem clamp(1.8rem, 3vw, 2.7rem) 0;
  overflow: hidden;
}

:where(.blog-detail) .faq-list summary:focus-visible {
  outline: 2px solid var(--article-coral);
  outline-offset: 5px;
}

:where(.blog-detail) .article-cta {
  margin-top: clamp(4rem, 8vw, 7rem);
  padding: clamp(2rem, 5vw, 4.5rem);
  background: var(--article-teal);
  color: var(--article-cream);
}

:where(.blog-detail) .article-cta .article-note__label,
:where(.blog-detail) .article-cta h2,
:where(.blog-detail) .article-cta p {
  color: var(--article-cream);
}

:where(.blog-detail) .article-cta h2 {
  max-width: 640px;
}

:where(.blog-detail) .article-cta p {
  max-width: 650px;
  color: rgba(255, 242, 224, 0.82);
}

:where(.blog-detail) .article-cta__link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 1.6rem;
  padding: 0.9rem 1.4rem;
  border-radius: 999px;
  background: var(--article-cream);
  color: var(--article-teal) !important;
  text-decoration: none;
}

:where(.blog-detail) .source-list {
  columns: 2;
  column-gap: 2.5rem;
  padding-left: 1.2rem;
}

:where(.blog-detail) .source-list li {
  break-inside: avoid;
  font-size: 0.87rem;
  line-height: 1.5;
}

:where(.blog-detail) .medical-note {
  margin-top: 2rem;
  border-color: var(--article-line);
  background: transparent;
}

:where(.blog-detail) .medical-note p {
  font-size: 0.9rem;
}

@media (min-width: 981px) and (max-height: 820px) {
  :where(.blog-detail) .article-toc {
    position: static;
  }
}

@media (max-width: 980px) {
  :where(.blog-detail) .article-layout {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
  }

  :where(.blog-detail) .article-content,
  :where(.blog-detail) .article-toc {
    min-width: 0;
    max-width: 100%;
  }

  :where(.blog-detail) .article-toc {
    position: static;
    max-height: none;
    margin-bottom: 1rem;
    padding: 1.25rem;
    border: 1px solid var(--article-line);
    overflow: visible;
  }

  :where(.blog-detail) .article-toc ol {
    columns: 2;
    column-gap: 2rem;
    border-left: 0;
  }

  :where(.blog-detail) .article-toc li {
    break-inside: avoid;
  }

  :where(.blog-detail) .article-toc a {
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
  }
}

@media (max-width: 767px) {
  .blog-detail main .hero,
  .blog-detail main .img-container {
    height: auto;
    min-height: 660px;
  }

  .blog-detail main .img-container::after {
    background:
      linear-gradient(90deg, rgba(14, 25, 25, 0.7), rgba(14, 25, 25, 0.18)),
      linear-gradient(0deg, rgba(12, 20, 20, 0.78), transparent 67%);
  }

  .blog-detail main .img-container {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 700px;
    padding: 10rem 1.5rem 2rem;
  }

  .blog-detail .quick-navigation {
    position: relative;
    inset: auto;
    margin-bottom: auto;
  }

  .blog-detail .hero-text {
    position: relative;
    inset: auto;
    width: 100%;
    max-width: none;
    margin-top: 3rem;
  }

  .blog-detail .hero-text h1 {
    width: 100%;
    max-width: 100%;
    font-size: clamp(2.15rem, 9vw, 2.5rem);
    hyphens: auto;
    overflow-wrap: anywhere;
  }

  .blog-detail .hero-text > p:not(.article-eyebrow) {
    width: 100%;
    margin-top: 1rem;
    font-size: 1rem;
    overflow-wrap: anywhere;
  }

  :where(.blog-detail) .article-meta {
    gap: 0.4rem 0.6rem;
    margin-top: 1.1rem;
    font-size: 0.72rem;
  }

  :where(.blog-detail) .article-meta > :not(:last-child)::after {
    margin-left: 0.6rem;
  }

  :where(.blog-detail) .blog-article {
    padding-top: 2.5rem;
  }

  :where(.blog-detail) .article-toc {
    margin-bottom: 1rem;
  }

  :where(.blog-detail) .article-toc ol {
    columns: 1;
  }

  :where(.blog-detail) .blog-article .article-content > .article-block:first-child {
    padding-left: 1.1rem;
  }

  :where(.blog-detail) .blog-article .article-content > .article-block:first-child > p:first-child {
    font-size: 1.3rem;
  }

  :where(.blog-detail) .blog-article h2 {
    font-size: clamp(1.55rem, 6vw, 1.875rem);
  }

  :where(.blog-detail) .step-grid,
  :where(.blog-detail) .decision-grid,
  :where(.blog-detail) .routine-grid,
  :where(.blog-detail) .dos-donts {
    grid-template-columns: 1fr;
  }

  :where(.blog-detail) .source-list {
    columns: 1;
  }

  :where(.blog-detail) .article-cta {
    margin-right: -1rem;
    margin-left: -1rem;
  }

  :where(.blog-detail) .faq-list summary {
    padding: 1.55rem 3rem 1.55rem 0;
    font-size: clamp(1.1rem, 4.5vw, 1.2rem);
  }

  :where(.blog-detail) .faq-list summary::after {
    right: 0.35rem;
    width: 18px;
    height: 18px;
  }

  :where(.blog-detail) .faq-list details > div > p {
    padding-right: 0;
    padding-bottom: 1.7rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  :where(.blog-detail) .article-toc a {
    transition: none;
  }
}

/* Reusable article sections: tables, inline images, sources and actions. */
:where(.blog-detail) .article-table-wrap {
  width: 100%;
  max-width: 100%;
  margin: 1.8rem 0;
  overflow-x: auto;
  border: 1px solid var(--article-line);
}

:where(.blog-detail) .article-table-wrap:focus-visible {
  outline: 2px solid var(--article-teal);
  outline-offset: 4px;
}

:where(.blog-detail) .article-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  text-align: left;
}

:where(.blog-detail) .article-table th,
:where(.blog-detail) .article-table td {
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--article-line);
  color: var(--article-ink);
  font-size: 1rem;
  font-weight: 200;
  line-height: 1.6;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
  hyphens: auto;
}

:where(.blog-detail) .article-table thead th {
  background: var(--article-teal);
  color: var(--article-cream);
  font-weight: 400;
}

:where(.blog-detail) .article-table tbody th {
  width: 30%;
  background: rgba(231, 243, 239, 0.52);
  font-weight: 400;
}

:where(.blog-detail) .article-table tr:last-child > * {
  border-bottom: 0;
}

:where(.blog-detail) .article-table--fixed {
  min-width: 0;
  table-layout: fixed;
}

:where(.blog-detail) .article-table--fixed th:first-child {
  width: 32%;
}

:where(.blog-detail) .article-table--comparison {
  min-width: 580px;
}

:where(.blog-detail) .article-table--comparison tbody th {
  width: 23%;
}

:where(.blog-detail) .article-table--grid th,
:where(.blog-detail) .article-table--grid td {
  border: 1px solid var(--article-line);
}

:where(.blog-detail) .article-table-wrap--plain {
  border: 0;
}

:where(.blog-detail) .article-treatment-image {
  max-width: 720px;
  margin: 2rem 0;
}

:where(.blog-detail) .article-treatment-image img {
  display: block;
  width: 100%;
  height: auto;
}

:where(.blog-detail) .article-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.6rem;
}

:where(.blog-detail) .article-actions .article-cta__link {
  margin: 0;
  max-width: 100%;
  justify-content: center;
  text-align: center;
}

:where(.blog-detail) .article-cta p a {
  color: var(--article-cream);
}

:where(.blog-detail) .article-citations {
  white-space: nowrap;
  font-size: 0.85em;
}

:where(.blog-detail) .source-list li {
  scroll-margin-top: 7rem;
  overflow-wrap: anywhere;
}

:where(.blog-detail) .source-list li:target {
  outline: 2px solid var(--article-teal);
  outline-offset: 5px;
}

:where(.blog-detail) .faq-list summary h3 {
  margin: 0;
  color: inherit;
  font: inherit;
}

@media (max-width: 767px) {
  :where(.blog-detail) .article-table--fixed th,
  :where(.blog-detail) .article-table--fixed td {
    padding: 0.8rem 0.65rem;
    font-size: 0.875rem;
  }

  :where(.blog-detail) .article-table--fixed th:first-child {
    width: 36%;
  }
}

/* Shared by the homepages, blog indexes and related-article sections. */
:root {
  /* Match the intro, FAQ and contact sections in index-cb18.css. */
  --blog-page-gutter: 8rem;
}

@media (max-width: 1024px) {
  :root {
    --blog-page-gutter: 1rem;
  }
}

@media (min-width: 1024px) and (max-width: 1520px) {
  :root {
    --blog-page-gutter: 5rem;
  }
}

.blog-section {
  width: 100%;
  margin: 0;
  padding: clamp(2rem, 3vw, 3rem) var(--blog-page-gutter);
}

.blog-layout {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 2rem 0 0;
  width: 100%;
  gap: clamp(1rem, 1.25vw, 1.25rem);
}

.blog-section.article-related > h2 {
  width: 100%;
}

.blog-card {
  --card-paper: #fff2e0;
  --card-ink: #1a1a1d;
  --card-muted: #59645e;
  --card-accent: #34656d;
  position: relative;
  isolation: isolate;
  width: 100%;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(52, 101, 109, 0.18);
  border-radius: 6px;
  background: var(--card-paper);
  box-shadow: 0 6px 24px rgba(55, 45, 32, 0.05);
  transition: border-color 220ms ease, box-shadow 220ms ease;
}

.blog-card__inner {
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: 100%;
}

.blog-card__media {
  position: relative;
  flex-shrink: 0;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #e7f3ef;
}

.blog-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(0.22, 1, 0.36, 1);
}

.blog-card__tags {
  position: absolute;
  top: 1rem;
  left: 1rem;
  right: 1rem;
  z-index: 2;
  pointer-events: none;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.5rem;
}

.blog-card__tag,
.blog-card__badge {
  max-width: 100%;
  padding: 0.5rem 0.85rem;
  border: 1px solid rgba(47, 87, 85, 0.12);
  border-radius: 999px;
  background: var(--card-paper);
  color: var(--card-accent);
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.04em;
  overflow-wrap: anywhere;
}

.blog-card__content {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  padding: 1rem;
}

.blog-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.65rem;
  margin-bottom: 0.75rem;
  color: var(--card-muted);
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.01em;
}

.blog-card__meta > * {
  min-width: 0;
  overflow-wrap: anywhere;
}

.blog-card__meta > :not(:last-child)::after {
  content: "";
  display: inline-block;
  width: 3px;
  height: 3px;
  margin-left: 0.65rem;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
  opacity: 0.5;
}

.blog-card h3 {
  width: 100%;
  max-width: none;
  margin: 0;
  color: var(--card-ink);
  font-family: "PPNeueCorp", sans-serif;
  font-size: clamp(1.5rem, 1.65vw, 1.85rem);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.14;
  text-wrap: wrap;
  overflow-wrap: break-word;
}

.blog-card p {
  width: 100%;
  margin: 0.7rem 0 1.1rem;
  color: var(--card-muted) !important;
  font-size: 0.95rem;
  font-weight: 300;
  line-height: 1.5;
}

.blog-card .blog-card__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 44px;
  max-width: 100%;
  margin-top: auto;
  padding: 0.8rem 1.4rem;
  border: none;
  border-radius: 4px;
  background: #34656d;
  color: #fff2e0;
  font-family: "Roboto", sans-serif !important;
  font-size: 1rem;
  font-weight: 200 !important;
  cursor: pointer;
  box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.25);
  text-decoration: none;
  transition:
    background-color 0.2s cubic-bezier(0.445, 0.05, 0.55, 0.95),
    color 0.2s ease;
}

/* Keep the whole card clickable with one accessible, focusable link. */
.blog-card__link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.blog-card__link img {
  flex: 0 0 auto;
  width: 10px;
  height: auto;
  transition: filter 0.25s ease;
}

.blog-card--featured {
  margin-bottom: 2.5rem;
  border-color: var(--card-accent);
  background: var(--card-accent);
}

.blog-card--featured .blog-card__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  min-height: 26rem;
}

.blog-card--featured .blog-card__media {
  min-height: 0;
  aspect-ratio: auto;
}

.blog-card--featured .blog-card__media img {
  /* Keep the image's intrinsic dimensions from enlarging the grid row. */
  position: absolute;
  inset: 0;
  object-position: center bottom;
}

.blog-card--featured .blog-card__content {
  justify-content: center;
}

.blog-card--featured .blog-card__meta {
  color: #e0e8e1;
}

.blog-card--featured h3 {
  max-width: 560px;
  color: var(--card-paper);
  font-size: clamp(1.5rem, 1.8vw, 2rem);
}

.blog-card--featured p {
  max-width: 560px;
  color: #e0e8e1 !important;
  font-size: 1rem;
}

.blog-card--featured .blog-card__link {
  margin-top: 0;
  background: #fff2e0;
  color: var(--card-accent);
}

.blog-card--featured .blog-card__link img {
  filter: brightness(0);
}

.blog-card:focus-within {
  outline: 3px solid var(--card-accent);
  outline-offset: 4px;
}

.blog-card .blog-card__link:focus-visible {
  outline: 2px solid var(--card-accent);
  outline-offset: 3px;
}

.blog-card--featured .blog-card__link:focus-visible {
  outline-color: var(--card-paper);
}

@media (hover: hover) {
  .blog-card:hover {
    border-color: #93a49a;
    box-shadow: 0 12px 32px rgba(55, 45, 32, 0.1);
  }

  .blog-card:hover .blog-card__media img {
    transform: scale(1.035);
  }

  .blog-card:hover .blog-card__link {
    background: #1a1a1d;
    color: #fff2e0;
  }

  .blog-card--featured:hover .blog-card__link {
    background: #ffffff;
    color: var(--card-accent);
  }
}

@media (max-width: 1024px) {
  .blog-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .blog-card .blog-card__link {
    gap: 2px;
    padding: 0.7rem 1.1rem;
  }

  .blog-card__link img {
    width: 9px;
  }
}

@media (max-width: 767px) {
  .blog-card--featured .blog-card__inner {
    display: flex;
    min-height: 0;
  }

  .blog-card--featured .blog-card__media {
    min-height: 0;
    aspect-ratio: 16 / 10;
  }

  .blog-card--featured h3 {
    font-size: 1.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .blog-card,
  .blog-card__media img,
  .blog-card .blog-card__link,
  .blog-card__link img {
    transition: none;
  }

  .blog-card:hover .blog-card__media img,
  .blog-card:hover .blog-card__link img {
    transform: none;
  }
}

/* Shared, server-rendered related articles on every DE/EN blog detail. */
.blog-section.article-related {
  border-top: 1px solid rgba(26, 26, 29, 0.15);
}

.article-related__heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin: 0 0 2rem;
}

.article-related__heading h2 {
  margin: 0;
  max-width: 32ch;
  font-family: "PPNeueCorp", sans-serif;
  font-weight: 500;
  color: var(--article-ink);
  font-size: clamp(1.8rem, 2.5vw, 2.3rem);
  line-height: 1.15;
  letter-spacing: 0;
}

.article-related__all {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: #34656d;
  font-size: 1rem;
  text-underline-offset: 0.2em;
}

.article-related .blog-layout {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.article-related .blog-card {
  grid-column: auto;
  margin: 0;
}

.article-related .blog-card h3 {
  font-size: 1.65rem;
  letter-spacing: 0;
}

.article-related a:focus-visible {
  outline: 2px solid #34656d;
  outline-offset: 4px;
}

@media (max-width: 1024px) {
  .blog-section.article-related {
    padding-inline: 1rem;
  }
}

@media (min-width: 768px) and (max-width: 1100px) {
  .article-related .blog-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .article-related .blog-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Blog overview layout. */

.blog-main {
  margin-top: -50px;
  overflow-x: clip;
  overflow-y: visible;
}

.blog-main .hero,
.blog-main .img-container {
  height: min(860px, 88svh);
  min-height: 650px;
}

.blog-main .img-container::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(13, 23, 23, 0.3) 0%, transparent 24%),
    linear-gradient(90deg, rgba(16, 28, 28, 0.82) 0%, rgba(19, 30, 30, 0.52) 43%, rgba(16, 25, 25, 0.14) 78%),
    linear-gradient(0deg, rgba(14, 22, 22, 0.5), transparent 50%);
  pointer-events: none;
}

.blog-main .scroll-img {
  filter: none;
  object-position: center 52%;
  transform: scale(1.04);
}

.blog-main .quick-navigation {
  top: 12rem;
  left: var(--blog-page-gutter);
}

.blog-main .quick-navigation a {
  font-size: 0.95rem;
}

.blog-main .quick-navigation,
.blog-main .hero-text {
  z-index: 2;
}

.blog-main .hero-text {
  left: var(--blog-page-gutter);
  right: var(--blog-page-gutter);
  bottom: clamp(3.25rem, 8vh, 6.5rem);
  max-width: 860px;
}

.blog-main .hero-text .hero-kicker {
  width: auto;
  margin: 0 0 1rem;
  color: var(--article-cream);
  font-size: 0.8rem;
  font-weight: 300;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.blog-main .hero-text h1 {
  width: min(760px, 82vw);
  margin: 0;
  font-size: clamp(2.5rem, 3.6vw, 4rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.blog-main .hero-text .hero-lead {
  width: min(600px, 70vw);
  margin: 1.15rem 0 0;
  font-size: clamp(0.98rem, 1.05vw, 1.1rem);
  line-height: 1.42;
}

.blog-main .hero-journal-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 1.4rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid rgba(255, 242, 224, 0.58);
  color: var(--article-cream);
  font-size: 0.88rem;
  font-weight: 300;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: gap 220ms ease, border-color 220ms ease;
}

.blog-main .hero-journal-link__icon {
  flex: 0 0 auto;
  transform: rotate(135deg);
}

.blog-main .hero-journal-link:hover {
  gap: 0.75rem;
  border-color: var(--blog-coral);
}

.blog-main .blog-layout {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  margin: 0 auto;
}

.blog-main .blog-card {
  grid-column: span 4;
}

.blog-main .blog-card--featured {
  grid-column: 1 / -1;
}

.blog-main .hero-journal-link:focus-visible,
.blog-main .quick-navigation a:focus-visible {
  outline: 2px solid var(--blog-coral);
  outline-offset: 4px;
}

.blog-index .newsletter-section {
  margin-top: clamp(2rem, 5vw, 5rem);
}

@media (max-width: 1100px) {
  .blog-main .blog-card {
    grid-column: span 6;
  }

  .blog-main .blog-card--featured {
    grid-column: 1 / -1;
  }
}

@media (max-width: 767px) {
  .blog-main .blog-card,
  .blog-main .blog-card--featured {
    grid-column: 1;
  }

  .blog-main .hero,
  .blog-main .img-container {
    height: min(720px, 78svh);
    min-height: 610px;
  }

  .blog-main .img-container::after {
    background:
      linear-gradient(90deg, rgba(16, 28, 28, 0.74), rgba(16, 28, 28, 0.22)),
      linear-gradient(0deg, rgba(14, 22, 22, 0.72), transparent 62%);
  }

  .blog-main .scroll-img {
    object-position: 56% center;
  }

  .blog-main .quick-navigation {
    top: 9.5rem;
  }

  .blog-main .hero-text {
    bottom: 2.2rem;
  }

  .blog-main .hero-text h1 {
    width: 100%;
    font-size: clamp(2.25rem, 10vw, 2.75rem);
    line-height: 0.98;
  }

  .blog-main .hero-text .hero-lead {
    width: 100%;
    margin-top: 0.9rem;
    font-size: 0.98rem;
    line-height: 1.42;
  }

  .blog-main .hero-journal-link {
    margin-top: 1.2rem;
  }

  .blog-main .blog-layout {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  

  .blog-main .hero-journal-link {
    transition: none;
  }
}
