/* ============================================================
   DeftBrain — Shared Guide Stylesheet
   Location: /public/guides/guide.css → served as /guides/guide.css
   Used by: every guide under /guides/{category}/{slug}.html
   Edit here once; all guides update. Do not inline styles in
   individual guide files — design consistency lives here.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink:    #1a1816;
  --ink2:   #3d3a36;
  --ink3:   #6b6760;
  --paper:  #f7f4ef;
  --warm:   #f0ebe2;
  --accent: #c94f2c;
  --accent2:#e8935e;
  --rule:   #e0dbd2;
  --max:    720px;
  --col:    clamp(16px, 4vw, 24px);
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  line-height: 1.75;
  min-height: 100vh;
}

/* ── Masthead / footer ── */
.masthead {
  border-bottom: 1px solid var(--rule);
  padding: 14px var(--col);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.masthead-logo {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 15px;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: .03em;
}
.masthead-logo span { color: var(--accent); }
.masthead-cta {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink3);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 1px;
  transition: color .15s, border-color .15s;
}
.masthead-cta:hover { color: var(--accent); border-color: var(--accent2); }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--col);
}

/* ── Article header ── */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 48px 0 20px;
}
.tag {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}
.eyebrow-rule { flex: 1; height: 1px; background: var(--rule); }

h1 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: clamp(32px, 6vw, 52px);
  line-height: 1.1;
  letter-spacing: -.02em;
  color: var(--ink);
  margin-bottom: 24px;
}
h1 em { font-style: italic; color: var(--accent); }

.deck {
  font-size: clamp(16px, 2.2vw, 19px);
  font-weight: 300;
  color: var(--ink2);
  line-height: 1.65;
  border-left: 3px solid var(--accent2);
  padding-left: 18px;
  margin-bottom: 40px;
}

.meta-line {
  font-size: 12px;
  color: var(--ink3);
  letter-spacing: .04em;
  margin-bottom: 32px;
}
.meta-line a { color: var(--ink3); text-decoration: underline; text-decoration-color: var(--rule); }
.meta-line a:hover { color: var(--accent); text-decoration-color: var(--accent2); }

.lede {
  font-size: clamp(16px, 2vw, 18px);
  font-weight: 300;
  line-height: 1.8;
  color: var(--ink2);
  margin-bottom: 20px;
}

/* ── Section rules / headings ── */
.section-rule {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 40px 0 32px;
}
.section-rule span {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink3);
  white-space: nowrap;
}
.section-rule::before,
.section-rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--rule);
}

h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(20px, 3vw, 26px);
  font-weight: 700;
  line-height: 1.25;
  color: var(--ink);
  margin-bottom: 12px;
}

/* ── Steps ── */
.step {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 0 16px;
  margin-bottom: 32px;
  align-items: start;
}
.step-num {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--accent2);
  line-height: 1;
  padding-top: 3px;
  opacity: .5;
}
.step-body h3 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 6px;
  letter-spacing: .01em;
}
.step-body p {
  font-size: 15px;
  color: var(--ink2);
  line-height: 1.7;
}

/* ── Callout ── */
.callout {
  background: var(--warm);
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
  border-radius: 0 8px 8px 0;
  padding: 20px 24px;
  margin: 32px 0;
}
.callout-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}
.callout .say {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 17px;
  color: var(--ink);
  line-height: 1.55;
}
.callout-note {
  margin-top: 10px;
  font-size: 15px;
  font-weight: 300;
  color: var(--ink2);
  line-height: 1.7;
}

/* ── CTA block (tool promotion) ── */
.cta-block {
  background: var(--ink);
  border-radius: 12px;
  padding: clamp(28px, 5vw, 48px) clamp(24px, 5vw, 48px);
  margin: 48px 0;
  position: relative;
  overflow: hidden;
}
.cta-block::before {
  content: attr(data-glyph);
  position: absolute;
  right: 32px; top: 28px;
  font-size: 64px;
  opacity: .07;
}
.cta-block .cta-eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent2);
  margin-bottom: 12px;
}
.cta-block h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(22px, 3.5vw, 30px);
  color: #f7f4ef;
  margin-bottom: 12px;
}
.cta-block p {
  font-size: 15px;
  font-weight: 300;
  color: #a8a39a;
  line-height: 1.7;
  max-width: 480px;
  margin-bottom: 24px;
}
.cta-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}
.cta-feature {
  font-size: 12px;
  font-weight: 400;
  color: #c8c3ba;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 99px;
  padding: 4px 12px;
}
.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .02em;
  padding: 13px 24px;
  border-radius: 6px;
  transition: background .15s, transform .1s;
}
.cta-btn:hover { background: #b04425; transform: translateY(-1px); }
.cta-subtext {
  display: block;
  margin-top: 12px;
  font-size: 12px;
  color: #6b6760;
}

/* ── Related cluster ── */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
  margin: 16px 0 48px;
}
.related-card {
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 14px 16px;
  text-decoration: none;
  transition: border-color .12s, background .12s;
}
.related-card:hover {
  border-color: var(--accent2);
  background: var(--warm);
}
.rel-cat {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent2);
  margin-bottom: 5px;
}
.rel-title {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink2);
  line-height: 1.45;
}

/* ── Footer ── */
footer {
  border-top: 1px solid var(--rule);
  padding: 24px var(--col);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-brand {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink3);
  text-decoration: none;
}
.footer-brand span { color: var(--accent); }
.footer-copy { font-size: 12px; color: var(--ink3); }

/* ── Entrance animation ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.container > * { animation: fadeUp .5s ease both; }
.eyebrow      { animation-delay: .05s; }
h1            { animation-delay: .10s; }
.deck         { animation-delay: .15s; }
.lede         { animation-delay: .20s; }
.section-rule { animation-delay: .25s; }

@media (prefers-reduced-motion: reduce) {
  .container > * { animation: none; }
}

@media (max-width: 480px) {
  .step { grid-template-columns: 28px 1fr; }
}
