/* CloudStream /pay/ — design option 5 of 5: "BIG TOUCH TILES" (Stadium V3 look).
   Drop-in replacement for cs-pay-20260927.css — CSS only: every id, class, text and script of
   /pay/index.php and /pay/pay.js is untouched.
   Layout: the story column is dissolved (display: contents) into one page grid —
     1. a compact band: headline + lead + the three benefits (price first) as a row,
     2. the form as a grid of large touch tiles: price scoreboard, a hero Device ID tile with a
        huge monospace code field (8 drawn character cells) and a big counter/status box,
        email + WhatsApp side by side, two big square payment tiles, the policy + consent as one
        tile with a 56px checkbox, and a very tall lime submit,
     3. the after-payment steps + licence notice below the form.
   Tile numbers are CSS counters (numbers/symbols only, no words). Every touch target >= 56px.
   The Hotmart checkout window (.csx-*) keeps the same colour-only overrides as the live sheet.
   Deployed next to fonts/ in /wp-content/uploads/cs-home-option1/stadium/. */

/* ---------- Barlow + Barlow Condensed (SIL Open Font License), self-hosted latin subset ---------- */
@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/barlow-400.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/barlow-500.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/barlow-600.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/barlow-700.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/barlow-condensed-700-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: italic;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/barlow-condensed-800-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/barlow-condensed-700.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/barlow-condensed-800.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens (homepage values, verbatim) ---------- */
:root {
  --bg: #0A0F1F;
  --s1: #111A33;
  --s2: #17223F;
  --line: #26335A;
  --line2: #33426E;
  --hair: #1B2647;
  --foot: #060A15;
  --text: #F2F5FF;
  --soft: #C9D1E8;
  --muted: #A3AECB;
  --acc: #C8FF2E;
  --acc-hi: #DBFF6E;
  --acc-ink: #0A0F1F;
  --acc2: #2B59E0;
  --acc2-hi: #3D6BF0;
  --deco: #3D7BFF;
  --wa: #25D366;
  --cond: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Barlow", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, "Courier New", monospace;
  --skew: -12deg;
  /* page-only state colours, all >= 6:1 on the dark panels */
  --err: #FF8A8A;
  --info: #8AB0FF;
  --warn: #FFC24B;
  --ph: #7A87AD;
  --hdr: 76px;
  --gut: clamp(20px, 3.4vw, 48px);
  /* option 5: tile system */
  --col-a: 620px;   /* headline / steps column */
  --col-b: 460px;   /* lead / notice column (a + b = form width) */
  --tg: 14px;       /* gap between tiles */
  --tp: 26px;       /* tile padding */
  --touch: 56px;    /* minimum touch target */
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--hdr) + 20px);
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: var(--acc);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--acc-hi);
}

/* big, obvious focus for keyboard and TV-remote (D-pad) users */
a:focus-visible,
button:focus-visible,
input[type="checkbox"]:focus-visible {
  outline: 4px solid var(--acc);
  outline-offset: 4px;
}

i[class*="fa-"] {
  font-style: normal;
}

/* ---------- Sticky header: dark bar + logo + condensed italic wordmark ---------- */
body::before {
  content: "";
  position: fixed;
  z-index: 60;
  top: 0;
  left: 0;
  right: 0;
  height: var(--hdr);
  background: var(--bg);
  border-bottom: 1px solid var(--hair);
  pointer-events: none;
}

.brand {
  position: fixed;
  z-index: 61;
  top: 0;
  left: var(--gut);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: max-content;
  height: var(--hdr);
  color: var(--text);
  text-decoration: none;
  font-family: var(--cond);
  font-size: 30px;
  font-weight: 800;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.brand:hover {
  color: var(--text);
}

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
}

/* "Pay" becomes a small lime scoreboard tag */
.brand span {
  position: relative;
  isolation: isolate;
  margin-left: 4px;
  padding: 5px 11px 4px;
  font-size: 19px;
  letter-spacing: 0.08em;
  color: var(--acc-ink);
}

.brand span::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--acc);
  transform: skewX(var(--skew));
}

/* =====================================================================
   Page grid. The two story wrappers are dissolved so their children join this grid:
   band (h1 | lead, benefits) -> form -> steps | notice.
   ===================================================================== */
.pay-layout {
  display: grid;
  grid-template-columns:
    minmax(var(--gut), 1fr)
    minmax(0, var(--col-a))
    minmax(0, var(--col-b))
    minmax(var(--gut), 1fr);
  grid-template-areas:
    ".    h1    lead  ."
    ".    ben   ben   ."
    "form form  form  form"
    ".    steps note  .";
  align-items: start;
  padding-top: var(--hdr);
  overflow-x: clip;
  background: var(--bg);
}

