/* Guide article design — freecreditsnodeposit.com
 *
 * Applies to the 105 plain WordPress pages (bonus guides + casino reviews),
 * which shipped with no styling of their own: unstyled text at full browser
 * width. Everything is scoped under .guide so it cannot leak into the
 * Elementor-built homepage.
 *
 * Palette and type are taken from what the site already has — the dark of the
 * existing footer, the brand gold, the cream header band, and the three font
 * families already downloaded locally. No new network requests.
 */

.guide {
  --ink: #12171C;        /* existing site footer */
  --ink-soft: #1B222B;
  --gold: #E7B40A;       /* existing brand accent */
  --gold-deep: #8A6A00;  /* 4.9:1 on white — safe for text */
  --sand: #F5EDE6;       /* existing header band */
  --paper: #FFFFFF;
  --slate: #58616E;      /* 6.1:1 on white */
  --rule: #E6DED5;

  --measure: 68ch;
  --display: "Roboto Slab", Georgia, serif;
  --ui: "Poppins", system-ui, sans-serif;
  --body: "Roboto", system-ui, sans-serif;

  max-width: 1180px;
  margin-inline: auto;
  padding: 0 20px 72px;
  box-sizing: border-box;
  color: var(--ink);
  font-family: var(--body);
}

/* ---------- hero ---------------------------------------------------- */

.guide .page-header {
  background: var(--ink);
  border-radius: 14px;
  padding: 44px 36px 40px;
  margin: 28px 0 0;
  position: relative;
  overflow: hidden;
}

/* A single hairline of brand gold along the top edge. The one flourish. */
.guide .page-header::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: var(--gold);
}

.guide .guide-eyebrow {
  font-family: var(--ui);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 14px;
}

.guide .entry-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3rem);
  line-height: 1.12;
  letter-spacing: -.015em;
  color: #fff;
  margin: 0;
  max-width: 20ch;
}

.guide .guide-standfirst {
  font-family: var(--body);
  font-size: 1.05rem;
  line-height: 1.65;
  color: #C6CDD6;
  margin: 18px 0 0;
  max-width: 62ch;
}

/* ---------- two-column shell ---------------------------------------- */

.guide .guide-shell {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  margin-top: 40px;
}

@media (min-width: 1000px) {
  .guide .guide-shell {
    grid-template-columns: 232px minmax(0, 1fr);
    gap: 56px;
  }
}

/* ---------- signature: section index with a reading thread ---------- */

.guide .guide-index {
  font-family: var(--ui);
  font-size: .875rem;
}

.guide .guide-index-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--slate);
  margin: 0 0 14px;
}

.guide .guide-index ol {
  list-style: none;
  margin: 0;
  padding: 0 0 0 18px;
  position: relative;
}

/* The track, and the gold thread that fills as you read. */
.guide .guide-index ol::before,
.guide .guide-index ol::after {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 2px;
  border-radius: 2px;
}
.guide .guide-index ol::before { background: var(--rule); }
.guide .guide-index ol::after {
  background: var(--gold);
  bottom: auto;
  height: var(--guide-progress, 0%);
  transition: height .18s linear;
}

.guide .guide-index li + li { margin-top: 2px; }

.guide .guide-index a {
  display: block;
  padding: 7px 10px 7px 12px;
  border-radius: 7px;
  color: var(--slate);
  text-decoration: none;
  line-height: 1.4;
  transition: color .15s ease, background-color .15s ease;
}

.guide .guide-index a:hover { color: var(--ink); background: var(--sand); }

.guide .guide-index a[aria-current="true"] {
  color: var(--ink);
  font-weight: 600;
  background: var(--sand);
}

@media (min-width: 1000px) {
  .guide .guide-index {
    position: sticky;
    top: 24px;
    align-self: start;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
  }
  /* <details> is used so the index collapses on small screens. On desktop it
     is always open, so the summary would duplicate .guide-index-title. */
  .guide .guide-index > summary {
    display: none;
  }
}

