/*
  Page-specific styles for /article/. Shared chrome (navbar, offcanvas,
  footer, cookie bar) lives in main.css. This page's Contentful-driven
  content used to exist only as a JS-built innerHTML string with no
  static fallback — the hero (incl. the page's only <h1>), body, and
  sidebar below are now real elements in the raw HTML from the start,
  with js/article.js filling in text/attributes once the fetch
  resolves, rather than creating the elements themselves.
*/

/* ── Breadcrumb ── */

.breadcrumb {

  background: var(--surface);

  padding-top: 76px;

  border-bottom: 1px solid var(--border);
}

.breadcrumb-inner {

  padding: 16px 0;

  display: flex;

  align-items: center;

  gap: 10px;
}

.breadcrumb-link {

  font-family: var(--fh);

  font-size: 11px;

  font-weight: 600;

  color: var(--mid);

  letter-spacing: 1px;

  transition: color 0.2s;
}

.breadcrumb-link:hover {

  color: var(--orange);
}

.breadcrumb-sep {

  color: var(--mid);

  font-size: 11px;
}

.breadcrumb-current {

  font-family: var(--fh);

  font-size: 11px;

  font-weight: 600;

  color: var(--orange);

  letter-spacing: 1px;
}

/* ── Article hero ── */

.article-hero {

  background: var(--page);
}

.article-hero-inner {

  padding: 40px 0 36px;
}

.article-meta-top {

  display: flex;

  align-items: center;

  gap: 16px;

  margin-bottom: 24px;

  flex-wrap: wrap;
}

.article-cat-badge {

  background: var(--orange);

  color: var(--white);

  font-family: var(--fh);

  font-size: 9px;

  font-weight: 700;

  padding: 6px 14px;

  letter-spacing: 2px;

  text-transform: uppercase;
}

.article-date {

  font-family: var(--fh);

  font-size: 11px;

  color: var(--mid);

  letter-spacing: 1px;
}

.article-author-chip {

  display: flex;

  align-items: center;

  gap: 8px;
}

.article-author-dot {

  width: 4px;

  height: 4px;

  background: var(--border);

  border-radius: 50%;
}

.article-author-name {

  font-family: var(--fh);

  font-size: 11px;

  color: var(--mid);

  letter-spacing: 1px;
}

.article-title {

  font-family: var(--fh);

  font-size: clamp(30px, 4.5vw, 64px);

  font-weight: 900;

  color: var(--black);

  line-height: 1.05;

  letter-spacing: -0.5px;

  margin-bottom: 24px;

  max-width: 860px;
}

.article-excerpt {

  font-size: 17px;

  color: var(--mid);

  max-width: 680px;

  line-height: 1.8;

  margin-bottom: 40px;

  border-left: 3px solid var(--orange);

  padding-left: 22px;
}

.article-hero-img {

  position: relative;

  aspect-ratio: 21 / 9;

  overflow: hidden;

  background: var(--surface);
}

.article-hero-img img {

  width: 100%;

  height: 100%;

  object-fit: cover;

  display: block;
}

