.article-page {
  padding-top: 66px;
  background: #fff;
  color: var(--text);
}

.article-shell {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

.article-page :is(h1, h2, h3, h4) {
  font-family: var(--font-title);
  font-weight: 700;
}

.article-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(72px, 9vw, 124px) 0 clamp(56px, 7vw, 92px);
  background: linear-gradient(145deg, #f8fbfa 0%, var(--teal-soft) 100%);
  border-bottom: 1px solid var(--border);
}

.article-hero-media,
.article-hero--image::before {
  position: absolute;
  inset: 0;
}

.article-hero-media {
  z-index: 0;
}

.article-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}

.article-hero--image::before {
  content: "";
  z-index: 1;
  background: linear-gradient(90deg, rgba(16, 34, 60, 0.88) 0%, rgba(16, 34, 60, 0.72) 58%, rgba(16, 34, 60, 0.5) 100%);
}

.article-hero > .article-shell {
  position: relative;
  z-index: 2;
}

.article-hero--image,
.article-hero--image h1,
.article-hero--image .article-meta,
.article-hero--image .article-breadcrumbs,
.article-hero--image .article-breadcrumbs a,
.article-hero--image .article-subtitle {
  color: #fff;
}

.article-hero--image h1 {
  text-shadow: 0 3px 24px rgba(0, 0, 0, 0.24);
}

.article-breadcrumbs {
  position: static;
  inset: auto;
  z-index: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 40px;
  color: var(--muted);
  font-size: 14px;
  width: auto;
  height: auto;
  padding: 0;
  background: transparent;
  border: 0;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.article-breadcrumbs a {
  color: var(--navy);
  text-underline-offset: 3px;
}

.article-breadcrumbs span[aria-current="page"] {
  max-width: min(520px, 70vw);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.article-category {
  margin: 0 0 16px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.article-hero h1 {
  max-width: 980px;
  font-size: clamp(2.25rem, 4.5vw, 4.2rem);
  line-height: 1.06;
  letter-spacing: -0.035em;
}

.article-title-line {
  display: block;
}

.article-subtitle {
  max-width: 800px;
  margin: 24px 0 0;
  color: #42566f;
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  line-height: 1.55;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 32px;
  color: var(--muted);
  font-size: 14px;
}

.article-meta span + span::before {
  content: "\00b7";
  margin-right: 22px;
  color: var(--teal);
}

.article-layout {
  display: block;
  max-width: 1040px;
  padding-top: clamp(56px, 8vw, 104px);
  padding-bottom: clamp(72px, 10vw, 132px);
}

.article-body {
  min-width: 0;
  margin-inline: auto;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.75;
}

.article-body > :first-child {
  margin-top: 0;
}

.article-body h2 {
  margin: 72px 0 24px;
  scroll-margin-top: 108px;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.12;
}

.article-body h3 {
  margin: 44px 0 18px;
  scroll-margin-top: 108px;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  line-height: 1.22;
}

.article-body h4 {
  margin: 34px 0 14px;
  scroll-margin-top: 108px;
  color: var(--navy);
  font-size: 1.2rem;
  line-height: 1.3;
}

.article-body p {
  margin: 0 0 24px;
  font-size: inherit;
  line-height: inherit;
}

.article-body a {
  color: var(--royal);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.article-body ul,
.article-body ol {
  display: grid;
  gap: 10px;
  margin: 0 0 30px;
  padding-left: 28px;
}

.article-body li {
  padding-left: 6px;
  font-size: inherit;
  line-height: 1.65;
}

.article-body li::marker {
  color: var(--teal);
  font-weight: 700;
}

.article-callout {
  margin: 36px 0;
  padding: 24px 26px;
  border-left: 5px solid var(--teal);
  border-radius: 0 14px 14px 0;
  background: var(--teal-soft);
}

.article-callout strong {
  display: block;
  margin-bottom: 8px;
  color: var(--navy);
}

.article-callout p {
  margin: 0;
}

.article-table-wrap {
  max-width: 100%;
  margin: 36px 0;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
}

.article-table-wrap:focus-visible {
  outline: 3px solid var(--royal);
  outline-offset: 3px;
}

.article-body table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 16px;
}

.article-body th,
.article-body td {
  padding: 15px 18px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.article-body th {
  background: var(--navy);
  color: #fff;
  font-weight: 600;
}

.article-body tbody tr:nth-child(even) {
  background: var(--canvas);
}

.article-references {
  margin-top: 72px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--canvas);
  overflow: hidden;
}

.article-references summary {
  position: relative;
  padding: 24px 72px 24px 28px;
  color: var(--navy);
  font-family: var(--font-title);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  list-style: none;
}

.article-references summary::-webkit-details-marker {
  display: none;
}

.article-references summary::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 28px;
  width: 12px;
  height: 12px;
  border-right: 3px solid var(--teal);
  border-bottom: 3px solid var(--teal);
  transform: translateY(-70%) rotate(45deg);
  transition: transform 180ms ease;
}

.article-references[open] summary::after {
  transform: translateY(-30%) rotate(225deg);
}

.article-references summary:focus-visible {
  outline: 3px solid var(--royal);
  outline-offset: -3px;
}

.article-references-content {
  padding: 4px 28px 28px;
  border-top: 1px solid var(--border);
}

.article-references-content > :first-child {
  margin-top: 24px;
}

.article-references-content > :last-child {
  margin-bottom: 0;
}

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

.article-faq:last-of-type {
  border-bottom: 1px solid var(--border);
}

.article-faq summary {
  position: relative;
  padding: 22px 48px 22px 0;
  color: var(--navy);
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.article-faq summary::-webkit-details-marker {
  display: none;
}

.article-faq summary::after {
  content: "+";
  position: absolute;
  top: 18px;
  right: 6px;
  color: var(--teal);
  font-size: 26px;
  font-weight: 400;
}

.article-faq[open] summary::after {
  content: "−";
}

.article-faq-answer {
  padding: 0 48px 8px 0;
}

.article-related {
  padding: clamp(64px, 8vw, 104px) max(20px, calc((100vw - 1180px) / 2));
  background: var(--sage-lt);
}

.article-related > h2 {
  margin: 0 0 34px;
  font-size: clamp(2rem, 4vw, 3.2rem);
}

.article-related > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.article-related-card {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #fff;
  color: inherit;
  text-decoration: none;
}

.article-related-card span {
  color: var(--teal);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.article-related-card h3 {
  margin: 14px 0 12px;
}

.article-related-card p {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 15px;
}

.article-related-card strong {
  margin-top: auto;
  color: var(--teal);
}

@media (max-width: 900px) {
  .article-related > div {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .article-shell {
    width: min(100% - 32px, 1180px);
  }

  .article-hero {
    padding-top: 48px;
  }

  .article-breadcrumbs {
    margin-bottom: 28px;
  }

  .article-meta {
    display: grid;
    gap: 7px;
  }

  .article-meta span + span::before {
    content: none;
  }

  .article-body {
    font-size: 17px;
  }

  .article-callout {
    padding: 20px;
  }

  .article-references summary,
  .article-references-content {
    padding-right: 20px;
    padding-left: 20px;
  }
}

@media print {
  #mainNav,
  footer,
  .article-related {
    display: none !important;
  }

  .article-layout {
    display: block;
    padding-top: 32px;
  }
}