/* On narrow screens the index collapses; a sticky rail would eat the fold. */
@media (max-width: 999px) {
  .guide .guide-index {
    border: 1px solid var(--rule);
    border-radius: 12px;
    padding: 4px 16px;
    background: var(--paper);
  }
  .guide .guide-index summary {
    cursor: pointer;
    padding: 14px 0;
    font-weight: 600;
    color: var(--ink);
    list-style: none;
  }
  .guide .guide-index summary::-webkit-details-marker { display: none; }
  .guide .guide-index summary::after {
    content: "＋";
    float: right;
    color: var(--gold-deep);
    font-weight: 400;
  }
  .guide .guide-index[open] summary::after { content: "－"; }
  .guide .guide-index ol { padding-bottom: 14px; }
  .guide .guide-index-title { display: none; }
}

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

.guide .page-content {
  max-width: var(--measure);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--slate);
}

.guide .page-content > p { margin: 0 0 1.25em; }

/* Lead paragraph. The opening paragraph is styled in place rather than lifted
   into the hero — moving it would duplicate content for anything reading the
   raw markup, and these pages are read by crawlers as much as by people. */
.guide .page-content > p:first-of-type {
  font-size: 1.175rem;
  line-height: 1.7;
  color: var(--ink);
}

.guide .page-content h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(1.4rem, 1.1rem + 1vw, 1.85rem);
  line-height: 1.25;
  letter-spacing: -.01em;
  color: var(--ink);
  margin: 2.4em 0 .2em;
  scroll-margin-top: 24px;
}

/* Short gold rule under each section head — marks structure without
   numbering it. These sections are topics, not an ordered process. */
.guide .page-content h2::after {
  content: "";
  display: block;
  width: 46px;
  height: 3px;
  background: var(--gold);
  border-radius: 2px;
  margin-top: .55em;
}

.guide .page-content h2 + p { margin-top: 1.1em; }

.guide .page-content h3 {
  font-family: var(--ui);
  font-weight: 600;
  font-size: 1.075rem;
  line-height: 1.4;
  color: var(--ink);
  margin: 2em 0 .5em;
  scroll-margin-top: 24px;
}

.guide .page-content strong { color: var(--ink); font-weight: 600; }

.guide .page-content a {
  color: var(--gold-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.guide .page-content a:hover { color: var(--ink); }

.guide .page-content ul {
  list-style: none;
  margin: 0 0 1.5em;
  padding: 0;
}

.guide .page-content ul li {
  position: relative;
  padding-left: 26px;
  margin-bottom: .7em;
}

.guide .page-content ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: .62em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 2px solid var(--gold);
}

.guide .page-content ol { padding-left: 1.3em; margin: 0 0 1.5em; }
.guide .page-content ol li { margin-bottom: .6em; }

.guide .page-content img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
}

.guide .page-content figure { margin: 1.8em 0; }

.guide .page-content table {
  width: 100%;
  border-collapse: collapse;
  font-size: .95rem;
  margin: 1.6em 0;
}
.guide .page-content th,
.guide .page-content td {
  border: 1px solid var(--rule);
  padding: 11px 13px;
  text-align: left;
  vertical-align: top;
}
.guide .page-content th { background: var(--sand); color: var(--ink); font-family: var(--ui); }

/* Wide content must scroll inside itself, never the page. */
.guide .page-content .table-scroll { overflow-x: auto; }

/* ---------- FAQ ------------------------------------------------------ */

/* Marked at build time: the H2 whose text is FAQ(s) and everything after it. */
.guide .guide-faq {
  margin-top: 3em;
  border-top: 1px solid var(--rule);
  padding-top: 2em;
}

.guide .guide-faq h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--ink);
  margin: 1.6em 0 .4em;
  padding-left: 26px;
  position: relative;
}

/* A shape, not a letter. CSS generated content is exposed to screen readers in
   Chrome, so a "Q" here would be announced as part of every question. */
.guide .guide-faq h3::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .62em;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  background: var(--gold);
  transform: rotate(45deg);
}

.guide .guide-faq h3 + p { padding-left: 26px; margin-bottom: 1.2em; }

/* ---------- quality floor -------------------------------------------- */

.guide a:focus-visible,
.guide .guide-index a:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .guide .guide-index ol::after,
  .guide .guide-index a { transition: none; }
  .guide * { scroll-behavior: auto !important; }
}
