/* Referral pages only. Kept out of css/styles.css deliberately: adding classes
   there would force a ?v= bump on all ~80 HTML files. Tokens and the btn/eyebrow
   classes come from styles.css; everything here is rf- prefixed. */

.rf-wrap { max-width: 960px; margin: 0 auto; padding: 0 24px; }
.rf-lede { font-size: 19px; color: var(--text-2); max-width: 62ch; }
.rf-section { padding-top: 56px; padding-bottom: 56px; border-top: 1px solid var(--hairline); }
.rf-section:first-of-type { border-top: 0; }
.rf-section h2 { font-size: 32px; margin-bottom: 8px; }
.rf-section h3 { font-size: 20px; margin-bottom: 6px; }
.rf-hero { padding-top: 44px; padding-bottom: 40px; }
.rf-hero h1 { font-size: 46px; line-height: 1.08; letter-spacing: -0.02em; margin-bottom: 14px; }
.rf-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.rf-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 26px; }
.rf-step { border: 1px solid var(--hairline); border-radius: 14px; padding: 20px; background: #fff; }
.rf-step__n { font: 700 13px/1 var(--font-head); color: var(--coral); letter-spacing: .08em; }
.rf-step h3 { margin: 10px 0 6px; font-size: 18px; }
.rf-step p { color: var(--text-2); font-size: 15px; }

.rf-tiers { width: 100%; border-collapse: collapse; margin-top: 18px; max-width: 460px; }
.rf-tiers th, .rf-tiers td { padding: 12px 14px; border-bottom: 1px solid var(--hairline); text-align: left; }
.rf-tiers th { font: 600 13px/1.2 var(--font-head); color: var(--text-2); letter-spacing: .04em; text-transform: uppercase; }
.rf-tiers td { font-size: 17px; }
.rf-num { text-align: right; }
.rf-note { margin-top: 14px; color: var(--text-2); font-size: 15px; max-width: 60ch; }

.rf-dates { display: flex; flex-wrap: wrap; gap: 26px; margin-top: 20px; }
.rf-dates div { min-width: 150px; }
.rf-dates dt { font: 600 12px/1.2 var(--font-head); color: var(--text-2); letter-spacing: .05em; text-transform: uppercase; }
.rf-dates dd { font-size: 18px; margin-top: 4px; }

/* Cards, forms */
.rf-card { border: 1px solid var(--hairline); border-radius: 16px; padding: 26px; background: #fff; max-width: 560px; }
.rf-card--wide { max-width: 100%; }
.rf-field { display: block; margin-bottom: 16px; }
.rf-field > span { display: block; font: 600 14px/1.4 var(--font-head); margin-bottom: 6px; }
.rf-field input, .rf-field select {
  width: 100%; padding: 12px 14px; min-height: 44px;
  border: 1px solid var(--chip-border); border-radius: 10px;
  font: 400 16px/1.4 var(--font-body); color: var(--ink); background: #fff;
}
.rf-field input:focus, .rf-field select:focus { outline: 2px solid var(--teal); outline-offset: 1px; }
.rf-field input[aria-invalid="true"], .rf-field select[aria-invalid="true"] { border-color: var(--coral); }
.rf-field input[readonly] { background: var(--hover-row); color: var(--text-2); }
.rf-hint { display: block; margin-top: 6px; color: var(--text-2); font-size: 13px; }
.rf-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.rf-pin { position: relative; }
.rf-pin-toggle {
  position: absolute; right: 8px; bottom: 6px; min-height: 32px; padding: 0 10px;
  border: 1px solid var(--chip-border); border-radius: 8px; background: #fff;
  font: 600 13px/1 var(--font-head); color: var(--text-2); cursor: pointer;
}
.rf-consent { display: flex; gap: 10px; align-items: flex-start; margin: 6px 0 18px; font-size: 15px; }
.rf-consent input { width: 20px; height: 20px; min-width: 20px; margin-top: 2px; }
.rf-msg { margin: 0 0 14px; font-size: 15px; padding: 10px 12px; border-radius: 10px; }
.rf-msg--error { background: #FDECEE; color: #8C2731; }
.rf-msg--ok { background: #E8F7F8; color: #0B6E76; }

/* Auth and portal chrome */
.rf-tabbar { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 22px; border-bottom: 1px solid var(--hairline); }
.rf-tabbar button {
  appearance: none; background: none; border: 0; border-bottom: 2px solid transparent;
  padding: 12px 14px; min-height: 44px; cursor: pointer;
  font: 600 15px/1.2 var(--font-head); color: var(--text-2);
}
.rf-tabbar button.is-active { color: var(--ink); border-bottom-color: var(--coral); }
.rf-portalbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; }
.rf-portalbar__who { font-size: 15px; color: var(--text-2); }
.rf-portalbar__who strong { color: var(--ink); }

/* My code */
.rf-code { display: flex; gap: 26px; flex-wrap: wrap; align-items: flex-start; }
.rf-code__main { flex: 1 1 280px; }
.rf-code__value {
  font: 800 40px/1.1 var(--font-head); letter-spacing: .04em;
  padding: 16px 20px; border: 2px dashed var(--chip-border); border-radius: 14px;
  display: inline-block; background: #fff;
}
.rf-code__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.rf-qr { text-align: center; }
.rf-qr svg { border: 1px solid var(--hairline); border-radius: 12px; }
.rf-qr figcaption { margin-top: 8px; font-size: 13px; color: var(--text-2); max-width: 180px; }

/* Referral list */
.rf-row { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--hairline); }
.rf-row__main strong { display: block; font-size: 17px; }
.rf-row__meta { display: block; margin-top: 3px; color: var(--text-2); font-size: 14px; }
.rf-row__reason { margin-top: 6px; font-size: 14px; color: #8C2731; }
.rf-row__side { text-align: right; white-space: nowrap; }
.rf-row__ref { display: block; margin-top: 6px; color: var(--muted); font-size: 13px; }
.rf-empty { color: var(--text-2); padding: 18px 0; }

/* Status pills. Colours follow the agreed vocabulary. */
.rf-pill {
  display: inline-block; padding: 4px 10px; border-radius: 999px;
  font: 600 12px/1.5 var(--font-head); border: 1px solid transparent; white-space: nowrap;
}
.rf-pill--received, .rf-pill--contacted, .rf-pill--in_discussion,
.rf-pill--eligible { background: #EAF1FB; color: #23486F; }
.rf-pill--order_placed, .rf-pill--payment_received,
.rf-pill--approved { background: #FDF1DC; color: #7A5210; }
.rf-pill--reward_confirmed, .rf-pill--paid { background: #E4F6EA; color: #1C6B3C; }
.rf-pill--did_not_proceed, .rf-pill--void { background: var(--hover-row); color: var(--text-2); }
.rf-pill--not_eligible { background: #FDECEE; color: #8C2731; }
.rf-pill--under_review { background: #fff; color: #7A5210; border-color: #E4C580; }

/* Earnings */
.rf-progress { margin: 8px 0 22px; }
.rf-progress__track { height: 10px; border-radius: 999px; background: var(--hover-row); overflow: hidden; }
.rf-progress__bar { height: 100%; background: var(--teal); width: 0; transition: width .3s ease; }
.rf-progress__labels { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; font-size: 15px; }
.rf-progress__labels strong { font-family: var(--font-head); }
.rf-totals { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 20px 0 26px; }
.rf-total { border: 1px solid var(--hairline); border-radius: 12px; padding: 14px; background: #fff; }
.rf-total dt { font: 600 12px/1.2 var(--font-head); color: var(--text-2); letter-spacing: .04em; text-transform: uppercase; }
.rf-total dd { font: 700 22px/1.2 var(--font-head); margin-top: 6px; }
.rf-tablewrap { overflow-x: auto; }
.rf-lines { width: 100%; border-collapse: collapse; min-width: 620px; }
.rf-lines th, .rf-lines td { padding: 10px 12px; border-bottom: 1px solid var(--hairline); text-align: left; font-size: 14px; }
.rf-lines th { font: 600 12px/1.2 var(--font-head); color: var(--text-2); letter-spacing: .04em; text-transform: uppercase; }
.rf-foot { margin-top: 14px; color: var(--text-2); font-size: 14px; }
.rf-payout { margin-top: 22px; border: 1px solid var(--hairline); border-radius: 12px; padding: 16px; background: var(--hover-row); }
.rf-payout h3 { font-size: 16px; margin-bottom: 6px; }
.rf-payout p { font-size: 14px; color: var(--text-2); }

/* Verdict card */
.rf-verdict { border-radius: 14px; padding: 18px 20px; border: 1px solid var(--hairline); margin-bottom: 16px; }
.rf-verdict strong { display: block; font: 700 19px/1.3 var(--font-head); margin-bottom: 4px; }
.rf-verdict p { font-size: 15px; }
.rf-verdict--ok { background: #E4F6EA; border-color: #B6E0C5; }
.rf-verdict--review { background: #FDF1DC; border-color: #E4C580; }
.rf-verdict--no { background: #FDECEE; border-color: #F3C2C7; }

/* FAQ reuses the site's <details> pattern */
.rf-faq { max-width: 760px; margin-top: 20px; }
.rf-faq details { border-bottom: 1px solid var(--hairline); padding: 16px 0; }
.rf-faq summary { cursor: pointer; font: 600 17px/1.4 var(--font-head); list-style: none; min-height: 32px; }
.rf-faq summary::-webkit-details-marker { display: none; }
.rf-faq p { margin-top: 10px; color: var(--text-2); }

/* Terms */
.rf-terms { max-width: 760px; }
.rf-terms h2 { font-size: 24px; margin: 30px 0 8px; }
.rf-terms p, .rf-terms li { color: var(--text-2); margin-bottom: 10px; }
.rf-terms ul { list-style: disc; padding-left: 22px; }
.rf-terms .rf-pending { background: #FDF1DC; padding: 2px 6px; border-radius: 6px; color: #7A5210; }

.rf-offline { background: #FDF1DC; color: #7A5210; padding: 10px 24px; font-size: 14px; text-align: center; }
.rf-crumbs { padding-top: 18px; font-size: 14px; color: var(--text-2); }
.rf-crumbs a { color: var(--teal); }

@media (max-width: 860px) {
  .rf-steps { grid-template-columns: 1fr; }
  .rf-totals { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .rf-wrap { padding: 0 18px; }
  .rf-hero h1 { font-size: 32px; }
  .rf-section h2 { font-size: 26px; }
  .rf-code__value { font-size: 30px; }
  .rf-grid2 { grid-template-columns: 1fr; }
  .rf-code { gap: 20px; }
  .rf-qr { width: 100%; }
  .rf-qr figcaption { max-width: none; }
}

/* ============================================================================
   Landing-page creative (rebuilt 5 Sep 2026 for conversion). The 4 Sep cut
   was accurate and long: the same three numbers appeared in five places, two
   CTAs competed in the hero, and on a phone the primary button sat at the
   very bottom of the first screen underneath the site-wide "Book a demo" bar,
   which is a prospect's CTA and means nothing to a retailer who already owns
   the POS. This pass does four things: one dark hero with one button, a
   page-owned sticky bar, one section that carries the money, and copy short
   enough to be read standing at a counter. Still rf- prefixed, still on the
   site's tokens; the dark treatment reuses the hero--video palette.
   ========================================================================== */

.rf-subhead { font: 700 20px/1.3 var(--font-head); margin: 26px 0 14px; }

/* These two are prospect-facing sales channels (the FAB's prefilled text is
   "I'm interested in your POS system"). On pages for existing customers they
   are noise, and on a 390px screen the FAB sat on top of the reward ladder. */
.wa-float { display: none; }

/* Page-owned sticky bar: one action, full width. Inherits the fixed/flex
   behaviour and the <=1024px breakpoint from .sticky-cta in styles.css. */
.rf-sticky { padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); }
.rf-sticky__go {
  flex: 1; display: block; text-align: center; text-decoration: none;
  background: var(--coral); color: #fff; border-radius: 100px; padding: 12px 0 11px;
  font: 700 16px/1.2 var(--font-body);
}
.rf-sticky__go small { display: block; font: 500 12px/1.3 var(--font-body); opacity: .92; margin-top: 2px; }

/* ---- dark hero ---- */
.rf-dark { background: var(--ink); color: #fff; }
.rf-dark .rf-crumbs { color: rgba(255, 255, 255, .5); padding-top: 16px; }
.rf-dark .rf-crumbs a { color: #7FDDE6; }
.rf-dark .eyebrow { color: #FF98A0; }
.rf-dark h1 { color: #fff; }
.rf-dark .rf-lede { color: rgba(255, 255, 255, .84); font-size: 20px; max-width: 46ch; }
.rf-hero--lead { padding-top: 22px; padding-bottom: 46px; }
.rf-split { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.rf-hero h1 .rf-amt { color: #5EDCE6; white-space: nowrap; }
.rf-hero--lead h1 { font-size: 52px; }

.rf-cta-main { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 28px; }
.rf-dark .btn--coral { padding: 17px 38px; font-size: 17px; }
.rf-dark .btn--coral:hover { background: #fff; color: var(--ink); }
.rf-track { font: 500 15px/1.4 var(--font-body); color: rgba(255, 255, 255, .78); text-decoration: underline; text-underline-offset: 3px; }
.rf-track:hover { color: #fff; }

/* Trust row: three short facts, one line, under the button not above it. */
.rf-trust { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 24px 0 0; padding: 0; list-style: none; }
.rf-trust li { font: 500 14px/1.4 var(--font-body); color: rgba(255, 255, 255, .8); }
.rf-trust li::before { content: "\2713"; color: #5EDCE6; margin-right: 8px; font-weight: 700; }

/* Reward ladder, rendered from GET /programme so a band change on the CRM
   side shows up here without a deploy. Cards are white on the dark ground. */
.rf-ladder { display: flex; flex-direction: column; gap: 10px; }
.rf-rung {
  display: flex; justify-content: space-between; align-items: baseline; gap: 14px;
  border-radius: 14px; background: #fff; color: var(--ink); padding: 15px 18px;
  border: 1.5px solid transparent;
}
.rf-rung:nth-child(1) { margin-right: 32px; }
.rf-rung:nth-child(2) { margin-right: 16px; }
.rf-rung--top { border-color: #5EDCE6; box-shadow: 0 0 0 4px rgba(94, 220, 230, .18); }
.rf-rung__when { font: 600 13px/1.3 var(--font-head); color: var(--text-2); }
.rf-rung__amt { font: 800 26px/1 var(--font-head); letter-spacing: -.01em; }
.rf-rung--top .rf-rung__amt { color: var(--teal); }
.rf-ladder__foot { margin-top: 12px; font-size: 13px; color: rgba(255, 255, 255, .6); }

/* ---- what you earn: the one section that carries the money ---- */
.rf-calc {
  border: 1px solid var(--hairline); border-radius: 20px; background: #fff;
  padding: 30px 32px; margin-top: 22px; max-width: 720px;
}
.rf-calc__out { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; }
.rf-calc__total { font: 800 clamp(46px, 9vw, 70px)/1 var(--font-head); letter-spacing: -.03em; color: var(--ink); }
.rf-calc__rate { font: 600 16px/1.4 var(--font-head); color: var(--text-2); }
.rf-calc__topup {
  margin-top: 12px; font-size: 15px; color: #0B6E76;
  background: #E8F7F8; border-radius: 10px; padding: 9px 13px; display: inline-block;
}
.rf-calc__ctrl { margin-top: 24px; }
.rf-calc__ctrl label { display: block; font: 600 14px/1.4 var(--font-head); margin-bottom: 12px; }
.rf-calc__scale { display: flex; justify-content: space-between; margin-top: 8px; font-size: 12px; color: var(--muted); }

.rf-range { --fill: 0%; -webkit-appearance: none; appearance: none; width: 100%; height: 30px; background: none; cursor: pointer; display: block; }
.rf-range:focus-visible { outline: 2px solid var(--teal); outline-offset: 4px; border-radius: 8px; }
.rf-range::-webkit-slider-runnable-track {
  height: 8px; border-radius: 999px;
  background: linear-gradient(to right, var(--teal) var(--fill), var(--hover-row) var(--fill));
}
.rf-range::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 28px; height: 28px; margin-top: -10px; border-radius: 50%;
  background: #fff; border: 3px solid var(--teal); box-shadow: 0 2px 6px rgba(20, 32, 47, .18);
}
.rf-range::-moz-range-track { height: 8px; border-radius: 999px; background: var(--hover-row); }
.rf-range::-moz-range-progress { height: 8px; border-radius: 999px; background: var(--teal); }
.rf-range::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 3px solid var(--teal); box-shadow: 0 2px 6px rgba(20, 32, 47, .18); }

/* The retroactive rule in one sentence with the number in it, not a diagram. */
.rf-rule { display: flex; gap: 14px; align-items: flex-start; margin-top: 20px; max-width: 720px; padding: 16px 18px; border-radius: 14px; background: var(--hover-row); }
.rf-rule__mark { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--teal); color: #fff; font: 800 18px/34px var(--font-head); text-align: center; }
.rf-rule p { margin: 0; font-size: 15px; }
.rf-rule strong { font-family: var(--font-head); }

/* ---- how it works: three steps in one strip ---- */
.rf-flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 24px; }
.rf-flow__step { display: flex; gap: 13px; align-items: flex-start; }
.rf-flow__n { flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--coral); color: #fff; font: 800 15px/32px var(--font-head); text-align: center; }
.rf-flow__step h3 { font: 700 17px/1.3 var(--font-head); margin: 4px 0 4px; }
.rf-flow__step p { font-size: 14.5px; color: var(--text-2); margin: 0; }

/* ---- three reasons ---- */
.rf-benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 22px; }
.rf-benefit { border: 1px solid var(--hairline); border-radius: 14px; padding: 18px 20px; background: #fff; }
.rf-benefit h3 { font: 700 16.5px/1.3 var(--font-head); margin-bottom: 6px; }
.rf-benefit p { font-size: 14.5px; color: var(--text-2); margin: 0; }

/* ---- closing band ---- */
.rf-band { border-radius: 20px; background: var(--ink); color: #fff; padding: 36px 34px; margin: 8px 0 56px; }
.rf-band h2 { color: #fff; font-size: 30px; margin-bottom: 8px; }
.rf-band p { color: #C6CFDA; max-width: 54ch; font-size: 16px; }
.rf-band .rf-ctas { margin-top: 22px; }
.rf-band .btn--coral:hover { background: #fff; color: var(--ink); }
.rf-band .btn--outline { border-color: rgba(255, 255, 255, .55); color: #fff; }
.rf-band .btn--outline:hover { background: #fff; color: var(--ink); border-color: #fff; }

/* ---- register page: the reward stays in view while the form is filled ---- */
.rf-reward { display: flex; align-items: center; gap: 14px; background: var(--ink); color: #fff; border-radius: 14px; padding: 14px 18px; margin: 20px 0 0; }
.rf-reward strong { font: 800 24px/1 var(--font-head); color: #5EDCE6; white-space: nowrap; }
.rf-reward span { font-size: 14.5px; color: rgba(255, 255, 255, .86); }
.rf-terms-line { margin-top: 12px; font-size: 13px; color: var(--text-2); text-align: center; }
.rf-terms-line a { color: var(--teal); }

@media (max-width: 860px) {
  .rf-split { grid-template-columns: 1fr; gap: 28px; }
  .rf-rung:nth-child(1), .rf-rung:nth-child(2) { margin-right: 0; }
  .rf-flow, .rf-benefits { grid-template-columns: 1fr; }
  .rf-flow { gap: 18px; }
  .rf-hero--lead h1 { font-size: 40px; }
}
@media (max-width: 640px) {
  .rf-hero--lead { padding-top: 16px; padding-bottom: 34px; }
  .rf-hero--lead h1 { font-size: 34px; }
  .rf-dark .rf-lede { font-size: 17px; }
  .rf-dark .btn--coral { width: 100%; padding: 16px 20px; }
  .rf-cta-main { gap: 12px; }
  .rf-track { width: 100%; text-align: center; }
  .rf-trust { gap: 6px 16px; }
  .rf-trust li { font-size: 13.5px; }
  /* On a phone the ladder is a compact three-row strip, not three stacked cards. */
  .rf-ladder { flex-direction: row; gap: 8px; }
  .rf-rung { flex: 1; flex-direction: column; align-items: flex-start; gap: 4px; padding: 12px 12px; }
  .rf-rung__when { font-size: 11.5px; }
  .rf-rung__amt { font-size: 19px; }
  .rf-calc { padding: 22px 18px; border-radius: 16px; }
  .rf-band { padding: 26px 20px; }
  .rf-band h2 { font-size: 24px; }
  .rf-reward { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* The section right under the dark hero should not open with a hairline. */
.rf-dark + .rf-section { border-top: 0; }
