/* The Quote Link: the customer's page (/r/<slug>), the owner's Quote requests page, and the demo result.
   Loaded after style.css; uses only its colour tokens, so light and dark both work. */

/* ---------------------------------------------------------------- the customer's page */
.ql-body { background: var(--bg-sunken); min-height: 100vh; }
.ql-wrap { max-width: 680px; margin: 0 auto; padding: 22px 16px 56px; }
.ql-loading, .ql-error { text-align: center; color: var(--text-muted); padding: 60px 8px; font-size: 16px; }
.ql-error { color: var(--text); }
.ql-demo-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 0 0 14px; padding: 12px 16px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-strong); font-size: 14px; font-weight: 600; line-height: 1.4; }
.ql-demo-bar label { font-weight: 700; }
.ql-demo-bar select { font-size: 14px; padding: 7px 10px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--bg-elevated); color: var(--text); }
.ql-head { display: flex; gap: 16px; align-items: center; margin-bottom: 18px; }
.ql-logo { width: 56px; height: 56px; border-radius: 12px; object-fit: contain; background: #fff; border: 1px solid var(--border); flex: none; }
.ql-biz { font-size: clamp(1.45rem, 5vw, 1.9rem); line-height: 1.15; letter-spacing: -0.03em; margin: 0; }
.ql-sub { margin: 4px 0 0; color: var(--text-muted); font-size: 14.5px; line-height: 1.5; }
.ql-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow); padding: 24px 22px; }
.ql-lede { margin: 0 0 20px; font-size: 16.5px; line-height: 1.55; color: var(--text); }
.ql-form fieldset { border: 0; padding: 0; margin: 0 0 22px; min-width: 0; }
.ql-form legend, .ql-form .ql-label { display: block; padding: 0; margin: 0 0 10px; font-size: 15px; font-weight: 800; letter-spacing: -0.01em; color: var(--text); }
.ql-num { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 8px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 800; vertical-align: 1px; }
.ql-hint { margin: -4px 0 10px; font-size: 13.5px; color: var(--text-muted); line-height: 1.45; }
.ql-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ql-chip { position: relative; }
.ql-chip input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.ql-chip span { display: inline-flex; align-items: center; min-height: 44px; padding: 9px 16px; border: 1.5px solid var(--border-strong); border-radius: 999px; background: var(--bg); font-size: 14.5px; font-weight: 600; line-height: 1.25; color: var(--text); transition: border-color .15s ease, background .15s ease; }
.ql-chip input:hover + span { border-color: var(--accent); }
.ql-chip input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-strong); box-shadow: inset 0 0 0 1px var(--accent); }
.ql-chip input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }
.ql-form .field { margin-bottom: 14px; }
.ql-form .field input, .ql-form .field textarea { font-size: 16px; }              /* 16px stops iOS zooming in on focus */
.ql-form textarea { min-height: 116px; }
.ql-count { text-align: right; font-size: 12.5px; color: var(--text-muted); margin-top: 4px; }
.ql-q { margin-bottom: 18px; }
.ql-q .ql-label { font-size: 14.5px; font-weight: 700; margin-bottom: 8px; }
.ql-photos { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-start; }
.ql-photo-add { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; width: 96px; height: 96px; border: 2px dashed var(--border-strong); border-radius: 14px; background: var(--bg); color: var(--accent-strong); font-size: 12.5px; font-weight: 700; cursor: pointer; text-align: center; padding: 6px; }
.ql-photo-add:hover, .ql-photo-add:focus-within { border-color: var(--accent); background: var(--accent-soft); }
.ql-photo-add input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.ql-photo-add[hidden] { display: none; }
.ql-thumb { position: relative; width: 96px; height: 96px; border-radius: 14px; overflow: hidden; border: 1px solid var(--border); background: var(--bg-sunken); }
.ql-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ql-thumb.busy::after { content: ""; position: absolute; inset: 0; background: color-mix(in srgb, var(--bg-elevated) 70%, transparent); }
.ql-thumb button { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; border-radius: 50%; border: 0; background: rgba(14, 31, 24, .78); color: #fff; font-size: 17px; line-height: 1; cursor: pointer; }
.ql-thumb button:focus-visible { outline: 2px solid #fff; outline-offset: 1px; }
.ql-consent { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 16px; font-size: 14px; line-height: 1.5; color: var(--text-muted); }
.ql-consent input { width: 22px; height: 22px; margin-top: 1px; flex: none; accent-color: var(--accent); }
.ql-consent a { color: var(--accent-strong); }
.ql-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.ql-submit { width: 100%; justify-content: center; min-height: 52px; font-size: 16.5px; }
.ql-msg { margin: 0 0 14px; padding: 11px 14px; border-radius: 10px; font-size: 14.5px; line-height: 1.45; background: var(--red-soft); color: var(--red); }
.ql-msg[hidden] { display: none; }
.ql-fine { margin: 14px 0 0; font-size: 12.5px; line-height: 1.5; color: var(--text-muted); text-align: center; }
.ql-done { text-align: center; padding: 14px 4px 6px; }
.ql-done .ql-tick { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-strong); }
.ql-done h2 { font-size: 1.5rem; letter-spacing: -0.03em; margin: 0 0 8px; }
.ql-done p { color: var(--text-muted); font-size: 16px; line-height: 1.55; max-width: 44ch; margin: 0 auto 10px; }
.ql-next { text-align: left; max-width: 420px; margin: 18px auto 0; padding: 0; list-style: none; counter-reset: n; }
.ql-next li { counter-increment: n; position: relative; padding: 0 0 12px 36px; font-size: 15px; line-height: 1.45; color: var(--text); }
.ql-next li::before { content: counter(n); position: absolute; left: 0; top: -1px; width: 24px; height: 24px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-strong); font-weight: 800; font-size: 13px; display: grid; place-items: center; }
.ql-powered { margin: 22px 0 0; padding: 14px 16px; border-radius: 12px; background: var(--bg-sunken); font-size: 14px; color: var(--text-muted); line-height: 1.5; text-align: center; }
.ql-powered a { color: var(--accent-strong); font-weight: 700; }

