/* True Rate on the FantasyLab hub. Identity: "Name Patch" (workwear label), see
   digital-product-engine/docs/brand/TRUE-RATE-DIRECTIONS.md, direction C.
   Only the product content (main.tr) takes the new look. The house nav, footer and type around it stay as they are. */

@font-face { font-family: "Hepta Slab"; src: url(/true-rate/assets/fonts/hepta-slab.woff) format("woff"); font-weight: 500 900; font-display: swap; }
@font-face { font-family: "Commissioner"; src: url(/true-rate/assets/fonts/commissioner.woff) format("woff"); font-weight: 400 800; font-display: swap; }

body {
  --accent: #f0a93b; --accent-2: #2f4a78;
  --hickory: #f2f0ea;  /* the ground */
  --navy: #1c2741;     /* text and numbers on light, 13.0:1 */
  --denim: #2f4a78;    /* secondary, 7.8:1 */
  --gold: #f0a93b;     /* thread, stitches, accent; text only as big figures on navy (7.4:1) */
  --red: #b5281f;      /* loss, label selvedge: graphic or large only */
  --thread: #f4ebda;   /* text on navy, 12.5:1 */
  --duck: #b07a3f;     /* accent, never behind text */
  --pocket: #ffffff; --cloth: #f7e7b6; --twill: #24314f;
  --slab: "Hepta Slab", Rockwell, Georgia, serif;
  --tr-text: "Commissioner", "Helvetica Neue", Arial, sans-serif;
}
/* The house grain is not part of this identity: lift the product content above it. The nav keeps its place on top. */
main.tr { position: relative; z-index: 101; }
.nav { z-index: 102; }

.tr { font: 400 18px/1.55 var(--tr-text); color: var(--navy); }
.tr ::selection { background: var(--gold); color: var(--navy); }
.tr :focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 2px; }
.tr h1, .tr h2, .tr h3 { font-family: var(--slab); letter-spacing: -.01em; text-wrap: balance; }
.tr h1 { font-weight: 800; line-height: 1.02; }
.tr h2 { font-weight: 800; font-size: clamp(34px, 4.4vw, 60px); line-height: 1.04; max-width: 20ch; }
.tr h3 { font-weight: 700; font-size: clamp(21px, 1.8vw, 25px); line-height: 1.2; margin: 0 0 8px; }
.tr h1 em, .tr h2 em { font-style: normal; }
.tr h2 em { color: var(--red); }
.tr .lede { color: var(--denim); font-size: clamp(19px, 1.5vw, 22px); line-height: 1.5; }
.tr p { max-width: 62ch; }
.tr a:hover { color: inherit; }
.tr .num, .tr .label dd, .tr .price-num, .tr .wow-line b, .tr .mm td { font-variant-numeric: tabular-nums lining-nums; }