.story-panel,
.story-main {
  display: contents;
}

/* the band's background (a grid item under the headline rows) */
.pay-layout::before {
  content: "";
  grid-column: 1 / -1;
  grid-row: h1-start / ben-end;
  align-self: stretch;
  background:
    radial-gradient(60% 140% at 0% 100%, rgba(43, 89, 224, 0.22) 0%, rgba(43, 89, 224, 0) 62%),
    radial-gradient(45% 120% at 100% 0%, rgba(61, 123, 255, 0.12) 0%, rgba(61, 123, 255, 0) 70%),
    var(--bg);
  border-bottom: 1px solid var(--hair);
}

/* the lower band behind steps + notice (painted first: order -1) */
.pay-layout::after {
  content: "";
  order: -1;
  grid-column: 1 / -1;
  grid-row: steps-start / note-end;
  align-self: stretch;
  background: linear-gradient(180deg, var(--foot) 0%, var(--bg) 100%);
  border-top: 1px solid var(--hair);
}

/* ---------- Band: headline + lead ---------- */
h1 {
  grid-area: h1;
  align-self: end;
  max-width: none;
  margin: clamp(30px, 3vw, 44px) 28px 0 0;
  font-family: var(--cond);
  font-size: clamp(46px, 4.1vw, 60px);
  font-weight: 800;
  font-style: italic;
  line-height: 0.9;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  text-wrap: balance;
  color: var(--text);
}

h1::before {
  content: "";
  display: block;
  width: 56px;
  height: 5px;
  margin: 0 0 18px 4px;
  background: var(--acc);
  transform: skewX(var(--skew));
}

h1 em,
h1 strong {
  font-style: inherit;
  font-weight: inherit;
  color: var(--acc);
}

.lifetime-words {
  white-space: nowrap;
}

.lead {
  grid-area: lead;
  align-self: end;
  max-width: 50ch;
  margin: 0 0 2px;
  color: var(--soft);
  font-size: 16px;
  line-height: 1.55;
}

/* ---------- Band: benefits as one row of three tiles, price first ---------- */
.benefits {
  grid-area: ben;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: none;
  margin: 26px 0 clamp(26px, 2.6vw, 34px);
}

.benefit {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 76px;
  padding: 12px 16px 12px 12px;
  background: rgba(17, 26, 51, 0.78);
  border: 1px solid var(--line);
}

.benefit:first-child {
  background:
    linear-gradient(90deg, rgba(200, 255, 46, 0.1) 0%, rgba(200, 255, 46, 0) 75%),
    var(--s1);
  border-color: rgba(200, 255, 46, 0.5);
}

.benefit-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--acc);
  font-size: 19px;
}

.benefit:first-child .benefit-icon {
  background: var(--acc);
  border-color: var(--acc);
  color: var(--acc-ink);
}

.benefit-copy {
  min-width: 0;
  padding: 0;
}

.benefit-copy b {
  display: block;
  font-family: var(--cond);
  font-size: 21px;
  font-weight: 800;
  font-style: italic;
  line-height: 1.08;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text);
}

.benefit:first-child .benefit-copy b {
  font-size: 25px;
}

.benefit-copy b .teal {
  display: inline;
  margin: 0;
  font-size: inherit;
  color: var(--acc);
}

.benefit-copy > span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.35;
}

/* ---------- Below the form: after-payment steps ---------- */
.activation-steps {
  grid-area: steps;
  margin: clamp(36px, 3.6vw, 52px) 36px clamp(40px, 4vw, 60px) 0;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 24px;
  font-family: var(--cond);
  font-size: 17px;
  font-weight: 800;
  font-style: italic;
  line-height: 1.2;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--acc);
}

.eyebrow::before {
  content: "";
  flex-shrink: 0;
  width: 34px;
  height: 3px;
  background: currentColor;
  transform: skewX(var(--skew));
}

.steps-row {
  display: grid;
  grid-template-columns: 1fr 30px 1fr 30px 1fr;
  align-items: start;
}

.step {
  position: relative;
  text-align: center;
  color: var(--soft);
  font-size: 15px;
  line-height: 1.4;
}

.step-icon {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  margin: 0 auto 12px;
  background: var(--s1);
  border: 1px solid var(--line);
  color: var(--acc);
  font-size: 22px;
}

.step-number {
  position: absolute;
  top: -9px;
  left: calc(50% - 41px);
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  background: var(--acc);
  color: var(--acc-ink);
  font-family: var(--cond);
  font-size: 16px;
  font-weight: 800;
  font-style: italic;
  line-height: 1;
}

