/* ==========================================================================
   Smart Post Weekly — main stylesheet
   Hand-written CSS, mobile-first, CSS Grid with named areas.
   ========================================================================== */

:root {
  --ink: #1a1613;
  --ink-soft: #46403a;
  --paper: #fdfbf7;
  --paper-tint: #f6f1e8;
  --line: #ddd3c2;
  --line-strong: #1a1613;
  --amber: #c8791f;
  --amber-dark: #9c5c14;
  --ribbon-bg: #f3cf8f;
  --ribbon-ink: #5b3a1e;
  --green: #2e7d52;
  --green-dark: #1f5c3a;
  --green-tint: #e7f3ea;
  --focus: #1668c1;

  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Source Sans 3", "Segoe UI", Arial, sans-serif;

  --max-shell: 1180px;
  --max-article: 740px;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.75rem;
  --space-4: 2.75rem;
  --space-5: 4rem;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  overflow-x: hidden;
}

img,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--amber-dark);
  text-decoration-thickness: 1px;
}

a:hover {
  color: var(--ink);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 0.6em;
}

p {
  margin: 0 0 1.1em;
}

ul, ol {
  margin: 0 0 1.1em;
  padding-left: 1.3em;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------------------------------------------------------------------
   Page shell — CSS Grid with named areas
   --------------------------------------------------------------------- */

.page {
  display: grid;
  grid-template-areas:
    "ribbon"
    "header"
    "main"
    "footer";
  grid-template-rows: auto auto 1fr auto;
  min-height: 100vh;
}

.page__ribbon { grid-area: ribbon; }
.page__header { grid-area: header; }
.page__main   { grid-area: main; }
.page__footer { grid-area: footer; }

/* ---------------------------------------------------------------------
   Advertising ribbon
   --------------------------------------------------------------------- */

.ribbon {
  background: var(--ribbon-bg);
  border-bottom: 1px solid var(--line);
}

.ribbon__inner {
  max-width: var(--max-shell);
  margin: 0 auto;
  padding: 0.55rem 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  font-size: 0.82rem;
  color: var(--ribbon-ink);
}

.ribbon__badge {
  display: inline-block;
  background: var(--ribbon-ink);
  color: var(--ribbon-bg);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.72rem;
  padding: 0.22rem 0.6rem;
  border-radius: 3px;
}

.ribbon__text {
  font-weight: 600;
}

/* ---------------------------------------------------------------------
   Masthead
   --------------------------------------------------------------------- */

.masthead {
  background: var(--paper);
  border-bottom: 3px double var(--line-strong);
  padding: 1.5rem 1rem 1.1rem;
  text-align: center;
}

.masthead__link {
  display: inline-block;
  text-decoration: none;
}

.masthead__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.75rem, 6vw, 2.6rem);
  letter-spacing: 0.01em;
  color: var(--ink);
  margin: 0;
}

.masthead__tagline {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  font-size: clamp(0.85rem, 2.4vw, 1rem);
  margin-top: 0.2rem;
}

.masthead__nav {
  margin-top: 0.9rem;
}

.masthead__home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.45rem 1.4rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.masthead__home:hover {
  background: var(--ink);
  color: var(--paper);
}

/* ---------------------------------------------------------------------
   Article shell
   --------------------------------------------------------------------- */

.article {
  max-width: var(--max-article);
  margin: 0 auto;
  padding: var(--space-3) 1rem var(--space-5);
}

.article__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--amber-dark);
  margin-bottom: 0.6rem;
}

.article__title {
  font-weight: 800;
  font-size: clamp(1.7rem, 5.4vw, 2.7rem);
  margin-bottom: 0.55em;
}

.article__dek {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.05rem, 2.6vw, 1.3rem);
  color: var(--ink-soft);
  margin-bottom: 1.1em;
}

.byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.5rem;
  font-size: 0.88rem;
  color: var(--ink-soft);
  padding-bottom: 1.4rem;
  margin-bottom: 1.6rem;
  border-bottom: 1px solid var(--line);
}

.byline__author {
  font-weight: 700;
  color: var(--ink);
}

.byline__dot::before {
  content: "\00b7";
  margin-right: 0.5rem;
}

/* ---------------------------------------------------------------------
   Media frames (images + video loops share a consistent aspect box)
   --------------------------------------------------------------------- */

.media-frame {
  margin: var(--space-3) 0;
}

.media-frame__box {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 10px;
  background: var(--paper-tint);
  box-shadow: 0 1px 3px rgba(26, 22, 19, 0.12);
}

.media-frame__box video,
.media-frame__box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame--hero .media-frame__box {
  aspect-ratio: 16 / 10;
  border-radius: 12px;
}

.media-frame--wide .media-frame__box {
  aspect-ratio: 16 / 9;
}

