/*
Theme Name: Reward Rush Ledger
Template: astra
Description: Reward Rush child theme, bordeaux and cream ledger
Author: Reward Rush
Version: 1.1.0
Text Domain: rush
*/

/* ======================================================================
   1. Astra integration overrides (container fix + empty Astra chrome shells)
   ====================================================================== */

#content .ast-container, .ast-container { display: block !important; width: 100% !important; max-width: 100% !important; }
#primary, .site-main, #main { width: 100% !important; max-width: 100% !important; flex: 1 1 100% !important; margin-inline: auto !important; }

/* Astra's own chrome is replaced by the child theme header and footer. */
.ast-main-header-wrap, #masthead .ast-main-header-bar-alignment { display: none; }
.site-footer #colophon, #colophon { display: none; }

/* ======================================================================
   2. Design tokens — palette from manifest/site.json
   ====================================================================== */

:root {
  --rr-paper: #faf6ef;
  --rr-card: #fffdf8;
  --rr-ink: #2b2118;
  --rr-muted: #6b5d4f;
  --rr-wine: #5d1f2c;
  --rr-wine-deep: #4a1822;
  --rr-gold: #a8762a;
  --rr-gold-soft: #e0b15e;
  --rr-line: #e4d9c6;
  --rr-tint-wine: #f4ecdd;
  --rr-tint-gold: #f7efdd;
  --rr-radii: 12px;
  --rr-measure: 840px;
  --rr-pad: 20px;
  --rr-font-head: "Playfair Display", Georgia, serif;
  --rr-font-body: "Source Sans 3", Inter, system-ui, sans-serif;
}

/* ======================================================================
   3. Base element defaults
   ====================================================================== */

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

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

body {
  margin: 0;
  background: var(--rr-paper);
  color: var(--rr-ink);
  font-family: var(--rr-font-body);
  font-size: 17px;
  line-height: 1.6;
  font-variant-numeric: tabular-nums;
  overflow-wrap: break-word;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--rr-font-head);
  color: var(--rr-wine);
  line-height: 1.25;
  margin: 0 0 12px;
}

p { margin: 0 0 16px; }

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

a {
  color: var(--rr-wine);
  text-decoration: underline;
  text-underline-offset: 2px;
}

a:hover { color: var(--rr-gold); }

:focus-visible { outline: 2px solid var(--rr-gold); outline-offset: 2px; }

/* ======================================================================
   4. Reading column — one shared measure for every flow block
   ====================================================================== */

.rr-breadcrumb,
.rr-hero,
.rr-leadin,
.rr-toc,
.rr-body,
.rr-calc-slot,
.rr-board-slot,
.rr-compare-note,
.rr-faq,
.rr-offshore-note,
.rr-care,
.rr-onward,
.rr-colophon {
  width: 100%;
  max-width: var(--rr-measure);
  margin-inline: auto;
}

.rr-breadcrumb,
.rr-hero,
.rr-leadin,
.rr-body,
.rr-board-slot,
.rr-compare-note,
.rr-faq,
.rr-onward,
.rr-colophon {
  padding-inline: var(--rr-pad);
}

/* Board slot: the [rrb_board] grid must never exceed the shared measure,
   whatever width its host column gives it. */
.rr-board-slot .rrb-board { max-width: 100%; }

/* ======================================================================
   5. Site header — wine bar: brand band over a centred menu band
   ====================================================================== */

.rr-site-header {
  position: relative;
  background: var(--rr-wine);
  color: var(--rr-paper);
  border-bottom: 3px solid var(--rr-gold);
  box-shadow: 0 6px 22px rgba(43, 33, 24, 0.18);
}

.rr-header-inner {
  max-width: 1280px;
  margin-inline: auto;
  padding: 0 var(--rr-pad);
}

.rr-brandrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 18px;
  padding-block: 14px 10px;
}

.rr-brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.rr-brand,
.rr-brand a {
  font-family: var(--rr-font-head);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.12;
  color: var(--rr-paper);
  text-decoration: none;
}

.rr-brand a { display: block; }

.rr-tagline {
  font-family: var(--rr-font-body);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.06em;
  white-space: nowrap;
  color: var(--rr-gold-soft);
}