.step-arrow {
  padding-top: 20px;
  color: var(--line2);
  text-align: center;
}

/* ---------- Below the form: licence notice ---------- */
.media-notice {
  grid-area: note;
  position: relative;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  margin: clamp(36px, 3.6vw, 52px) 0 clamp(40px, 4vw, 60px);
  padding: 20px 22px;
  background: var(--s1);
  border: 1px solid var(--line);
  color: var(--soft);
  font-size: 14.5px;
  line-height: 1.55;
}

.media-notice::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  width: 48px;
  height: 4px;
  background: var(--deco);
}

.media-notice i {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--acc);
  font-size: 17px;
}

.media-notice strong {
  color: var(--text);
}

/* =====================================================================
   The form: a grid of large touch tiles
   ===================================================================== */
.checkout-panel {
  grid-area: form;
  display: block;
  padding: clamp(28px, 2.8vw, 40px) var(--gut) clamp(36px, 3.6vw, 52px);
  background: none;
}

.checkout-form {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--tg);
  width: 100%;
  max-width: calc(var(--col-a) + var(--col-b));
  margin: 0 auto;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  counter-reset: tile;
}

.checkout-form::before {
  content: none;
}

.checkout-form > * {
  grid-column: 1 / -1;
  min-width: 0;
}

/* tile numbers (CSS counters: numbers / symbols only) */
.field > label::before,
.methods-title::before,
.purchase-policy > strong::before {
  counter-increment: tile;
  content: counter(tile, decimal-leading-zero);
  content: counter(tile, decimal-leading-zero) / "";
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  min-width: 40px;
  height: 30px;
  padding: 0 8px 0 6px;
  background: var(--acc);
  color: var(--acc-ink);
  font-family: var(--cond);
  font-size: 19px;
  font-weight: 800;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.02em;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}

/* ---------- Price scoreboard, big, at the top of the form ---------- */
.price-heading {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 30px;
  margin: 0 16px 2px;
  padding: 18px 36px 16px;
}

.price-heading::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(200, 255, 46, 0.08) 0%, rgba(200, 255, 46, 0) 55%),
    var(--s1);
  border: 1px solid var(--line2);
  transform: skewX(var(--skew));
}

.price-heading::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 14px;
  width: 72px;
  height: 5px;
  background: var(--acc);
  transform: skewX(var(--skew));
}

.price-heading b {
  font-family: var(--cond);
  font-size: clamp(64px, 7vw, 100px);
  font-weight: 800;
  font-style: italic;
  line-height: 0.95;
  letter-spacing: 0.005em;
  color: var(--acc);
  white-space: nowrap;
}

.price-heading b span {
  color: var(--soft);
}

.price-copy strong {
  display: block;
  font-family: var(--cond);
  font-size: clamp(28px, 2.8vw, 40px);
  font-weight: 800;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.price-copy span {
  display: block;
  margin-top: 6px;
  color: var(--soft);
  font-size: 17px;
  line-height: 1.3;
}

/* ---------- Field tiles ---------- */
.field {
  position: relative;
  margin: 0;
  padding: 22px 24px 24px;
  background: var(--s1);
  border: 1px solid var(--line);
  transition: border-color 0.15s ease;
}

/* short bar on the tile's top edge: lights up lime while the tile is in use */
.field::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  width: 56px;
  height: 5px;
  background: var(--line2);
  transition: background-color 0.15s ease;
}

.field:focus-within {
  border-color: var(--line2);
}

.field:focus-within::before {
  background: var(--acc);
}

.field > label {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin: 0 0 14px;
  font-family: var(--cond);
  font-size: 19px;
  font-weight: 800;
  font-style: italic;
  line-height: 1.15;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text);
  cursor: pointer;
}