/* the demo result: what the tradesperson sees */
.ql-result { margin-top: 20px; border: 2px solid var(--accent); border-radius: 18px; background: var(--bg-elevated); overflow: hidden; }
.ql-result-head { padding: 12px 18px; background: var(--accent); color: var(--on-accent); font-size: 13px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.ql-result-body { padding: 18px; }
.ql-result h3 { font-size: 1.15rem; letter-spacing: -0.02em; margin: 0 0 6px; }
.ql-result p { margin: 0 0 12px; color: var(--text-muted); font-size: 15px; line-height: 1.55; }
.ql-result h4 { font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); margin: 16px 0 6px; }
.ql-result ul { margin: 0 0 8px; padding-left: 20px; font-size: 15px; line-height: 1.55; color: var(--text); }
.ql-items { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.ql-items th, .ql-items td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--border); vertical-align: top; }
.ql-items th { font-size: 12px; letter-spacing: .05em; text-transform: uppercase; color: var(--text-muted); }
.ql-items .num { text-align: right; white-space: nowrap; }
.ql-items .need { color: var(--gold); font-weight: 700; font-size: 12.5px; }
.ql-total { display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; padding-top: 10px; border-top: 3px solid var(--highlight); font-weight: 800; font-size: 17px; }
.ql-reply { margin: 6px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--bg-sunken); color: var(--text); font-size: 15px; line-height: 1.5; white-space: pre-wrap; }
.ql-result-cta { padding: 16px 18px; background: var(--bg-sunken); text-align: center; border-top: 1px solid var(--border); }
.ql-result-cta p { margin: 0 0 12px; color: var(--text); font-weight: 600; }
.ql-result-cta .btn { white-space: normal; justify-content: center; margin: 4px; }
.ql-tag { display: inline-block; margin-left: 6px; padding: 2px 9px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-strong); font-size: 11.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; vertical-align: 2px; }