/* ======================================================================
   6. Primary navigation — centred wrapping row; every link high-contrast
   ====================================================================== */

.rr-nav {
  min-width: 0;
  border-top: 1px solid rgba(250, 246, 239, 0.25);
  padding-block: 6px 10px;
}

.rr-nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2px 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rr-nav-item {
  position: relative;
  margin: 0;
}

/* Top-level category links: cream on wine, semibold — the palette pair
   behind the header, always readable on every hub and page. */
.rr-nav-link {
  display: block;
  padding: 7px 11px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--rr-paper) !important;
  text-decoration: none;
  white-space: nowrap;
  border-radius: 8px;
}

.rr-nav-link:hover,
.rr-nav-link:focus-visible {
  color: #ffffff !important;
  background: rgba(250, 246, 239, 0.16);
}

.rr-sub {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  margin: 0;
  padding: 6px 0;
  list-style: none;
  background: var(--rr-card);
  border: 1px solid var(--rr-line);
  border-radius: 10px;
  box-shadow: 0 14px 30px rgba(43, 33, 24, 0.22);
  z-index: 50;
  display: none;
}

.rr-nav-item:last-child > .rr-sub,
.rr-nav-item:nth-last-child(2) > .rr-sub {
  left: auto;
  right: 0;
}

.rr-nav-item:hover > .rr-sub,
.rr-nav-item:focus-within > .rr-sub,
.rr-nav-item.is-open > .rr-sub { display: block; }

.rr-sub li { margin: 0; }

.rr-sub a {
  display: block;
  padding: 8px 14px;
  font-size: 14px;
  line-height: 1.35;
  color: var(--rr-ink) !important;
  text-decoration: none;
  white-space: nowrap;
}

.rr-sub a:hover,
.rr-sub a:focus-visible {
  background: var(--rr-tint-wine);
  color: var(--rr-wine) !important;
}

/* Caret button beside hub links with children (desktop hover opens the
   panel; the button keeps a tap/keyboard route). */
.rr-has-sub > .rr-nav-toggle {
  appearance: none;
  background: transparent;
  border: 0;
  color: var(--rr-gold-soft);
  font-size: 12px;
  line-height: 1;
  padding: 8px 4px 8px 0;
  margin-left: -4px;
  cursor: pointer;
}

/* Mobile menu button — hidden at desktop widths. */
.rr-menu-toggle {
  display: none;
  appearance: none;
  background: transparent;
  border: 1px solid rgba(250, 246, 239, 0.5);
  color: var(--rr-paper);
  font-family: var(--rr-font-body);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  padding: 9px 14px;
  border-radius: 8px;
  cursor: pointer;
  flex: 0 0 auto;
}

.rr-menu-toggle:hover,
.rr-menu-toggle:focus-visible { background: rgba(250, 246, 239, 0.14); }

/* ======================================================================
   7. Breadcrumb
   ====================================================================== */

.rr-breadcrumb {
  padding-top: 16px;
  font-size: 13.5px;
  color: var(--rr-muted);
}

.rr-breadcrumb a {
  color: var(--rr-muted);
  text-decoration: none;
}

.rr-breadcrumb a:hover,
.rr-breadcrumb a:focus-visible { color: var(--rr-wine); }

