/* odesk.css — Options Desk tab (2026-10-23). Tokens only (styles.css vars + --cvc-orange); every class is prefixed od-.
   Reads in light, dark and every skin; nothing dimmed with opacity. Tables scroll inside .od-twrap, never #table-wrap. */
.od-tab { padding: 0 14px 24px; font-size: 13px; color: var(--text); }
.od-tab .muted, .od-muted { color: var(--muted); }
.od-nw { white-space: nowrap; }
.od-num { font-variant-numeric: tabular-nums; text-align: right; }
.od-link { color: var(--accent); cursor: pointer; text-decoration: none; }
.od-link:hover { text-decoration: underline; }
.od-tab a { color: var(--accent); }

/* ─── chrome ─── */
.od-chrome { position: sticky; top: 0; z-index: 6; margin: 0 -14px 12px; padding: 6px 14px 7px; background: var(--panel); border-bottom: 1px solid var(--border); }
.od-pbar { display: flex; align-items: center; gap: 6px 10px; flex-wrap: wrap; }
.od-pages { display: flex; gap: 3px; flex-wrap: wrap; align-items: center; }
.od-page { font: inherit; font-size: 13px; font-weight: 650; line-height: 1.5; padding: 3px 12px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; white-space: nowrap; }
.od-page:hover { color: var(--text); background: var(--hover); border-color: var(--border); }
.od-page.active { background: var(--accent); border-color: var(--accent); color: var(--panel); }
.od-q { font: inherit; font-size: 12.5px; padding: 3px 8px; border: 1px solid var(--border); border-radius: 7px; background: var(--bg); color: var(--text); width: 150px; }
.od-q:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.od-fresh { margin-left: auto; font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.od-fresh b { color: var(--text); font-weight: 600; }
.od-crumb { font-size: 12px; color: var(--muted); margin: 0 0 8px; }
.od-crumb b { color: var(--text); font-weight: 650; }

/* ─── chips rows (≤ 1 line of chrome per block) ─── */
.od-chips { display: flex; gap: 4px 6px; flex-wrap: wrap; align-items: center; font-size: 11.5px; margin: 4px 0 8px; }
.od-chip { font: inherit; font-size: 11.5px; line-height: 1.5; padding: 1px 9px; border: 1px solid var(--border); border-radius: 11px; background: var(--panel); color: var(--muted); cursor: pointer; white-space: nowrap; }
.od-chip:hover { color: var(--text); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.od-chip.on { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 600; }
.od-chips .od-lab { color: var(--muted); margin-right: 2px; }

/* ─── verdict + KPI tiles ─── */
.od-verdict { font-size: 13.5px; line-height: 1.55; margin: 0 0 10px; }
.od-verdict b { font-weight: 650; }
.od-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: 6px; margin: 0 0 12px; }
.od-kpi { border: 1px solid var(--border); border-radius: 8px; padding: 6px 9px 5px; background: var(--panel); min-width: 0; }
.od-kpi .l { font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.od-kpi .v { font-size: 17px; font-weight: 650; line-height: 1.25; font-variant-numeric: tabular-nums; }
.od-kpi .s { font-size: 11px; color: var(--muted); line-height: 1.35; }
.od-kpi.rich .v, .od-up { color: var(--bull); }
.od-kpi.cheap .v, .od-dn { color: var(--bear); }
.od-kpi.warn .v { color: var(--amber); }

/* ─── cards ─── */
.od-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.od-card { border: 1px solid var(--border); border-radius: 9px; background: var(--panel); padding: 8px 11px 9px; margin: 0 0 10px; min-width: 0; }
.od-card h3 { font-size: 13.5px; font-weight: 650; margin: 0 0 2px; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.od-card h3 .od-sub { font-size: 11.5px; font-weight: 400; color: var(--muted); }
.od-read { font-size: 12.5px; line-height: 1.5; margin: 0 0 6px; }
.od-read b { font-weight: 650; }
.od-fold { font-size: 12px; color: var(--muted); }
.od-fold summary { cursor: pointer; color: var(--accent); font-size: 11.5px; }
.od-fold p { margin: 4px 0; line-height: 1.5; }
.od-chart { position: relative; min-height: 120px; }
.od-chart svg { display: block; width: 100%; height: auto; }
.od-note { font-size: 11.5px; color: var(--muted); line-height: 1.45; margin: 4px 0 0; }

/* ─── tables ─── */
.od-twrap { overflow-x: auto; max-width: 100%; }
.od-t { border-collapse: collapse; width: 100%; font-size: 12.5px; }
.od-t th, .od-t td { padding: 3px 7px; border-bottom: 1px solid var(--row-border, var(--border)); white-space: nowrap; vertical-align: middle; }
.od-t th { position: sticky; top: 0; background: var(--thead, var(--panel)); color: var(--muted); font-weight: 600; font-size: 11px; text-align: left; z-index: 1; cursor: pointer; user-select: none; }
.od-t th.od-num, .od-t td.od-num { text-align: right; }
.od-t th.sorted { color: var(--accent); }
.od-t tbody tr:hover { background: var(--hover); }
.od-t tr.od-row-link { cursor: pointer; }
.od-t tr.od-self td { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.od-t td.od-name { font-weight: 650; }
.od-t td.od-name small { font-weight: 400; color: var(--muted); margin-left: 4px; }
/* Structures ranked: the template description goes on its own wrapped line so Max profit stays in view */
.od-t td.od-name small.od-desc { display: block; margin-left: 0; white-space: normal; max-width: 230px; line-height: 1.3; }
/* Why: must out-rank `.od-t td { nowrap }` or the reasons spill under the Score column */
.od-t td.od-why { font-size: 11.5px; color: var(--muted); white-space: normal; min-width: 300px; max-width: 440px; line-height: 1.35; }
/* warning / alt notes under a structure wrap in a narrow block instead of widening the table */
.od-t td small.od-cellnote { display: inline-block; white-space: normal; max-width: 260px; line-height: 1.3; }
/* inline bars: value printed over a proportional wash; diverging bars grow from the centre */
.od-bar { position: relative; display: inline-block; min-width: 64px; height: 16px; line-height: 16px; font-variant-numeric: tabular-nums; }
.od-bar i { position: absolute; top: 2px; bottom: 2px; left: 0; background: color-mix(in srgb, var(--accent) 28%, transparent); border-radius: 2px; }
.od-bar.div i { left: 50%; }
.od-bar.div i.neg { left: auto; right: 50%; background: color-mix(in srgb, var(--bear) 32%, transparent); }
.od-bar.div i.pos { background: color-mix(in srgb, var(--bull) 32%, transparent); }
.od-bar span { position: relative; padding: 0 3px; }
/* heat-map table: colour per column percentile, number always printed */
.od-heat td.od-c { text-align: right; font-variant-numeric: tabular-nums; }
.od-heat th.od-c { text-align: right; }
.od-heat td.od-c.k0 { background: color-mix(in srgb, var(--bear) 34%, transparent); }
.od-heat td.od-c.k1 { background: color-mix(in srgb, var(--bear) 16%, transparent); }
.od-heat td.od-c.k3 { background: color-mix(in srgb, var(--bull) 16%, transparent); }
.od-heat td.od-c.k4 { background: color-mix(in srgb, var(--bull) 34%, transparent); }
.od-leg { font-size: 11px; color: var(--muted); margin: 4px 0 0; }

/* ─── strategy page ─── */
.od-entry { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.od-legs td.buy { color: var(--bull); font-weight: 650; }
.od-legs td.sell { color: var(--bear); font-weight: 650; }
.od-steps { margin: 4px 0 0; padding-left: 20px; line-height: 1.55; font-size: 12.5px; }
.od-steps li { margin: 2px 0; }
.od-kv { display: grid; grid-template-columns: max-content 1fr; gap: 2px 10px; font-size: 12.5px; line-height: 1.5; }
.od-kv dt { color: var(--muted); }
.od-kv dd { margin: 0; font-variant-numeric: tabular-nums; }
.od-sliders { display: flex; gap: 8px 18px; flex-wrap: wrap; align-items: center; font-size: 12px; margin: 2px 0 6px; }
.od-sliders label { display: inline-flex; align-items: center; gap: 6px; }
.od-sliders input[type=range] { width: 120px; accent-color: var(--accent); }
.od-sliders b { min-width: 52px; display: inline-block; font-variant-numeric: tabular-nums; }
.od-risk { border-left: 3px solid var(--amber); padding: 2px 8px; margin: 4px 0; font-size: 12.5px; line-height: 1.45; }
.od-risk.bad { border-color: var(--bear); }
.od-ok { border-left: 3px solid var(--bull); padding: 2px 8px; margin: 4px 0; font-size: 12.5px; }
.od-sign { display: inline-block; min-width: 14px; text-align: center; }

/* ─── guide drawer ─── */
.od-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(440px, 92vw); z-index: 40; background: var(--panel); border-left: 1px solid var(--border); box-shadow: -6px 0 18px rgba(0,0,0,.18); overflow: auto; padding: 12px 16px 24px; font-size: 12.5px; line-height: 1.5; }
.od-drawer h3 { margin: 10px 0 4px; font-size: 13.5px; }
.od-drawer h2 { margin: 0 0 6px; font-size: 15px; display: flex; justify-content: space-between; align-items: center; }
.od-drawer dl { margin: 0; }
.od-drawer dt { font-weight: 650; margin-top: 5px; }
.od-drawer dd { margin: 0 0 2px; color: var(--text); }
.od-x { font: inherit; border: 1px solid var(--border); background: var(--panel); color: var(--muted); border-radius: 6px; padding: 1px 8px; cursor: pointer; }

/* ─── legacy-table strip ─── */
.od-strip { font-size: 12px; margin: 0 0 6px; padding: 4px 8px; border: 1px dashed var(--border); border-radius: 7px; color: var(--muted); }

/* ─── small screens ─── */
@media (max-width: 820px) {
  .od-grid2, .od-entry { grid-template-columns: 1fr; }
  .od-q { width: 110px; }
  .od-fresh { margin-left: 0; }
}
/* tooltip + legend for the desk's own SVG charts */
.od-tip { display: none; position: absolute; z-index: 5; pointer-events: none; background: var(--panel); color: var(--text); border: 1px solid var(--border); border-radius: 6px; padding: 4px 7px; font-size: 11px; line-height: 1.4; box-shadow: 0 2px 8px rgba(0,0,0,.15); white-space: nowrap; }
.od-lg { display: flex; gap: 4px 12px; flex-wrap: wrap; font-size: 11px; color: var(--muted); margin: 0 0 2px; }
.od-lg i { display: inline-block; width: 14px; height: 0; border-top: 2px solid currentColor; vertical-align: middle; margin-right: 4px; }
.od-lg b { font-weight: 500; color: var(--text); }