.media-frame figcaption {
  font-size: 0.85rem;
  color: var(--ink-soft);
  font-style: italic;
  margin-top: 0.55rem;
  line-height: 1.4;
}

/* ---------------------------------------------------------------------
   Prose
   --------------------------------------------------------------------- */

.prose h2 {
  font-size: clamp(1.35rem, 3.6vw, 1.75rem);
  margin-top: var(--space-4);
  padding-top: 0.2rem;
}

.prose h3 {
  font-size: clamp(1.1rem, 2.8vw, 1.3rem);
  margin-top: var(--space-3);
}

.prose p {
  color: var(--ink-soft);
}

.prose strong {
  color: var(--ink);
}

.lede {
  font-size: 1.12rem;
  color: var(--ink);
}

/* ---------------------------------------------------------------------
   CTA block
   --------------------------------------------------------------------- */

.cta-block {
  display: grid;
  grid-template-areas:
    "eyebrow"
    "heading"
    "button";
  gap: 0.6rem;
  background: var(--ink);
  color: var(--paper);
  border-radius: 12px;
  padding: 1.6rem 1.4rem;
  margin: var(--space-4) 0;
  text-align: center;
}

.cta-block__eyebrow {
  grid-area: eyebrow;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ribbon-bg);
}

.cta-block__heading {
  grid-area: heading;
  font-size: clamp(1.15rem, 3.4vw, 1.5rem);
  color: var(--paper);
  margin: 0;
}

.cta-block__sub {
  color: #e6e0d6;
  font-size: 0.95rem;
  margin: -0.4rem 0 0;
}

.cta-block__button {
  grid-area: button;
  justify-self: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.75rem 1.6rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 2px solid transparent;
  transition: transform 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.btn--cta {
  background: var(--amber);
  color: var(--ink);
}

.btn--cta:hover {
  background: var(--ribbon-bg);
  color: var(--ink);
  transform: translateY(-1px);
}

.btn--ghost {
  background: transparent;
  border-color: var(--paper);
  color: var(--paper);
}

.btn--ghost:hover {
  background: var(--paper);
  color: var(--ink);
}

/* ---------------------------------------------------------------------
   Affiliate sentence callout (near first CTA)
   --------------------------------------------------------------------- */

.disclosure-line {
  font-size: 0.92rem;
  color: var(--ink-soft);
  background: var(--paper-tint);
  border-left: 3px solid var(--amber);
  padding: 0.8rem 1rem;
  border-radius: 0 6px 6px 0;
  margin: 0.4rem 0 var(--space-3);
}

.disclosure-line strong {
  color: var(--ink);
}

/* ---------------------------------------------------------------------
   Trust / badge row (accent-borrowed treatment)
   --------------------------------------------------------------------- */

.badge-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
  margin: var(--space-3) 0;
  padding: 0;
  list-style: none;
}

.badge-row__item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--green-tint);
  color: var(--green-dark);
  border: 1px solid #cfe6d6;
  border-radius: 999px;
  padding: 0.55rem 0.9rem;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.25;
}

.badge-row__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

.badge-row__note {
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin-top: -0.4rem;
}

/* ---------------------------------------------------------------------
   Fact box
   --------------------------------------------------------------------- */

.fact-box {
  background: var(--paper-tint);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.3rem 1.3rem 1.1rem;
  margin: var(--space-3) 0;
}

.fact-box__title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--amber-dark);
  margin-bottom: 0.7rem;
}

.fact-box ul {
  margin: 0;
  padding-left: 1.2em;
}

.fact-box li {
  margin-bottom: 0.5rem;
  color: var(--ink-soft);
}

.fact-box__footnote {
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin: 0.8rem 0 0;
  font-style: italic;
}

/* ---------------------------------------------------------------------
   Steps
   --------------------------------------------------------------------- */

.steps {
  list-style: none;
  padding: 0;
  margin: var(--space-3) 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
}

.steps__item {
  display: grid;
  grid-template-columns: 2.4rem 1fr;
  gap: 0.85rem;
  align-items: start;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.9rem 1rem;
}

.steps__num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
}

.steps__body h3 {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
}

.steps__body p {
  margin: 0;
  font-size: 0.94rem;
  color: var(--ink-soft);
}

/* ---------------------------------------------------------------------
   Mistakes
   --------------------------------------------------------------------- */

.mistake {
  border-top: 1px solid var(--line);
  padding-top: 1.3rem;
  margin-top: 1.3rem;
}

.mistake:first-of-type {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.mistake__title {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
}

.mistake__index {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--amber);
}

.mistake__fix {
  background: var(--green-tint);
  border-radius: 8px;
  padding: 0.75rem 0.9rem;
  margin-top: 0.6rem;
  font-size: 0.94rem;
  color: var(--green-dark);
}

