/* Shared across every article page and the /articles index: the breadcrumb
   back-link used inside an article, and the card grid used to list articles
   (both on /articles itself and in the homepage teaser section). */

.article-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 28px;
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  transition: color 0.15s ease;
}
.article-breadcrumb svg { width: 14px; height: 14px; flex-shrink: 0; }
.article-breadcrumb:hover, .article-breadcrumb:focus-visible { color: var(--accent-cool); outline: none; }

.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.article-card {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.article-card:hover, .article-card:focus-visible {
  border-color: var(--border-hover);
  background: var(--panel-hover);
  transform: translateY(-2px);
  outline: none;
}
.article-card:focus-visible { box-shadow: 0 0 0 2px var(--accent-cool); }

.article-card-thumb {
  aspect-ratio: 16 / 9;
  background: var(--bg);
}
.article-card-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }

.article-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.article-card-kicker {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-cool);
  margin: 0;
}

.article-card h4, .article-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  margin: 0;
}

.article-card p.dek {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-muted);
  flex: 1;
}

.article-card-cta {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
}

/* /articles index page */
.articles-main {
  position: relative;
  z-index: 1;
  padding: clamp(28px, 5vw, 56px);
}
.articles-intro {
  max-width: 1100px;
  margin: 0 auto 36px;
}
.articles-intro p {
  color: var(--text-muted);
  max-width: 62ch;
  line-height: 1.55;
  margin: 10px 0 0;
}
.articles-wrap { max-width: 1100px; margin: 0 auto; }

/* ---------------------------------------------------------------------
   Article page layout — shared by every article under /articles/<slug>/.
   --------------------------------------------------------------------- */

.article-main {
  position: relative;
  z-index: 1;
  padding: clamp(28px, 5vw, 56px);
}

.article {
  max-width: 760px;
  margin: 0 auto;
}

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

.article-kicker {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-cool);
  margin: 0 0 14px;
}

.article-header h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 2.9rem);
  line-height: 1.12;
  margin: 0 0 14px;
}
.article-header h1 .dash { color: var(--accent); }

.article-dek {
  font-size: 1.1rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
  max-width: 56ch;
}

.article-updated {
  margin: 14px 0 0;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.article-hero {
  margin: 0 0 40px;
  aspect-ratio: 16 / 9;
}

.article-figure {
  margin: 36px 0;
}

figure.photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
}

figure.photo figcaption {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-muted);
}

.article-body {
  font-size: 1.05rem;
  line-height: 1.72;
}

.article-body p {
  margin: 0 0 20px;
  color: var(--text);
}

.article-body h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.7rem;
  margin: 48px 0 20px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

.article-list {
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}
.article-list li {
  position: relative;
  padding: 10px 0 10px 26px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}
.article-list li:first-child { border-top: 1px solid var(--border); }
.article-list li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 19px;
  width: 6px;
  height: 6px;
  border-radius: 2px;
  background: var(--accent);
}

blockquote.pull-quote {
  margin: 36px 0;
  padding: 4px 0 4px 22px;
  border-left: 3px solid var(--accent-cool);
}
.pull-quote p {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.3rem;
  line-height: 1.5;
  color: var(--text);
  margin: 0 0 8px;
}
.pull-quote cite {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-style: normal;
}

blockquote.testimonial {
  margin: 36px 0;
  padding: 28px clamp(20px, 4vw, 32px);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}
.testimonial p {
  font-size: 0.98rem;
  line-height: 1.68;
  color: var(--text);
  margin: 0 0 14px;
}
.testimonial p:last-of-type { margin-bottom: 0; }
.testimonial footer {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.testimonial cite {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  font-style: normal;
  color: var(--text);
}
.testimonial-role {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.author-box {
  margin: 40px 0 0;
  padding: 20px clamp(20px, 4vw, 28px);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}
.author-box-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-cool);
  margin: 0 0 6px;
}
.author-box-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  margin: 0;
}
.author-box-note {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 6px 0 0;
}

@media (max-width: 520px) {
  .article-body { font-size: 1rem; }
  blockquote.pull-quote { padding-left: 16px; }
  .pull-quote p { font-size: 1.15rem; }
}

/* ---------------------------------------------------------------------
   Photo carousel — a strip of extra photos at the end of an article that
   didn't earn a spot in the body text. Markup + JS: see articles.js.
   --------------------------------------------------------------------- */
.photo-carousel { margin-top: 36px; }

.carousel-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
  aspect-ratio: 16 / 9;
}

.carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.4s ease;
}

.carousel-slide {
  position: relative;
  flex: 0 0 100%;
  height: 100%;
  margin: 0;
}
.carousel-slide img { display: block; width: 100%; height: 100%; object-fit: cover; }

.carousel-slide figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 28px 16px 12px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.78));
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.5;
}

.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 16px;
}

.carousel-btn {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.carousel-btn svg { width: 16px; height: 16px; }
.carousel-btn:hover, .carousel-btn:focus-visible {
  border-color: var(--accent-cool);
  color: var(--accent-cool);
  background: var(--panel-hover);
  outline: none;
}

.carousel-dots { display: flex; align-items: center; gap: 8px; }
.carousel-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--border-hover);
  cursor: pointer;
}
.carousel-dot.active { background: var(--accent); }

@media (max-width: 520px) {
  .carousel-viewport { aspect-ratio: 4 / 3; }
}