/* buttons: a gold patch on navy, a navy patch on light. Both carry a stitched inner edge. */
.tr .btn { min-height: 54px; padding: 0 26px; border-radius: 999px; border: 0; font: 700 18px/1 var(--tr-text); letter-spacing: 0; text-transform: none;
  background: var(--gold); color: var(--navy); box-shadow: inset 0 0 0 2px var(--gold), inset 0 0 0 4px rgba(28, 39, 65, .35);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.tr .btn:hover { color: var(--navy); transform: translateY(-2px); box-shadow: inset 0 0 0 2px var(--gold), inset 0 0 0 4px rgba(28, 39, 65, .35), 0 8px 18px -10px rgba(0, 0, 0, .7); }
.tr .btn.navy { background: var(--navy); color: var(--thread); box-shadow: inset 0 0 0 2px var(--navy), inset 0 0 0 4px rgba(240, 169, 59, .7); }
.tr .btn.navy:hover { color: var(--thread); box-shadow: inset 0 0 0 2px var(--navy), inset 0 0 0 4px rgba(240, 169, 59, .7), 0 8px 18px -10px rgba(28, 39, 65, .8); }
/* the quiet link: underlined with a stitched (dashed) thread */
.tr .quiet { display: inline-flex; align-items: center; min-height: 44px; font: 600 17px/1.3 var(--tr-text); color: var(--navy); text-decoration: underline dashed var(--red) 2px; text-underline-offset: 7px; }
.tr .quiet:hover { color: var(--denim); text-decoration-color: var(--denim); }

/* ---------- the one navy twill band: the hero ---------- */
.twill { color: var(--thread); background: repeating-linear-gradient(-35deg, rgba(255, 255, 255, .035) 0 2px, transparent 2px 5px), var(--navy); }
.twill::after { content: ""; position: absolute; left: 0; right: 0; bottom: 14px; height: 2px; pointer-events: none;
  background: repeating-linear-gradient(90deg, rgba(240, 169, 59, .7) 0 7px, transparent 7px 12px); }
.scrolly { position: relative; }
.scrolly .track { position: absolute; left: 0; top: 0; width: 1px; height: calc(100% - 100svh); pointer-events: none; }
.stage .track-m { position: absolute; left: 0; top: -38svh; width: 1px; height: 38svh; pointer-events: none; }
@media (min-width: 901px) {
  .hero .copy { padding-top: 12px; padding-bottom: 12px; }
}
@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  .scrolly { height: 250svh; }
  .scrolly .hero { position: sticky; top: 0; height: 100svh; min-height: 0; }
}
.hero { overflow: hidden; }
.tr-patch { margin: 0 0 16px; }
.tr-patch img { width: 136px; height: auto; transform: rotate(-2deg); filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .35)); }
.hero h1 { font-size: clamp(40px, 4.2vw, 62px); max-width: 15ch; color: var(--thread); margin-bottom: 18px; }
.hero h1 em { color: var(--gold); }
.hero .lede { color: var(--thread); max-width: 44ch; font-size: clamp(18px, 1.4vw, 21px); }
.hero .actions { gap: 10px 26px; margin-top: 20px; }
.hero .quiet { color: var(--thread); text-decoration-color: var(--gold); }
.hero .quiet:hover { color: var(--gold); text-decoration-color: var(--gold); }
.hero .stage .drag { position: absolute; z-index: 2; left: 14%; bottom: 18%; font: 500 15px/1 var(--tr-text); color: rgba(244, 235, 218, .78); }

/* the board log: what the pencil writes, lit line by line as the tape comes out */
.log { margin-top: 26px; max-width: 380px; }
.log ol { list-style: none; margin: 0; padding: 0; }
.log li { font: 500 15px/1.3 var(--tr-text); color: rgba(244, 235, 218, .62); padding: 5px 0 6px; position: relative; transition: color .6s var(--ease); }
.log li + li::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1.5px; background: repeating-linear-gradient(90deg, rgba(244, 235, 218, .22) 0 7px, transparent 7px 12px); }
.log li.on, .log.all li { color: var(--thread); }
.log li.big { font: 700 18px/1.3 var(--slab); }
.log li.big.on, .log.all li.big { color: var(--gold); }
.log li.free.on, .log.all li.free { color: var(--thread); background: var(--red); padding-left: 14px; padding-right: 14px; margin-top: 6px;
  box-shadow: inset 0 0 0 3px var(--red), inset 0 0 0 4.5px rgba(244, 235, 218, .55); }
.log li.free::before { display: none; }

/* ---------- the light ground: hickory, a very faint paired pinstripe ---------- */
.cloth-ground { background: repeating-linear-gradient(90deg, transparent 0 11px, rgba(28, 39, 65, .035) 11px 12.5px, transparent 12.5px 14.5px, rgba(28, 39, 65, .035) 14.5px 16px, transparent 16px 26px), var(--hickory); }
.tr-band { padding: clamp(72px, 9vw, 128px) 0; position: relative; }
/* chain-stitch seams between sections */
.tr-band + .tr-band::before { content: ""; position: absolute; top: 0; left: var(--gut); right: var(--gut); max-width: calc(var(--wrap) - 2 * var(--gut)); margin: 0 auto; height: 2px;
  background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .45) 0 7px, transparent 7px 12px); }

