/*
Theme Name: Astra Child Reel
Description: Child of Astra for reelplaykingdom.uk. Owns the single header printer, footer stripping (Astra copyright bar removed), title chain, the single content measure and the board slot.
Template: astra
Version: 1.0.6
Text Domain: reelking
*/

/* ---------- Palette tokens (Sunset reel) ---------- */
:root {
  --rkp-paper: #fdf6ec;
  --rkp-paper-2: #f7ecdb;
  --rkp-ink: #2a2a55;
  --rkp-ink-soft: #4a4a72;
  --rkp-coral: #e2643f;
  --rkp-coral-deep: #c14e2e;
  --rkp-rule: #e5d8c4;
  --rkp-radius: 8px;
  --rkp-measure: 1200px;
}

html, body { overflow-x: clip; }

body {
  background: var(--rkp-paper);
  color: var(--rkp-ink);
  font-family: Inter, "Helvetica Neue", Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
  font-family: Fraunces, Georgia, "Times New Roman", serif;
  color: var(--rkp-ink);
}

/* ---------- Astra flex-container trap: keep a centered content column.
   The container must stay a centered 1200px column (not width:100%), so the
   content is horizontally centered on wide screens at any wrapper depth. */
#content .ast-container, .ast-container {
  display: block !important;
  max-width: 1200px !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 20px !important;
  padding-right: 20px !important;
  box-sizing: border-box !important;
}
#primary, .site-main, #main {
  width: 100% !important;
  max-width: 100% !important;
  flex: 1 1 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* ---------- One content measure: centered reading column (hard rule) ---------- */
.rkp-page,
#primary .entry-content,
.site-main .entry-content,
.site-main article .entry-content,
#main .entry-content {
  display: block !important;
  max-width: 1200px !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  float: none !important;
  padding: 0 !important;
  box-sizing: border-box;
}

/* Hide the empty parent masthead shell and any residual footer
   ("Copyright © ... | Powered by Astra WordPress Theme" is removed in
   functions.php; these rules are belt-and-braces). */
.ast-breadcrumbs-wrapper, #masthead .main-header-bar-wrap { display: none; }
.site-header { display: none; }
#colophon, .ast-footer-copyright, .ast-footer-overlay, .ast-footer-html { display: none !important; }
.site-footer { display: none !important; }