/* ---------------------------------------------------------------- the owner's Quote requests page */
.qr-lock { text-align: center; padding: 8px 0; }
.qr-lock h2 { font-size: 20px; margin: 0 0 8px; letter-spacing: -0.02em; }
.qr-lock p { max-width: 54ch; margin: 0 auto 14px; color: var(--text-muted); font-size: 15px; line-height: 1.55; }
.qr-switch { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.qr-switch label.qr-toggle { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; cursor: pointer; }
.qr-toggle input { width: 22px; height: 22px; accent-color: var(--accent); }
.qr-linkrow { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 6px; }
.qr-linkrow input { flex: 1; min-width: 220px; font-family: var(--font-body); font-size: 14.5px; padding: 11px 13px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--bg); color: var(--text); }
.qr-share { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; }
.qr-grid { display: grid; grid-template-columns: minmax(0, 1fr) 190px; gap: 22px; align-items: start; }
.qr-qr { text-align: center; }
.qr-qr canvas, .qr-qr svg { width: 168px; height: 168px; padding: 10px; background: #fff; border: 1px solid var(--border); border-radius: 12px; display: block; margin: 0 auto 8px; }
.qr-qr small { display: block; color: var(--text-muted); font-size: 12.5px; line-height: 1.4; }
.qr-where { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 14px; color: var(--text-muted); }
.qr-where li::before { content: "\2192"; color: var(--accent-strong); font-weight: 800; margin-right: 8px; }
.qr-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.qr-fields .field-wide { grid-column: 1 / -1; }
.qr-filter { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; }
.qr-filter button { border: 1px solid var(--border-strong); background: var(--bg); color: var(--text); font-size: 13.5px; font-weight: 700; padding: 7px 14px; border-radius: 999px; cursor: pointer; font-family: var(--font-body); }
.qr-filter button[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-strong); }
.qr-list { display: grid; gap: 10px; }
.qr-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; text-align: left; width: 100%; padding: 14px 16px; border: 1px solid var(--border); border-radius: 14px; background: var(--bg-elevated); color: var(--text); cursor: pointer; font-family: var(--font-body); }
.qr-item:hover { border-color: var(--accent); }
.qr-item.is-new { border-left: 4px solid var(--accent); }
.qr-item strong { font-size: 15.5px; }
.qr-item .qr-meta { grid-column: 1 / -1; color: var(--text-muted); font-size: 13.5px; line-height: 1.4; }
.qr-item .qr-when { color: var(--text-muted); font-size: 12.5px; white-space: nowrap; }
.qr-detail { border: 1px solid var(--border); border-radius: 16px; padding: 20px; margin-top: 14px; background: var(--bg-elevated); }
.qr-detail h3 { font-size: 18px; margin: 0 0 4px; letter-spacing: -0.02em; }
.qr-detail h4 { font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); margin: 18px 0 6px; }
.qr-detail p { margin: 0 0 8px; font-size: 15px; line-height: 1.55; }
.qr-desc { white-space: pre-wrap; padding: 12px 14px; border-radius: 12px; background: var(--bg-sunken); }
.qr-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 0; }
.qr-photos { display: flex; gap: 8px; flex-wrap: wrap; }
.qr-photos img { width: 120px; height: 120px; object-fit: cover; border-radius: 12px; border: 1px solid var(--border); cursor: zoom-in; }
.qr-ai-note { font-size: 13px; color: var(--text-muted); }
.qr-pill { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; background: var(--bg-sunken); color: var(--text-muted); }
.qr-pill.new { background: var(--accent); color: var(--on-accent); }
.qr-pill.quoted { background: var(--accent-soft); color: var(--accent-strong); }
.qr-pill.urgent { background: var(--red-soft); color: var(--red); }
@media (max-width: 680px) {
  .qr-grid { grid-template-columns: 1fr; }
  .qr-fields { grid-template-columns: 1fr; }
  .ql-card { padding: 20px 16px; }
}

