/* Ecossistema SPITI — tema derivado de spiti.auction:
   monocromático, branco/off-white, quase-preto, caixa alta com espaçamento largo, cantos retos. */

:root {
  --bg: #ffffff;
  --surface: #f4f4f2;
  --surface-2: #ecebe9;
  --line: #e6e6e4;
  --line-strong: #cfcfcd;
  --ink: #1a1a1a;
  --ink-2: #3a3a3a;
  --ink-3: #4a4a4a;
  --muted: #767674;
  --faint: #bdbdba;
  --alert: #a33;
  --side: #1a1a1a;
  --side-ink: #ffffffe6;
  --side-muted: #ffffff8c;
  --side-line: #ffffff1f;

  --display: 'League Spartan', 'Helvetica Neue', Arial, sans-serif;
  --sans: 'Jost', 'Helvetica Neue', Helvetica, Arial, system-ui, sans-serif;

  --radius: 0;
  --sidebar-w: 248px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
svg { display: block; }

/* ---------- Tipografia SPITI ---------- */

.eyebrow {
  font-family: var(--display);
  font-size: .66rem;
  font-weight: 400;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
}
.display {
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: .14em;
  text-transform: uppercase;
}
h1, h2, h3 { margin: 0; font-weight: 300; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- Layout ---------- */

.shell { display: flex; min-height: 100vh; }

.sidebar {
  position: fixed; inset: 0 auto 0 0;
  width: var(--sidebar-w);
  background: var(--side);
  color: var(--side-ink);
  display: flex; flex-direction: column;
  padding: 28px 0 20px;
  z-index: 40;
  overflow-y: auto;
}
.brand { display: block; padding: 0 26px 26px; text-decoration: none; border-bottom: 1px solid var(--side-line); }
.brand-mark { display: block; font-family: var(--display); font-weight: 400; font-size: 1.02rem; letter-spacing: .22em; color: #fff; }
.brand-sub { display: block; margin-top: 6px; font-family: var(--display); font-size: .62rem; letter-spacing: .3em; text-transform: uppercase; color: var(--side-muted); }

.nav { padding: 18px 0; flex: 1; }
.nav-group { padding: 14px 26px 8px; font-family: var(--display); font-size: .6rem; letter-spacing: .24em; text-transform: uppercase; color: var(--side-muted); }
.nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 26px;
  text-decoration: none;
  font-family: var(--display);
  font-size: .74rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--side-muted);
  border-left: 2px solid transparent;
}
.nav a:hover { color: #fff; }
.nav a.active { color: #fff; border-left-color: #fff; background: #ffffff0d; }
.nav a .count { margin-left: auto; font-size: .64rem; letter-spacing: .08em; color: var(--side-muted); }

.sidebar-foot { padding: 18px 26px 0; border-top: 1px solid var(--side-line); display: grid; gap: 8px; }
.proto-tag { font-family: var(--display); font-size: .6rem; letter-spacing: .2em; text-transform: uppercase; color: var(--side-muted); }
.by { font-size: .74rem; color: var(--side-muted); }
.link-btn { background: none; border: 0; padding: 0; text-align: left; font-size: .8rem; color: var(--side-ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

.main { flex: 1; margin-left: var(--sidebar-w); min-width: 0; }

.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 16px;
  padding: 14px 40px;
  background: #fffffff0;
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.search { position: relative; flex: 1; max-width: 520px; }
.search-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.search input {
  width: 100%;
  padding: 9px 12px 9px 38px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius);
  font-size: .88rem;
}
.search input:focus { outline: none; border-color: var(--ink); background: #fff; }
.search-results {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px);
  background: #fff; border: 1px solid var(--line-strong);
  max-height: 60vh; overflow-y: auto;
  box-shadow: 0 12px 32px #1414141a;
}
.search-results a { display: flex; gap: 12px; align-items: center; padding: 10px 14px; text-decoration: none; border-bottom: 1px solid var(--line); }
.search-results a:hover, .search-results a.focus { background: var(--surface); }
.search-results .kind { margin-left: auto; }
.search-results .empty { padding: 14px; color: var(--muted); font-size: .88rem; }

.auction-pill {
  margin-left: auto;
  display: flex; align-items: center; gap: 12px;
  padding: 8px 14px;
  border: 1px solid var(--ink);
  text-decoration: none;
  font-family: var(--display);
  font-size: .66rem; letter-spacing: .18em; text-transform: uppercase;
  white-space: nowrap;
}
.auction-pill b { font-weight: 500; }
.auction-pill:hover { background: var(--ink); color: #fff; }

.icon-btn { background: none; border: 1px solid var(--line); width: 38px; height: 38px; display: inline-grid; place-items: center; cursor: pointer; }
.menu-btn { display: none; }
.scrim { display: none; }

.content { padding: 36px 40px 64px; max-width: 1480px; }

/* ---------- Cabeçalho de página ---------- */

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 30px; flex-wrap: wrap; }
.page-head h1 { font-family: var(--display); font-weight: 300; font-size: clamp(1.3rem, 3vw, 2rem); letter-spacing: .14em; text-transform: uppercase; margin-top: 8px; line-height: 1.15; }
.page-head p { margin: 10px 0 0; color: var(--muted); max-width: 640px; }
.page-head .actions { display: flex; gap: 10px; flex-wrap: wrap; }
.back { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; margin-bottom: 18px; }
.back:hover { color: var(--ink); }

/* ---------- Botões e controles ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px;
  border: 1px solid var(--ink);
  background: var(--ink); color: #fff;
  border-radius: var(--radius);
  font-family: var(--display); font-size: .68rem; font-weight: 400; letter-spacing: .18em; text-transform: uppercase;
  text-decoration: none;
  cursor: pointer; white-space: nowrap;
}
.btn:hover { background: var(--ink-2); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: var(--surface); }
.btn.sm { padding: 7px 12px; font-size: .62rem; }
.btn:disabled { opacity: .4; cursor: default; }

.seg { display: inline-flex; border: 1px solid var(--line-strong); }
.seg button { background: none; border: 0; padding: 8px 14px; font-family: var(--display); font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); cursor: pointer; }
.seg button + button { border-left: 1px solid var(--line-strong); }
.seg button.on { background: var(--ink); color: #fff; }

.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 22px; }
select, .input, textarea {
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: var(--radius);
  font-size: .88rem;
}
select:focus, .input:focus, textarea:focus { outline: none; border-color: var(--ink); }
.field { display: grid; gap: 6px; }
.field label, .field .label { font-family: var(--display); font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.field .hint { font-size: .78rem; color: var(--muted); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.form-grid .full { grid-column: 1 / -1; }

/* ---------- Cartões e grade ---------- */

.grid { display: grid; gap: 20px; }
.g-kpi { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-main { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.g-side { grid-template-columns: minmax(0, 1fr) 380px; align-items: start; }
.stack { display: grid; gap: 20px; align-content: start; }

.card { border: 1px solid var(--line); background: #fff; padding: 22px 24px; min-width: 0; }
.card.flat { background: var(--surface); border-color: var(--surface); }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.card-head h2 { font-family: var(--display); font-weight: 400; font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; }
.card-head a { font-family: var(--display); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); text-decoration: none; }
.card-head a:hover { color: var(--ink); }

.kpi { padding: 20px 22px; border-right: 1px solid var(--line); }
.kpi:last-child { border-right: 0; }
.kpi .value { font-family: var(--display); font-weight: 300; font-size: 2rem; line-height: 1.1; margin-top: 10px; letter-spacing: .02em; }
.kpi .sub { font-size: .8rem; color: var(--muted); margin-top: 6px; }
.kpi.dark { background: var(--ink); color: #fff; }
.kpi.dark .eyebrow, .kpi.dark .sub { color: var(--side-muted); }

/* ---------- Faixa do leilão ---------- */

.hero {
  background: var(--ink); color: #fff;
  padding: 34px 36px;
  display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px;
  margin-bottom: 20px;
}
.hero .eyebrow { color: var(--side-muted); }
.hero h2 { font-family: var(--display); font-weight: 300; font-size: clamp(1.6rem, 3.6vw, 2.6rem); letter-spacing: .14em; margin: 10px 0 6px; }
.hero .dates { font-family: var(--display); font-size: .82rem; letter-spacing: .18em; text-transform: uppercase; color: var(--side-ink); }
.hero p { color: var(--side-muted); margin: 14px 0 0; max-width: 520px; }
.hero-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-left: 1px solid var(--side-line); }
.hero-stats div { padding: 0 20px; border-right: 1px solid var(--side-line); }
.hero-stats div:last-child { border-right: 0; }
.hero-stats b { display: block; font-family: var(--display); font-weight: 300; font-size: 2.2rem; line-height: 1.1; margin-top: 10px; }
.hero-stats span.s { font-size: .78rem; color: var(--side-muted); }
.hero .btn { background: #fff; color: var(--ink); border-color: #fff; margin-top: 22px; }
.hero .btn:hover { background: var(--surface); }

/* ---------- Chips ---------- */

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 8px;
  border: 1px solid var(--line-strong);
  font-family: var(--display); font-size: .6rem; letter-spacing: .14em; text-transform: uppercase;
  white-space: nowrap; color: var(--ink-3);
}
.chip.solid { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.soft { background: var(--surface-2); border-color: var(--surface-2); }
.chip.alert { color: var(--alert); border-color: currentColor; }
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.stage-nova, .stage-triagem, .stage-documentacao, .stage-avaliacao { }
.stage-aprovada, .stage-consignada { background: var(--surface-2); border-color: var(--surface-2); color: var(--ink); }
.stage-catalogo, .stage-leilao { background: var(--ink); border-color: var(--ink); color: #fff; }
.stage-vendida, .stage-posvenda { background: var(--ink-3); border-color: var(--ink-3); color: #fff; }
.stage-recusada { color: var(--alert); border-color: currentColor; }
.stage-offmarket { border-style: dashed; border-color: var(--ink); color: var(--ink); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- Gráficos ---------- */

.hbars { display: grid; gap: 10px; }
.hbar { display: grid; grid-template-columns: 140px minmax(0, 1fr) 44px; gap: 12px; align-items: center; font-size: .84rem; text-decoration: none; }
.hbar .lbl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink-2); }
.hbar .track { height: 10px; background: var(--surface); position: relative; }
.hbar .fill { position: absolute; inset: 0 auto 0 0; background: var(--ink); border-radius: 0 2px 2px 0; }
.hbar .val { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink-2); }
a.hbar:hover .lbl { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
a.hbar:hover .fill { background: var(--ink-3); }
.chart { width: 100%; }
.chart text { font-family: var(--sans); font-size: 11px; fill: var(--muted); }
.chart .bar { fill: var(--ink); }
.chart .bar:hover, .chart .bar.hl { fill: var(--ink-3); }
.chart .grid-line { stroke: var(--line); }
.chart .hit { fill: transparent; cursor: default; }

.tooltip {
  position: fixed; z-index: 90; pointer-events: none;
  background: var(--ink); color: #fff;
  padding: 7px 10px; font-size: .78rem; line-height: 1.35;
  opacity: 0; transform: translateY(4px); transition: opacity .12s, transform .12s;
  max-width: 260px;
}
.tooltip.show { opacity: 1; transform: none; }
.tooltip b { font-weight: 500; }

/* ---------- Listas ---------- */

.list { display: grid; }
.list-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); text-decoration: none; min-width: 0; }
.list-row:first-child { border-top: 0; padding-top: 0; }
.list-row .grow { flex: 1; min-width: 0; }
.list-row .title { font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-row .meta { font-size: .78rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
a.list-row:hover .title { text-decoration: underline; text-underline-offset: 3px; }

.task-ico { width: 30px; height: 30px; flex: none; display: grid; place-items: center; border: 1px solid var(--line-strong); color: var(--ink-2); }
.task-ico.alert { color: var(--alert); border-color: currentColor; }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: .86rem; }
th { text-align: left; font-family: var(--display); font-weight: 400; font-size: .6rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--surface); white-space: nowrap; }
td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr.click { cursor: pointer; }
tbody tr.click:hover td { background: var(--surface); }
td.r, th.r { text-align: right; }

.avatar { width: 30px; height: 30px; flex: none; border-radius: 50%; background: var(--surface-2); display: inline-grid; place-items: center; font-family: var(--display); font-size: .62rem; letter-spacing: .06em; color: var(--ink-2); }
.avatar.lg { width: 56px; height: 56px; font-size: .9rem; }
.avatar.dark { background: var(--ink); color: #fff; }

/* ---------- Obras (miniaturas) ---------- */

.art { background: var(--surface); display: grid; place-items: center; overflow: hidden; flex: none; }
.art svg { width: 100%; height: 100%; }
.art.framed { padding: 10%; }
.art.framed svg { box-shadow: 0 1px 2px #1414141f, 0 8px 24px #14141414; height: auto; max-height: 100%; }

.works-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 26px 20px; }
.work-tile { text-decoration: none; display: grid; gap: 10px; }
.work-tile .art { aspect-ratio: 1; }
.work-tile .artist { font-family: var(--display); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; }
.work-tile .t { font-size: .86rem; color: var(--ink-2); }
.work-tile .foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: .8rem; color: var(--muted); }
.work-tile:hover .artist { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Kanban ---------- */

.board { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 14px; align-items: flex-start; }
.col { flex: 0 0 248px; background: var(--surface); display: flex; flex-direction: column; max-height: calc(100vh - 230px); }
.col.side { background: #fff; border: 1px dashed var(--line-strong); }
.col-head { padding: 14px 14px 10px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.col-head h3 { font-family: var(--display); font-weight: 400; font-size: .66rem; letter-spacing: .18em; text-transform: uppercase; }
.col-head .n { font-family: var(--display); font-size: .7rem; color: var(--muted); }
.col-sum { padding: 0 14px 10px; font-size: .74rem; color: var(--muted); }
.col-body { padding: 0 10px 12px; display: grid; gap: 8px; overflow-y: auto; min-height: 80px; align-content: start; }
.col.drop .col-body { outline: 1px dashed var(--ink); outline-offset: -4px; }
.kcard { background: #fff; border: 1px solid var(--line); padding: 10px; display: grid; gap: 8px; cursor: grab; text-decoration: none; }
.kcard:hover { border-color: var(--line-strong); }
.kcard.dragging { opacity: .4; }
.kcard .top { display: flex; gap: 10px; }
.kcard .art { width: 46px; height: 46px; }
.kcard .code { font-family: var(--display); font-size: .58rem; letter-spacing: .16em; color: var(--muted); }
.kcard .artist { font-family: var(--display); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; line-height: 1.3; margin-top: 2px; }
.kcard .t { font-size: .8rem; color: var(--ink-2); line-height: 1.3; }
.kcard .bot { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: .72rem; color: var(--muted); }
.kcard .avatar { width: 22px; height: 22px; font-size: .5rem; }
.kcard .flag { color: var(--alert); }
.meter { display: inline-flex; gap: 2px; }
.meter i { width: 8px; height: 3px; background: var(--line-strong); }
.meter i.on { background: var(--ink); }

/* ---------- Dossiê ---------- */

.dossie-head { display: grid; grid-template-columns: minmax(260px, 420px) minmax(0, 1fr); gap: 40px; margin-bottom: 28px; }
.dossie-head .art { aspect-ratio: 1; }
.dossie-head h1 { font-family: var(--display); font-weight: 300; font-size: clamp(1.4rem, 3vw, 2.2rem); letter-spacing: .14em; text-transform: uppercase; margin: 12px 0 4px; line-height: 1.15; }
.dossie-head .work-title { font-size: 1.15rem; color: var(--ink-2); }
.dossie-head .specs { color: var(--muted); margin-top: 4px; }
.dossie-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; align-items: center; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 24px; }
.facts div { padding: 14px 16px 14px 0; }
.facts div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.facts b { display: block; font-family: var(--display); font-weight: 300; font-size: 1.35rem; margin-top: 6px; }

.dl { display: grid; grid-template-columns: 170px minmax(0, 1fr); font-size: .88rem; }
.dl dt, .dl dd { padding: 9px 0; border-top: 1px solid var(--line); margin: 0; }
.dl dt { color: var(--muted); font-family: var(--display); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase; padding-top: 12px; }
.dl dd.empty { color: var(--faint); font-style: italic; }

.checks { display: grid; gap: 10px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; }
.check .ico { width: 20px; height: 20px; flex: none; display: grid; place-items: center; border: 1px solid var(--ink); }
.check.ok .ico { background: var(--ink); color: #fff; }
.check.pend .ico { border-style: dashed; color: var(--muted); border-color: var(--muted); }
.check.pend { color: var(--muted); }

.prequal { border: 1px solid var(--ink); padding: 22px 24px; }
.prequal .next { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.prequal .next b { display: block; font-family: var(--display); font-weight: 400; font-size: .86rem; letter-spacing: .16em; text-transform: uppercase; margin-top: 6px; }

.match-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) 120px; gap: 14px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.match-row:first-child { border-top: 0; padding-top: 0; }
.match-row .rank { font-family: var(--display); font-size: .8rem; color: var(--muted); }
.match-row .who { min-width: 0; }
.match-row .who a { text-decoration: none; font-size: .92rem; }
.match-row .who a:hover { text-decoration: underline; text-underline-offset: 3px; }
.match-row .why { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; font-size: .76rem; color: var(--muted); }
.match-row .why span::before { content: '— '; color: var(--faint); }
.score { text-align: right; }
.score b { font-family: var(--display); font-weight: 300; font-size: 1.5rem; }
.score i { display: block; height: 3px; background: var(--surface-2); margin-top: 4px; }
.score i em { display: block; height: 100%; background: var(--ink); }
.match-row .acts { grid-column: 2 / -1; display: flex; gap: 8px; }
.note-ai { font-size: .76rem; color: var(--muted); margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }

.timeline { display: grid; }
.tl { display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 12px; padding-bottom: 16px; position: relative; }
.tl::before { content: ''; position: absolute; left: 6px; top: 14px; bottom: 0; width: 1px; background: var(--line-strong); }
.tl:last-child::before { display: none; }
.tl .pt { width: 13px; height: 13px; border-radius: 50%; border: 1px solid var(--ink); background: #fff; margin-top: 4px; }
.tl.note .pt { background: var(--ink); }
.tl .what { font-size: .88rem; }
.tl .when { font-size: .74rem; color: var(--muted); }

.stepper { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.stepper div { padding-top: 10px; border-top: 3px solid var(--line-strong); font-size: .7rem; color: var(--muted); line-height: 1.3; }
.stepper div.done { border-top-color: var(--ink); color: var(--ink); }
.stepper div.cur { border-top-color: var(--ink); color: var(--ink); font-weight: 500; }

/* ---------- Marketplace / off-market ---------- */

.triad { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--ink); margin-bottom: 26px; }
.triad div { padding: 22px 24px; border-right: 1px solid var(--ink); }
.triad div:last-child { border-right: 0; background: var(--ink); color: #fff; }
.triad div:last-child .eyebrow { color: var(--side-muted); }
.triad q { display: block; font-family: var(--display); font-weight: 300; font-size: 1.15rem; letter-spacing: .06em; margin: 10px 0 6px; quotes: '“' '”'; }
.triad .s { font-size: .82rem; color: var(--muted); }
.triad div:last-child .s { color: var(--side-muted); }

.demand { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 24px; }
.demand + .demand { margin-top: 0; }
.want { font-family: var(--display); font-weight: 300; font-size: 1.1rem; letter-spacing: .08em; text-transform: uppercase; margin: 8px 0 4px; }
.mini-works { display: flex; gap: 12px; flex-wrap: wrap; }
.mini-work { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 10px; align-items: center; text-decoration: none; width: 100%; padding: 8px 0; border-top: 1px solid var(--line); }
.mini-work:first-child { border-top: 0; padding-top: 0; }
.mini-work .art { width: 52px; height: 52px; }
.mini-work:hover .title { text-decoration: underline; text-underline-offset: 3px; }
.empty-box { border: 1px dashed var(--line-strong); padding: 16px; font-size: .84rem; color: var(--muted); }

.private { border: 1px solid var(--ink); display: grid; grid-template-columns: 220px minmax(0, 1fr); }
.private .art { position: relative; min-height: 220px; }
.private .art > svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.private .art::after { content: ''; position: absolute; inset: 0; backdrop-filter: blur(6px) grayscale(1); background: #f4f4f280; }
.private .art .lock { position: absolute; z-index: 1; inset: 0; display: grid; place-items: center; }
.private .art .lock svg { width: 28px; height: 28px; }
.private .body { padding: 22px 24px; display: grid; gap: 14px; align-content: start; }
.private h3 { font-family: var(--display); font-weight: 300; font-size: 1.3rem; letter-spacing: .12em; text-transform: uppercase; }

/* ---------- Formulário público ---------- */

.portal { max-width: 860px; margin: 0 auto; }
.portal-hero { text-align: center; padding: 18px 0 30px; }
.portal-hero h1 { font-family: var(--display); font-weight: 300; font-size: clamp(1.5rem, 3.4vw, 2.4rem); letter-spacing: .16em; text-transform: uppercase; margin: 12px 0; }
.portal-hero p { color: var(--muted); max-width: 560px; margin: 0 auto; }
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-bottom: 28px; }
.steps div { border-top: 2px solid var(--line-strong); padding-top: 10px; font-family: var(--display); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.steps div.on { border-top-color: var(--ink); color: var(--ink); }
.choice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.choice { border: 1px solid var(--line-strong); padding: 20px 18px; text-align: left; background: #fff; cursor: pointer; display: grid; gap: 6px; }
.choice b { font-family: var(--display); font-weight: 400; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; }
.choice span { font-size: .8rem; color: var(--muted); }
.choice:hover { border-color: var(--ink); }
.choice.on { border-color: var(--ink); background: var(--ink); color: #fff; }
.choice.on span { color: var(--side-muted); }
.tip-line { background: var(--surface); padding: 12px 16px; font-size: .86rem; color: var(--ink-2); margin-bottom: 20px; }
.uploads { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.upload { aspect-ratio: 1; border: 1px dashed var(--line-strong); display: grid; place-items: center; text-align: center; padding: 10px; font-size: .74rem; color: var(--muted); cursor: pointer; background: #fff; }
.upload:hover { border-color: var(--ink); color: var(--ink); }
.upload.done { border-style: solid; border-color: var(--ink); background: var(--surface); color: var(--ink); }
.form-nav { display: flex; justify-content: space-between; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.receipt { border: 1px solid var(--ink); }
.receipt-head { background: var(--ink); color: #fff; padding: 22px 26px; }
.receipt-head .eyebrow { color: var(--side-muted); }
.receipt-head h2 { font-family: var(--display); font-weight: 300; font-size: 1.5rem; letter-spacing: .16em; margin-top: 8px; }
.receipt-body { padding: 24px 26px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }

/* ---------- Roteiro ---------- */

.phase { border-top: 1px solid var(--ink); padding: 22px 0; display: grid; grid-template-columns: 220px minmax(0, 1fr) 160px; gap: 24px; }
.phase h3 { font-family: var(--display); font-weight: 300; font-size: 1.1rem; letter-spacing: .14em; text-transform: uppercase; margin-top: 6px; }
.phase ul { margin: 0; padding: 0; list-style: none; columns: 2; column-gap: 24px; font-size: .88rem; }
.phase li { padding: 3px 0; break-inside: avoid; }
.phase li.in::before { content: '■ '; font-size: .6rem; vertical-align: 2px; }
.phase li.out { color: var(--muted); }
.phase li.out::before { content: '□ '; font-size: .6rem; vertical-align: 2px; }
.chain { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; font-family: var(--display); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; padding: 22px 24px; border: 1px solid var(--line); margin-bottom: 28px; }
.chain span.arrow { color: var(--faint); }

/* ---------- Modal e toast ---------- */

.modal { position: fixed; inset: 0; z-index: 80; background: #1a1a1a99; display: none; place-items: center; padding: 20px; }
.modal.open { display: grid; }
.modal-panel { background: #fff; width: min(560px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; padding: 28px 30px; }
.modal-panel h2 { font-family: var(--display); font-weight: 300; font-size: 1.2rem; letter-spacing: .14em; text-transform: uppercase; margin: 6px 0 20px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 20px); z-index: 95; background: var(--ink); color: #fff; padding: 12px 18px; font-size: .86rem; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Responsivo ---------- */

@media (max-width: 1200px) {
  .g-kpi { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .g-kpi .kpi:nth-child(3) { border-right: 0; }
  .g-kpi .kpi:nth-child(n + 4) { border-top: 1px solid var(--line); }
  .g-main, .g-side { grid-template-columns: minmax(0, 1fr); }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero-stats { border-left: 0; border-top: 1px solid var(--side-line); padding-top: 18px; }
  .hero-stats div:first-child { padding-left: 0; }
}

@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: none; }
  .scrim.show { display: block; position: fixed; inset: 0; background: #1a1a1a66; z-index: 35; }
  .main { margin-left: 0; }
  .menu-btn { display: inline-grid; }
  .topbar { padding: 12px 16px; gap: 10px; }
  .auction-pill .long { display: none; }
  .content { padding: 24px 16px 48px; }
  .g-2, .g-3, .demand, .dossie-head, .receipt-body { grid-template-columns: minmax(0, 1fr); }
  .g-kpi { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-kpi .kpi { border-right: 1px solid var(--line); border-top: 1px solid var(--line); }
  .g-kpi .kpi:nth-child(-n + 2) { border-top: 0; }
  .g-kpi .kpi:nth-child(2n) { border-right: 0; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .facts div + div { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .triad { grid-template-columns: minmax(0, 1fr); }
  .triad div { border-right: 0; border-bottom: 1px solid var(--ink); }
  .private { grid-template-columns: minmax(0, 1fr); }
  .private .art { min-height: 160px; }
  .list-row .title, .list-row .meta { white-space: normal; }
  .choice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .uploads { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .phase { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .phase ul { columns: 1; }
  .dl { grid-template-columns: 120px minmax(0, 1fr); }
  .hbar { grid-template-columns: 100px minmax(0, 1fr) 36px; }
  .hero { padding: 26px 22px; }
  .hero-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero-stats div { padding: 0 10px; }
  .hero-stats b { font-size: 1.6rem; }
  .stepper { grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: 12px; }
  .col { max-height: none; }
}