.rr-breadcrumb ol,
.rr-breadcrumb ul {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rr-breadcrumb li { margin: 0; }

.rr-breadcrumb li + li::before {
  content: "\203A";
  margin-right: 6px;
  color: var(--rr-gold);
}

.rr-breadcrumb .rr-sep {
  color: var(--rr-gold);
  margin-inline: 4px;
}

/* ======================================================================
   8. Hero and standfirst
   ====================================================================== */

.rr-hero { padding-block: 26px 6px; }

.rr-hero h1 {
  margin: 0 0 12px;
  font-size: 40px;
  line-height: 1.15;
  color: var(--rr-wine);
}

.rr-standfirst {
  margin: 0;
  font-size: 19px;
  line-height: 1.55;
  color: var(--rr-muted);
}

/* ======================================================================
   9. Lead-in
   ====================================================================== */

.rr-leadin {
  margin-block: 4px 0;
  font-size: 18px;
  color: var(--rr-ink);
}

/* ======================================================================
   10. Table of contents
   ====================================================================== */

.rr-toc {
  margin-block: 24px;
  padding: 18px var(--rr-pad);
  background: var(--rr-card);
  border: 1px solid var(--rr-line);
  border-radius: var(--rr-radii);
}

.rr-toc h2 {
  margin: 0 0 12px;
  padding-top: 0;
  border-top: 0;
  font-size: 22px;
}

.rr-toc ol,
.rr-toc ul {
  columns: 2;
  column-gap: 36px;
  margin: 0;
  padding-left: 20px;
}

.rr-toc li {
  margin: 0 0 7px;
  break-inside: avoid;
}

.rr-toc a { color: var(--rr-wine); }

.rr-toc a:hover,
.rr-toc a:focus-visible {
  color: var(--rr-wine);
  text-decoration: underline;
}

/* ======================================================================
   11. Article body flow
   ====================================================================== */

.rr-body { margin-block: 10px 0; }

.rr-body > * { max-width: 100%; }

.rr-body h2,
.rr-faq h2 {
  margin: 36px 0 14px;
  padding-top: 16px;
  border-top: 2px solid var(--rr-gold);
  font-size: 28px;
}

.rr-body p { line-height: 1.65; }

.rr-body ul,
.rr-body ol {
  margin: 0 0 16px;
  padding-left: 22px;
}

.rr-body li { margin: 0 0 6px; }

/* ======================================================================
   12. Figures
   ====================================================================== */

.rr-figure {
  margin: 24px 0;
  padding: 18px var(--rr-pad);
  background: var(--rr-card);
  border: 1px solid var(--rr-line);
  border-radius: var(--rr-radii);
}

.rr-figure svg {
  display: block;
  width: 100%;
  height: auto;
}

.rr-figure figcaption {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--rr-muted);
}

/* ======================================================================
   13. Data and comparison tables
   ====================================================================== */

.rr-tablewrap,
.rr-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.rr-data,
.rr-compare {
  width: 100%;
  margin: 22px 0;
  border-collapse: collapse;
  background: var(--rr-card);
  font-size: 14px;
  line-height: 1.5;
  hyphens: auto;
}

.rr-data caption,
.rr-compare caption {
  caption-side: top;
  text-align: left;
  padding: 0 0 10px;
  font-size: 13.5px;
  color: var(--rr-muted);
}

.rr-data th,
.rr-compare th {
  padding: 10px 12px;
  border: 1px solid var(--rr-wine);
  background: var(--rr-wine);
  color: var(--rr-paper);
  text-align: left;
  font-weight: 600;
}

.rr-data td,
.rr-compare td {
  padding: 9px 12px;
  border: 1px solid var(--rr-line);
  vertical-align: top;
  color: var(--rr-ink);
}

.rr-data tbody tr:nth-child(even),
.rr-compare tbody tr:nth-child(even) { background: var(--rr-tint-wine); }

.rr-compare-note {
  margin: -10px 0 24px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--rr-muted);
}

/* ======================================================================
   14. Calculator slot
   ====================================================================== */

.rr-calc-slot {
  margin-block: 26px;
  padding: 20px var(--rr-pad);
  background: var(--rr-card);
  border: 1px solid var(--rr-line);
  border-radius: var(--rr-radii);
}

.rr-calc-slot h2 {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
  font-size: 22px;
}

/* ======================================================================
   15. FAQ
   ====================================================================== */

.rr-faq { margin-block: 8px 0; }

.rr-q {
  position: relative;
  margin: 24px 0 8px;
  padding-left: 20px;
  font-family: var(--rr-font-head);
  font-size: 18px;
  line-height: 1.4;
  color: var(--rr-ink);
}

.rr-q::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--rr-gold);
}

.rr-a { margin: 0 0 18px; }

.rr-a p {
  margin: 0 0 10px;
  line-height: 1.65;
  color: color-mix(in srgb, var(--rr-ink) 72%, var(--rr-muted));
}