.field > label span {
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.input-wrap {
  position: relative;
}

.field input {
  display: block;
  width: 100%;
  min-height: 64px;
  margin: 0;
  padding: 16px 18px;
  background: var(--foot);
  border: 2px solid var(--line2);
  border-radius: 0;
  color: var(--text);
  font-family: var(--body);
  font-size: 18px;
  outline: 0;
  box-shadow: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input::placeholder {
  color: var(--ph);
  opacity: 1;
}

.field input:hover {
  border-color: #3F5184;
}

.field input:focus {
  border-color: var(--acc);
  box-shadow: 0 0 0 4px rgba(200, 255, 46, 0.16);
}

.hint {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

/* email (col 1) + WhatsApp (col 2) side by side */
.price-heading + .field + .field {
  grid-column: 1 / 2;
}

.price-heading + .field + .field + .field {
  grid-column: 2 / 3;
}

/* WhatsApp is optional: "+" tag instead of a number */
.price-heading + .field + .field + .field > label::before {
  counter-increment: none;
  content: "+";
  content: "+" / "";
  background: var(--line2);
  color: var(--text);
}

/* =====================================================================
   HERO tile: the Device ID — huge monospace code field with 8 drawn cells
   ===================================================================== */
.price-heading + .field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "label label"
    "input meta"
    "hint  hint"
    "msg   msg";
  column-gap: 12px;
  padding: 26px 28px 28px;
  background:
    radial-gradient(70% 140% at 0% 0%, rgba(43, 89, 224, 0.2) 0%, rgba(43, 89, 224, 0) 60%),
    var(--s1);
  border: 1px solid var(--line2);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
}

.price-heading + .field::before {
  width: 110px;
  height: 6px;
  background: var(--acc);
}

.price-heading + .field > label {
  grid-area: label;
  font-size: clamp(21px, 2.1vw, 27px);
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.price-heading + .field .input-wrap {
  display: contents;
}

#pay-device-id {
  /* cell geometry in ch of the input's own mono font: pitch = 1ch glyph + letter-spacing */
  --ls: 0.62ch;
  --pitch: calc(1ch + var(--ls));
  --cell: calc(var(--pitch) - 0.24ch);
  --off: calc((1ch - var(--cell)) / 2);
  --u: var(--line2);                       /* cell underline */
  --f: rgba(201, 209, 232, 0.06);          /* cell fill */
  grid-area: input;
  min-height: 112px;
  padding: 16px 24px;
  background-color: var(--foot);
  background-repeat: no-repeat;
  background-origin: content-box;
  border-width: 3px;
  caret-color: var(--acc);
  font-family: var(--mono);
  font-size: clamp(30px, 9vw, 58px);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: var(--ls);
  text-transform: uppercase;
}

/* once something is typed, the 8 character boxes appear (Firestick-style code entry) */
#pay-device-id:not(:placeholder-shown) {
  background-image:
    repeating-linear-gradient(90deg, var(--u) 0 var(--cell), transparent var(--cell) var(--pitch)),
    repeating-linear-gradient(90deg, var(--f) 0 var(--cell), transparent var(--cell) var(--pitch));
  background-size: calc(var(--pitch) * 8) 4px, calc(var(--pitch) * 8) 1.3em;
  background-position: var(--off) calc(50% + 0.65em - 2px), var(--off) 50%;
}

#pay-device-id:focus {
  --u: #5A6CA0;
}

/* while empty, the field uses the placeholder's size so the hint text sits centred
   (the box keeps its height through min-height, so nothing jumps when typing starts) */
#pay-device-id:placeholder-shown {
  font-size: clamp(16px, 1.7vw, 21px);
}

#pay-device-id::placeholder {
  font-family: var(--body);
  font-size: clamp(16px, 1.7vw, 21px);
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: none;
}

/* the field follows the server's Device ID answer (progressive; ignored without :has) */
.input-wrap:has(.pay-device-status.is-valid) #pay-device-id {
  --u: var(--acc);
  --f: rgba(200, 255, 46, 0.09);
  border-color: var(--acc);
}

.input-wrap:has(.pay-device-status.is-invalid) #pay-device-id {
  --u: var(--err);
  --f: rgba(255, 138, 138, 0.08);
  border-color: var(--err);
}

.input-wrap:has(.pay-device-status.is-already-lifetime) #pay-device-id,
.input-wrap:has(.pay-device-status.is-reseller) #pay-device-id {
  --u: var(--info);
  --f: rgba(138, 176, 255, 0.08);
  border-color: var(--info);
}

.input-wrap:has(.pay-device-status.is-valid) #pay-device-id:focus {
  box-shadow: 0 0 0 4px rgba(200, 255, 46, 0.16);
}

.input-wrap:has(.pay-device-status.is-invalid) #pay-device-id:focus {
  box-shadow: 0 0 0 4px rgba(255, 138, 138, 0.18);
}

.input-wrap:has(.pay-device-status.is-already-lifetime) #pay-device-id:focus,
.input-wrap:has(.pay-device-status.is-reseller) #pay-device-id:focus {
  box-shadow: 0 0 0 4px rgba(138, 176, 255, 0.18);
}