.article-hero-img-caption {

  position: absolute;

  bottom: 0;

  left: 0;

  right: 0;

  padding: 14px 22px;

  background: linear-gradient(to top, #000000a6 0%, transparent 100%);

  font-family: var(--fh);

  font-size: 10px;

  font-weight: 600;

  color: #ffffff7a;

  letter-spacing: 1px;

  text-transform: uppercase;
}

/* ── Layout ── */

.article-layout {

  background: var(--page);

  padding: 56px 0 88px;
}

/* ── Body text ── */

.article-body {

  background: var(--white);

  padding: 48px 52px;

  border: 1px solid var(--border);
}

.article-body p {

  font-size: 17px;

  color: #2a2a2a;

  line-height: 1.85;

  margin-bottom: 22px;
}

.article-body h2 {

  font-family: var(--fh);

  font-size: clamp(20px, 2.4vw, 28px);

  font-weight: 800;

  color: var(--black);

  line-height: 1.2;

  margin: 36px 0 14px;
}

.article-body h3 {

  font-family: var(--fh);

  font-size: clamp(17px, 1.9vw, 22px);

  font-weight: 700;

  color: var(--black);

  line-height: 1.3;

  margin: 28px 0 10px;
}

.article-body ul,
.article-body ol {

  padding-left: 22px;

  margin-bottom: 22px;
}

.article-body li {

  font-size: 17px;

  color: #2a2a2a;

  line-height: 1.75;

  margin-bottom: 7px;
}

.article-body blockquote {

  border-left: 3px solid var(--orange);

  padding: 18px 24px;

  margin: 28px 0;

  background: var(--orange-pale);
}

.article-body blockquote p {

  font-family: var(--fh);

  font-size: 16px;

  font-weight: 600;

  color: var(--black);

  font-style: italic;

  margin-bottom: 0;
}

.article-body strong {

  font-weight: 700;

  color: var(--black);
}

.article-body a {

  color: var(--orange);

  text-decoration: underline;

  transition: opacity 0.2s;
}

.article-body a:hover {

  opacity: 0.75;
}

.article-body hr {

  border: none;

  border-top: 1px solid var(--border);

  margin: 36px 0;

  opacity: 1;
}

.article-body figure {

  margin: 28px 0;
}

.article-body figure img {

  max-width: 100%;

  height: auto;

  display: block;
}

/* Skeleton loading placeholder — real body content replaces this once fetched */

.skel {

  height: 20px;

  margin-bottom: 14px;

  background: var(--surface);

  border-radius: 3px;

  animation: sk 1.5s ease-in-out infinite;
}

.skel:nth-child(1) {

 width: 92%; }

.skel:nth-child(2) {

 width: 88%; }

.skel:nth-child(3) {

 width: 95%; }

.skel:nth-child(4) {

 width: 60%; }

@keyframes sk {

  0%, 100% {

 opacity: 1; }

  50% {

 opacity: 0.5; }
}

/* ── Sidebar ── */

.article-sidebar {

  position: sticky;

  top: 88px;

  display: flex;

  flex-direction: column;

  gap: 2px;
}

.sidebar-card {

  background: var(--white);

  padding: 24px;

  border: 1px solid var(--border);
}

.sidebar-card-label {

  font-family: var(--fh);

  font-size: 9px;

  font-weight: 700;

  letter-spacing: 3px;

  text-transform: uppercase;

  color: var(--orange);

  margin-bottom: 14px;

  display: flex;

  align-items: center;

  gap: 8px;
}

.sidebar-card-label::before {

  content: '';

  display: block;

  width: 14px;

  height: 2px;

  background: var(--orange);
}

.share-btns {

  display: flex;

  flex-direction: column;

  gap: 6px;
}

.share-btn {

  display: flex;

  align-items: center;

  gap: 11px;

  padding: 11px 14px;

  background: var(--surface);

  font-family: var(--fh);

  font-size: 12px;

  font-weight: 600;

  color: var(--black);

  transition: background 0.25s, color 0.25s;

  cursor: pointer;

  border: none;

  width: 100%;

  text-align: left;
}

.share-btn:hover {

  background: var(--orange);

  color: var(--white);
}

.share-btn:focus-visible {

  outline: 2px solid var(--orange);

  outline-offset: 2px;
}

.share-btn svg {

  width: 14px;

  height: 14px;

  fill: currentColor;

  flex-shrink: 0;
}

.story-info-item {

  display: flex;

  align-items: flex-start;

  gap: 12px;

  margin-bottom: 14px;

  padding-bottom: 14px;

  border-bottom: 1px solid var(--border);
}

.story-info-item:last-child {

  margin-bottom: 0;

  padding-bottom: 0;

  border-bottom: none;
}

.story-info-label {

  font-family: var(--fh);

  font-size: 10px;

  font-weight: 700;

  color: var(--mid);

  letter-spacing: 1px;

  text-transform: uppercase;

  min-width: 76px;

  padding-top: 2px;
}

.story-info-value {

  font-size: 13px;

  color: var(--black);

  font-weight: 500;

  line-height: 1.5;
}

.back-to-portal {

  display: flex;

  align-items: center;

  gap: 9px;

  padding: 15px 18px;

  background: var(--surface);

  color: var(--black);

  font-family: var(--fh);

  font-size: 12px;

  font-weight: 700;

  letter-spacing: 0.5px;

  border: 1px solid var(--border);

  transition: background 0.25s, color 0.25s, border-color 0.25s;
}

.back-to-portal:hover {

  background: var(--orange);

  color: var(--white);

  border-color: var(--orange);
}

.back-to-portal svg {

  width: 13px;

  height: 13px;

  stroke: currentColor;

  fill: none;

  stroke-width: 2.5;

  transition: transform 0.25s;
}

.back-to-portal:hover svg {

  transform: translateX(-3px);
}

/* ── Error / not found (reuses .article-body's card) ── */

.article-error {

  min-height: 40vh;

  display: flex;

  align-items: center;

  justify-content: center;

  flex-direction: column;

  gap: 18px;

  text-align: center;

  padding: 40px 24px;
}

.article-error-icon {

  width: 64px;

  height: 64px;

  background: var(--orange-pale);

  border-radius: 50%;

  display: flex;

  align-items: center;

  justify-content: center;

  margin: 0 auto;
}

.article-error-icon svg {

  width: 28px;

  height: 28px;

  stroke: var(--orange);

  fill: none;

  stroke-width: 1.5;
}

.article-error-title {

  font-family: var(--fh);

  font-size: 22px;

  font-weight: 800;

  color: var(--black);
}

.article-error-body {

  font-size: 15px;

  color: var(--mid);

  max-width: 400px;

  line-height: 1.7;
}

/*
  Scoped to .article-error rather than just .article-error-btn: this
  renders inside #article_body, so it needs to outrank .article-body a
  (used for rich-text prose links) which would otherwise win on
  specificity and leave the button's text the same colour as its
  background.
*/

.article-error .article-error-btn {

  display: inline-flex;

  align-items: center;

  gap: 9px;

  padding: 14px 28px;

  background: var(--orange);

  color: var(--white);

  text-decoration: none;

  font-family: var(--fh);

  font-size: 13px;

  font-weight: 700;

  transition: background 0.25s;
}

.article-error-btn:hover {

  background: var(--orange-dk);
}

/* ── More stories ── */

.more-stories {

  background: var(--surface);

  padding: 72px 0;

  border-top: 1px solid var(--border);
}

.more-stories-hd {

  display: flex;

  align-items: center;

  justify-content: space-between;

  margin-bottom: 36px;
}

.more-stories-title {

  font-family: var(--fh);

  font-size: clamp(20px, 2.4vw, 30px);

  font-weight: 900;

  color: var(--black);
}

.more-stories-link {

  font-family: var(--fh);

  font-size: 12px;

  font-weight: 700;

  color: var(--orange);

  display: flex;

  align-items: center;

  gap: 7px;

  transition: gap 0.25s;
}

.more-stories-link:hover {

  gap: 13px;
}

.more-stories-link svg {

  width: 13px;

  height: 13px;

  stroke: var(--orange);

  fill: none;

  stroke-width: 2.5;
}

.more-stories-grid {

  display: grid;

  grid-template-columns: repeat(3, 1fr);

  gap: 14px;
}

.ms-card {

  background: var(--white);

  display: block;

  overflow: hidden;

  border: 1px solid var(--border);

  transition: transform 0.35s var(--ease), box-shadow 0.35s, border-color 0.3s;
}

.ms-card:hover {

  transform: translateY(-5px);

  box-shadow: 0 16px 40px #00000017;

  border-color: #ff7a0040;
}

.ms-img {

  position: relative;

  aspect-ratio: 16 / 9;

  overflow: hidden;
}

.ms-img img {

  width: 100%;

  height: 100%;

  object-fit: cover;

  transition: transform 0.5s var(--ease);

  display: block;
}

.ms-card:hover .ms-img img {

  transform: scale(1.05);
}

.ms-cat {

  position: absolute;

  bottom: 0;

  left: 0;

  background: var(--orange);

  color: var(--white);

  font-family: var(--fh);

  font-size: 9px;

  font-weight: 700;

  padding: 4px 10px;

  letter-spacing: 2px;

  text-transform: uppercase;
}

.ms-body {

  padding: 18px 18px 16px;
}

.ms-title {

  font-family: var(--fh);

  font-size: 14px;

  font-weight: 700;

  color: var(--black);

  line-height: 1.35;

  margin-bottom: 7px;
}

.ms-exc {

  font-size: 12px;

  color: var(--mid);

  line-height: 1.6;

  display: -webkit-box;

  -webkit-line-clamp: 2;

  -webkit-box-orient: vertical;

  overflow: hidden;
}

/* ── Responsive ── */

@media (width < 1100px) {

  .more-stories-grid {

    grid-template-columns: 1fr 1fr;
  }
}

@media (width < 900px) {

  .article-body {

    padding: 32px 22px;
  }

  .more-stories-grid {

    grid-template-columns: 1fr;
  }
}

/*
  Uppercase micro-labels drop to 8-9px on desktop; on phones that's
  below comfortable reading size, so floor them at 10px there.
*/

@media (width < 600px) {

  .article-cat-badge,
  .sidebar-card-label,
  .ms-cat {

    font-size: 10px;
  }
}