/* ---------------------------------------------------------------- marketing: the Quote Link on the home page, /quote-link and the trade pages */
.qlm { display: flex; align-items: center; justify-content: center; gap: 14px; flex-wrap: wrap; }
.qlm-phone, .qlm-inbox { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 22px; box-shadow: var(--shadow-lg); text-align: left; color: var(--text); font-size: 13px; line-height: 1.4; }
.qlm-phone { width: 250px; padding: 14px 14px 16px; border-radius: 28px; border-width: 2px; }
.qlm-phone .qlm-bar { width: 54px; height: 5px; border-radius: 3px; background: var(--border-strong); margin: 0 auto 12px; opacity: .6; }
.qlm-biz { font-weight: 800; font-size: 15.5px; letter-spacing: -0.02em; }
.qlm-sub { color: var(--text-muted); font-size: 11.5px; margin-bottom: 10px; }
.qlm-label { font-weight: 800; font-size: 12px; margin: 8px 0 6px; }
.qlm-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.qlm-chips span { padding: 5px 10px; border: 1.5px solid var(--border-strong); border-radius: 999px; font-size: 11.5px; font-weight: 600; background: var(--bg); }
.qlm-chips span.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-strong); }
.qlm-text { margin-top: 8px; padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 9px; background: var(--bg); color: var(--text-muted); font-size: 11.5px; }
.qlm-photos { display: flex; gap: 6px; margin-top: 8px; }
.qlm-photos i { width: 46px; height: 46px; border-radius: 9px; background: linear-gradient(135deg, #b9c9c0, #7e978a); display: block; }
.qlm-photos i:nth-child(2) { background: linear-gradient(135deg, #cdbfa8, #8d7b5f); }
.qlm-photos i.add { background: var(--bg); border: 2px dashed var(--border-strong); display: grid; place-items: center; color: var(--accent-strong); font-style: normal; font-weight: 800; font-size: 18px; }
.qlm-btn { margin-top: 12px; padding: 10px 12px; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-weight: 800; font-size: 12.5px; text-align: center; }
.qlm-arrow { font-size: 26px; color: var(--accent-strong); font-weight: 800; }
.qlm-inbox { width: 292px; padding: 16px 16px 16px; }
.qlm-tag { display: inline-block; padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-strong); font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.qlm-title { margin: 8px 0 4px; font-weight: 800; font-size: 15px; letter-spacing: -0.02em; }
.qlm-title b { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: var(--red-soft); color: var(--red); font-size: 10.5px; letter-spacing: .03em; text-transform: uppercase; vertical-align: 1px; }
.qlm-row { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 12px; }
.qlm-row span:last-child { white-space: nowrap; font-weight: 700; }
.qlm-row .need { color: var(--gold); font-weight: 800; }
.qlm-sum { display: flex; justify-content: space-between; margin-top: 8px; padding-top: 8px; border-top: 3px solid var(--highlight); font-weight: 800; font-size: 14px; }
.qlm-note { margin: 8px 0 0; font-size: 11px; color: var(--text-muted); }
.qlm-cap { text-align: center; margin: 12px 0 0; font-size: 12.5px; color: var(--text-muted); }
@media (max-width: 640px) { .qlm { flex-direction: column; } .qlm-arrow { transform: rotate(90deg); } .qlm-inbox { width: 100%; max-width: 330px; } }

.qlm-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 26px 0 0; padding: 0; list-style: none; counter-reset: s; }
.qlm-steps li { counter-increment: s; position: relative; padding: 18px 18px 18px; border: 1px solid var(--border); border-radius: 16px; background: var(--bg-elevated); }
.qlm-steps li::before { content: counter(s); display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 10px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-weight: 800; font-size: 14px; }
.qlm-steps h3 { font-size: 1.02rem; margin: 0 0 6px; letter-spacing: -0.015em; }
.qlm-steps p { margin: 0; color: var(--text-muted); font-size: 14.5px; line-height: 1.55; }
@media (max-width: 900px) { .qlm-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .qlm-steps { grid-template-columns: 1fr; } }
.qlm-trades { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; }
.qlm-trades a { display: inline-flex; min-height: 44px; align-items: center; padding: 9px 16px; border: 1.5px solid var(--border-strong); border-radius: 999px; background: var(--bg-elevated); color: var(--text); font-weight: 700; font-size: 14.5px; text-decoration: none; }
.qlm-trades a:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-strong); }
.qlm-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
.qlm-two > div { border: 1px solid var(--border); border-radius: 16px; background: var(--bg-elevated); padding: 20px 22px; }
.qlm-two h3 { margin: 0 0 8px; font-size: 1.05rem; letter-spacing: -0.015em; }
.qlm-two ul { margin: 0; padding-left: 20px; color: var(--text-muted); font-size: 15px; line-height: 1.65; }
.qlm-two .qlm-yes h3 { color: var(--accent-strong); }
@media (max-width: 760px) { .qlm-two { grid-template-columns: 1fr; } }
.qlm-band { padding: 8px 0 0; }
.qlm-plan { display: inline-block; margin-top: 10px; padding: 4px 12px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-strong); font-size: 12.5px; font-weight: 800; }
.th-visual .qlm { flex-direction: column; gap: 6px; }
.th-visual .qlm-arrow { transform: rotate(90deg); line-height: 1; }
.th-visual .qlm-inbox { width: 100%; max-width: 330px; }