.rr-a p:last-child { margin-bottom: 0; }

/* ======================================================================
   16. Offshore note and care panel
   ====================================================================== */

.rr-offshore-note {
  margin-block: 26px;
  padding: 16px var(--rr-pad) 16px calc(var(--rr-pad) - 4px);
  background: var(--rr-tint-wine);
  border-left: 4px solid var(--rr-wine);
  border-radius: 0 var(--rr-radii) var(--rr-radii) 0;
  color: var(--rr-ink);
}

.rr-offshore-note p {
  margin: 0 0 8px;
  line-height: 1.6;
}

.rr-offshore-note p:last-child { margin-bottom: 0; }

.rr-care {
  margin-block: 26px;
  padding: 14px var(--rr-pad);
  background: var(--rr-tint-gold);
  border: 1px solid var(--rr-line);
  border-radius: var(--rr-radii);
  font-size: 14px;
  line-height: 1.55;
  color: var(--rr-ink);
}

.rr-care p { margin: 0 0 8px; }

.rr-care p:last-child { margin-bottom: 0; }

/* ======================================================================
   17. Onward — pill links
   ====================================================================== */

.rr-onward {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-block: 26px;
  list-style: none;
}

.rr-onward li { margin: 0; }

.rr-onward a {
  display: inline-block;
  padding: 8px 16px;
  background: var(--rr-card);
  border: 1px solid var(--rr-line);
  border-radius: 999px;
  color: var(--rr-wine);
  font-size: 14.5px;
  line-height: 1.3;
  text-decoration: none;
}

.rr-onward a:hover,
.rr-onward a:focus-visible {
  background: var(--rr-wine);
  border-color: var(--rr-wine);
  color: var(--rr-paper);
}

/* ======================================================================
   18. Buttons and CTAs — wine inherited
   ====================================================================== */

.rr-btn,
.rr-cta {
  display: inline-block;
  padding: 11px 22px;
  background: var(--rr-wine);
  border: 1px solid var(--rr-wine);
  border-radius: 8px;
  color: var(--rr-paper);
  font-family: var(--rr-font-body);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
}

.rr-btn:hover,
.rr-btn:focus-visible,
.rr-cta:hover,
.rr-cta:focus-visible {
  background: color-mix(in srgb, var(--rr-wine) 78%, var(--rr-ink));
  border-color: color-mix(in srgb, var(--rr-wine) 78%, var(--rr-ink));
  color: var(--rr-paper);
}

/* ======================================================================
   19. Site footer — wine slab: brand column, three link columns, bottom bar
   ====================================================================== */

.rr-site-footer {
  margin-top: 56px;
  background: var(--rr-wine);
  color: var(--rr-paper);
  border-top: 3px solid var(--rr-gold);
}

.rr-foot-wrap {
  max-width: 1280px;
  margin-inline: auto;
  padding: 44px var(--rr-pad) 0;
}

.rr-foot-cols {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr 1fr;
  gap: 34px 40px;
  padding-bottom: 36px;
}

.rr-foot-name {
  margin: 0 0 12px;
  font-family: var(--rr-font-head);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.15;
}

.rr-foot-name a {
  color: var(--rr-paper);
  text-decoration: none;
}

.rr-foot-name a:hover,
.rr-foot-name a:focus-visible { color: var(--rr-gold-soft); }

.rr-foot-about {
  margin: 0 0 14px;
  font-size: 14px;
  line-height: 1.65;
  color: rgba(250, 246, 239, 0.82);
}

.rr-foot-18plus {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: rgba(250, 246, 239, 0.82);
}

