/* Studio Versa · identidade: preto quente, creme, Bodoni Moda + Inter, rótulos numerados, pílulas */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); font: 300 15px/1.65 var(--sans); display: flex; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; }
em { font-style: italic; }
.lbl { font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; letter-spacing: -.015em; line-height: 1.08; margin: 0; }
h1 { font-size: clamp(34px, 4.4vw, 58px); } h2 { font-size: clamp(24px, 2.6vw, 34px); } h3 { font-size: 20px; }
h1 em, h2 em { color: var(--muted); }

/* menu lateral */
.side { width: 248px; flex: none; background: var(--side); color: var(--side-text); display: flex; flex-direction: column; padding: 26px 20px 20px; gap: 6px; height: 100%; overflow-y: auto; }
.logo { font: 400 28px/1 var(--display); letter-spacing: -.02em; padding: 0 8px 22px; }
.logo em { color: var(--sand); } .logo small { display: block; font: 400 10px var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--side-muted); margin-top: 8px; }
.nav { display: grid; gap: 2px; }
.nav a { display: flex; align-items: baseline; gap: 12px; padding: 9px 10px; border-radius: 10px; text-decoration: none; color: var(--side-muted); font-size: 14px; transition: background .15s, color .15s; }
.nav a i { font: 400 10px var(--sans); letter-spacing: .12em; font-style: normal; width: 18px; opacity: .6; }
.nav a:hover { color: var(--side-text); } .nav a.on { background: #24221d; color: var(--side-text); }
.nav .sep { height: 1px; background: var(--side-line); margin: 10px 8px; }
.nav .soon { opacity: .45; pointer-events: none; }
.nav .soon::after { content: "em breve"; margin-left: auto; font-size: 9px; letter-spacing: .14em; text-transform: uppercase; }
.side .foot { margin-top: auto; display: grid; gap: 10px; padding: 14px 8px 0; font-size: 11px; color: var(--side-muted); }
.theme { display: grid; grid-template-columns: repeat(3, 1fr); background: #1f1d19; border-radius: 999px; padding: 3px; }
.theme button { border: 0; background: transparent; border-radius: 999px; padding: 6px 0; font-size: 11px; color: var(--side-muted); }
.theme button.on { background: var(--side-text); color: #141311; }
.conn { display: flex; align-items: center; gap: 8px; cursor: pointer; } .conn b { width: 7px; height: 7px; border-radius: 50%; background: #666; } .conn.ok b { background: #7bc08a; }

/* área principal */
.main { flex: 1; min-width: 0; height: 100%; overflow-y: auto; }
.page { padding: 44px clamp(20px, 4vw, 64px) 80px; max-width: 1180px; margin: 0 auto; }
.page.wide { max-width: none; }
.head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 34px; }
.head .lbl { margin-bottom: 14px; display: block; }
.crumb { font-size: 12px; color: var(--muted); margin-bottom: 18px; } .crumb a { text-decoration: none; } .crumb a:hover { color: var(--text); }
.btn { border: 1px solid var(--text); background: transparent; border-radius: 999px; padding: 10px 22px; font-size: 13px; font-weight: 400; letter-spacing: .02em; transition: background .15s, color .15s; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.btn:hover { background: var(--text); color: var(--bg); }
.btn.solid { background: var(--accent); color: var(--on-accent); } .btn.solid:hover { opacity: .85; }
.btn.small { padding: 6px 14px; font-size: 12px; }
.btn.ghost { border-color: var(--line); } .btn.ghost:hover { background: var(--surface-2); color: var(--text); }
.btn:disabled { opacity: .4; pointer-events: none; }
.link { background: none; border: 0; padding: 0 0 2px; border-bottom: 1px solid currentColor; font-size: 13px; cursor: pointer; }
input, select, textarea { font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; width: 100%; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--text); }
label.f { display: grid; gap: 6px; } label.f > span { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }

/* cartões e listas */
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; text-decoration: none; display: grid; gap: 10px; align-content: start; transition: border-color .15s, transform .15s; }
a.card:hover, .card.click:hover { border-color: var(--text); transform: translateY(-2px); }
.card .t { font: 400 24px/1.1 var(--display); }
.card .m { font-size: 13px; color: var(--muted); display: flex; gap: 6px 14px; flex-wrap: wrap; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 40px; }
.stat { border-top: 1px solid var(--text); padding-top: 14px; } .stat b { display: block; font: 400 52px/1 var(--display); letter-spacing: -.03em; margin: 8px 0 2px; } .stat span { font-size: 13px; color: var(--muted); }
.list { border-top: 1px solid var(--line); } .row { display: flex; align-items: center; gap: 16px; padding: 16px 4px; border-bottom: 1px solid var(--line); text-decoration: none; }
.row .grow { flex: 1; min-width: 0; } .row .t { font: 400 20px/1.2 var(--display); } .row .m { font-size: 13px; color: var(--muted); }
a.row:hover .t, .row a.grow:hover .t { text-decoration: underline; text-underline-offset: 4px; }
.pill { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; border: 1px solid var(--line); border-radius: 999px; padding: 3px 11px; color: var(--muted); white-space: nowrap; display: inline-block; }
.pill.rascunho { } .pill.em-aprovacao { border-color: var(--warn); color: var(--warn); } .pill.aprovada, .pill.aceita, .pill.assinado, .pill.publicada { border-color: var(--ok); color: var(--ok); } .pill.enviada, .pill.enviado { border-color: var(--text); color: var(--text); }
.empty { padding: 48px 0; color: var(--muted); text-align: center; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 30px; overflow-x: auto; }
.tabs button { background: none; border: 0; padding: 12px 16px; font-size: 14px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs button.on { color: var(--text); border-bottom-color: var(--text); } .tabs button sup { font-size: 10px; margin-left: 4px; }
.sec { display: flex; justify-content: space-between; align-items: center; margin: 0 0 18px; gap: 12px; }

/* materiais */
.drop { border: 1px dashed var(--muted); border-radius: 14px; padding: 28px; text-align: center; color: var(--muted); margin-bottom: 22px; transition: background .15s, border-color .15s; }
.drop.over { background: var(--surface-2); border-color: var(--text); color: var(--text); }
.filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; } .filters button { border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 5px 14px; font-size: 12px; } .filters button.on { background: var(--text); color: var(--bg); border-color: var(--text); }
.files { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 14px; }
.file { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); position: relative; display: grid; text-decoration: none; }
.file .th { aspect-ratio: 4/3; background: var(--surface-2) center/cover no-repeat; display: grid; place-items: center; font: 400 22px var(--display); color: var(--muted); }
.file .th.contain { background-size: contain; background-color: #fff; }
.file .nm { padding: 9px 12px 10px; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .file .nm small { display: block; color: var(--muted); font-size: 11px; }
.file .x { position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: rgba(20,19,17,.7); color: #fff; font-size: 14px; line-height: 1; display: none; }
.file:hover .x { display: block; }

/* editor de página: Claude + prévia */
.ws { display: grid; grid-template-columns: 420px 1fr; height: 100%; }
.ws-left { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; background: var(--bg); }
.ws-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line); min-height: 58px; }
.ws-bar .tt { font: 400 19px/1.1 var(--display); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .ws-bar .tt small { display: block; font: 400 10px var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: 3px; }
.ws-tabs { display: flex; border-bottom: 1px solid var(--line); } .ws-tabs button { flex: 1; background: none; border: 0; padding: 10px; font-size: 13px; color: var(--muted); border-bottom: 2px solid transparent; } .ws-tabs button.on { color: var(--text); border-bottom-color: var(--text); }
.ws-pane { flex: 1; min-height: 0; position: relative; } .ws-pane iframe { width: 100%; height: 100%; border: 0; display: block; background: var(--bg); }
.ws-pane .coms { position: absolute; inset: 0; overflow-y: auto; padding: 16px; }
.ws-right { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--surface-2); }
.pv-bar { display: flex; gap: 8px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--bg); flex-wrap: wrap; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 2px; } .seg button { border: 0; background: none; border-radius: 999px; padding: 4px 12px; font-size: 12px; color: var(--muted); } .seg button.on { background: var(--text); color: var(--bg); }
.pv-stage { flex: 1; min-height: 0; display: flex; justify-content: center; align-items: stretch; padding: 14px; overflow: auto; }
.pv-frame { width: 100%; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 8px 40px rgba(0,0,0,.14); transition: width .25s; max-width: 100%; display: flex; }
.pv-frame iframe { width: 100%; border: 0; flex: 1; background: #fff; }
.pv-frame.tablet { width: 820px; } .pv-frame.mobile { width: 390px; }
.com { border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; display: grid; gap: 6px; }
.com.res { opacity: .55; } .com .n { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--text); color: var(--bg); font-size: 11px; font-weight: 500; margin-right: 8px; }
.com .q { font-size: 12px; color: var(--muted); border-left: 2px solid var(--line); padding-left: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.com .acts { display: flex; gap: 12px; font-size: 12px; color: var(--muted); } .com .acts button { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.cform { position: absolute; z-index: 5; background: var(--surface); border: 1px solid var(--text); border-radius: 14px; padding: 12px; width: 280px; display: grid; gap: 8px; box-shadow: 0 14px 40px rgba(0,0,0,.25); }

/* documentos: proposta e contrato */
.doc-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.paper { background: #fbf9f4; color: #141311; border: 1px solid var(--line); border-radius: 6px; padding: clamp(24px, 4vw, 54px); box-shadow: 0 10px 40px rgba(0,0,0,.08); font-family: var(--sans); }
.paper h1 { font-size: 40px; margin: 10px 0 24px; } .paper h2 { font-size: 22px; margin: 26px 0 8px; } .paper p { margin: 0 0 10px; } .paper .lbl { color: #7a7567; }
.paper table { width: 100%; border-collapse: collapse; margin: 14px 0; } .paper td, .paper th { text-align: left; padding: 11px 0; border-bottom: 1px solid #d9d3c5; font-weight: 300; } .paper td:last-child, .paper th:last-child { text-align: right; white-space: nowrap; }
.paper .tot td { border-bottom: 0; font: 400 24px var(--display); padding-top: 16px; }
.items { display: grid; gap: 8px; } .item { display: grid; grid-template-columns: 1fr 130px 34px; gap: 8px; }
.item button { border: 1px solid var(--line); border-radius: 12px; background: none; }
.md-edit { font: 13px/1.6 ui-monospace, Menlo, Consolas, monospace; min-height: 70vh; resize: vertical; }
.saved { font-size: 12px; color: var(--muted); }

dialog { border: 1px solid var(--line); border-radius: 20px; background: var(--surface); color: var(--text); padding: 28px; width: min(440px, calc(100vw - 32px)); }
dialog::backdrop { background: rgba(0,0,0,.5); }
dialog h2 { margin-bottom: 8px; } dialog p { color: var(--muted); margin: 0 0 16px; font-size: 14px; }
dialog .acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.tip { color: var(--muted); font-size: 13px; max-width: 60ch; }
.cli-view { max-width: 820px; margin: 0 auto; }

.mtop { display: none; }
@media (max-width: 900px) {
  body { flex-direction: column; }
  .side { display: none; }
  .mtop { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: var(--side); color: var(--side-text); gap: 10px; }
  .mtop .logo { padding: 0; font-size: 22px; } .mtop select { width: auto; background: #24221d; color: #f1ede4; border: 0; padding: 8px 12px; border-radius: 999px; font-size: 13px; }
  .main { height: auto; flex: 1; min-height: 0; }
  .ws { grid-template-columns: 1fr; grid-template-rows: auto 1fr; } .ws-left, .ws-right { display: none; } .ws[data-m="claude"] .ws-left, .ws[data-m="prev"] .ws-right, .ws[data-m="coms"] .ws-left { display: flex; }
  .ws-mtabs { display: flex !important; }
  .doc-grid { grid-template-columns: 1fr; }
  .pv-frame.tablet, .pv-frame.mobile { width: 100%; }
}
.ws-mtabs { display: none; border-bottom: 1px solid var(--line); } .ws-mtabs button { flex: 1; background: none; border: 0; padding: 12px; font-size: 13px; color: var(--muted); border-bottom: 2px solid transparent; } .ws-mtabs button.on { color: var(--text); border-bottom-color: var(--text); }
@media print { .side, .mtop, .head, .tabs, .btn, .no-print { display: none !important; } body { display: block; background: #fff; } .main { overflow: visible; height: auto; } .paper { border: 0; box-shadow: none; } }

/* menu recolhível e colunas redimensionáveis */
.side { position: relative; transition: width .18s; }
.sidebtn { position: absolute; top: 24px; right: 12px; width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--side-line); background: transparent; color: var(--side-muted); font-size: 15px; line-height: 1; padding: 0; }
.sidebtn:hover { color: var(--side-text); border-color: var(--side-muted); }
.lm { display: none; font: 400 26px/1 var(--display); } .lm em { color: var(--sand); }
body.mini .side { width: 68px; padding-left: 10px; padding-right: 10px; }
body.mini .lg, body.mini .logo small, body.mini .nav .tx, body.mini .nav .soon::after, body.mini .side .theme, body.mini .conn span, body.mini .foot { display: none; }
body.mini .foot { display: grid; } body.mini .foot .theme, body.mini .conn span { display: none; }
body.mini .lm { display: block; text-align: center; } body.mini .logo { padding: 34px 0 18px; }
body.mini .nav a { justify-content: center; padding: 11px 0; } body.mini .nav a i { width: auto; font-size: 11px; opacity: .9; }
body.mini .sidebtn { right: 21px; top: 20px; }
body.mini .conn { justify-content: center; }
.ws { grid-template-columns: var(--wl, 420px) minmax(0, 1fr); }
.ws-left { position: relative; min-width: 0; }
.ws-grip { position: absolute; top: 0; bottom: 0; right: -5px; width: 10px; cursor: col-resize; z-index: 8; }
.ws-grip::after { content: ""; position: absolute; left: 4px; top: 0; bottom: 0; width: 2px; background: transparent; transition: background .15s; }
.ws-grip:hover::after, .ws.drag .ws-grip::after { background: var(--text); }
.ws.drag { user-select: none; cursor: col-resize; } .ws.drag iframe { pointer-events: none; }
@media (max-width: 900px) { .ws-grip { display: none; } .ws { grid-template-columns: 1fr; } }

.bf-linkbox { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; border: 1px solid var(--line); background: var(--surface); border-radius: 14px; padding: 16px 20px; margin-bottom: 22px; }
.bf-link { font: 13px ui-monospace, Menlo, Consolas, monospace; color: var(--text); word-break: break-all; margin-top: 4px; }

.bf-tools { display: flex; align-items: flex-end; gap: 16px 20px; flex-wrap: wrap; margin: 4px 0 30px; }
.bf-tools .tip { flex: 1 1 260px; margin-bottom: 8px; }
.bf-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }

.orc-l { display: grid; grid-template-columns: 1fr 78px 110px auto; gap: 10px; align-items: center; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 10px 12px; }
.orc-l small { display: block; color: var(--muted); font-size: 12.5px; } .orc-l input { text-align: center; padding: 8px; } .orc-l .sub { text-align: right; font-weight: 500; white-space: nowrap; }
.chips-add { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.orc-tot { display: flex; gap: 28px; align-items: flex-end; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.orc-tot span small { display: block; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); } .orc-tot span b { font: 400 30px/1.1 var(--display); letter-spacing: -.02em; }
.sec-d { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); padding: 10px 14px; } .sec-d summary { cursor: pointer; font-weight: 500; } .sec-d summary small { color: var(--muted); font-weight: 300; margin-left: 8px; }
.sec-d textarea { margin-top: 10px; font-size: 14px; }
.bloco { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: var(--surface-2); }
.pd-tab { width: 100%; border-collapse: collapse; margin: 10px 0 16px; } .pd-tab td { padding: 12px 0; border-bottom: 1px solid #d9d3c5; vertical-align: top; font-weight: 300; } .pd-tab td:last-child { text-align: right; white-space: nowrap; }
.pd-tab small { display: block; color: #6b665a; font-size: 13px; } .pd-tot td { border-bottom: 0; font: 400 26px var(--display); padding-top: 16px; }
.paper .pd-para { margin: 0 0 8px; } .paper .md p { margin: 0 0 10px; } .paper .md ul { margin: 0 0 10px; padding-left: 1.3em; }
@media (max-width: 900px) { .orc-l { grid-template-columns: 1fr 64px; } .orc-l .sub { text-align: left; } }

.pill.atrasado { border-color: var(--bad); color: var(--bad); } .pill.jp { text-transform: none; letter-spacing: .02em; font-size: 12px; }
.jbar { display: flex; gap: 8px; flex-wrap: wrap; } .jp-step { flex: 1 1 120px; min-width: 110px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; display: grid; gap: 1px; background: var(--surface); }
.jp-step i { font-style: normal; font-size: 12px; color: var(--muted); } .jp-step b { font-weight: 500; font-size: 13.5px; } .jp-step small { color: var(--muted); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; }
.jp-step.feito { opacity: .6; } .jp-step.feito i { color: var(--ok); } .jp-step.atual { border-color: var(--text); box-shadow: 0 0 0 1px var(--text); } .jp-step.pendente { background: transparent; border-style: dashed; }
.cform { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; max-width: 900px; }

.chks { display: flex; gap: 8px 20px; flex-wrap: wrap; } label.chk { display: inline-flex; gap: 8px; align-items: center; font-size: 14.5px; cursor: pointer; } label.chk input { width: auto; }
.com .rep { margin-left: 10px; padding-left: 10px; border-left: 2px solid var(--line); font-size: 13.5px; } .com .rep b { font-weight: 500; }