.split { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(36px, 6vw, 96px); align-items: start; }

/* the daily moment, along a stitched seam */
#moment h2 { max-width: 22ch; }
.seam { list-style: none; margin: 48px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 clamp(24px, 4vw, 56px); position: relative; }
.seam::before { content: ""; position: absolute; left: 0; right: 0; top: 9px; height: 2px; background: repeating-linear-gradient(90deg, var(--gold) 0 7px, transparent 7px 12px); }
.seam li { position: relative; padding-top: 38px; display: flex; flex-direction: column; align-items: flex-start; }
.seam li::before { content: ""; position: absolute; left: 0; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--navy); box-shadow: 0 0 0 3px var(--hickory), inset 0 0 0 4px var(--gold); }
.seam li:nth-child(2) { margin-top: 28px; }
.seam li:nth-child(3) { margin-top: 56px; }
.seam p { color: var(--navy); margin: 0 0 10px; }
.said { margin: 64px 0 0; padding: 0 0 0 22px; max-width: 34ch; position: relative; }
.said::before { content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 2px; background: repeating-linear-gradient(180deg, var(--duck) 0 7px, transparent 7px 12px); }
.said p { font: 600 clamp(21px, 1.9vw, 26px)/1.35 var(--slab); margin: 0 0 10px; color: var(--navy); }
.said .src { font-size: 15px; color: var(--denim); text-underline-offset: 4px; }

/* the worked example: the three rates on a woven label */
.worked { color: var(--denim); border-left: 4px solid var(--duck); padding-left: 16px; margin-top: 26px; }
.label { position: relative; background: var(--thread); color: var(--navy); padding: 26px 34px; border-top: 7px solid var(--red); border-bottom: 7px solid var(--red);
  box-shadow: 0 14px 26px -18px rgba(28, 39, 65, .7); transform: rotate(1.2deg); margin-top: 8px; }
.label::before, .label::after { content: ""; position: absolute; top: 10px; bottom: 10px; width: 2px; background: repeating-linear-gradient(180deg, rgba(28, 39, 65, .5) 0 7px, transparent 7px 12px); }
.label::before { left: 12px; } .label::after { right: 12px; }
.label dl { margin: 0; }
.label dl > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 16px; align-items: baseline; padding: 14px 0; }
.label dl > div + div { background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .3) 0 7px, transparent 7px 12px) top / 100% 1.5px no-repeat; }
.label dt { font: 700 17px/1.2 var(--tr-text); }
.label dd { margin: 0; font: 800 clamp(34px, 3.6vw, 48px)/1 var(--slab); grid-row: span 2; align-self: center; }
.label span { font-size: 15px; line-height: 1.35; color: var(--denim); }

