/* articles.css — reading layout for crocodata.net/articles
   Depends on styles.css for the colour tokens and font variables.
   Priorities here are measure, rhythm and contrast, not decoration. */

.art-main {
  padding-top: 120px;
  padding-bottom: 120px;
}

.art-wrap {
  max-width: 720px;      /* ~68-72 characters at this size: the comfortable measure */
  margin: 0 auto;
  padding: 0 24px;
}

.art-crumb {
  display: inline-block;
  margin-bottom: 40px;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  text-decoration: none;
  transition: color var(--transition);
}
.art-crumb:hover { color: var(--color-accent); }

.art-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
  font-weight: 600;
  margin-bottom: 18px;
}

/* ---------- index listing ---------- */

.art-index-head { margin-bottom: 72px; }

.art-index-head h1 {
  font-size: clamp(2rem, 5vw, 2.9rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.art-index-head h1 em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--color-accent);
}
.art-index-head p {
  color: var(--color-text-muted);
  font-size: 1.08rem;
  line-height: 1.75;
}

.art-list { display: flex; flex-direction: column; gap: 20px; }

.art-card {
  display: block;
  padding: 32px 34px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: border-color var(--transition), transform var(--transition), background var(--transition);
}
.art-card:hover {
  border-color: var(--color-accent);
  background: var(--color-surface);
  transform: translateY(-2px);
}

.art-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: 14px;
}
.art-card-tag {
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--color-accent-dim);
  color: var(--color-accent);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.art-card h2 {
  font-size: 1.35rem;
  line-height: 1.35;
  color: var(--color-text);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
.art-card p {
  color: var(--color-text-muted);
  font-size: 0.98rem;
  line-height: 1.7;
  margin: 0;
}
.art-card-more {
  display: inline-block;
  margin-top: 18px;
  color: var(--color-accent);
  font-size: 0.9rem;
  font-weight: 500;
}

.art-empty {
  margin-top: 28px;
  padding: 28px 32px;
  border: 1px dashed var(--color-border-hover);
  border-radius: var(--radius);
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ---------- article body ---------- */

.art-header { margin-bottom: 56px; }

.art-header h1 {
  font-size: clamp(1.9rem, 4.6vw, 2.7rem);
  line-height: 1.18;
  letter-spacing: -0.02em;
  margin-bottom: 22px;
}

.art-standfirst {
  font-size: 1.15rem;
  line-height: 1.75;
  color: var(--color-text-muted);
  margin-bottom: 26px;
}

.art-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
  padding-top: 22px;
  border-top: 1px solid var(--color-border);
  font-size: 0.85rem;
  color: var(--color-text-muted);
}
.art-meta .dot { opacity: 0.4; }

.art-body { font-size: 1.06rem; line-height: 1.8; }

.art-body h2 {
  font-size: 1.45rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 60px 0 20px;
  padding-top: 8px;
  scroll-margin-top: 100px;
}
.art-body h2:first-child { margin-top: 0; }

.art-body h3 {
  font-size: 1.12rem;
  margin: 40px 0 14px;
  color: var(--color-text);
}

.art-body p {
  margin-bottom: 24px;
  color: #cfdcd5;   /* a touch softer than headings, easier over long reads */
}

.art-body strong { color: var(--color-text); font-weight: 600; }
.art-body em { font-style: italic; }

.art-body a {
  color: var(--color-accent);
  text-decoration: none;
  border-bottom: 1px solid rgba(62, 207, 142, 0.35);
  transition: border-color var(--transition);
}
.art-body a:hover { border-bottom-color: var(--color-accent); }

.art-body ol, .art-body ul { margin: 0 0 26px; padding-left: 26px; }
.art-body li { margin-bottom: 14px; color: #cfdcd5; padding-left: 4px; }
.art-body li::marker { color: var(--color-accent); font-weight: 600; }
.art-body li:last-child { margin-bottom: 0; }

/* callout for the standout stat or claim */
.art-pull {
  margin: 44px 0;
  padding: 28px 32px;
  background: var(--color-bg-card);
  border-left: 3px solid var(--color-accent);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.art-pull p { margin: 0; font-size: 1.08rem; color: var(--color-text); line-height: 1.7; }

/* numbers strip */
.art-figures {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 18px;
  margin: 44px 0;
}
.art-figure {
  padding: 24px 22px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}
.art-figure .n {
  display: block;
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--color-accent);
  line-height: 1.1;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.art-figure .l {
  display: block;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.art-rules {
  margin: 40px 0;
  padding: 8px 0;
  counter-reset: rule;
  list-style: none;
  padding-left: 0;
}
.art-rules li {
  position: relative;
  counter-increment: rule;
  padding: 20px 0 20px 52px;
  border-bottom: 1px solid var(--color-border);
  margin: 0;
}
.art-rules li:last-child { border-bottom: none; }
.art-rules li::before {
  content: counter(rule);
  position: absolute;
  left: 0;
  top: 20px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--color-accent-dim);
  color: var(--color-accent);
  font-size: 0.85rem;
  font-weight: 700;
}

/* suggested prompts — set apart from body copy so they read as things to copy */
.art-prompts {
  margin: 32px 0 40px;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.art-prompts li {
  margin: 0;
  padding: 16px 20px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-text);
  font-style: italic;
  line-height: 1.6;
}
.art-prompts li::before {
  content: '“';
  color: var(--color-accent);
  font-weight: 700;
  margin-right: 2px;
}
.art-prompts li::after { content: '”'; color: var(--color-accent); font-weight: 700; }

/* two-mode comparison */
.art-modes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin: 44px 0;
}
.art-mode {
  padding: 28px 26px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}
.art-mode.good { border-color: rgba(62, 207, 142, 0.45); }
.art-mode h3 {
  margin: 0 0 14px;
  font-size: 1.05rem;
  color: var(--color-text);
}
.art-mode.good h3 { color: var(--color-accent); }
.art-mode p { font-size: 0.96rem; line-height: 1.7; margin-bottom: 14px; }
.art-mode p:last-child { margin-bottom: 0; }
.art-mode .tell {
  display: block;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--color-border);
  font-size: 0.88rem;
  color: var(--color-text-muted);
}

.art-sources {
  margin-top: 72px;
  padding-top: 32px;
  border-top: 1px solid var(--color-border);
}
.art-sources h2 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-accent);
  margin-bottom: 18px;
}
.art-sources p { font-size: 0.9rem; line-height: 2; color: var(--color-text-muted); margin: 0; }
.art-sources a { color: var(--color-text-muted); border-bottom: 1px solid var(--color-border-hover); }
.art-sources a:hover { color: var(--color-accent); }

.art-foot {
  margin-top: 64px;
  padding: 32px 34px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-align: center;
}
.art-foot p { color: var(--color-text-muted); font-size: 0.95rem; line-height: 1.7; margin-bottom: 18px; }
.art-foot a.btn { margin: 0 6px; }

.art-nav-bottom {
  margin-top: 48px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.9rem;
}
.art-nav-bottom a { color: var(--color-accent); text-decoration: none; }
.art-nav-bottom a:hover { text-decoration: underline; }

@media (max-width: 640px) {
  .art-main { padding-top: 96px; padding-bottom: 80px; }
  .art-card { padding: 26px 24px; }
  .art-body { font-size: 1.02rem; }
  .art-body h2 { margin-top: 48px; }
  .art-pull { padding: 22px 24px; }
  .art-foot { padding: 26px 24px; }
}