/* ---------- Single header (brand row, nav row below, wrap allowed, clipping forbidden) ---------- */
.rkp-header {
  background: #20204a;
  color: #ffffff;
  padding: 0;
}
.rkp-header__brand-row { text-align: center; }
.rkp-header__brand {
  display: inline-block;
  text-align: center;
  padding: 18px 16px 2px;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.7rem;
  letter-spacing: 0.02em;
  color: #ffffff;
  text-decoration: none;
}
.rkp-header__tagline {
  display: block;
  text-align: center;
  font-size: 0.82rem;
  color: #ffe3d2;
  padding-bottom: 10px;
}
.rkp-header__navwrap { background: #20204a; }
.rkp-header__nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px 18px;
  padding: 10px 16px 14px;
  margin: 0 auto;
  list-style: none;
  background: #20204a;
  max-width: 1200px;
}
.rkp-header__nav li { position: relative; }
.rkp-header__nav a {
  color: #ffffff;
  text-decoration: none;
  font-size: 0.92rem;
  padding: 4px 2px;
  white-space: nowrap;
}
.rkp-header__nav a:hover { color: #ffd9c4; }
.rkp-header__nav .rkp-has-children > a::after { content: " \25BE"; font-size: 0.7rem; }
.rkp-header__nav .rkp-sub {
  display: none;
  position: absolute;
  left: 0;
  top: 100%;
  background: #20204a;
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  min-width: 230px;
  padding: 8px 0;
  list-style: none;
  margin: 0;
  z-index: 60;
  box-shadow: 0 8px 18px rgba(32, 32, 74, 0.45);
}
.rkp-header__nav li:hover > .rkp-sub,
.rkp-header__nav li:focus-within > .rkp-sub { display: block; }
.rkp-header__nav .rkp-sub a { display: block; padding: 7px 16px; color: #ffffff; }

/* ---------- Breadcrumb: inline-flex row, never framed-list styling ---------- */
.rkp-breadcrumb ol,
.rkp-crumbs .rkp-crumbs-list,
.rkp-crumbs-list {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  font-size: 0.85rem;
  color: var(--rkp-ink-soft);
}
.rkp-breadcrumb li, .rkp-crumbs-list li { margin: 0; padding: 0; }
.rkp-crumbs-list li + li::before { content: "/"; margin-right: 8px; color: var(--rkp-rule); }
.rkp-breadcrumb a, .rkp-crumbs-list a { color: var(--rkp-coral-deep); text-decoration: none; }

/* ---------- Hero ---------- */
.rkp-hero { padding: 22px 0 6px; }
.rkp-hero h1 { font-size: 2.3rem; margin: 0 0 8px; line-height: 1.15; }
.rkp-hero .rkp-standfirst { font-size: 1.08rem; color: var(--rkp-ink-soft); max-width: 100%; margin: 0; }
.rkp-kicker {
  display: inline-block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--rkp-coral-deep);
  margin: 0 0 4px;
}

/* ---------- Contents bar ---------- */
.rkp-toc {
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  background: var(--rkp-paper-2);
  padding: 14px 18px;
  margin: 20px 0;
}
.rkp-toc ol {
  margin: 0;
  padding: 0 0 0 20px;
  columns: 2;
  column-gap: 32px;
}
.rkp-toc li { margin: 3px 0; }
.rkp-toc a { color: var(--rkp-coral-deep); text-decoration: none; }

/* ---------- Sections ---------- */
.rkp-page section, .entry-content section.rkp-sec { margin: 0 0 26px; }
.rkp-page h2, .entry-content h2 {
  font-size: 1.5rem;
  margin: 30px 0 10px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--rkp-coral);
}
.rkp-page h3, .entry-content h3 { font-size: 1.15rem; margin: 20px 0 8px; }
.rkp-page p, .entry-content p { line-height: 1.65; margin: 0 0 14px; }
.rkp-page ul, .rkp-page ol, .entry-content ul, .entry-content ol { line-height: 1.6; margin: 0 0 14px; padding-left: 22px; }

/* ---------- Tables in scroll wrappers ---------- */
.rkp-tablewrap, .rkp-fig { overflow-x: auto; margin: 16px 0 22px; width: 100%; }
.rkp-tablewrap table, .entry-content table, .rkp-fig table.rkp-fig-table {
  border-collapse: collapse;
  width: 100%;
  min-width: 640px;
  font-variant-numeric: tabular-nums;
  font-size: 0.92rem;
}
.rkp-tablewrap th, .entry-content table th, .rkp-fig table.rkp-fig-table th {
  background: var(--rkp-ink);
  color: #ffffff;
  text-align: left;
  padding: 9px 12px;
  font-weight: 600;
}
.rkp-tablewrap td, .entry-content table td, .rkp-fig table.rkp-fig-table td { padding: 8px 12px; border-bottom: 1px solid var(--rkp-rule); }
.rkp-tablewrap tr:nth-child(even) td, .entry-content table tr:nth-child(even) td, .rkp-fig table.rkp-fig-table tr:nth-child(even) td { background: var(--rkp-paper-2); }
.rkp-table-note { font-size: 0.82rem; color: var(--rkp-ink-soft); margin: 6px 0 0; }
.rkp-fig figcaption, .rkp-fig-table figcaption { font-size: 0.82rem; color: var(--rkp-ink-soft); margin-top: 6px; }