/* big counter + live status box next to the code field */
.input-meta {
  grid-area: meta;
  position: static;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 132px;
  padding: 10px 18px;
  background: var(--foot);
  border: 3px solid var(--line2);
  color: var(--soft);
  font-family: var(--cond);
  font-size: 36px;
  font-weight: 800;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.04em;
  transform: none;
  pointer-events: none;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.pay-device-status {
  display: none;
  font-size: 34px;
}

.pay-device-status.is-checking,
.pay-device-status.is-valid,
.pay-device-status.is-invalid,
.pay-device-status.is-already-lifetime,
.pay-device-status.is-reseller {
  display: inline-block;
}

.pay-device-status.is-checking { color: var(--muted); }
.pay-device-status.is-valid { color: var(--acc); }
.pay-device-status.is-invalid { color: var(--err); }
.pay-device-status.is-already-lifetime,
.pay-device-status.is-reseller { color: var(--info); }

.input-meta:has(.is-valid) {
  border-color: var(--acc);
  color: var(--acc);
  background: rgba(200, 255, 46, 0.07);
}

.input-meta:has(.is-invalid) {
  border-color: var(--err);
  color: var(--err);
}

.input-meta:has(.is-already-lifetime),
.input-meta:has(.is-reseller) {
  border-color: var(--info);
  color: var(--info);
}

.price-heading + .field .hint {
  grid-area: hint;
  margin-top: 14px;
  font-size: 15px;
}

.pay-device-msg {
  grid-area: msg;
  display: none;
  margin: 14px 0 0;
  padding: 14px 18px;
  background: rgba(255, 138, 138, 0.08);
  border-left: 5px solid var(--err);
  color: var(--err);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.45;
}

.pay-device-msg.is-visible {
  display: block;
}

.pay-device-msg.is-info {
  background: rgba(138, 176, 255, 0.08);
  border-left-color: var(--info);
  color: var(--info);
}

/* ---------- Payment methods: two big square tiles ---------- */
.methods {
  margin: 12px 0 0;
  padding: 0;
  border: 0;
}

.methods-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
  font-family: var(--cond);
  font-size: clamp(24px, 2.4vw, 30px);
  font-weight: 800;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text);
}

.method-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--tg);
}

.method-button {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 250px;
  margin: 0;
  padding: 30px 22px 26px;
  background: var(--s1);
  border: 2px solid var(--line2);
  border-radius: 0;
  color: var(--text);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.method-button:hover {
  border-color: var(--deco);
}

.method-button.is-on {
  background:
    linear-gradient(180deg, rgba(200, 255, 46, 0.15) 0%, rgba(200, 255, 46, 0.03) 65%),
    var(--s2);
  border-color: var(--acc);
  box-shadow: inset 0 0 0 2px var(--acc), 0 18px 44px rgba(200, 255, 46, 0.1);
}

.method-button.is-on::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  height: 8px;
  background: var(--acc);
}

.method-button:focus-visible {
  outline: 4px solid var(--acc);
  outline-offset: 4px;
}

.method-radio {
  position: absolute;
  top: 18px;
  right: 18px;
  color: var(--muted);
  font-size: 30px;
  line-height: 1;
}

.method-button.is-on .method-radio {
  color: var(--acc);
}

.method-main-icon {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--soft);
  font-size: 42px;
  text-align: center;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.method-button.is-on .method-main-icon {
  background: var(--acc);
  border-color: var(--acc);
  color: var(--acc-ink);
}

.method-copy {
  min-width: 0;
  max-width: 100%;
}

.method-copy strong {
  display: block;
  font-family: var(--cond);
  font-size: clamp(24px, 2.6vw, 32px);
  font-weight: 800;
  font-style: italic;
  line-height: 1.02;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.method-copy span {
  display: block;
  margin-top: 6px;
  color: var(--soft);
  font-size: 15px;
  line-height: 1.35;
}

/* brand logos sit on light tiles so Visa/PayPal blues stay legible on the dark panel */
.payment-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 2px;
}

.payment-logos img {
  display: block;
  width: 54px;
  height: 36px;
  max-width: none;
  max-height: none;
  padding: 7px 8px;
  background: var(--text);
  object-fit: contain;
}

.payment-logos .wide {
  width: 60px;
  max-width: none;
}

/* ---------- Policy + consent: one tile (policy on top, a big tick area below) ---------- */
.purchase-policy {
  position: relative;
  margin: 12px 0 0;
  padding: 24px 28px 22px;
  background:
    linear-gradient(0deg, rgba(255, 194, 75, 0.06), rgba(255, 194, 75, 0.06)),
    var(--s1);
  border: 2px solid var(--line2);
  border-bottom: 0;
  color: var(--soft);
  font-size: 14.5px;
  line-height: 1.6;
  transition: border-color 0.15s ease;
}