/* the wow: the year as a tailor's cloth tape */
.wow { margin-top: clamp(64px, 8vw, 112px); }
.wow-line { font: 800 clamp(34px, 5vw, 72px)/1.05 var(--slab); max-width: 18ch; margin: 0 0 34px; text-wrap: balance; }
.wow-line b { font-weight: 900; font-size: 1.7em; line-height: .9; color: var(--navy); letter-spacing: -.02em; }
.cloth { position: relative; height: 70px; margin-left: 14px; background: var(--cloth); border-radius: 2px; box-shadow: 0 2px 0 rgba(28, 39, 65, .25), 0 16px 24px -16px rgba(28, 39, 65, .6); }
.cloth .ticks { position: absolute; inset: 0; overflow: hidden; background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .7) 0 1.5px, transparent 1.5px calc(100% / 48)) 0 0 / 100% 16px no-repeat; }
.cloth .ticks b { position: absolute; top: 30px; transform: translateX(-50%); font: 700 22px/1 var(--slab); color: var(--navy); }
.cloth .tip { position: absolute; left: -12px; top: -3px; bottom: -3px; width: 14px; border-radius: 3px 0 0 3px; background: linear-gradient(90deg, #8b8e93, #d5d7da 50%, #8b8e93); }
.cloth .loss, .cloth .gift { position: absolute; top: 0; bottom: 0; }
.cloth .loss { left: 73.75%; width: 6.25%; background: var(--red); }
.cloth .gift { left: 80%; right: 0; background: repeating-linear-gradient(-35deg, rgba(240, 169, 59, .95) 0 3px, rgba(240, 169, 59, .55) 3px 6px); }
.cloth .stitch { position: absolute; top: 6px; bottom: 6px; left: 73.75%; right: 6px; border-radius: 3px; pointer-events: none; border: 2px dashed var(--navy); }
.cloth .ticks b.end { left: auto; right: 10px; transform: none; }
.cloth .ticks b.r { left: 73.75% !important; transform: translateX(calc(-100% - 8px)); color: var(--navy); }
.key { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 20px 0 0; padding: 0; color: var(--navy); font-size: 16px; }
.key i { display: inline-block; width: 18px; height: 12px; margin-right: 8px; vertical-align: -1px; border-radius: 1px; }
.key .k-paid { background: var(--cloth); box-shadow: inset 0 0 0 1.5px rgba(28, 39, 65, .45); }
.key .k-loss { background: var(--red); }
.key .k-gift { background: repeating-linear-gradient(-35deg, rgba(240, 169, 59, .95) 0 3px, rgba(240, 169, 59, .55) 3px 6px); box-shadow: inset 0 0 0 1.5px rgba(28, 39, 65, .3); }
.wow-note { margin-top: 26px; font-size: clamp(18px, 1.5vw, 21px); }
.wow-note strong { font-weight: 700; }
.go { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; margin-top: 30px; max-width: none; }

/* markup and margin */
#margin .split { align-items: center; }
.mm { border-collapse: collapse; width: 100%; max-width: 420px; justify-self: end; }
.mm caption { text-align: left; padding-bottom: 12px; font: 700 17px/1.3 var(--tr-text); color: var(--navy); }
.mm th { font: 600 15px/1 var(--tr-text); text-align: left; color: var(--denim); padding: 12px 0; }
.mm td { font: 800 clamp(30px, 3vw, 40px)/1 var(--slab); padding: 14px 0 12px; color: var(--navy); }
.mm td + td { color: var(--denim); }
.mm tr { background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .35) 0 7px, transparent 7px 12px) bottom / 100% 1.5px no-repeat; }
.mm tbody tr:nth-child(3) td:first-child { color: var(--navy); }

/* the kit */
.kit { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(36px, 6vw, 90px); margin-top: 40px; align-items: start; }
.tabs { list-style: none; margin: 0; padding: 0; }
.tabs li { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 6px 24px; padding: 18px 0; align-items: baseline;
  background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .3) 0 7px, transparent 7px 12px) bottom / 100% 1.5px no-repeat; }
.tabs h3 { margin: 0; font-size: 21px; }
.tabs p { margin: 0; color: var(--denim); font-size: 17px; }
.tabs em { font-style: normal; font-weight: 700; color: var(--navy); }
.shot { margin: 8px 0 0; }
.shot img { width: 100%; height: auto; border-radius: 6px; box-shadow: 0 0 0 2px var(--navy), 0 0 0 5px var(--pocket), 0 0 0 6.5px rgba(28, 39, 65, .3), 0 24px 40px -26px rgba(28, 39, 65, .7); transform: rotate(.6deg); }
.shot figcaption { margin-top: 16px; font-size: 15px; color: var(--denim); }
.plain { list-style: none; margin: 30px 0 0; padding: 0; }
.plain li { padding: 11px 0 11px 28px; position: relative; color: var(--navy); }
.plain li::before { content: ""; position: absolute; left: 0; top: 22px; width: 16px; height: 2px; background: repeating-linear-gradient(90deg, var(--duck) 0 5px, transparent 5px 8px); }