/* ---------- Calculator ---------- */
.rkp-calc {
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  background: #fffdf8;
  padding: 18px;
  margin: 20px 0 26px;
}
.rkp-calc h2, .rkp-calc .rkp-calc-title { margin-top: 0; }
.rkp-calc label { display: block; font-size: 0.88rem; margin: 10px 0 4px; font-weight: 600; }
.rkp-calc input {
  width: 100%;
  max-width: 260px;
  padding: 8px 10px;
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  font-size: 1rem;
  background: #ffffff;
}
.rkp-calc .rkp-calc-result {
  margin-top: 14px;
  padding: 12px 14px;
  background: var(--rkp-ink);
  color: #ffffff;
  border-radius: var(--rkp-radius);
  font-variant-numeric: tabular-nums;
  font-size: 1.02rem;
}
.rkp-calc .rkp-calc-note { font-size: 0.82rem; color: var(--rkp-ink-soft); margin: 10px 0 0; }

/* ---------- FAQ: details/summary family, the site's one markup ---------- */
.rkp-faq details, details.rkp-faq {
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  background: #fffdf8;
  margin: 0 0 10px;
}
.rkp-faq summary, details.rkp-faq summary {
  cursor: pointer;
  font-family: Fraunces, Georgia, serif;
  font-weight: 600;
  padding: 12px 16px;
  color: var(--rkp-ink);
}
.rkp-faq .rkp-faq-a, details.rkp-faq .rkp-faq-a { padding: 0 16px 14px; margin: 0; line-height: 1.6; }
.rkp-faq { margin: 20px 0; }

/* ---------- Aside (licence labelling, one per page) ---------- */
.rkp-licence, .rkp-aside {
  border-left: 4px solid var(--rkp-coral);
  background: var(--rkp-paper-2);
  border-radius: 0 var(--rkp-radius) var(--rkp-radius) 0;
  padding: 14px 18px;
  margin: 22px 0;
  font-size: 0.95rem;
}

/* ---------- Care block ---------- */
.rkp-care {
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  background: #fffdf8;
  padding: 14px 18px;
  margin: 22px 0;
  font-size: 0.92rem;
}

/* ---------- Onward links ---------- */
.rkp-onward { border-top: 1px solid var(--rkp-rule); padding-top: 16px; margin: 26px 0; }
.rkp-onward a { color: var(--rkp-coral-deep); text-decoration: none; font-weight: 600; }

/* ---------- Colophon / footer ---------- */
.rkp-colophon {
  border-top: 2px solid var(--rkp-ink);
  margin-top: 40px;
  padding: 22px 20px 30px;
  font-size: 0.85rem;
  color: var(--rkp-ink-soft);
  text-align: center;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}
.rkp-colophon a { color: var(--rkp-coral-deep); }

/* Board slot output (scorecard cards) */
.rkp-board, .rkp-board-slot-inner { margin: 20px 0 28px; }
.rkp-board__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}
.rkp-card {
  border: 1px solid var(--rkp-rule);
  border-radius: var(--rkp-radius);
  background: #fffdf8;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
}
.rkp-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rkp-card__rank { font-family: Fraunces, Georgia, serif; font-size: 1.6rem; color: var(--rkp-coral-deep); font-weight: 700; }
.rkp-card__brand { font-family: Fraunces, Georgia, serif; font-size: 1.25rem; font-weight: 700; color: var(--rkp-ink); }
.rkp-card__pill {
  background: var(--rkp-coral);
  color: #ffffff;
  border-radius: 999px;
  padding: 3px 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-size: 0.95rem;
  white-space: nowrap;
}
.rkp-card__offer { font-size: 0.95rem; line-height: 1.5; }
.rkp-card__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.rkp-card__chip {
  background: var(--rkp-paper-2);
  border: 1px solid var(--rkp-rule);
  border-radius: 999px;
  font-size: 0.76rem;
  padding: 3px 10px;
  color: var(--rkp-ink-soft);
}
.rkp-card__licence { font-size: 0.78rem; color: var(--rkp-ink-soft); }
.rkp-card__cta {
  display: inline-block;
  margin-top: auto;
  background: var(--rkp-coral);
  color: #ffffff;
  text-align: center;
  text-decoration: none;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: var(--rkp-radius);
}
.rkp-card__cta:hover { background: var(--rkp-coral-deep); }
.rkp-card__meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; }

@media (max-width: 700px) {
  .rkp-toc ol { columns: 1; }
  .rkp-hero h1 { font-size: 1.7rem; }
}