.rr-foot-18plus span {
  display: inline-block;
  margin-right: 8px;
  padding: 3px 9px;
  border: 1.5px solid var(--rr-gold-soft);
  border-radius: 6px;
  color: var(--rr-gold-soft);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.rr-foot-head {
  margin: 0 0 12px;
  font-family: var(--rr-font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--rr-gold-soft);
}

.rr-foot-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rr-foot-list li { margin: 0 0 9px; }

.rr-foot-list a {
  color: var(--rr-paper);
  text-decoration: none;
  font-size: 14.5px;
  line-height: 1.45;
}

.rr-foot-list a:hover,
.rr-foot-list a:focus-visible {
  color: var(--rr-gold-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.rr-foot-bottom {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding-block: 16px;
  border-top: 1px solid rgba(250, 246, 239, 0.25);
  font-size: 13px;
  line-height: 1.6;
  color: rgba(250, 246, 239, 0.82);
}

.rr-foot-bottom p { margin: 0; }

.rr-foot-gambling a {
  color: var(--rr-gold-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.rr-foot-gambling a:hover,
.rr-foot-gambling a:focus-visible { color: #ffffff; }

/* ======================================================================
   20. Colophon (in-content) — kept for fragment markup
   ====================================================================== */

.rr-colophon {
  margin-top: 44px;
  padding-top: 18px;
  padding-bottom: 8px;
  border-top: 1px solid var(--rr-line);
  color: var(--rr-muted);
  font-size: 13.5px;
  line-height: 1.6;
}

.rr-colophon a { color: var(--rr-wine); }

.rr-colophon p:last-child,
.rr-colophon ul:last-child { margin-bottom: 0; }

/* ======================================================================
   21. Responsive breakpoints
   ====================================================================== */

/* Between 1025px and 1200px the centred menu simply uses a tighter
   rhythm; nothing is clipped because the row wraps. */
@media (min-width: 1025px) and (max-width: 1200px) {
  .rr-brandrow { gap: 4px 14px; }

  .rr-brand,
  .rr-brand a { font-size: 22px; }

  .rr-nav-list { gap: 2px 2px; }

  .rr-nav-link { padding: 7px 8px; font-size: 14.5px; }
}

/* Toggle navigation under 1025px; submenus become static panels opened by
   the caret buttons (or keyboard focus), never by hover. */
@media (max-width: 1024px) {
  .rr-brandrow {
    flex-wrap: nowrap;
    padding-block: 12px;
  }

  .rr-menu-toggle { display: inline-block; }

  .rr-nav {
    display: none;
    border-top: 1px solid rgba(250, 246, 239, 0.25);
    padding-block: 4px 10px;
  }

  .rr-site-header.is-open .rr-nav { display: block; }

  .rr-nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  .rr-nav-item { width: 100%; }

  .rr-nav-link {
    padding: 11px 8px;
    white-space: normal;
  }

  .rr-sub {
    position: static;
    display: none;
    min-width: 0;
    margin: 2px 0 8px;
    padding: 4px 0;
    box-shadow: none;
    border-radius: 8px;
  }

  .rr-nav-item:hover > .rr-sub { display: none; }

  .rr-nav-item:focus-within > .rr-sub,
  .rr-nav-item.is-open > .rr-sub { display: block; }

  .rr-sub a { padding: 9px 12px 9px 24px; white-space: normal; }
}

/* Tagline steps aside on narrow phones. */
@media (max-width: 600px) {
  :root { --rr-pad: 16px; }

  .rr-tagline { display: none; }

  .rr-hero { padding-block: 20px 4px; }

  .rr-hero h1 { font-size: 28px; }

  .rr-standfirst { font-size: 17px; }

  .rr-leadin { font-size: 17px; }

  .rr-body h2,
  .rr-faq h2 {
    margin-top: 30px;
    padding-top: 12px;
    font-size: 23px;
  }

  .rr-toc { padding-block: 16px; }

  .rr-figure { padding-block: 14px; }

  .rr-onward { gap: 8px; }

  .rr-onward a {
    padding: 7px 14px;
    font-size: 14px;
  }

  .rr-colophon { padding-bottom: 4px; }
}

/* Footer reflows: two columns under 980px, one under 620px. */
@media (max-width: 980px) {
  .rr-foot-cols { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
  .rr-foot-cols { grid-template-columns: 1fr; gap: 28px; }

  .rr-foot-wrap { padding-top: 36px; }

  .rr-foot-bottom { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 390px) {
  :root { --rr-pad: 14px; }

  .rr-breadcrumb { font-size: 12.5px; }

  .rr-body h2,
  .rr-faq h2 { font-size: 22px; }

  .rr-figure { padding-block: 12px; }
}