/* limits */
.limits { list-style: none; margin: 0; padding: 0; }
.limits li { padding: 16px 0; color: var(--denim); background: repeating-linear-gradient(90deg, rgba(28, 39, 65, .3) 0 7px, transparent 7px 12px) bottom / 100% 1.5px no-repeat; }
.limits b { color: var(--navy); font-weight: 700; }

/* get it */
.get { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 40px; align-items: center; }
.get .actions { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; margin-top: 30px; }
.price { justify-self: center; text-align: left; }
.price-num { display: block; font: 900 clamp(130px, 16vw, 230px)/.85 var(--slab); letter-spacing: -.04em; color: var(--navy); }
.price-sub { display: block; margin-top: 14px; font: 600 18px/1.3 var(--tr-text); color: var(--denim); padding-top: 12px;
  background: repeating-linear-gradient(90deg, var(--gold) 0 7px, transparent 7px 12px) top / 100% 2px no-repeat; }
.ask { margin-top: 26px; color: var(--denim); }
.ask a { color: var(--navy); }

@media (max-width: 900px) {
  .split, .kit, .get { grid-template-columns: 1fr; }
  .seam { grid-template-columns: 1fr; gap: 34px; }
  .seam::before { left: 7px; right: auto; top: 10px; bottom: 0; width: 2px; height: auto; background: repeating-linear-gradient(180deg, var(--gold) 0 7px, transparent 7px 12px); }
  .seam li { padding: 0 0 0 40px; }
  .seam li:nth-child(n) { margin-top: 0; }
  .mm { justify-self: start; }
  .price { justify-self: start; }
  .log { max-width: none; }
  .label { transform: none; }
}
@media (max-width: 560px) {
  .tr { font-size: 17px; }
  .hero .stage { height: 56svh; }
  .hero h1 { font-size: 40px; }
  .label { padding: 22px 26px; }
  .label dd { font-size: 34px; }
  .tabs li { grid-template-columns: 1fr; }
  .cloth { height: 62px; }
  .cloth .ticks b { font-size: 18px; top: 28px; }
  .wow-line { font-size: 34px; }
}

/* ---- craft pass (v2.1, docs/brand/TRUE-RATE-CRAFT.md in digital-product-engine): the stitch only on edges that take
   stress, hairlines for rows, numbers set (half-size raised dollar sign, tabular figures), one hand-drawn chain stitch
   under the key number, woven-label lettering for the few labels. */
.tabs li, .limits li, .mm tr { background: none; border-bottom: 1px solid rgba(28, 39, 65, .2); }
.label dl > div + div { background: none; border-top: 1px solid rgba(28, 39, 65, .22); }
.label dd, .price-num, .mm td, .wow-line b { font-variant-numeric: tabular-nums lining-nums; font-feature-settings: "tnum", "lnum"; }
.label dd::first-letter { font-size: .5em; font-weight: 600; vertical-align: .8em; line-height: 0; margin-right: .03em; }
.price-num::first-letter { font-size: .42em; font-weight: 700; vertical-align: 1.1em; line-height: 0; margin-right: .04em; }
.label dl > div:last-child dd { padding-bottom: 14px; background: url(/true-rate/assets/chain.svg) no-repeat 0 100% / 100% 22px; }
.label dt { font: 700 16px/1.2 var(--slab); letter-spacing: .08em; text-transform: uppercase; }
.label span { font-size: 16px; }
.worked { border-left: 0; padding-left: 0; }
.worked::before { content: "Worked example"; display: block; margin-bottom: 6px; color: var(--navy); font: 700 16px/1.2 var(--slab); letter-spacing: .08em; text-transform: uppercase; }
.log li { font-size: 16px; color: rgba(244, 235, 218, .8); }
.log li + li::before { background: rgba(244, 235, 218, .18); height: 1px; }
.said .src, .shot figcaption, .mm th, .hero .stage .drag { font-size: 16px; }
.tr h2 em { color: inherit; }
#moment h2 em { color: var(--red); }
