/* Cortessian Insights — hub and editorial layout */
/* Inherit the existing Cortessian page colours. */

/* Hub introduction */

.insights-hero {
  padding: clamp(64px, 9vw, 116px) 0 clamp(40px, 6vw, 76px);
  border-bottom: 1px solid var(--border);
}

.insights-hero .eyebrow {
  margin-bottom: 22px;
}

.insights-hero h1 {
  max-width: 780px;
}

.insights-hero .hero-sub {
  max-width: 66ch;
  margin-top: 20px;
  color: var(--text-muted);
}

/* Article listing */

.insights-listing {
  padding: clamp(40px, 6vw, 76px) 0 100px;
}

.insights-featured {
  margin-bottom: 28px;
}

.insights-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.insights-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(26px, 4vw, 40px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.insights-card--featured {
  padding: clamp(32px, 5vw, 60px);
}

.insights-card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  margin-bottom: 22px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.76rem;
}

.insights-card-meta span {
  color: var(--accent);
}

.insights-card h2 {
  margin-bottom: 16px;
  font-size: clamp(1.45rem, 2vw, 2rem);
  line-height: 1.2;
}

.insights-card--featured h2 {
  max-width: 780px;
  font-size: clamp(2rem, 3.5vw, 3rem);
}

.insights-card h2 a {
  color: var(--text);
}

.insights-card h2 a:hover,
.insights-card h2 a:focus-visible {
  color: var(--accent);
}

.insights-card p {
  max-width: 65ch;
  margin-bottom: 24px;
  color: var(--text-muted);
}

.insights-card-more {
  margin-top: auto;
  color: var(--accent);
  font-size: 0.92rem;
  font-weight: 600;
}

/* Empty-library local preview */

.insights-empty {
  max-width: 680px;
  padding: 44px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.insights-empty p {
  margin-bottom: 0;
  color: var(--text-muted);
}

/* Individual article foundation */

.insight-article {
  padding: clamp(48px, 7vw, 90px) 0 100px;
}

.insight-article-header {
  max-width: 780px;
  margin: 0 auto 52px;
}

.insight-article-body {
  max-width: 68ch;
  margin: 0 auto;
}

.insight-article-body h2 {
  margin-top: 2em;
}

.insight-article-body h3 {
  margin-top: 1.6em;
}

.insight-article-body p,
.insight-article-body ul,
.insight-article-body ol,
.insight-article-body blockquote {
  margin-bottom: 1.4em;
}

.insight-article-body img {
  height: auto;
}

.insight-article-body a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.insight-article-body blockquote {
  padding: 8px 0 8px 24px;
  border-left: 3px solid var(--accent);
  color: var(--text-muted);
}

/* Responsive behaviour */

@media (max-width: 720px) {
  .insights-grid {
    grid-template-columns: 1fr;
  }

  .insights-listing {
    padding-bottom: 64px;
  }

  .insights-empty {
    padding: 28px;
  }

  .insight-article-header {
    margin-bottom: 36px;
  }
}

/* Article identity and metadata */

.insight-breadcrumb {
  margin-bottom: 32px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.insight-breadcrumb a {
  color: var(--text-muted);
}

.insight-article-meta {
  margin-bottom: 18px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.insight-article-header h1 {
  margin-bottom: 24px;
}

.insight-article-header .hero-sub {
  max-width: 65ch;
  color: var(--text-muted);
}

.insight-byline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
}

.insight-byline a {
  color: var(--text);
  font-weight: 600;
}

/* Further Insights — editorial recommendations */

.insight-related {
  margin-top: 80px;
  padding-top: 36px;
  border-top: 1px solid var(--border);
}

.insight-related h2 {
  margin-bottom: 28px;
}

.insight-related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.insight-related-card {
  min-width: 0;
  padding: 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.insight-related-topic {
  margin-bottom: 14px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

.insight-related-card h3 {
  font-size: 1.3rem;
  line-height: 1.25;
}

.insight-related-card h3 a {
  color: var(--text);
}

.insight-related-card h3 a:hover,
.insight-related-card h3 a:focus-visible {
  color: var(--accent);
}

.insight-related-card > p:last-child {
  margin-bottom: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Optional commercial next step */

.insight-service {
  margin-top: 48px;
  padding: clamp(28px, 4vw, 44px);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.insight-service .eyebrow {
  margin-bottom: 16px;
}

.insight-service h2 {
  margin-bottom: 12px;
}

.insight-service > p:not(.eyebrow) {
  max-width: 58ch;
  color: var(--text-muted);
}

.insight-service > a {
  display: inline-block;
  margin-top: 8px;
  font-weight: 600;
}

/* Article responsive layout */

@media (max-width: 800px) {
  .insight-related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .insight-related-grid {
    grid-template-columns: 1fr;
  }

  .insight-related {
    margin-top: 56px;
  }

  .insight-service {
    margin-top: 36px;
  }
}

/* Keep featured articles prominent without excessive empty space. */

.insights-card--featured {
  padding-block: clamp(28px, 4vw, 44px);
}