.mistake__fix strong {
  color: var(--green-dark);
}

/* ---------------------------------------------------------------------
   Honest limits block
   --------------------------------------------------------------------- */

.limits-block {
  background: var(--ink);
  color: var(--paper);
  border-radius: 12px;
  padding: 1.5rem 1.4rem;
  margin: var(--space-4) 0;
}

.limits-block__title {
  color: var(--paper);
  font-size: clamp(1.2rem, 3.2vw, 1.5rem);
}

.limits-block ul {
  margin: 0;
  padding-left: 1.2em;
}

.limits-block li {
  color: #e6e0d6;
  margin-bottom: 0.6rem;
}

/* ---------------------------------------------------------------------
   FAQ accordion (accent-borrowed treatment)
   --------------------------------------------------------------------- */

.faq {
  margin: var(--space-3) 0;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.faq__item {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0;
  overflow: hidden;
}

.faq__item summary {
  cursor: pointer;
  list-style: none;
  padding: 0.95rem 1.1rem;
  font-weight: 700;
  font-size: 0.98rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  color: var(--ink);
  min-height: 44px;
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

.faq__icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--green-tint);
  color: var(--green-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

.faq__item[open] .faq__icon {
  background: var(--green);
  color: var(--paper);
}

.faq__answer {
  padding: 0 1.1rem 1.05rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.faq__answer p {
  margin: 0;
}

/* ---------------------------------------------------------------------
   Sections & rhythm
   --------------------------------------------------------------------- */

.section-tint {
  background: var(--paper-tint);
  margin: var(--space-4) -1rem 0;
  padding: var(--space-4) 1rem;
}

/* ---------------------------------------------------------------------
   Legal / about pages
   --------------------------------------------------------------------- */

.legal {
  max-width: var(--max-article);
  margin: 0 auto;
  padding: var(--space-4) 1rem var(--space-5);
}

.legal__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--amber-dark);
  margin-bottom: 0.6rem;
}

.legal__title {
  font-weight: 800;
  font-size: clamp(1.6rem, 4.6vw, 2.3rem);
  margin-bottom: 0.4em;
}

.legal__updated {
  font-size: 0.88rem;
  color: var(--ink-soft);
  margin-bottom: 1.8rem;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid var(--line);
}

.legal__body h2 {
  font-size: 1.3rem;
  margin-top: var(--space-4);
}

.legal__body p,
.legal__body li {
  color: var(--ink-soft);
}

.legal__body address {
  font-style: normal;
  color: var(--ink);
  background: var(--paper-tint);
  border-radius: 8px;
  padding: 1rem 1.1rem;
  line-height: 1.7;
}

/* ---------------------------------------------------------------------
   Page-close: disclaimer aside + footer
   --------------------------------------------------------------------- */

.ad-disclosure {
  display: block;
  max-width: var(--max-shell);
  margin: 0 auto;
  padding: var(--space-3) 1rem;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
}

.ad-disclosure a {
  font-weight: 700;
}

.foot {
  background: var(--ink);
  color: #d8d2c6;
  padding: var(--space-4) 1rem var(--space-3);
}

.foot .owner {
  max-width: var(--max-shell);
  margin: 0 auto;
  font-size: 0.92rem;
  line-height: 1.65;
}

.foot .owner strong {
  display: block;
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.foot .meta-links {
  max-width: var(--max-shell);
  margin: 1.4rem auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 1.3rem;
  padding-top: 1.2rem;
  border-top: 1px solid #423d34;
  list-style: none;
  padding-left: 0;
}

.foot .meta-links a {
  color: #d8d2c6;
  font-size: 0.9rem;
  text-decoration: underline;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.foot .meta-links a:hover {
  color: var(--ribbon-bg);
}

.foot__copy {
  max-width: var(--max-shell);
  margin: 1rem auto 0;
  font-size: 0.78rem;
  color: #9d9788;
}

/* ==========================================================================
   Breakpoints
   ========================================================================== */

@media (min-width: 480px) {
  .badge-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .article {
    padding-top: var(--space-4);
  }

  .badge-row {
    grid-template-columns: repeat(4, 1fr);
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .cta-block {
    grid-template-areas:
      "eyebrow eyebrow"
      "heading button";
    align-items: center;
    text-align: left;
    padding: 2rem 2.2rem;
  }

  .cta-block__heading {
    margin: 0;
  }

  .cta-block__button {
    justify-self: end;
  }

  .masthead {
    padding: 2.1rem 1rem 1.4rem;
  }

  .foot .owner,
  .ad-disclosure {
    font-size: 0.95rem;
  }
}

@media (min-width: 1024px) {
  .article {
    padding-top: var(--space-5);
    padding-bottom: var(--space-5);
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.2rem;
  }

  .mistake__index {
    font-size: 1.7rem;
  }
}