/* ---------------------------------------------------------------- the Top trades page */
.tt-rank { display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 6px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-size: 12.5px; font-weight: 800; vertical-align: 1px; }
.tt-podium { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 22px; box-shadow: var(--shadow-lg); padding: 22px 22px 18px; max-width: 420px; margin: 0 auto; }
.tt-podium-title { margin: 0 0 12px; font-weight: 800; font-size: 14px; letter-spacing: .04em; text-transform: uppercase; color: var(--accent-strong); }
.tt-podium ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.tt-podium li { display: grid; grid-template-columns: 30px 1fr; grid-template-rows: auto auto; column-gap: 8px; align-items: center; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg); font-weight: 700; }
.tt-podium li .tt-rank { grid-row: 1 / span 2; margin: 0; width: 28px; height: 28px; }
.tt-podium li small { grid-column: 2; font-weight: 600; color: var(--text-muted); font-size: 12.5px; }
.tt-podium-note { margin: 12px 0 0; font-size: 12.5px; color: var(--text-muted); text-align: center; }
.tt-table th, .tt-table td { text-align: center; vertical-align: middle; font-size: 13.5px; }
.tt-table thead th { font-size: 12px; line-height: 1.3; }
.tt-table tbody th { text-align: left; white-space: nowrap; }
.tt-table td:last-child { text-align: left; min-width: 150px; }
.tt-date { font-weight: 500; color: var(--text-muted); }
.tt-y { color: var(--green); font-weight: 800; font-size: 18px; }
.tt-n { color: var(--text-muted); font-weight: 700; }
.tt-d { color: var(--gold); font-weight: 800; font-size: 18px; }
.tt-sources { padding-left: 20px; color: var(--text-muted); font-size: 15px; line-height: 1.65; }
.tt-sources li { margin-bottom: 8px; }
.tt-disclosure { margin: 6px 0 18px; padding: 14px 16px; border-radius: 12px; background: var(--accent-soft); color: var(--text); font-size: 14.5px; line-height: 1.55; }
.tt-disclosure a { color: var(--accent-strong); font-weight: 700; }
.tt-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.tt-tab { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px; border: 1.5px solid var(--border-strong); border-radius: 999px; background: var(--bg-elevated); color: var(--text); font: 700 14.5px var(--font-body); cursor: pointer; }
.tt-tab:hover { border-color: var(--accent); }
.tt-tab[aria-selected="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-strong); box-shadow: inset 0 0 0 1px var(--accent); }
.tt-tab:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.tt-panel h3 { margin: 18px 0 8px; font-size: 1.08rem; letter-spacing: -0.015em; }
.tt-why { padding-left: 20px; color: var(--text-muted); font-size: 15px; line-height: 1.65; }
.tt-count { margin: 0 0 10px; color: var(--text-muted); font-size: 13.5px; }
.tt-loading { color: var(--text-muted); }
.tt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.tt-card { display: flex; flex-direction: column; gap: 8px; padding: 18px; border: 1px solid var(--border); border-radius: 16px; background: var(--bg-elevated); min-width: 0; }
.tt-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.tt-top h4 { margin: 0; font-size: 1.05rem; letter-spacing: -0.015em; overflow-wrap: anywhere; }
.tt-tag { flex: none; padding: 2px 9px; border-radius: 999px; background: var(--bg-sunken); color: var(--text-muted); font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.tt-head { margin: 0; font-weight: 700; font-size: 14.5px; }
.tt-about { margin: 0; color: var(--text-muted); font-size: 14px; line-height: 1.55; }
.tt-meta { margin: 0; padding: 0; list-style: none; display: grid; gap: 3px; color: var(--text-muted); font-size: 13px; line-height: 1.45; }
.tt-meta strong { color: var(--text); }
.tt-meta a { color: var(--accent-strong); font-weight: 700; }
.tt-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 6px; }
.tt-report { align-self: flex-start; color: var(--text-muted); font-size: 12.5px; text-decoration: underline; }
.tt-open { border-style: dashed; border-color: var(--border-strong); background: var(--bg); }

/* inside .trade-points the page's link colour would win over the button colours, so the cards set their own */
body.trade .tt-card a.btn { text-decoration: none; }
body.trade .tt-card a.btn-primary { color: var(--on-accent); }
body.trade .tt-card a.btn-ghost { color: var(--text); }
body.trade .trade-points a.btn-primary { color: var(--on-accent); text-decoration: none; }
body.trade .trade-points a.btn-ghost { color: var(--text); text-decoration: none; }
.tt-card .tt-meta { padding-left: 0; }
.tt-card .tt-meta li { margin: 0; }
.tt-panel .tt-why { margin-top: 0; }
/* a wide table scrolls inside its own box instead of widening the whole page on a phone */
.trade-points .compare-table-wrap { min-width: 0; max-width: 100%; position: relative; }   /* position: so hidden screen-reader text inside the table is clipped with it */
