/* tools.css: the two free tools (B-876), /ebay-fee-calculator and
   /sell-through-rate-calculator. Loaded through page_css on those pages alone.

   The tools have their own look (Walker, 25 Oct 2026) so they do not read as
   one more copy of the feature-page template: a deep navy hero with a drawing
   of what the tool is about (a binder page of card pockets; the sell-through curve)
   that the tool is pulled up over, one wide tool panel, left-aligned
   reference sections, then the site's standard CTA band (Walker asked for
   that one to match the other pages; he turned down ruled notebook lines in
   the hero). Colours are site.css tokens plus the navy ink below, so both
   themes come for free. */

.tl-page {
  --tl-ink: #0b1238;
  --tl-ink-2: #121b4a;
  --tl-max: 1320px;
  background: var(--bg);
}
[data-theme="dark"] .tl-page { --tl-ink: #0a0f2c; --tl-ink-2: #10183f; }

/* ── Ledger hero ─────────────────────────────────────────────────────── */
.tl-hero {
  position: relative; overflow: hidden; color: #fff; isolation: isolate;
  padding: calc(var(--nav-h) + 2.4rem) var(--gutter) 7.5rem;
  background:
    radial-gradient(48rem 26rem at 92% -8%, rgba(79, 110, 247, .55), transparent 64%),
    radial-gradient(34rem 22rem at 70% 105%, rgba(124, 58, 237, .30), transparent 62%),
    radial-gradient(30rem 20rem at -4% 30%, rgba(47, 205, 254, .16), transparent 60%),
    linear-gradient(165deg, #0a1035 0%, #111a55 52%, #0c1240 100%);
}
/* Film grain over the glows, so the gradients do not band and the navy has
   some texture to it. */
.tl-hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .14; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* A thin light along the hero's bottom edge, where the tool panel overlaps. */
.tl-hero::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; z-index: -1;
  background: linear-gradient(90deg, transparent, rgba(125, 154, 255, .55) 30%, rgba(47, 205, 254, .55) 70%, transparent);
}
[data-theme="dark"] .tl-hero {
  background:
    radial-gradient(48rem 26rem at 92% -8%, rgba(79, 110, 247, .42), transparent 64%),
    radial-gradient(34rem 22rem at 70% 105%, rgba(124, 58, 237, .24), transparent 62%),
    radial-gradient(30rem 20rem at -4% 30%, rgba(47, 205, 254, .12), transparent 60%),
    linear-gradient(165deg, #080d2b 0%, #0e1547 52%, #0a0f34 100%);
}
/* Sell-through: a chart grid of dots behind the curve, fading in from the
   right. */
.tl-dots { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(rgba(125, 154, 255, .38) 1.1px, transparent 1.6px); background-size: 26px 26px;
  -webkit-mask-image: linear-gradient(100deg, transparent 25%, #000 80%);
          mask-image: linear-gradient(100deg, transparent 25%, #000 80%); }
/* Fee calculator: the pockets of a card binder page, tilted and fading in
   from the right behind the site picker. */
.tl-binder { position: absolute; inset: -30% -10% -30% 30%; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='104' height='142' viewBox='0 0 104 142'%3E%3Crect x='6' y='6' width='92' height='130' rx='7' fill='rgba(255,255,255,0.02)' stroke='rgba(125,154,255,0.26)' stroke-width='1.2'/%3E%3C/svg%3E"); background-size: 104px 142px; transform: rotate(-9deg);
  -webkit-mask-image: linear-gradient(100deg, transparent 8%, #000 70%);
          mask-image: linear-gradient(100deg, transparent 8%, #000 70%); }
@media (max-width: 979px) { .tl-binder { inset: -20% -20% -20% 0; opacity: .6; } }
.tl-hero-in { position: relative; z-index: 1; max-width: var(--tl-max); margin: 0 auto;
  display: grid; gap: 2rem 3.5rem; align-items: end; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 980px) { .tl-hero-in { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); } }
.tl-hero h1 { font-size: clamp(2.1rem, 4.3vw, 3.55rem); font-weight: 800; line-height: 1.04; letter-spacing: -.025em;
  margin: 0 0 1.1rem; color: #fff; max-width: 18ch; text-wrap: balance; }
.tl-hero-copy p { max-width: 62ch; margin: 0; font-size: 1.04rem; line-height: 1.65; color: rgba(255,255,255,.82); }
.tl-elsewhere { margin-top: 1rem !important; font-size: .93rem !important; }
.tl-elsewhere a { color: var(--brand-bright); font-weight: 700; }

/* Country picker: each eBay site with its card fee, so the switch also
   answers the question people search for. */
.tl-sites { display: grid; gap: .5rem; grid-template-columns: 1fr 1fr; align-content: end; }
@media (min-width: 980px) { .tl-sites { grid-template-columns: 1fr; } }
.tl-sites-h { grid-column: 1 / -1; margin: 0 0 .15rem; font-size: .84rem; font-weight: 600; color: rgba(255,255,255,.62); }
.tl-site { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .15rem 1rem; text-decoration: none;
  padding: .7rem .95rem; border-radius: 10px; border: 1px solid rgba(255,255,255,.16); background: rgba(11, 18, 56, .72);
  backdrop-filter: blur(6px);
  color: #fff; font-size: .92rem; transition: background .15s, border-color .15s; }
.tl-site span:first-child { font-weight: 700; }
.tl-site span:last-child { color: rgba(255,255,255,.7); font-variant-numeric: tabular-nums; }
.tl-site:hover { background: rgba(30, 40, 96, .85); border-color: rgba(255,255,255,.3); }
.tl-site.active { background: #fff; border-color: #fff; color: var(--tl-ink); box-shadow: inset 4px 0 0 var(--brand-bright); }
.tl-site.active span:last-child { color: #3b4672; }
.tl-site:focus-visible, .tl-tabs button:focus-visible, .tl-more summary:focus-visible, .tl-q summary:focus-visible,
.tl-btn:focus-visible, .tl-viewall:focus-visible { outline: 3px solid var(--brand-bright); outline-offset: 2px; }

/* Sell-through hero: the model's own shape as a framed chart, drawn from
   the calculator's starting numbers (75 new listings a day, 10% a month), so
   it agrees with the prediction under it. The line draws once on load. */
.tl-hero-st { padding-bottom: 7.5rem; }
/* Side by side only where the chart card has room for legible labels;
   below that it sits under the intro at a readable width. */
@media (min-width: 980px) { .tl-hero-st .tl-hero-in { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 1180px) { .tl-hero-st .tl-hero-in { align-items: center; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
@media (max-width: 1179px) { .tl-plot { max-width: 760px; } }
.tl-h1-accent { color: var(--brand-bright); }
.tl-plot { margin: 0; padding: 1rem 1.1rem .8rem; border-radius: 16px; border: 1px solid rgba(125, 154, 255, .28);
  background: linear-gradient(160deg, rgba(18, 28, 84, .78), rgba(10, 16, 53, .78)); backdrop-filter: blur(6px);
  box-shadow: 0 20px 50px rgba(3, 6, 28, .45); }
.tl-plot svg { display: block; width: 100%; height: auto; overflow: visible; }
.tl-plot .g { stroke: rgba(125, 154, 255, .16); stroke-width: 1; }
.tl-plot .ty { fill: rgba(255, 255, 255, .55); font-size: 10.5px; text-anchor: end; }
.tl-plot .tx { fill: rgba(255, 255, 255, .55); font-size: 10.5px; text-anchor: middle; }
.tl-plot .axis { fill: rgba(255, 255, 255, .7); font-size: 11px; font-weight: 700; text-anchor: middle; }
.tl-plot .axis-y { text-anchor: start; }
.tl-plot .cap { stroke: rgba(255, 255, 255, .4); stroke-width: 1; stroke-dasharray: 5 6; }
.tl-plot .capt { fill: #fff; font-size: 11.5px; font-weight: 700; text-anchor: end; }
.tl-plot .fill { fill: url(#tlPlotFill); }
.tl-plot .line { fill: none; stroke: var(--brand-bright); stroke-width: 3; stroke-linecap: round;
  stroke-dasharray: 1200; stroke-dashoffset: 0; animation: tl-draw 1.6s cubic-bezier(.3,.6,.2,1) both; }
.tl-plot .pt { fill: #0b1238; stroke: #fff; stroke-width: 2.5; }
.tl-plot .cl { fill: rgba(8, 13, 43, .92); stroke: rgba(125, 154, 255, .45); stroke-width: 1; }
.tl-plot .ct { fill: #fff; font-size: 11.5px; font-weight: 700; }
.tl-plot .ld { stroke: rgba(255, 255, 255, .45); stroke-width: 1; }
.tl-plot figcaption { margin-top: .4rem; font-size: .76rem; color: rgba(255, 255, 255, .6); }
@keyframes tl-draw { from { stroke-dashoffset: 1200; } to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .tl-plot .line { animation: none; } }

/* ── The tool panel, pulled up over the hero ─────────────────────────── */
.tl-wrap { max-width: var(--tl-max); margin: 0 auto; padding: 0 var(--gutter); box-sizing: content-box; }
.tl-lift { position: relative; z-index: 2; margin-top: -5.5rem; }
.tl-calc { background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
  box-shadow: 0 24px 60px rgba(8, 14, 48, .18), 0 2px 6px rgba(8, 14, 48, .06); overflow: hidden; }
[data-theme="dark"] .tl-calc { box-shadow: 0 24px 60px rgba(0,0,0,.45); }
.tl-calc + .tl-calc { margin-top: 1.5rem; }
.tl-calc-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .8rem 1.5rem;
  padding: 1rem 1.5rem; border-bottom: 1px solid var(--border); background: var(--bg2); }
.tl-calc-bar h2 { margin: 0; font-size: 1.15rem; font-weight: 800; color: var(--text); }
.tl-currency { margin: 0; font-size: .86rem; color: var(--muted); }
.tl-calc-bar .tl-btn { margin-top: 0; }
.tl-calc-foot { padding: .9rem 1.5rem 1rem; border-top: 1px solid var(--border); background: var(--bg2); }
.tl-calc-foot .tl-fees { flex-direction: column; }

/* Marketplace switch: one segmented control, not a row of loose buttons. */
.tl-tabs { display: inline-flex; flex-wrap: wrap; gap: 3px; padding: 4px; border-radius: 12px;
  background: var(--bg3); border: 1px solid var(--border); }
.tl-tabs button { font: inherit; font-size: .9rem; font-weight: 700; padding: .55rem 1.05rem; border-radius: 9px;
  border: 0; background: transparent; color: var(--text2); cursor: pointer; }
.tl-tabs button:hover { color: var(--text); }
.tl-tabs button.active { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(8,14,48,.14), inset 0 -2px 0 var(--brand); }

.tl-calc-body { display: grid; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 980px) { .tl-calc-body { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); } }
.tl-inputs { padding: 1.4rem 1.5rem 1.5rem; min-width: 0; }
.tl-out { padding: 1.4rem 1.5rem 1.6rem; min-width: 0; background: var(--bg2); border-top: 1px solid var(--border); }
@media (min-width: 980px) { .tl-out { border-top: 0; border-left: 1px solid var(--border); } }
.tl-inputs h2, .tl-out h2 { font-size: 1rem; font-weight: 800; margin: 0 0 .85rem; color: var(--text); }
.tl-inputs h2 + .tl-fields { margin-bottom: 1rem; }
.tl-inputs .tl-check + h2, .tl-inputs .tl-fields + h2, .tl-inputs .tl-store-note + h2 { margin-top: 1.4rem; }

/* Fields */
.tl-fields { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem 1rem; align-items: end; }
@media (min-width: 640px) {
  .tl-f4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .tl-f3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.tl-fields .tl-wide { grid-column: 1 / -1; }
.tl-field { display: block; font-size: .8rem; font-weight: 700; color: var(--text2); min-width: 0; }
.tl-field .tl-in { position: relative; display: block; margin-top: .3rem; }
.tl-field input, .tl-field select { width: 100%; font: inherit; font-size: .98rem; font-weight: 700; color: var(--text);
  font-variant-numeric: tabular-nums; background: var(--bg); border: 1px solid var(--border2); border-radius: 9px;
  padding: .58rem .65rem; box-sizing: border-box; }
.tl-field input:focus, .tl-field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-mid-a); }
.tl-field input:read-only { background: var(--bg3); color: var(--muted); }
.tl-field .tl-in.money input { padding-left: 1.45rem; }
.tl-sym2 .tl-field .tl-in.money input { padding-left: 2.05rem; }
.tl-sym3 .tl-field .tl-in.money input { padding-left: 2.8rem; }
.tl-field .tl-sym { position: absolute; left: .65rem; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: .9rem; }
.tl-field .tl-in.pct input { padding-right: 1.6rem; }
.tl-field .tl-in.pct::after { content: '%'; position: absolute; right: .65rem; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: .9rem; }
.tl-field .tl-in.tl-pair { display: flex; gap: .35rem; }
.tl-field .tl-in.tl-pair input { flex: 1 1 auto; min-width: 0; }
.tl-field .tl-in.tl-pair select { flex: 0 0 4.2rem; width: 4.2rem; }
.tl-check { display: flex; align-items: center; gap: .55rem; font-size: .9rem; font-weight: 600; color: var(--text2); cursor: pointer; }
.tl-check input { width: 1.05rem; height: 1.05rem; accent-color: var(--brand); }
.tl-check[hidden] { display: none; }
.tl-check-field { align-self: end; min-height: 2.6rem; }
.tl-store-note { margin: .6rem 0 0; }
.tl-store-note:empty, .tl-store-note[hidden] { display: none; }
.tl-hint { font-size: .8rem; color: var(--muted); margin: .5rem 0 0; line-height: 1.45; }

.tl-more { border-top: 1px solid var(--border); margin-top: 1.2rem; }
.tl-more summary { cursor: pointer; font-weight: 700; font-size: .92rem; color: var(--brand-strong); padding: .8rem 0; }
[data-theme="dark"] .tl-more summary { color: var(--brand-bright); }
.tl-rates { display: grid; grid-template-columns: 7.5rem repeat(3, minmax(0, 1fr)); gap: .6rem .9rem; align-items: end; }
.tl-rates[hidden] { display: none; }
.tl-rates:not([hidden]) ~ .tl-rates:not([hidden]) { margin-top: .9rem; }
.tl-rates .tl-rlabel { font-size: .86rem; font-weight: 800; color: var(--text); align-self: center; padding-top: 1.2rem; }
.tl-btn { font: inherit; font-size: .85rem; font-weight: 700; padding: .55rem .95rem; border-radius: 9px; cursor: pointer;
  border: 1px solid var(--border2); background: var(--bg); color: var(--text); margin-top: 1rem; }
.tl-btn:hover { border-color: var(--brand); }
.tl-btn-quiet { margin-top: 1.2rem; }

/* ── Results ─────────────────────────────────────────────────────────── */
.tl-keep { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: .1rem 1rem;
  padding-bottom: 1rem; }
.tl-keep-l { font-size: .9rem; font-weight: 700; color: var(--text2); }
.tl-keep strong { grid-row: span 2; font-size: clamp(2.3rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.02em;
  line-height: 1; font-variant-numeric: tabular-nums; }
.tl-keep-m { font-size: .86rem; font-weight: 600; color: var(--muted); }

/* Where the sale goes: the signature of this page. */
.tl-split { display: flex; height: 16px; border-radius: 6px; overflow: hidden; background: var(--bg3); gap: 2px; }
.tl-seg { display: block; height: 100%; min-width: 3px; transition: width .25s ease; }
@media (prefers-reduced-motion: reduce) { .tl-seg { transition: none; } }
.tl-seg-fee { background: var(--red); }
.tl-seg-ship { background: var(--amber); }
.tl-seg-card { background: var(--purple); }
.tl-seg-keep { background: var(--green); }
.tl-split-key { list-style: none; margin: .7rem 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: .35rem 1rem;
  font-size: .82rem; color: var(--text2); }
.tl-split-key li { display: flex; align-items: center; gap: .45rem; }
.tl-split-key i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.tl-split-key b { margin-left: auto; color: var(--text); font-variant-numeric: tabular-nums; }
.tl-loss { margin: .7rem 0 0; font-size: .88rem; font-weight: 700; color: var(--red); }
.tl-lines { margin-top: 1.1rem; padding-top: .4rem; border-top: 1px dashed var(--border2); }

.tl-row { display: flex; justify-content: space-between; gap: 1rem; padding: .42rem 0; font-size: .92rem; color: var(--text2); }
.tl-row span:last-child { text-align: right; font-weight: 700; color: var(--text); white-space: nowrap; font-variant-numeric: tabular-nums; }
.tl-div { border-top: 1px solid var(--border); margin: .35rem 0; }
.tl-row span.tl-pos, .tl-pos { color: var(--green); }
.tl-row span.tl-neg, .tl-neg { color: var(--red); }
.tl-row span.tl-amber { color: var(--amber); }
.tl-be { margin: 1rem 0 0; padding: .8rem .95rem; border-radius: 10px; background: var(--surface); border: 1px solid var(--border);
  font-size: .9rem; color: var(--text2); }
.tl-be:empty { display: none; }
.tl-be strong { color: var(--text); font-variant-numeric: tabular-nums; }
.tl-empty { color: var(--muted); font-size: .92rem; margin: .4rem 0; }
.tl-badge { display: inline-block; font-size: .7rem; font-weight: 800; letter-spacing: .02em;
  background: var(--green); color: #fff; border-radius: 5px; padding: .14rem .45rem; margin-left: .35rem; vertical-align: middle; }
[data-theme="dark"] .tl-badge { color: #052e16; }

/* Compare All: one bar per marketplace, scaled to the best profit. */
.tl-cmp-lede { margin: 0 0 .9rem; font-size: .88rem; color: var(--muted); }
.tl-cmp { padding: .8rem 0; border-top: 1px solid var(--border); }
.tl-cmp:first-of-type { border-top: 0; }
.tl-cmp-top { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.tl-cmp-name { font-weight: 800; color: var(--text); }
.tl-cmp-val { font-size: 1.3rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.tl-cmp-track { height: 8px; border-radius: 4px; background: var(--bg3); margin: .45rem 0 .4rem; overflow: hidden; }
.tl-cmp-track span { display: block; height: 100%; background: var(--brand); border-radius: 4px; }
.tl-cmp-best .tl-cmp-track span { background: var(--green); }
.tl-cmp-sub { display: flex; justify-content: space-between; gap: 1rem; font-size: .8rem; color: var(--muted); font-variant-numeric: tabular-nums; }

/* ── Sell-through: grouped inputs row, prediction row ─────────────────── */
.tl-fees { margin: 0; font-size: .84rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: .2rem 1.2rem; }
.tl-groups { display: grid; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 700px) { .tl-groups { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1180px) { .tl-groups { grid-template-columns: 1fr 1.25fr .85fr 1.25fr; } }
.tl-group { padding: 1.3rem 1.5rem 1.4rem; min-width: 0; border-top: 1px solid var(--border); }
@media (min-width: 700px) { .tl-group:nth-child(-n+2) { border-top: 0; } .tl-group:nth-child(even) { border-left: 1px solid var(--border); } }
@media (min-width: 1180px) { .tl-group { border-top: 0; } .tl-group + .tl-group { border-left: 1px solid var(--border); } }
.tl-group h3 { font-size: .95rem; font-weight: 800; margin: 0 0 .85rem; color: var(--text); }
.tl-group .tl-fields + .tl-fields { margin-top: .8rem; }
.tl-pred-body { padding: 1.4rem 1.5rem 1.4rem; }
.tl-pred-body h3 { font-size: .95rem; font-weight: 800; margin: 1.4rem 0 .5rem; color: var(--text); }
.tl-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
@media (min-width: 900px) { .tl-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tl-tile { border-left: 3px solid var(--border2); padding: .2rem 0 .2rem .9rem; }
.tl-tile span { display: block; font-size: .84rem; font-weight: 700; color: var(--text2); }
.tl-tile strong { display: block; font-size: clamp(1.4rem, 2.4vw, 1.9rem); font-weight: 800; letter-spacing: -.015em;
  color: var(--text); margin: .25rem 0 .15rem; font-variant-numeric: tabular-nums; }
.tl-tile small { font-size: .78rem; color: var(--muted); }
/* Under the four tiles: the prediction is a model, not a promise (25 Oct 2026). */
.tl-pred-note { margin: .6rem 0 0; font-size: .82rem; color: var(--muted); }
.tl-tile-key { border-left-color: var(--green); }
.tl-tile-key strong { color: var(--green); }
.tl-chart { width: 100%; height: 300px; display: block; }
.tl-table-wrap { overflow-x: auto; margin-top: 1rem; }
.tl-table { width: 100%; border-collapse: collapse; font-size: .88rem; font-variant-numeric: tabular-nums; }
.tl-table th { text-align: right; font-size: .78rem; font-weight: 700; color: var(--muted);
  padding: .55rem .6rem; border-bottom: 1px solid var(--border2); white-space: nowrap; }
.tl-table td { text-align: right; padding: .55rem .6rem; border-bottom: 1px solid var(--border); white-space: nowrap; color: var(--text2); }
.tl-table th:first-child, .tl-table td:first-child { text-align: left; }
.tl-table tr.tl-hidden { display: none; }
.tl-table tr.tl-sub td { font-size: .8rem; color: var(--muted); padding-top: .3rem; padding-bottom: .3rem; border-bottom-style: dashed; }
.tl-table tr.tl-sub td:first-child { padding-left: 1.2rem; }
.tl-table td.tl-pc.tl-pos { color: var(--green); font-weight: 700; }
.tl-table td.tl-pc.tl-neg { color: var(--red); font-weight: 700; }

/* Chart hover */
.tl-chart-wrap { position: relative; }
.tl-chart-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .3rem 1rem; margin: 1.4rem 0 .5rem; }
.tl-chart-head h3 { margin: 0 !important; }
.tl-legend { margin: 0; font-size: .8rem; color: var(--muted); display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.tl-key { display: inline-block; width: 18px; height: 0; border-top: 2.5px solid var(--brand); margin-left: .4rem; }
.tl-key-live { border-top: 2px dashed var(--cyan); }
.tl-chart-tip em { display: block; font-style: normal; font-size: .74rem; color: var(--cyan); }
.tl-chart-tip { position: absolute; transform: translate(-50%, -100%); pointer-events: none; white-space: nowrap;
  background: var(--surface); border: 1px solid var(--border2); border-radius: 8px; padding: .4rem .65rem;
  box-shadow: var(--shadow-md); font-size: .8rem; color: var(--text2); text-align: center; }
.tl-chart-tip[hidden] { display: none; }
.tl-chart-tip span { display: block; font-weight: 700; color: var(--muted); font-size: .74rem; }
.tl-chart-tip strong { font-size: 1rem; color: var(--text); }
.tl-chart-tip small { margin-left: .3rem; color: var(--muted); }
.tl-chart-dot { fill: var(--surface); stroke: var(--brand); stroke-width: 2.5; }

/* Hover hints on unclear inputs */
.tl-tip { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 1.05rem; height: 1.05rem;
  margin-left: .3rem; border-radius: 50%; border: 1px solid var(--border2); color: var(--muted); font-size: .68rem;
  font-weight: 800; cursor: help; vertical-align: middle; }
.tl-tip:hover, .tl-tip:focus-visible { color: var(--text); border-color: var(--brand); outline: none; }
.tl-tip::after { content: attr(data-help); position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%);
  width: 15rem; padding: .55rem .7rem; border-radius: 8px; background: var(--text); color: var(--bg); font-size: .76rem;
  font-weight: 500; line-height: 1.45; text-align: left; box-shadow: var(--shadow-md); opacity: 0; visibility: hidden;
  transition: opacity .12s; z-index: 5; pointer-events: none; }
.tl-tip:hover::after, .tl-tip:focus-visible::after { opacity: 1; visibility: visible; }
@media (prefers-reduced-motion: reduce) { .tl-tip::after { transition: none; } }
.tl-viewall { font: inherit; display: block; margin: .8rem auto 0; background: none; border: none; color: var(--brand-strong);
  font-weight: 700; font-size: .9rem; cursor: pointer; }
[data-theme="dark"] .tl-viewall { color: var(--brand-bright); }

/* ── Reference sections: left-aligned, two columns ───────────────────── */
.tl-ref, .tl-tips, .tl-faq { padding-top: 4.5rem; }
.tl-ref { display: grid; gap: 2.5rem 4rem; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 980px) { .tl-ref { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); } }
.tl-ref h2, .tl-tips h2, .tl-faq h2 { font-size: clamp(1.45rem, 2.4vw, 1.95rem); font-weight: 800; letter-spacing: -.015em;
  line-height: 1.15; margin: 0 0 1.1rem; color: var(--text); text-wrap: balance; }
.tl-ref p, .tl-ref li, .tl-tips li { color: var(--text2); line-height: 1.7; font-size: 1rem; max-width: 70ch; }
.tl-ref p { margin: 0 0 1rem; }
.tl-ref a { color: var(--brand-strong); font-weight: 600; }
[data-theme="dark"] .tl-ref a { color: var(--brand-bright); }
.tl-ftable { width: 100%; border-collapse: collapse; margin: 0 0 1.3rem; font-size: .94rem; }
.tl-ftable th, .tl-ftable td { text-align: left; padding: .65rem .2rem; border-bottom: 1px solid var(--border); color: var(--text2); vertical-align: top; }
.tl-ftable thead th { color: var(--muted); font-size: .82rem; font-weight: 700; border-bottom-color: var(--border2); }
.tl-ftable td:first-child { color: var(--text); font-weight: 600; padding-right: 1.2rem; }

/* The worked example as a sale slip: the same two orders side by side. */
.tl-slip { width: 100%; border-collapse: collapse; margin: 0 0 1.3rem; font-size: .94rem; font-variant-numeric: tabular-nums;
  background: var(--bg2); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.tl-slip th, .tl-slip td { padding: .6rem 1rem; text-align: right; color: var(--text2); }
.tl-slip th[scope="row"] { text-align: left; font-weight: 600; color: var(--text2); }
.tl-slip thead th { font-size: .82rem; font-weight: 700; color: var(--muted); border-bottom: 1px solid var(--border); }
.tl-slip tfoot th, .tl-slip tfoot td { border-top: 1px dashed var(--border2); color: var(--text); font-weight: 800; }
.tl-slip tfoot tr:first-child td { font-size: 1.05rem; }
.tl-slip tfoot td.tl-pos { color: var(--green); }
.tl-slip tfoot td.tl-neg { color: var(--red); }
.tl-slip .tl-slip-per th, .tl-slip .tl-slip-per td { border-top: 0; padding-top: 0; font-weight: 600; color: var(--muted); font-size: .86rem; }
.tl-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.tl-steps { padding-left: 1.1rem; margin: 0; }
.tl-steps li + li { margin-top: .55rem; }

/* Ways to keep more: four short tips across, each under its own rule. */
.tl-tiplist { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.5rem 2rem;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.tl-tiplist li { border-top: 3px solid var(--brand); padding-top: .9rem; font-size: .96rem; line-height: 1.65; }
.tl-tiplist strong { display: block; color: var(--text); font-size: 1.02rem; margin-bottom: .3rem; }

/* FAQ: heading beside one ruled list. */
.tl-faq { display: grid; gap: 1.5rem 4rem; grid-template-columns: minmax(0, 1fr); padding-bottom: 4rem; }
@media (min-width: 980px) {
  .tl-faq { grid-template-columns: minmax(0, .8fr) minmax(0, 1.6fr); }
  .tl-faq-head { position: sticky; top: calc(var(--nav-h) + 1.5rem); align-self: start; }
}
.tl-faq-head p { margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.6; }
.tl-faq-list { border-top: 1px solid var(--border2); }
.tl-q { border-bottom: 1px solid var(--border); }
.tl-q summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 1.5rem;
  padding: 1.05rem 0; font-weight: 700; font-size: 1.04rem; color: var(--text); }
.tl-q summary::-webkit-details-marker { display: none; }
.tl-q summary::after { content: ''; flex: none; width: .55rem; height: .55rem; margin-top: .35rem;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s; }
.tl-q[open] summary::after { transform: rotate(-135deg); margin-top: .6rem; }
@media (prefers-reduced-motion: reduce) { .tl-q summary::after { transition: none; } }
.tl-q p { margin: 0 0 1.15rem; max-width: 72ch; color: var(--text2); font-size: 1rem; line-height: 1.7; }

/* Closing CTA: the site's blue band carrying the page's own paragraph. */
.tl-cta { margin-top: 1rem; }
.tl-cta .cta-band-sub { max-width: 72ch; line-height: 1.65; }
.tl-cta .cta-band-sub a { color: #fff; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* Store table section on the sell-through page. */
.tl-stores { padding-top: 4.5rem; text-align: center; }
.tl-stores .tl-stores-lede, .tl-stores .tl-stores-note { margin-left: auto; margin-right: auto; }
.tl-stores .tl-tabs { justify-content: center; }
.tl-stores .tl-table-wrap { display: flex; justify-content: center; }
.tl-stores .tl-storetable { width: auto; min-width: min(100%, 980px); text-align: left; }
.tl-stores h2 { font-size: clamp(1.45rem, 2.4vw, 1.95rem); font-weight: 800; letter-spacing: -.015em; line-height: 1.15;
  margin: 0 0 .9rem; color: var(--text); }
.tl-stores-lede { margin: 0 0 1.2rem; max-width: 78ch; color: var(--text2); line-height: 1.7; font-size: 1rem; }
.tl-stores .tl-tabs { margin-bottom: 1rem; }
.tl-storetable { margin: 0; font-variant-numeric: tabular-nums; }
.tl-storetable th, .tl-storetable td { white-space: nowrap; padding-right: 1.2rem; }
.tl-storetable tbody th { color: var(--text); font-weight: 700; }
.tl-store-panel[hidden] { display: none; }
.tl-stores-note { max-width: 90ch; font-size: .88rem; margin-top: .8rem; }

/* Upgrade advice when the listings pass a Store's free listings. */
.tl-advice { margin: 1.2rem 0 0; padding: .85rem 1rem; border-radius: 10px; border: 1px solid var(--amber);
  background: rgba(217, 119, 6, .08); color: var(--text); font-size: .92rem; line-height: 1.55; }
.tl-advice[hidden] { display: none; }
.tl-advice + .tl-advice { margin-top: .6rem; }
.tl-advice-var { border-color: var(--purple); background: rgba(124, 58, 237, .08); }
.tl-advice-var .tl-advice-btn + .tl-advice-btn { margin-left: .4rem; }
.tl-var-check { margin-top: .9rem; flex-wrap: wrap; }
.tl-advice-var .tl-advice-btn { border-color: var(--purple); text-decoration: none; display: inline-block; }
.tl-advice-var .tl-advice-btn:hover { background: var(--purple); color: #fff; }
.tl-advice-row td { white-space: normal !important; text-align: left !important; background: rgba(217, 119, 6, .08);
  color: var(--text); font-size: .86rem; line-height: 1.5; border-left: 3px solid var(--amber); }
.tl-advice-btn { font: inherit; font-size: .82rem; font-weight: 700; margin-left: .4rem; padding: .3rem .7rem; border-radius: 7px;
  border: 1px solid var(--amber); background: var(--surface); color: var(--text); cursor: pointer; }
.tl-advice-btn:hover { background: var(--amber); color: #fff; }
.tl-table td.tl-amber { color: var(--amber); font-weight: 700; }

@media (max-width: 639px) {
  .tl-hero { padding-bottom: 6rem; }
  .tl-lift { margin-top: -4rem; }
  .tl-calc-bar, .tl-inputs, .tl-out, .tl-group, .tl-pred-body { padding-left: 1.05rem; padding-right: 1.05rem; }
  .tl-tabs { display: flex; width: 100%; }
  .tl-tabs button { flex: 1 1 auto; padding: .5rem .6rem; font-size: .85rem; }
  .tl-rates { grid-template-columns: 1fr 1fr; }
  .tl-f3 > :last-child { grid-column: 1 / -1; }
  .tl-sites { grid-template-columns: 1fr; gap: .4rem; }
  .tl-site { padding: .55rem .8rem; font-size: .86rem; flex-wrap: nowrap; }
  .tl-rates .tl-rlabel { grid-column: 1 / -1; padding-top: 0; }
  .tl-split-key { grid-template-columns: 1fr; }
  .tl-slip th, .tl-slip td { padding: .5rem .55rem; font-size: .86rem; }
  .tl-site-extra { display: none; }
  .tl-ref, .tl-tips, .tl-faq { padding-top: 3.2rem; }
}

/* Touch sizes and number wrapping, phones and tablets. */
.tl-slip td { white-space: nowrap; }
@media (max-width: 834px) {
  .tl-tabs button { min-height: 44px; }
  .tl-viewall { padding: .75rem 1rem; }
  .tl-advice-btn { min-height: 38px; }
}

/* Number fields with steppers: the % sign sits left of the arrows. */
.tl-field .tl-in.pct input[type="number"] { padding-right: 2.5rem; }
.tl-field .tl-in.pct:has(input[type="number"])::after { right: 1.85rem; }