.purchase-policy::after {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  width: 72px;
  height: 5px;
  background: var(--warn);
}

.purchase-policy strong {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-bottom: 10px;
  font-family: var(--cond);
  font-size: clamp(20px, 2vw, 24px);
  font-weight: 800;
  font-style: italic;
  line-height: 1.15;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--warn);
}

.purchase-policy strong i {
  margin-right: 0;
}

.purchase-consent {
  display: grid;
  grid-template-columns: var(--touch) minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  min-height: 100px;
  margin: calc(-1 * var(--tg)) 0 0;
  padding: 22px 28px;
  background: var(--bg);
  border: 2px solid var(--line2);
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.purchase-consent:hover {
  border-color: var(--deco);
}

.purchase-consent:has(input:checked) {
  background: rgba(200, 255, 46, 0.07);
  border-color: var(--acc);
}

.purchase-policy:has(+ .purchase-consent input:checked) {
  border-color: var(--acc);
}

/* the real checkbox, enlarged to a 56px square tick box */
.purchase-consent input {
  display: block;
  width: var(--touch);
  height: var(--touch);
  margin: 0;
  background: var(--foot) no-repeat center / 62% 62%;
  border: 3px solid var(--muted);
  border-radius: 0;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.purchase-consent:hover input {
  border-color: var(--acc);
}

.purchase-consent input:checked {
  background-color: var(--acc);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3.5 12.5l5.5 5.5L20.5 6' fill='none' stroke='%230A0F1F' stroke-width='3.8' stroke-linecap='square'/%3E%3C/svg%3E");
  border-color: var(--acc);
}

.purchase-consent a {
  color: var(--acc);
  font-weight: 600;
}

@media (forced-colors: active) {
  .purchase-consent input {
    -webkit-appearance: auto;
    appearance: auto;
    width: 32px;
    height: 32px;
  }
}

/* ---------- Submit: very tall skewed lime plate (drawn by ::before so the label stays upright) ---------- */
#pay-submit {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  justify-self: stretch;
  width: auto;
  min-height: 100px;
  margin: 18px 16px 0;
  padding: 14px 28px;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  color: var(--acc-ink);
  font-family: var(--cond);
  font-size: clamp(24px, 2.7vw, 34px);
  font-weight: 800;
  font-style: italic;
  line-height: 1.1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  cursor: pointer;
}

#pay-submit::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--acc);
  border: 2px solid var(--acc);
  box-shadow: 0 20px 48px rgba(200, 255, 46, 0.2);
  transform: skewX(var(--skew));
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

#pay-submit:hover:not(:disabled)::before {
  background: var(--acc-hi);
  border-color: var(--acc-hi);
}

#pay-submit:focus-visible {
  outline: 4px solid var(--text);
  outline-offset: 6px;
}

/* waiting for a valid Device ID + accepted policy */
#pay-submit:disabled {
  color: var(--muted);
  cursor: not-allowed;
}

#pay-submit:disabled::before {
  background: var(--s2);
  border-color: var(--line2);
  box-shadow: none;
}

/* busy: pay.js swaps in a spinner while the order is created — keep it lime */
#pay-submit:disabled:has(.fa-spin) {
  color: var(--acc-ink);
  cursor: progress;
}

#pay-submit:disabled:has(.fa-spin)::before {
  background: var(--acc);
  border-color: var(--acc);
  opacity: 0.82;
}

.submit-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 6px 0 0;
  color: var(--soft);
  font-size: 16px;
  line-height: 1.4;
  text-align: center;
}

.submit-note i {
  flex-shrink: 0;
  color: var(--acc);
  font-size: 18px;
}

.pay-err {
  display: none;
  margin: 0;
  padding: 15px 18px;
  background: rgba(255, 138, 138, 0.09);
  border: 1px solid rgba(255, 138, 138, 0.4);
  border-left: 5px solid var(--err);
  color: var(--err);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.45;
}

.legal {
  margin: 8px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
  text-align: center;
}

.legal strong {
  color: var(--text);
}

.footer-links {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.6;
  text-align: center;
}

.footer-links a {
  color: var(--acc);
  font-weight: 600;
}

/* =====================================================================
   Hotmart checkout window (built by pay.js createCheckoutWindow).
   pay.js injects its own <style id="csx-style"> later in <head>, so these rules
   carry "html body" for specificity. Colours/borders/fonts/corners only.
   ===================================================================== */
html body .csx-overlay {
  background: rgba(4, 7, 15, 0.84);
}

html body .csx-dialog {
  background: var(--s1);
  border: 1px solid var(--line);
  border-top: 6px solid var(--acc);
  border-radius: 0;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.7);
  font-family: var(--body);
  color: var(--text);
}

