/* ==========================================================================
   Venpo · free tools index (/tools)

   Ported from the "Venpo Tools v2" prototype (tools-base / tools-page-v2 /
   tools-detail-v2 / tools-sketches). Loaded AFTER pub/pub.css, which supplies
   the tokens and a handful of bare-element rules — `section{padding:64px 0 0}`
   above all — plus classes this page would otherwise collide with (.btn,
   .band, .faq). Every rule below is therefore scoped under .tls, and the
   inherited `section` padding is reset explicitly rather than relied on.

   Per-tool accents (each section's icon tile, check marks and button) arrive
   as the inline custom property --tls-accent on the element that needs them,
   so one set of rules covers all four tools.
   ========================================================================== */

.tls {
    /* The prototype's palette minus what pub.css already declares on :root. */
    --tls-neut-soft: #eeecf2;
    --tls-navy-soft: #e8eef4;
    --tls-border-soft: #efedf3;
    --tls-mono: 'JetBrains Mono', ui-monospace, monospace;
    --tls-serif: 'Source Serif 4', Georgia, serif;
    background: var(--paper);
}

.tls section { padding: 0; scroll-margin-top: 72px; }
.tls-wrap { max-width: 1200px; margin: 0 auto; padding: 0 40px; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
.tls-hero { background: var(--paper); }
.tls-hero .tls-wrap { padding-top: 72px; padding-bottom: 64px; text-align: center; }
.tls-hero h1 {
    margin: 0 auto;
    max-width: 760px;
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -1.8px;
    color: var(--ink);
    text-wrap: balance;
}
.tls-hero p {
    margin: 18px auto 0;
    max-width: 520px;
    font-size: 17px;
    line-height: 1.55;
    color: var(--body);
    text-wrap: pretty;
}
.tls-chips { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 32px; }
.tls-chip {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 9px 16px 9px 10px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #fff;
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}
.tls-chip:hover { border-color: var(--purple-line); color: var(--ink); }
.tls-chip i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 7px;
    background: var(--tls-accent);
    flex: 0 0 auto;
}

/* --------------------------------------------------------------------------
   One tool: copy on one side, a lo-fi sketch of the tool on the other
   -------------------------------------------------------------------------- */
.tls-tool { background: var(--paper); }
.tls-tool .tls-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: 64px;
    align-items: center;
    padding-top: 80px;
    padding-bottom: 80px;
}
.tls-tool-text { min-width: 0; order: 1; }
.tls-tool-art { min-width: 0; order: 2; }
.tls-flip .tls-tool-text { order: 2; }
.tls-flip .tls-tool-art { order: 1; }

.tls-kick { display: flex; align-items: center; gap: 10px; }
.tls-kick span { font-size: 14px; font-weight: 600; color: var(--muted); }
.tls-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--tls-accent);
    flex: 0 0 auto;
}
.tls h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 34px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.9px;
    color: var(--ink);
    text-wrap: pretty;
}
.tls-tool h2 { margin-top: 18px; }
.tls-lede {
    margin: 14px 0 0;
    max-width: 480px;
    font-size: 16.5px;
    line-height: 1.6;
    color: var(--body);
    text-wrap: pretty;
}
.tls-points { margin: 24px 0 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.tls-points li { display: flex; gap: 12px; align-items: center; font-size: 15px; color: var(--ink); }
.tls-points svg { flex: 0 0 auto; }
.tls-go { margin-top: 30px; }

.tls-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 18px;
    border: 1px solid transparent;
    border-radius: 999px;
    background: var(--tls-accent, var(--ink));
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}
/* brightness() rather than a second colour token: the accent differs per tool
   and is only known from the inline custom property. */
