/*
Theme Name: The Six-Minute Brief (Divi Child)
Description: Child theme for The Six-Minute Brief. Brief pages (home, market archives, issues, The Docket) use their own PHP templates on the Bryan Canning design system (assets/brief); Divi still runs wp-admin and ordinary pages. Requires the Divi parent theme.
Author: Bryan Canning
Template: Divi
Version: 1.6.11
*/

/* Design tokens as CSS custom properties — mirrors the 8-color palette from the design spec.
   These are also entered as Divi Global Colors (copied from Pursuits); kept here too so the site
   renders correctly even before Global Colors are configured. */
:root {
  --ps-base: #e3ded2;
  --ps-contrast: #17171a;
  --ps-accent: #b5231d;
  --ps-body-text: #514c43;
  --ps-muted: #8b8478;
  --ps-rule: #b9b2a3;
  --ps-rule-dark: #3a3a3d;
  --ps-muted-dark: #b09a94;
}

body {
  background: var(--ps-base);
  color: var(--ps-contrast);
}

/* Actual @font-face declarations and hard-case (bullseye / skew / offset-headshot) CSS
   live in fonts.css and style-hard-cases.css, enqueued via functions.php. */

/* Issue template: item anchors clear Divi's fixed header when jumped to. */
.smb-anchor {
  display: block;
  scroll-margin-top: 120px;
}

/* The Docket: scorecard ([smb_scorecard]). Hero element; #smb-scorecard is the screenshot target. */
.smb-scorecard {
  background: var(--ps-contrast);
  color: var(--ps-base);
  padding: 28px 32px 32px;
}
.smb-scorecard table {
  width: 100%;
  border-collapse: collapse;
  border: 0;
  margin: 0;
  table-layout: fixed;
}
.smb-scorecard th,
.smb-scorecard td {
  border: 0;
  border-top: 1px solid var(--ps-rule-dark);
  padding: 14px 16px 14px 0;
  vertical-align: top;
  text-align: left;
  font-size: 15px;
  line-height: 1.45;
  color: var(--ps-base);
}
.smb-scorecard thead th {
  border-top: 0;
  color: var(--ps-accent);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: lowercase;
  padding-bottom: 10px;
}
.smb-scorecard tbody th {
  width: 22%;
  font-weight: 500;
  color: var(--ps-muted-dark);
}
@media (max-width: 767px) {
  .smb-scorecard { padding: 20px; }
  .smb-scorecard thead { display: none; }
  .smb-scorecard table,
  .smb-scorecard tbody,
  .smb-scorecard tr,
  .smb-scorecard th,
  .smb-scorecard td { display: block; width: 100%; }
  .smb-scorecard tbody th { width: 100%; padding: 16px 0 6px; }
  .smb-scorecard td { border-top: 0; padding: 4px 0; }
  .smb-scorecard td::before {
    content: attr(data-market);
    display: block;
    color: var(--ps-accent);
    font-size: 12px;
    letter-spacing: 0.28em;
    text-transform: lowercase;
  }
}

/* The Docket: "This week's issues" strip ([smb_week_issues]). */
.smb-week-issues {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.smb-week-issues__card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  border: 1px solid var(--ps-contrast);
  color: var(--ps-contrast);
  text-decoration: none;
}
.smb-week-issues__card:hover { background: var(--ps-contrast); color: var(--ps-base); }
.smb-week-issues__region {
  color: var(--ps-accent);
  font-size: 13px;
  letter-spacing: 0.28em;
  text-transform: lowercase;
}
.smb-week-issues__title { font-size: 20px; font-weight: 500; line-height: 1.2; }
.smb-week-issues__lede { font-size: 15px; line-height: 1.45; color: var(--ps-body-text); }
.smb-week-issues__card:hover .smb-week-issues__lede { color: var(--ps-base); }

/* The Docket: patterns / BD read / coming up (post content). */
.smb-docket-body h2 {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: lowercase;
  color: var(--ps-accent);
  border-top: 1px solid var(--ps-contrast);
  padding: 24px 0 12px;
  margin-top: 32px;
}
.smb-docket-body h2:first-child { margin-top: 0; }
.smb-docket-body ol.smb-patterns { list-style: none; counter-reset: pattern; padding: 0; margin: 0; }
.smb-docket-body ol.smb-patterns li { counter-increment: pattern; position: relative; padding-left: 48px; margin-bottom: 20px; }
.smb-docket-body ol.smb-patterns li::before {
  content: counter(pattern);
  position: absolute;
  left: 0;
  top: -6px;
  font-size: 36px;
  line-height: 1;
  color: var(--ps-accent);
}
.smb-docket-body ol.smb-patterns strong { display: block; font-size: 22px; font-weight: 500; line-height: 1.25; margin-bottom: 6px; color: var(--ps-contrast); }
.smb-docket-body ul { padding-left: 1.2em; }
.smb-docket-body ul li { margin-bottom: 10px; }
