/* Byline, tables and source notes for the knowledge pages.
   Colours come from the custom properties below; nothing else is hard-coded. */
:root {
  --sp-wine: #6B2737;
  --sp-burgundy: #800020;
  --sp-ink: #07141E;
  --sp-line: #E8E0D4;
  --sp-cream: #F6F3EE;
}

.guide-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  max-width: 48rem;
  margin: -3rem 0 5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--sp-line);
  font-size: 0.8125rem;
  line-height: 1.7;
  color: var(--sp-wine);
}
.guide-meta a {
  text-decoration: underline;
  text-decoration-color: var(--sp-burgundy);
  text-underline-offset: 4px;
}
.guide-meta a:focus-visible,
.guide-table a:focus-visible,
.guide-source a:focus-visible {
  outline: 2px solid var(--sp-burgundy);
  outline-offset: 3px;
}

.guide-table-wrap {
  max-width: 56rem;
  margin: 2.5rem 0 1rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.guide-table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--sp-ink);
}
.guide-table caption {
  caption-side: top;
  text-align: left;
  padding-bottom: 0.75rem;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--sp-burgundy);
}
.guide-table th,
.guide-table td {
  padding: 0.875rem 1rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--sp-line);
}
.guide-table thead th {
  background: var(--sp-cream);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--sp-wine);
  border-bottom: 2px solid var(--sp-wine);
}
.guide-table tbody th {
  font-weight: 600;
  color: var(--sp-wine);
  white-space: nowrap;
}
.guide-table a {
  display: inline-block;
  padding: 0.25rem 0;
  text-decoration: underline;
  text-decoration-color: var(--sp-burgundy);
  text-underline-offset: 4px;
}

.guide-source {
  max-width: 48rem;
  margin: 0 0 2.5rem;
  font-size: 0.8125rem;
  line-height: 1.7;
  color: var(--sp-wine);
}
.guide-source a {
  text-decoration: underline;
  text-underline-offset: 4px;
}

html.dark .guide-table thead th { background: transparent; }
html.dark .guide-meta,
html.dark .guide-source,
html.dark .guide-table,
html.dark .guide-table caption,
html.dark .guide-table thead th,
html.dark .guide-table tbody th { color: inherit; }
html.dark .guide-meta,
html.dark .guide-table th,
html.dark .guide-table td { border-color: var(--sp-wine); }