.tls-btn:hover { color: #fff; filter: brightness(.92); }

/* --------------------------------------------------------------------------
   Sketches — a lo-fi rendering of each tool's own UI, not a screenshot
   -------------------------------------------------------------------------- */
.tls-sk { background: #fff; border-radius: 16px; overflow: hidden; padding: 20px; }
.tls-lab {
    font-family: var(--tls-mono);
    font-size: 8.5px;
    font-weight: 500;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--dim);
}

/* 1 · Vendor assessment */
.tls-as-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.tls-as-party { display: flex; align-items: center; gap: 8px; margin-top: 5px; }
.tls-as-party img { width: 22px; height: 22px; border-radius: 6px; object-fit: contain; }
.tls-as-party b { font-size: 17px; font-weight: 700; letter-spacing: -0.4px; color: var(--ink); }
.tls-as-head > div + div { text-align: right; }
.tls-as-head > div + div .tls-as-party { justify-content: flex-end; }
.tls-as-verdict {
    margin-top: 14px;
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 18px 20px;
    border-radius: 12px;
    background: linear-gradient(135deg, #8b1e2e, #6e1523);
    color: #fff;
}
.tls-as-verdict > div { min-width: 0; }
.tls-as-tag {
    display: inline-block;
    padding: 3px 7px;
    border-radius: 4px;
    background: rgba(255, 255, 255, .14);
    color: rgba(255, 255, 255, .75);
}
.tls-as-v { margin-top: 10px; font-size: 28px; font-weight: 800; letter-spacing: -0.9px; line-height: 1.05; }
.tls-as-score { border-left: 1px solid rgba(255, 255, 255, .18); padding-left: 16px; }
.tls-as-n { display: flex; align-items: baseline; gap: 3px; }
.tls-as-n b { font-size: 30px; font-weight: 800; letter-spacing: -1px; line-height: 1; }
.tls-as-n span { font-family: var(--tls-mono); font-size: 10px; color: rgba(255, 255, 255, .7); }
.tls-as-pips { display: flex; gap: 3px; margin-top: 8px; }
.tls-as-pips span { flex: 1; height: 5px; border-radius: 2px; background: rgba(255, 255, 255, .22); }
.tls-as-pips span.on { background: #e3b64a; }
.tls-as-score .tls-lab { margin-top: 8px; letter-spacing: 1px; color: rgba(255, 255, 255, .72); }
.tls-as-box { margin-top: 12px; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.tls-as-boxh { padding: 12px 14px; background: #efece3; border-bottom: 1px solid var(--border); }
.tls-as-boxh b { font-size: 13.5px; font-weight: 700; letter-spacing: -0.3px; color: var(--ink); }
.tls-as-boxh span { display: block; margin-top: 2px; font-size: 10.5px; color: var(--muted); }
.tls-as-q { display: flex; align-items: flex-start; gap: 9px; padding: 9px 14px; background: #fff; }
.tls-as-q + .tls-as-q { border-top: 1px solid var(--tls-border-soft); }
.tls-as-q > svg:first-child { margin-top: 2px; flex: 0 0 auto; }
.tls-as-q > div { min-width: 0; flex: 1; }
.tls-as-q b { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink); }
.tls-as-q span { display: block; margin-top: 1px; font-size: 10.5px; color: var(--muted); }
.tls-as-q > svg:last-child { flex: 0 0 auto; }

/* 2 · Subprocessor graph */
.tls-gr-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; align-items: start; }
.tls-gr-row.mid { align-items: center; }
.tls-gr-row > div { min-width: 0; }
.tls-gr-tagcell { display: flex; justify-content: flex-end; }
.tls-gr-tagcell.pad { padding-top: 8px; }
.tls-gr-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 7px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    font-family: var(--tls-mono);
    font-size: 8px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--dim);
    white-space: nowrap;
}
.tls-gr-tag b { font-size: 10px; color: var(--ink); }
.tls-node {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    padding: 6px 7px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: #fff;
}
.tls-node.dark { background: var(--ink); border-color: var(--ink); }
.tls-node > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    background: #fff;
    overflow: hidden;
    flex: 0 0 auto;
}
.tls-node > span img { width: 100%; height: 100%; object-fit: contain; }
.tls-node > div { min-width: 0; flex: 1; }
.tls-node b,
.tls-node em {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-style: normal;
}
.tls-node b { font-size: 11px; font-weight: 600; color: var(--ink); }
.tls-node em { font-size: 8.5px; color: var(--dim); }
.tls-node.dark b { color: #fff; }
.tls-node.dark em { color: rgba(255, 255, 255, .6); }
.tls-node > svg { flex: 0 0 auto; }
.tls-gr-end {
    margin-top: 5px;
    font-family: var(--tls-mono);
    font-size: 6.5px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    text-align: center;
    color: var(--purple);
}
.tls-gr-link { display: block; width: 100%; }

/* 3 · Redline */
.tls-rd-bar {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    padding: 10px 14px;
    border-bottom: 1px solid var(--tls-border-soft);
}
.tls-rd-view {
    padding: 5px 11px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: transparent;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--muted);
}
.tls-rd-view.on { background: var(--purple); border-color: var(--purple); color: #fff; }
.tls-rd-tgs { margin-left: auto; display: flex; gap: 12px; align-items: center; }
.tls-rd-tg {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-family: var(--tls-mono);
    font-size: 9.5px;
    color: var(--muted);
}
.tls-rd-tg i {
    position: relative;
    width: 20px;
    height: 11px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: var(--purple-soft);
}
.tls-rd-tg i::after {
    content: '';
    position: absolute;
    top: 1px;
    right: 1px;
    width: 7px;
    height: 7px;
    border-radius: 7px;
    background: var(--purple);
}
.tls-rd-doc {
    padding: 18px 20px;
    font-family: var(--tls-serif);
    font-size: 14px;
    line-height: 1.7;
    color: var(--body);
}
.tls-rd-cap { font-family: var(--tls-mono); font-size: 10px; color: var(--dim); margin-bottom: 8px; }
.tls-rd-doc del {
    padding: 0 2px;
    border-radius: 3px;
    background: var(--neg-soft);
    color: var(--neg);
    text-decoration: line-through;
    text-decoration-thickness: 1px;
}
.tls-rd-doc ins {
    padding: 0 2px;
    border-radius: 3px;
    background: var(--pos-soft);
    color: var(--pos);
    text-decoration: none;
}
.tls-rd-moved { padding: 0 2px; border-radius: 3px; background: var(--amber-soft); color: var(--amber); }
.tls-rd-foot {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--border);
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    font-family: var(--tls-mono);
    font-size: 9.5px;
    color: var(--muted);
}
.tls-rd-foot .add { color: var(--pos); }
.tls-rd-foot .rem { color: var(--neg); }
.tls-rd-foot .mov { color: var(--amber); }
.tls-rd-foot .rel { color: var(--dim); }

/* 4 · Change feed */
.tls-fd { position: relative; padding-left: 22px; }
.tls-fd > i { position: absolute; left: 5px; top: 8px; bottom: 8px; width: 1px; background: var(--tls-border-soft); }
.tls-fd-day + .tls-fd-day { margin-top: 18px; }
.tls-fd-h { position: relative; display: flex; align-items: center; gap: 10px; }
.tls-fd-h i {
    position: absolute;
    left: -21px;
    width: 9px;
    height: 9px;
    border-radius: 9px;
    background: var(--purple);
    box-shadow: 0 0 0 3px #fff;
}
.tls-fd-h span { font-size: 11.5px; font-weight: 600; color: var(--ink); }
.tls-fd-rows { margin-top: 8px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; }
.tls-fd-row {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 9px 12px;
    border: 1px solid var(--tls-border-soft);
    border-radius: 10px;
    background: #fff;
}
.tls-fd-row img { width: 20px; height: 20px; border-radius: 5px; object-fit: contain; flex: 0 0 auto; }
.tls-fd-row b { font-size: 12px; font-weight: 600; color: var(--ink); white-space: nowrap; }
.tls-fd-row em {
    flex: 1;
    min-width: 0;
    font-style: normal;
    font-size: 11.5px;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.tls-fd-n { display: flex; gap: 10px; flex: 0 0 auto; }
.tls-ct { display: inline-flex; align-items: center; gap: 4px; }
.tls-ct.zero { opacity: .38; }
.tls-ct i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    border-radius: 5px;
}
.tls-ct b { font-family: var(--tls-mono); font-size: 11px; font-weight: 600; min-width: 7px; }
.tls-ct.neg i { background: var(--neg-soft); color: var(--neg); }
.tls-ct.neg b { color: var(--neg); }
.tls-ct.pos i { background: var(--pos-soft); color: var(--pos); }
.tls-ct.pos b { color: var(--pos); }
.tls-ct.eq i { background: var(--tls-neut-soft); color: var(--body); }
.tls-ct.eq b { color: var(--body); }
.tls-ct.zero b { color: var(--faint); }

/* --------------------------------------------------------------------------
   FAQ — native <details>, so it answers without JavaScript
   -------------------------------------------------------------------------- */
.tls-faq { background: var(--paper); }
.tls-faq .tls-wrap { padding-top: 80px; padding-bottom: 80px; }
.tls-faq h2 { text-align: center; }
.tls-faq-list { max-width: 720px; margin: 32px auto 0; }
.tls-faq-list details { border-top: 1px solid var(--tls-border-soft); }
.tls-faq-list details:last-child { border-bottom: 1px solid var(--tls-border-soft); }
.tls-faq-list summary {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 0;
    list-style: none;
    cursor: pointer;
    font-size: 15.5px;
    font-weight: 600;
    color: var(--ink);
}
.tls-faq-list summary::-webkit-details-marker { display: none; }
.tls-faq-list summary span { flex: 1; }
.tls-faq-list summary .tls-minus,
.tls-faq-list details[open] summary .tls-plus { display: none; }
.tls-faq-list details[open] summary .tls-minus { display: block; }
.tls-faq-list p { margin: 0 0 20px; font-size: 15px; line-height: 1.6; color: var(--muted); text-wrap: pretty; }

/* --------------------------------------------------------------------------
   Closing band
   -------------------------------------------------------------------------- */
.tls-cta { background: var(--ink); }
/* The shared footer keeps a 56px paper margin above itself (chrome.css
   .footer). Every other public page ends on paper, where that reads as
   breathing room; here it would cut a light strip between the dark band and
   the footer, so the band reclaims it and sits flush. */
.tls-cta { margin-bottom: -56px; }
.tls-cta .tls-wrap { padding-top: 80px; padding-bottom: 80px; text-align: center; }
.tls-cta h2 { color: #fff; }
.tls-cta p {
    margin: 14px auto 0;
    max-width: 460px;
    font-size: 16.5px;
    line-height: 1.6;
    color: rgba(255, 255, 255, .72);
    text-wrap: pretty;
}
.tls-cta-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 28px; }
.tls-cta-btns a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 22px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
}
.tls-cta-btns .tls-solid { background: #fff; color: var(--ink); }
.tls-cta-btns .tls-solid:hover { background: #f2ecfd; color: var(--ink); }
.tls-cta-btns .tls-outline { border: 1px solid rgba(255, 255, 255, .28); color: #fff; }
.tls-cta-btns .tls-outline:hover { border-color: rgba(255, 255, 255, .55); color: #fff; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 860px) {
    .tls-tool .tls-wrap { grid-template-columns: minmax(0, 1fr); gap: 32px; }
    /* Copy always leads once the columns collapse, whichever side it sat on. */
    .tls-tool .tls-wrap > div { order: initial; }
}

@media (max-width: 640px) {
    .tls-wrap { padding-left: 22px; padding-right: 22px; }
}