html body .csx-head {
  background: var(--s1);
  border-bottom: 1px solid var(--line);
}

html body .csx-title {
  font-family: var(--cond);
  font-size: 22px;
  font-weight: 800;
  font-style: italic;
  line-height: 1.1;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text);
}

html body .csx-title i {
  color: var(--acc);
}

html body .csx-sub {
  color: var(--muted);
  font-size: 13px;
}

html body .csx-close,
html body .csx-newtab-icon {
  background: var(--s2);
  border: 1px solid var(--line);
  border-radius: 0;
  color: var(--text);
}

html body .csx-close:hover,
html body .csx-newtab-icon:hover {
  background: var(--s2);
  border-color: var(--acc);
  color: var(--acc);
}

html body .csx-close:focus-visible,
html body .csx-newtab:focus-visible,
html body .csx-newtab-icon:focus-visible {
  outline: 3px solid var(--acc);
  outline-offset: 2px;
}

html body .csx-body {
  background: var(--bg);
}

html body .csx-loader {
  color: var(--soft);
  font-size: 15px;
}

html body .csx-spin {
  border-color: var(--line2);
  border-top-color: var(--acc);
}

html body .csx-foot {
  background: var(--s1);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

html body .csx-dot {
  background: var(--acc);
  animation-name: csx-pulse-acc;
}

@keyframes csx-pulse-acc {
  0% { box-shadow: 0 0 0 0 rgba(200, 255, 46, 0.5); }
  70% { box-shadow: 0 0 0 7px rgba(200, 255, 46, 0); }
  100% { box-shadow: 0 0 0 0 rgba(200, 255, 46, 0); }
}

html body .csx-newtab {
  color: var(--acc);
  font-weight: 600;
}

html body .csx-newtab-icon {
  color: var(--acc);
}

/* =====================================================================
   Responsive
   ===================================================================== */

/* under 1100px: the band and the lower band stack into one column */
@media (max-width: 1099px) {
  .pay-layout {
    grid-template-areas:
      ".    h1    h1    ."
      ".    lead  lead  ."
      ".    ben   ben   ."
      "form form  form  form"
      ".    steps steps ."
      ".    note  note  .";
  }
  h1 { align-self: start; margin-right: 0; }
  .lead { max-width: 68ch; margin: 16px 0 0; }
  .benefits { margin-top: 22px; }
  .activation-steps { margin: 44px 0 0; }
  .media-notice { margin: 30px 0 52px; }
  .checkout-form { max-width: 920px; }
}

@media (max-width: 860px) {
  .benefit { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 10px 12px 10px 10px; }
  .benefit-icon { width: 40px; height: 40px; font-size: 16px; }
  .benefit-copy b { font-size: 18px; }
  .benefit:first-child .benefit-copy b { font-size: 21px; }
  .benefit-copy > span { font-size: 13px; }
  .method-button { min-height: 230px; }
}

@media (max-width: 760px) {
  :root { --hdr: 64px; }
  body { font-size: 16px; }
  .brand { gap: 10px; font-size: 24px; }
  .brand img { width: 34px; height: 34px; }
  .brand span { padding: 4px 9px 3px; font-size: 16px; }
  html body .csx-title { font-size: 19px; }
  /* benefits become one compact list inside a single tile */
  .benefits { grid-template-columns: minmax(0, 1fr); gap: 0; background: var(--s1); border: 1px solid var(--line); }
  .benefit { min-height: 60px; background: none; border: 0; }
  .benefit + .benefit { border-top: 1px solid var(--hair); }
  .benefit:first-child { background: linear-gradient(90deg, rgba(200, 255, 46, 0.1) 0%, rgba(200, 255, 46, 0) 75%); border: 0; box-shadow: inset 4px 0 0 var(--acc); }
}

/* phones: one column of tiles; the Device ID counter moves up beside the label */
@media (max-width: 640px) {
  :root { --gut: 16px; --tg: 12px; }
  .checkout-form { grid-template-columns: minmax(0, 1fr); }
  .price-heading + .field + .field,
  .price-heading + .field + .field + .field { grid-column: 1 / -1; }

  .price-heading + .field {
    grid-template-areas:
      "label meta"
      "input input"
      "hint  hint"
      "msg   msg";
    padding: 20px 16px 20px;
  }
  .price-heading + .field > label { align-self: center; margin-bottom: 14px; font-size: 20px; }
  .input-meta {
    flex-direction: row;
    align-self: start;
    min-width: 0;
    min-height: 50px;
    margin-bottom: 14px;
    padding: 6px 14px;
    border-width: 2px;
    font-size: 28px;
    gap: 10px;
  }
  .pay-device-status { font-size: 28px; }
  #pay-device-id { --ls: 0.5ch; min-height: 88px; padding: 12px 14px; font-size: clamp(28px, 9.2vw, 40px); }
  #pay-device-id:placeholder-shown,
  #pay-device-id::placeholder { font-size: 16px; }
  .price-heading + .field .hint { font-size: 14px; }
  .pay-device-msg { font-size: 15px; padding: 12px 14px; }
}

@media (max-width: 620px) {
  h1 { font-size: clamp(40px, 11.6vw, 54px); margin-top: 26px; }
  h1::before { width: 48px; height: 4px; margin-bottom: 16px; }
  .lifetime-words { display: block; }
  .lead { font-size: 15px; margin-top: 14px; }
  .benefits { margin: 18px 0 24px; }
  .benefit-copy b { font-size: 17px; }
  .benefit:first-child .benefit-copy b { font-size: 20px; }

  .checkout-panel { padding-top: 24px; padding-bottom: 32px; }
  .price-heading { margin: 0 18px 2px; padding: 14px 18px 12px; gap: 4px 18px; }
  .price-heading::after { left: 12px; width: 52px; height: 4px; }
  .price-heading b { font-size: clamp(54px, 16vw, 64px); }
  .price-copy { text-align: center; }
  .price-copy strong { font-size: 26px; }
  .price-copy span { font-size: 14px; margin-top: 4px; }

  .field { padding: 18px 16px 20px; }
  .field > label { font-size: 17px; letter-spacing: 0.1em; margin-bottom: 12px; gap: 6px 10px; }
  .field > label::before,
  .methods-title::before,
  .purchase-policy > strong::before { min-width: 36px; height: 28px; font-size: 17px; }
  .field input { min-height: var(--touch); padding: 13px 14px; font-size: 17px; }
  .hint { font-size: 13.5px; }

  .methods { margin-top: 8px; }
  .methods-title { font-size: 23px; gap: 10px; margin-bottom: 12px; }
  .method-list { gap: 10px; }
  .method-button { min-height: 200px; gap: 10px; padding: 26px 10px 18px; }
  .method-radio { top: 10px; right: 10px; font-size: 24px; }
  .method-main-icon { width: 64px; height: 64px; font-size: 32px; }
  .method-copy strong { font-size: 21px; }
  .method-copy span { font-size: 13px; margin-top: 4px; }
  .payment-logos { gap: 5px; }
  .payment-logos img { width: 36px; height: 26px; padding: 4px 5px; }
  .payment-logos .wide { width: 40px; }

  .purchase-policy { margin-top: 8px; padding: 20px 16px 18px; font-size: 13.5px; }
  .purchase-policy strong { font-size: 19px; gap: 6px 10px; }
  .purchase-consent { gap: 14px; padding: 18px 16px; font-size: 14px; align-items: start; }

  #pay-submit { min-height: 84px; margin: 12px 10px 0; padding: 12px 16px; font-size: 22px; letter-spacing: 0.04em; }
  .submit-note { font-size: 14.5px; }
  .pay-err { font-size: 15px; padding: 13px 14px; }
  .legal, .footer-links { font-size: 12.5px; }

  /* after-payment steps: shown on phones too, as a vertical list */
  .activation-steps { margin-top: 36px; }
  .eyebrow { font-size: 15px; letter-spacing: 0.12em; margin-bottom: 18px; }
  .steps-row { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .step-arrow { display: none; }
  .step { display: grid; grid-template-columns: 56px minmax(0, 1fr); align-items: center; gap: 16px; min-height: 56px; text-align: left; font-size: 15px; }
  .step-icon { width: 56px; height: 56px; margin: 0; font-size: 20px; }
  .step-number { top: -7px; left: -7px; width: 24px; height: 24px; font-size: 15px; }
  .media-notice { margin: 28px 0 40px; grid-template-columns: 38px minmax(0, 1fr); gap: 12px; padding: 18px 16px; font-size: 13.5px; }
  .media-notice i { width: 38px; height: 38px; font-size: 15px; }
}

@media (max-width: 380px) {
  .brand { font-size: 22px; }
  .price-heading b { font-size: 52px; }
  .method-copy strong { font-size: 19px; }
  .payment-logos img { width: 34px; height: 24px; }
  .payment-logos .wide { width: 38px; }
  #pay-submit { font-size: 20px; }
  .input-meta { font-size: 24px; padding: 6px 10px; }
  .pay-device-status { font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
  html body .csx-dot { animation: none; }
}
