/* ============================================================
   Discounts page.

   One graphic system at three sizes: the Apex banner, an offer card,
   and a firm row. Same navy grounds, same gold hairline, same action
   block of a code button over a gold link. A card is the banner with
   less room, not a different object.

   Scoped to .dc so this sheet can be dropped beside a global header and
   footer without touching them.
   ============================================================ */

.dc{
  --bg:#171C27;
  --lift:#2A3244;
  --surface:#131A27;
  --recess:#0E1420;
  --ink:#EDE8DF;
  --muted:#AAB5C7;
  --gold:#FCAF00;
  --champagne:#F0CE80;
  --edge:rgba(219,183,104,.28);
  --edge-2:rgba(224,188,110,.42);
  --line:rgba(217,182,108,.18);
  --brand:var(--champagne);
  --r:14px;

  box-sizing:border-box;
  min-height:100vh;
  background:
    radial-gradient(118% 80% at 50% 0%,var(--lift) 0%,transparent 58%),
    var(--bg);
  color:var(--ink);
  font:400 16px/1.6 Archivo,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  -webkit-font-smoothing:antialiased;
}
.dc *{box-sizing:border-box}
.dc :focus-visible{outline:2px solid var(--gold);outline-offset:3px;border-radius:4px}

.dc h1,.dc h2,.dc h3{color:#fff;line-height:1.14;margin:0}
.dc h1{font-size:clamp(30px,4.2vw,50px);font-variation-settings:"wdth" 88,"wght" 800;letter-spacing:-.025em}
.dc h2{font-size:clamp(22px,2.3vw,30px);font-variation-settings:"wdth" 88,"wght" 800;letter-spacing:-.02em}
.dc h3{font-size:16px;font-variation-settings:"wdth" 94,"wght" 700}
.dc p{margin:0}
.dc a{color:var(--champagne);text-underline-offset:4px}

.dc-shell{width:min(1240px,calc(100% - clamp(28px,5vw,72px)));margin:0 auto;padding:36px 0 52px}
.dc-sr{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

/* ---------- intro ------------------------------------------------ */

/* Short and centred: the first offer has to be reachable without a
   scroll, so this block is a heading and two lines, not a hero. */
.dc-intro{max-width:700px;margin:0 auto;text-align:center}
.dc-intro__mark{width:44px;height:44px;border-radius:12px;display:block;margin:0 auto 16px}
.dc-intro h1{margin-bottom:12px}
.dc-intro__lede{color:var(--muted);font-size:16px}
.dc-intro__meta{
  display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:6px 10px;
  margin-top:16px;font-size:12px;color:var(--muted);
}
.dc-intro__meta b{color:var(--champagne);font-weight:700;letter-spacing:.06em;text-transform:uppercase}

/* ---------- the Apex banner -------------------------------------- */

/* Horizontal band, same composition as the coupon on the Apex review:
   wordmark, figure, action. The blue is the partner's own and is used
   here and nowhere else on the page. */
.dc-apex{
  position:relative;isolation:isolate;overflow:hidden;
  display:grid;align-items:center;
  grid-template-columns:minmax(150px,.8fr) auto minmax(246px,.85fr);
  grid-template-areas:
    "logo deal act"
    "note note act"
    "fine fine fine";
  gap:10px 30px;margin-top:32px;padding:18px 28px;
  background:radial-gradient(ellipse at 45% 118%,#123075 0,transparent 64%),#060B16;
  border:1px solid var(--edge-2);border-radius:18px;
}
.dc-apex:before{
  content:"";position:absolute;z-index:-1;pointer-events:none;
  left:17%;top:-300px;width:470px;height:470px;
  border:1px solid rgba(35,107,255,.25);border-radius:50%;
  box-shadow:0 0 0 26px rgba(35,107,255,.045),0 0 0 52px rgba(35,107,255,.03);
}

.dc-apex__logo{grid-area:logo;margin:0;padding-right:24px;border-right:1px solid rgba(255,255,255,.14)}
.dc-apex__logo img{display:block;width:100%;max-width:234px;height:auto}

.dc-apex__deal{grid-area:deal;display:flex;flex-direction:column;gap:4px;white-space:nowrap}
.dc-apex__deal small{color:#ADBEDB;font-size:11px;font-weight:700;letter-spacing:.18em;text-transform:uppercase}
.dc-apex__deal b{
  font-size:clamp(38px,4.6vw,62px);line-height:1;letter-spacing:-.045em;
  font-variation-settings:"wdth" 88,"wght" 850;text-transform:uppercase;
  color:#77ABFF;
  background:linear-gradient(180deg,#B5D4FF,#3C81FF 65%,#1460EE);
  background-clip:text;-webkit-background-clip:text;-webkit-text-fill-color:transparent;
}

.dc-apex__note{grid-area:note;color:#C2CEE2;font-size:13px;max-width:62ch}
.dc-apex__note b{color:#fff;font-weight:700}

.dc-apex__act{grid-area:act;display:grid;gap:10px;min-width:0}

.dc-apex__fine{
  grid-area:fine;margin-top:4px;padding-top:12px;
  border-top:1px solid rgba(255,255,255,.09);
  color:#98A5BB;font-size:12px;line-height:1.55;
}
.dc-apex__fine a{color:#B5D4FF}

/* The code button on the banner is the partner's light treatment, so
   its focus ring has to be dark to stay visible. */
.dc-apex .dc-code{
  background:#F4F7FF;border:1px solid #fff;border-radius:9px;
  color:#10234C;min-height:48px;
}
.dc-apex .dc-code__t{color:#1765ED;font-size:17px}
.dc-apex .dc-code__s{background:#F4F7FF;color:#10234C}
.dc-apex .dc-code__i{color:#4E6796}
.dc-apex .dc-code:hover{border-color:#1765ED}
.dc-apex .dc-code:focus-visible{outline-color:#10234C}
.dc-apex .dc-cta{min-height:46px}

/* ---------- the offer grid --------------------------------------- */

.dc-sec{margin-top:52px;scroll-margin-top:72px}
.dc-head{max-width:720px;margin-bottom:22px}
.dc-head h2{margin-bottom:10px}
.dc-head p{color:var(--muted);font-size:14px}

.dc-grid{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;
  margin:0;padding:0;list-style:none;
}
.dc-grid>li{min-width:0;display:flex}

/* Rows in a fixed order so logos, figures and actions line up from one
   card to the next: head, programs, then the action block pushed to the
   floor by the auto margin. */
.dc-card{
  position:relative;overflow:hidden;
  display:flex;flex-direction:column;gap:14px;width:100%;
  padding:20px 22px 18px;background:var(--surface);
  border:1px solid var(--edge);border-radius:var(--r);
}
.dc-card:before{
  content:"";position:absolute;inset:0 0 auto;height:2px;
  background:var(--brand);opacity:.5;
}

.dc-card__head{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:14px}
.dc-card__id{min-width:0}
.dc-name{display:block;color:#fff;font-size:15px;font-variation-settings:"wdth" 94,"wght" 700}
.dc-card__id .dc-prog{display:block;margin-top:3px}

.dc-tile{
  position:relative;flex:none;display:grid;place-items:center;
  width:52px;height:52px;padding:8px;
  background:var(--recess);border-radius:12px;
}
.dc-tile:before{
  content:"";position:absolute;inset:-14px;border-radius:50%;
  background:radial-gradient(circle,var(--brand) 0,transparent 70%);
  opacity:.16;pointer-events:none;
}
.dc-tile:after{
  content:"";position:absolute;inset:0;border-radius:inherit;
  border:1px solid var(--brand);opacity:.3;
}
/* A definite box, not max-width:100%: inside a centred grid WebKit
   collapses an image sized only by percentage maxima and draws nothing.
   object-fit keeps every mark whole and in proportion. */
.dc-tile img{position:relative;width:100%;height:100%;object-fit:contain}

/* The figure is the headline of the card, and the word above it is part
   of the figure: it says who is claiming it. */
.dc-off{display:flex;flex-direction:column;align-items:flex-end;gap:2px;text-align:right}
.dc-off small{color:var(--muted);font-size:10px;font-weight:700;letter-spacing:.13em;text-transform:uppercase}
.dc-off b{
  color:var(--champagne);font-size:30px;line-height:1;letter-spacing:-.025em;
  font-variation-settings:"wdth" 88,"wght" 800;font-variant-numeric:tabular-nums;
}
.dc-off i{font-size:13px;font-style:normal;letter-spacing:0;margin-left:3px}

/* Two lines reserved, so a one line list and a two line list give the
   same card. */
.dc-prog{color:var(--muted);font-size:13px;line-height:1.5}
.dc-card>.dc-prog{min-height:calc(2 * 1.5 * 13px)}
.dc-prog span{color:#C7D0E0}

.dc-act{display:grid;gap:10px;margin-top:auto;min-width:0}
.dc-chk{color:var(--muted);font-size:11.5px;letter-spacing:.01em}

/* ---------- code button and gold link ---------------------------- */

/* The dashed edge is the only dashed line on the site, which is what
   makes a code read as a code. "Copied" is laid over the label instead
   of replacing it, so the button never changes width. */
.dc-code{
  position:relative;min-width:0;min-height:44px;width:100%;
  display:inline-flex;align-items:center;justify-content:space-between;gap:10px;
  padding:10px 14px;background:var(--recess);
  border:1px dashed var(--edge);border-radius:8px;
  color:var(--champagne);font:400 14px/1.2 Archivo,sans-serif;
  text-align:left;cursor:pointer;
  transition:border-color .18s ease,color .18s ease;
}
.dc-code__t{
  font-size:15px;font-variation-settings:"wdth" 94,"wght" 700;
  letter-spacing:.06em;overflow-wrap:anywhere;
}
.dc-code__i{
  flex:none;width:15px;height:15px;
  fill:none;stroke:currentColor;stroke-width:1.5;
  stroke-linecap:round;stroke-linejoin:round;opacity:.65;
}
.dc-code__s{
  position:absolute;inset:0;display:grid;place-items:center;visibility:hidden;
  background:var(--recess);border-radius:inherit;
  color:var(--gold);font-size:13px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;
}
.dc-code:hover{border-color:var(--champagne)}
.dc-code.is-done{border-style:solid;border-color:var(--gold)}
.dc-code.is-done .dc-code__t,.dc-code.is-done .dc-code__i{visibility:hidden}
.dc-code.is-done .dc-code__s{visibility:visible}
.dc-code.is-fail{border-style:solid;border-color:rgba(255,124,124,.7)}

/* .dc .dc-cta, not .dc-cta: the link colour set on ".dc a" is one point
   more specific and would otherwise paint this label champagne on gold. */
.dc .dc-cta{
  flex:none;min-height:44px;width:100%;
  display:inline-flex;align-items:center;justify-content:center;
  padding:10px 18px;background:var(--gold);border:1px solid var(--gold);
  border-radius:8px;color:#101725;
  font:400 14px/1.2 Archivo,sans-serif;font-variation-settings:"wdth" 94,"wght" 700;
  text-decoration:none;white-space:nowrap;
}
.dc .dc-cta:hover{background:#FFCA4A;border-color:#FFCA4A}

/* ---------- firms with no code ----------------------------------- */

/* Named, not left out. Shown as rows rather than cards so they cannot
   be mistaken for live offers. */
.dc-firms{
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;
  margin:0;padding:0;list-style:none;
}
.dc-firms li{
  display:flex;align-items:center;gap:13px;min-width:0;
  padding:14px 16px;background:var(--recess);
  border:1px solid var(--line);border-radius:12px;
}
.dc-firms .dc-tile{width:42px;height:42px;padding:6px;background:#0A0F18}
.dc-firms .dc-tile:before{content:none}
.dc-firms div{min-width:0}
.dc-firms p{color:var(--muted);font-size:12px;line-height:1.5;margin-top:2px}

/* ---------- using your code -------------------------------------- */

.dc-steps{
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;
  margin:0;padding:0;list-style:none;
}
.dc-steps li{
  padding:16px 18px;background:var(--surface);
  border:1px solid var(--line);border-radius:12px;
}
.dc-steps b{
  display:block;margin-bottom:8px;
  color:var(--champagne);font-size:11px;font-weight:700;letter-spacing:.14em;
  font-variant-numeric:tabular-nums;
}
.dc-steps h3{margin-bottom:6px}
.dc-steps p{color:var(--muted);font-size:13px;line-height:1.55}

/* ---------- conditions and disclosure ---------------------------- */

/* One panel in two columns rather than two stacked panels: the same
   material, a third of the height. */
.dc-end{
  display:grid;grid-template-columns:1.35fr 1fr;gap:28px 40px;
  padding:24px 28px;background:var(--surface);
  border:1px solid var(--edge);border-radius:var(--r);
}
.dc-end h2{font-size:19px;margin-bottom:10px}
.dc-end p{color:var(--muted);font-size:13.5px;line-height:1.6}
.dc-end p+p{margin-top:10px}

/* An unconfirmed condition should look unconfirmed. */
.dc-pending{
  margin-top:14px;padding:12px 16px;
  background:rgba(240,206,128,.06);border-left:2px solid var(--champagne);
  border-radius:0 8px 8px 0;
}
.dc-pending p{font-size:12.5px}
.dc-pending b{color:var(--champagne)}

.dc-risk{margin-top:24px;color:var(--muted);font-size:12px;line-height:1.6;max-width:92ch}

/* ---------- narrower --------------------------------------------- */

@media(max-width:1100px){
  .dc-apex{grid-template-columns:minmax(140px,.9fr) auto minmax(230px,.8fr);gap:10px 22px;padding:18px 22px}
  .dc-apex__logo{padding-right:18px}
}

/* The banner loses its third column before the figure has to shrink. */
@media(max-width:920px){
  .dc-apex{
    grid-template-columns:minmax(0,auto) minmax(0,1fr);
    grid-template-areas:
      "logo deal"
      "note note"
      "act  act"
      "fine fine";
    gap:14px 22px;
  }
  .dc-apex__act{grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:center}
  .dc-firms{grid-template-columns:repeat(2,minmax(0,1fr))}
  .dc-end{grid-template-columns:1fr;gap:22px}
}

@media(max-width:760px){
  .dc-grid{grid-template-columns:1fr}
  .dc-steps{grid-template-columns:1fr}
  .dc-steps li{padding:14px 16px}
}

/* Mobile banner: wordmark and figure first, then the action, then the
   conditions. Not the desktop band with smaller type. */
@media(max-width:640px){
  .dc-shell{padding:28px 0 44px}
  .dc-sec{margin-top:40px}

  .dc-apex{
    grid-template-columns:minmax(0,1fr);
    grid-template-areas:"logo" "deal" "act" "note" "fine";
    gap:14px;padding:18px;border-radius:var(--r);
  }
  .dc-apex:before{left:-80px;top:-340px}
  .dc-apex__logo{padding:0 0 14px;border-right:0;border-bottom:1px solid rgba(255,255,255,.14)}
  .dc-apex__logo img{max-width:200px}
  .dc-apex__deal{gap:2px}
  .dc-apex__deal b{font-size:clamp(40px,13vw,54px)}
  .dc-apex__act{grid-template-columns:minmax(0,1fr)}

  .dc-card{padding:18px}
  .dc-card>.dc-prog{min-height:0}
  .dc-firms{grid-template-columns:1fr}
  .dc-end{padding:20px}
}

/* 320px: the figure and the tile give back room first. */
@media(max-width:360px){
  .dc-card__head{gap:10px}
  .dc-off b{font-size:26px}
  .dc-tile{width:46px;height:46px}
  .dc-code__t{font-size:14px}
}

@media(prefers-reduced-motion:reduce){
  .dc *{transition:none!important;animation:none!important}
}

/* Whole card opens the firm; the code button only copies. */
.dc-card,.dc-apex{cursor:pointer;transition:border-color .2s,transform .2s}
.dc-card:hover,.dc-apex:hover{border-color:rgba(219,183,104,.45)}
.dc-card .dc-code,.dc-apex .dc-code,.dc-card .dc-cta,.dc-apex .dc-cta{cursor:pointer}

/* The page sits on the site background, so no white shows between the content and the footer. */
html,body{background:#171c27}
