/* Portal do Cliente — visual industrial aprovado pelo Tiago em 14/10/2026 (protótipo "Portal do Cliente Inspect").
   Celular primeiro; a partir de 900 px o menu inferior vira menu lateral. Fontes no próprio servidor (LGPD). */
@font-face { font-family: Barlow; font-weight: 400; font-display: swap; src: url(fonts/barlow-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: Barlow; font-weight: 600; font-display: swap; src: url(fonts/barlow-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: Barlow; font-weight: 700; font-display: swap; src: url(fonts/barlow-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 700; font-display: swap; src: url(fonts/barlow-condensed-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 800; font-display: swap; src: url(fonts/barlow-condensed-latin-800-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-weight: 500; font-display: swap; src: url(fonts/ibm-plex-mono-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-weight: 600; font-display: swap; src: url(fonts/ibm-plex-mono-latin-600-normal.woff2) format('woff2'); }

:root {
  --ink: #0B1513; --ink-2: #142220; --ink-line: #263634;
  --ground: #ECEFEE; --grid: #E1E6E4; --card: #FFFFFF; --line: #CBD3D1; --line-2: #E3E8E6;
  --muted: #56645F; --muted-2: #3B4A46; --on-dark: #A9BAB6;
  --brand: #0F766E; --brand-dark: #084943; --brand-soft: #DFF3EF; --mint: #7FE0CF;
  --amber: #F59E0B; --amber-text: #92400E; --amber-soft: #FEF3C7;
  --red: #C2410C; --red-text: #B42318; --red-soft: #FDECEA;
  --display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --radius: 14px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--ink); font: 16px/1.45 Barlow, system-ui, sans-serif;
  background-color: var(--ground);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
}
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }
:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; }
.mono { font-family: var(--mono); font-weight: 600; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- topo escuro (grade técnica) ---- */
.pt-top {
  background-color: var(--ink); color: #FFF; padding: 16px 18px 18px;
  background-image: linear-gradient(rgba(127, 224, 207, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(127, 224, 207, .06) 1px, transparent 1px);
  background-size: 16px 16px;
}
.pt-top-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pt-marca { display: flex; align-items: center; gap: 10px; color: #FFF; text-decoration: none; }
.pt-marca:hover { color: #FFF; }
.pt-marca-r { width: 34px; height: 34px; border-radius: 8px; background: var(--brand); display: grid; place-items: center; font: 800 20px var(--display); }
.pt-marca-t { display: flex; flex-direction: column; line-height: 1.05; }
.pt-marca-t b { font: 800 18px var(--display); letter-spacing: .08em; }
.pt-marca-t span { font-size: 11px; color: var(--mint); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.pt-eyebrow { font-size: 11px; color: var(--mint); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.pt-titulo { margin: 4px 0 0; font: 800 26px/1.05 var(--display); letter-spacing: .01em; text-transform: uppercase; }
.pt-sub { font-size: 13px; color: var(--on-dark); }
.pt-icone-btn { width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--ink-line); background: var(--ink-2); color: #FFF; display: grid; place-items: center; text-decoration: none; }

/* ---- layout ---- */
.pt-app { display: flex; flex-direction: column; min-height: 100vh; }
.pt-main { flex: 1; width: 100%; max-width: 1180px; margin: 0 auto; padding: 16px 16px 104px; display: flex; flex-direction: column; gap: 16px; }
.pt-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

/* ---- cartões ---- */
.pt-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: 0 1px 0 var(--line); }
.pt-card-dark { background: var(--ink); color: #FFF; border-radius: var(--radius); padding: 16px; }
.pt-h2 { margin: 0; font: 800 20px var(--display); letter-spacing: .04em; text-transform: uppercase; }
.pt-h3 { margin: 0; font: 800 15px var(--display); letter-spacing: .1em; text-transform: uppercase; color: var(--muted-2); }
.pt-cabeca { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.pt-muted { color: var(--muted); font-size: 13px; }
.pt-hazard { height: 10px; background: repeating-linear-gradient(-45deg, var(--amber) 0 10px, var(--ink) 10px 20px); }

/* ---- luzes de painel (situação) ---- */
.pt-lamp { width: 12px; height: 12px; border-radius: 50%; display: inline-block; flex-shrink: 0; box-shadow: 0 0 0 3px rgba(15, 118, 110, .2); background: var(--brand); }
.pt-lamp.vence { background: var(--amber); box-shadow: 0 0 0 3px rgba(245, 158, 11, .25); }
.pt-lamp.vencido { background: var(--red); box-shadow: 0 0 0 3px rgba(194, 65, 12, .22); }
.pt-lamp.sem { background: #9AA6A3; box-shadow: 0 0 0 3px rgba(154, 166, 163, .25); }
.pt-st { font: 800 13px var(--display); letter-spacing: .06em; text-transform: uppercase; color: var(--brand-dark); }
.pt-st.vence { color: var(--amber-text); } .pt-st.vencido { color: var(--red-text); } .pt-st.sem { color: var(--muted); }

/* ---- botões ---- */
.pt-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 18px; border-radius: 10px; border: 1px solid var(--line); background: #FFF; color: var(--ink); font: 700 15px Barlow, sans-serif; text-decoration: none; cursor: pointer; }
.pt-btn:hover { color: var(--ink); border-color: var(--muted); }
.pt-btn.pri { background: var(--ink); border-color: var(--ink); color: #FFF; }
.pt-btn.pri:hover { background: var(--ink-2); color: #FFF; }
.pt-btn.mint { background: var(--mint); border-color: var(--mint); color: #062E2A; }
.pt-btn.block { width: 100%; }
.pt-btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ---- formulários ---- */
.pt-form { display: flex; flex-direction: column; gap: 12px; }
.pt-field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 700; }
.pt-field input, .pt-field select, .pt-field textarea { min-height: 50px; border: 1px solid #B9C3C0; border-radius: 10px; padding: 12px 14px; font: 400 16px Barlow, sans-serif; background: #FFF; color: var(--ink); width: 100%; }
.pt-field input[readonly] { background: #F3F5F4; color: var(--muted-2); }
.pt-field input.mono { font-family: var(--mono); }
.pt-field .erro, .pt-erro { color: var(--red-text); font-size: 13px; font-weight: 600; }
.pt-field input[aria-invalid="true"] { border-color: var(--red-text); box-shadow: 0 0 0 3px rgba(180, 35, 24, .12); }
.pt-field .ok { color: var(--brand); font-size: 13px; font-weight: 600; }
.pt-duas { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pt-check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.45; cursor: pointer; }
.pt-check input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--brand); flex-shrink: 0; }
.pt-info { border: 1px solid var(--line); background: #FFF; border-radius: 12px; padding: 12px 14px; font-size: 14px; }
.pt-info summary { font-weight: 700; cursor: pointer; }
.pt-info p { margin: 8px 0 0; color: var(--muted-2); font-size: 13px; line-height: 1.5; }
.pt-legal { margin: 8px 0 0; font-size: 11px; color: var(--muted); line-height: 1.5; text-align: center; }

/* ---- mensagens ---- */
.pt-msg { border-radius: 12px; padding: 12px 14px; font-size: 14px; font-weight: 600; }
.pt-msg.ok { background: var(--brand-soft); color: var(--brand-dark); }
.pt-msg.erro { background: var(--red-soft); color: var(--red-text); }

/* ---- menu: barra inferior no celular, lateral no computador ---- */
.pt-nav { position: fixed; left: 0; right: 0; bottom: 0; height: 74px; background: var(--ink); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding-bottom: env(safe-area-inset-bottom); z-index: 20; }
.pt-nav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: #8FA29E; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-decoration: none; border-top: 3px solid transparent; }
.pt-nav a[aria-current="page"] { color: var(--mint); border-top-color: var(--mint); }
.pt-nav svg { width: 22px; height: 22px; }
@media (min-width: 900px) {
  .pt-app.com-menu { flex-direction: row; }
  .pt-app.com-menu > .pt-corpo { flex: 1; min-width: 0; display: flex; flex-direction: column; }
  .pt-nav { position: sticky; top: 0; height: 100vh; width: 220px; flex-shrink: 0; grid-template-columns: 1fr; grid-auto-rows: 56px; align-content: start; padding: 92px 12px 0; }
  .pt-nav a { flex-direction: row; justify-content: flex-start; gap: 12px; padding: 0 14px; font-size: 14px; border-top: 0; border-left: 3px solid transparent; border-radius: 0 8px 8px 0; }
  .pt-nav a[aria-current="page"] { border-left-color: var(--mint); background: var(--ink-2); }
  .pt-main { padding-bottom: 40px; }
}

/* ---- página simples (convite, login) ---- */
.pt-estreito { max-width: 480px; margin: 0 auto; width: 100%; }

/* ---- painel ---- */
.pt-kpi { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; display: flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; }
.pt-kpi:hover { color: var(--ink); border-color: var(--muted); }
.pt-kpi span:last-child { display: flex; flex-direction: column; line-height: 1.05; font-size: 12px; color: var(--muted); }
.pt-kpi b { font: 800 22px var(--display); color: var(--ink); }
.pt-linha-data { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px dashed #D5DCDA; color: var(--ink); text-decoration: none; }
.pt-linha-data:hover { color: var(--ink); }
.pt-cal { width: 50px; flex-shrink: 0; text-align: center; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.pt-cal span { display: block; background: var(--ink); color: #FFF; font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: 2px 0; }
.pt-cal b { display: block; font: 800 22px var(--display); padding: 2px 0; }
.pt-dias { font: 800 15px var(--display); padding: 3px 9px; border-radius: 6px; background: var(--ground); color: var(--muted-2); white-space: nowrap; }
.pt-dias.vence { background: var(--amber-soft); color: var(--amber-text); }
.pt-rec { display: flex; gap: 12px; align-items: stretch; padding: 12px 0 12px 14px; border-bottom: 1px dashed #D5DCDA; color: var(--ink); text-decoration: none; position: relative; }
.pt-rec::before { content: ''; position: absolute; left: 0; top: 12px; bottom: 12px; width: 5px; border-radius: 3px; background: var(--brand); }
.pt-rec.sev-media::before { background: var(--amber); } .pt-rec.sev-alta::before, .pt-rec.sev-critica::before { background: var(--red); }
.pt-rec:hover { color: var(--ink); }

/* ---- equipamentos (placa de identificação) ---- */
.pt-busca { display: flex; align-items: center; gap: 10px; background: #FFF; border: 1px solid var(--line); border-radius: 12px; padding: 0 14px; min-height: 52px; }
.pt-busca input { border: 0; outline: 0; flex: 1; font: 400 16px Barlow, sans-serif; background: transparent; min-width: 0; }
.pt-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.pt-chip { border: 1px solid #B9C3C0; background: #FFF; color: var(--ink); font-weight: 700; font-size: 14px; padding: 10px 14px; border-radius: 8px; text-decoration: none; }
.pt-chip[aria-current="true"] { background: var(--ink); border-color: var(--ink); color: #FFF; }
.pt-placa { position: relative; display: flex; gap: 14px; align-items: center; text-decoration: none; color: var(--ink); background: linear-gradient(180deg, #FAFBFB, #E8ECEB); border: 1px solid #B9C3C0; border-radius: 10px; padding: 14px 16px 14px 18px; box-shadow: inset 0 1px 0 #FFF, 0 1px 0 var(--line); }
.pt-placa:hover { color: var(--ink); border-color: var(--muted); }
.pt-placa .rebite { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: #9AA6A3; }
.pt-placa .r1 { top: 6px; left: 6px; } .pt-placa .r2 { top: 6px; right: 6px; } .pt-placa .r3 { bottom: 6px; left: 6px; } .pt-placa .r4 { bottom: 6px; right: 6px; }
.pt-placa-tag { font-size: 10px; font-weight: 700; letter-spacing: .16em; color: var(--muted); }
.pt-placa-nome { font: 600 19px var(--mono); letter-spacing: .04em; line-height: 1.1; }
.pt-placa-luz { display: flex; flex-direction: column; align-items: center; gap: 5px; flex-shrink: 0; }
.pt-placa-luz .pt-lamp { width: 16px; height: 16px; }
.pt-lista { display: flex; flex-direction: column; gap: 10px; }
.pt-dado { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; }
.pt-dado span:first-child { color: var(--muted); }
.pt-dado b { text-align: right; }
.pt-doc { display: flex; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #FFF; }
.pt-doc-ic { width: 36px; height: 44px; border-radius: 4px; border: 1px solid var(--line); color: var(--red-text); font-size: 9px; font-weight: 800; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 5px; flex-shrink: 0; box-shadow: 3px 3px 0 var(--grid); }
.pt-doc .pt-btn { min-height: 44px; padding: 8px 12px; }
.pt-visor { width: 100%; height: 72vh; border: 1px solid var(--line); border-radius: 12px; background: #1E2B29; }

/* ==========================================================================
   Fase 2 (F3 — Tiago 2026-10-15): pendências, folha "Marcar como atendida", linha do tempo, aviso com
   desfazer, busca Ctrl+K, menu do usuário, tour, esqueleto e modo escuro. Mesmos tokens do visual industrial.
   ========================================================================== */
@view-transition { navigation: auto; }
.pt-btn.sm { min-height: 44px; padding: 8px 14px; font-size: 14px; }
.pt-btn.perigo { border-color: var(--red-text); color: var(--red-text); }
.pt-btn.fantasma { background: transparent; border-color: transparent; }
.pt-acoes { display: flex; gap: 8px; flex-wrap: wrap; }
.pt-linha { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pt-sep { height: 1px; background: var(--line-2); border: 0; margin: 4px 0; }
.pt-vazio { text-align: center; padding: 28px 16px; color: var(--muted-2); }
.pt-vazio svg { display: block; margin: 0 auto 10px; }
.pt-vazio b { display: block; font-size: 16px; color: var(--ink); margin-bottom: 4px; }

/* abas (rolagem horizontal no celular) */
.pt-abas { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 2px; }
.pt-abas::-webkit-scrollbar { display: none; }
.pt-abas a { flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 14px; border-radius: 10px; border: 1px solid #B9C3C0; background: #FFF; color: var(--ink); font-weight: 700; font-size: 14px; text-decoration: none; }
.pt-abas a[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: #FFF; }
.pt-abas .n { font: 800 13px var(--display); padding: 1px 7px; border-radius: 999px; background: var(--ground); color: var(--muted-2); }
.pt-abas a[aria-current="page"] .n { background: var(--mint); color: #062E2A; }
/* Tiago 11/11/2026: a última aba ficava cortada sem aviso (rolagem com a barra escondida). Celular: rola com um
   esmaecido na borda mostrando que tem mais; tela larga: as abas quebram linha e aparecem todas. */
.pt-abas { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent);
           mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); }
.pt-abas::after { content: ''; flex: 0 0 14px; }
@media (min-width: 900px) {
  .pt-abas { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; -webkit-mask-image: none; mask-image: none; }
  .pt-abas::after { display: none; }
}
/* plano de ação em Excel na tela de pendências */
.pt-plano { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.pt-plano-ico { flex-shrink: 0; }
.pt-plano-txt { flex: 1 1 260px; min-width: 0; display: grid; gap: 2px; }
.pt-plano-txt b { font: 800 16px var(--display); color: var(--ink); }
.pt-plano-txt span { font-size: 14px; color: var(--muted-2); line-height: 1.4; }
.pt-plano .pt-btn { flex-shrink: 0; }
@media (max-width: 560px) { .pt-plano .pt-btn { width: 100%; } }
html[data-tema="escuro"] .pt-plano-txt b { color: #E6EEEC; }

/* ---- PLANO-1 (Tiago 11/11/2026): plano do cliente no cartão, filtros por responsável, planejar várias ---- */
.pt-quem { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.pt-chip .n { font-weight: 600; opacity: .75; margin-left: 2px; }
/* VENCIDO-CHIP (Tiago 11/11/2026): com algum vencido, o botão "Vencido" da lista fica vermelho */
.pt-chip.vencido { background: var(--red-soft); border-color: var(--red); color: var(--red-text); }
.pt-chip.vencido[aria-current="true"] { background: var(--red); border-color: var(--red); color: #FFF; }
.pt-plano-ed { border-top: 1px dashed var(--line); padding-top: 10px; }
.pt-plano-ed > summary, .pt-plano-sum { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; list-style: none; cursor: pointer; }
.pt-plano-ed > summary::-webkit-details-marker { display: none; }
.pt-plano-ed[open] > summary .pt-plano-botao { display: none; }
.pt-plano-linha { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; min-width: 0; font-size: 14px; color: var(--muted-2); }
.pt-plano-item { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; color: var(--ink); }
.pt-plano-item svg { color: var(--muted); flex-shrink: 0; }
.pt-plano-item.depois { color: var(--amber-text); }
.pt-plano-obs-txt { flex-basis: 100%; font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.pt-mini.and-em_andamento { border-color: #A7DCD3; background: var(--brand-soft); color: var(--brand-dark); }
.pt-mini.and-parada { border-color: #F6D48F; background: var(--amber-soft); color: var(--amber-text); }
.pt-plano-botao { min-height: 40px; padding: 6px 12px; font-size: 14px; flex-shrink: 0; }
.pt-plano-form { margin-top: 12px; }
.pt-plano-campos { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.pt-plano-campos .pt-field > label { display: flex; align-items: center; gap: 8px; }
.pt-plano-campos .pt-field input, .pt-plano-campos .pt-field select { min-height: 46px; padding: 10px 12px; }
.pt-plano-resp, .pt-plano-obs { grid-column: 1 / -1; }
.pt-plano-outro { grid-column: 1 / -1; display: none; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.pt-plano-campos:has(select[data-plano-resp] option[value="outro"]:checked) .pt-plano-outro { display: grid; }
.pt-plano-aviso { color: var(--amber-text); font-size: 13px; font-weight: 600; }
.pt-plano-mudar input { width: 18px; height: 18px; min-height: 0; margin: 0; accent-color: var(--brand); }
.pt-plano-acoes { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.pt-planejar { display: flex; flex-direction: column; gap: 14px; }
@media (min-width: 900px) {
  .pt-planejar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); align-items: start; }
  .pt-planejar-campos { position: sticky; top: 16px; }
}
.pt-planejar-todas { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; cursor: pointer; }
.pt-planejar-todas input, .pt-planejar-lista input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--brand); flex-shrink: 0; }
.pt-planejar-lista { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.pt-planejar-lista label { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.pt-planejar-lista label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.pt-planejar-item { display: grid; gap: 4px; min-width: 0; }
.pt-planejar-item b { font-size: 15px; overflow-wrap: anywhere; }
.pt-planejar-topo { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; }
html[data-tema="escuro"] .pt-plano-item, html[data-tema="escuro"] .pt-planejar-item b { color: #E6EEEC; }
html[data-tema="escuro"] .pt-planejar-lista label:has(input:checked) { background: #12302B; }
html[data-tema="escuro"] .pt-mini.and-em_andamento { background: var(--brand-soft); border-color: #1F5C55; color: var(--brand-dark); }
html[data-tema="escuro"] .pt-mini.and-parada { background: var(--amber-soft); border-color: #6B4E12; color: var(--amber-text); }
.pt-filtros { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@media (min-width: 640px) { .pt-filtros { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); } }
/* ORDEM-DOCS-1 (11/11/2026): Documentos = busca + equipamento + ordem (celular: busca em cima, os dois lado a lado) */
.pt-filtros.docs { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.pt-filtros.docs .pt-busca { grid-column: 1 / -1; }
@media (min-width: 900px) { .pt-filtros.docs { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); } .pt-filtros.docs .pt-busca { grid-column: auto; } }
.pt-filtro-resumo { margin: -4px 0 0; font-size: 14px; }
.pt-filtros select { min-height: 52px; border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; font: 400 16px Barlow, sans-serif; background: #FFF; color: var(--ink); width: 100%; }

/* cartão de pendência */
.pt-pend { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: 0 1px 0 var(--line); }
.pt-pend-faixa { height: 6px; background: var(--brand); }
.pt-pend-faixa.media { background: var(--amber); } .pt-pend-faixa.alta, .pt-pend-faixa.critica { background: var(--red); }
.pt-pend-corpo { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 10px; }
.pt-pend-titulo { font-size: 17px; font-weight: 700; line-height: 1.3; color: var(--ink); text-decoration: none; }
.pt-pend-titulo:hover { color: var(--brand-dark); }
.pt-pend-desc { color: var(--muted-2); font-size: 14px; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pt-mini { display: inline-flex; align-items: center; gap: 5px; border: 1px solid #C9D2CF; background: #F6F8F7; color: var(--muted-2); font-weight: 700; font-size: 12px; padding: 4px 9px; border-radius: 999px; }
.pt-mini.vencido { border-color: #F3B4A9; background: var(--red-soft); color: var(--red-text); }
.pt-mini.vence { border-color: #F6D48F; background: var(--amber-soft); color: var(--amber-text); }
.pt-mini.ok { border-color: #A7DCD3; background: var(--brand-soft); color: var(--brand-dark); }
.pt-mini svg { width: 13px; height: 13px; }
.pt-selo { display: inline-flex; align-items: center; gap: 6px; font: 800 12px var(--display); letter-spacing: .06em; text-transform: uppercase; padding: 4px 8px; border-radius: 6px; }
.pt-selo.cliente { background: var(--brand-soft); color: var(--brand-dark); }
.pt-selo.engenheiro { background: #E8E7FB; color: #3730A3; }
.pt-aviso-dev { border-left: 4px solid var(--red); background: var(--red-soft); color: var(--red-text); padding: 10px 12px; border-radius: 0 10px 10px 0; font-size: 14px; }
.pt-aviso-dev b { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.pt-espera { display: flex; align-items: center; gap: 8px; background: #EEF0FF; color: #3730A3; padding: 10px 12px; border-radius: 10px; font-weight: 600; font-size: 14px; }
.pt-feito { display: flex; align-items: center; gap: 8px; background: var(--brand-soft); color: var(--brand-dark); padding: 10px 12px; border-radius: 10px; font-weight: 600; font-size: 14px; }

@media (min-width: 1100px) {  /* computador: cartões de pendência em duas colunas */
  .pt-lista.grade { display: grid; grid-template-columns: repeat(auto-fill, minmax(400px, 1fr)); align-items: start; gap: 14px; }
}
.pt-folha .pt-check { min-height: 44px; align-items: center; }
.pt-paleta .tipo { min-width: 96px; text-align: center; }

/* trilha de 3 etapas */
.pt-trilha { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; list-style: none; margin: 0; padding: 0; }
.pt-trilha li { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; color: var(--muted); text-align: center; }
.pt-trilha li::before { content: ''; position: absolute; top: 7px; left: -50%; width: 100%; height: 3px; background: var(--line); z-index: 0; }
.pt-trilha li:first-child::before { display: none; }
.pt-trilha .ponto { position: relative; z-index: 1; width: 17px; height: 17px; border-radius: 50%; border: 3px solid var(--line); background: var(--card); }
.pt-trilha li.feito { color: var(--brand-dark); }
.pt-trilha li.feito .ponto { border-color: var(--brand); background: var(--brand); }
.pt-trilha li.feito::before, .pt-trilha li.atual::before { background: var(--brand); }
.pt-trilha li.atual { color: var(--ink); }
.pt-trilha li.atual .ponto { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(15, 118, 110, .18); }

/* folha inferior no celular / modal no computador */
.pt-folha-fundo { position: fixed; inset: 0; background: rgba(11, 21, 19, .55); z-index: 60; opacity: 0; transition: opacity .2s; }
.pt-folha { position: fixed; left: 0; right: 0; bottom: 0; z-index: 61; background: var(--card); color: var(--ink); border-radius: 18px 18px 0 0; max-height: 92vh; overflow-y: auto; padding: 8px 18px calc(18px + env(safe-area-inset-bottom)); transform: translateY(100%); transition: transform .25s ease; box-shadow: 0 -10px 40px rgba(0, 0, 0, .25); }
.pt-folha[hidden], .pt-folha-fundo[hidden] { display: none; }
.pt-folha.aberta { transform: none; }
.pt-folha-fundo.aberta { opacity: 1; }
.pt-folha-alca { width: 44px; height: 5px; border-radius: 3px; background: var(--line); margin: 4px auto 12px; }
.pt-folha h2 { margin: 0; font: 800 22px/1.15 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.pt-folha-fechar { position: absolute; right: 10px; top: 10px; width: 44px; height: 44px; border-radius: 10px; border: 0; background: transparent; color: var(--muted-2); cursor: pointer; display: grid; place-items: center; }
@media (min-width: 900px) {
  .pt-folha { left: 50%; right: auto; bottom: auto; top: 50%; width: 560px; border-radius: 18px; transform: translate(-50%, -46%) scale(.98); opacity: 0; transition: opacity .2s, transform .2s; max-height: 88vh; padding: 22px 26px 24px; }
  .pt-folha.aberta { transform: translate(-50%, -50%); opacity: 1; }
  .pt-folha-alca { display: none; }
}
@media (prefers-reduced-motion: reduce) { .pt-folha, .pt-folha-fundo { transition: none; } }
.pt-camera { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pt-camera label { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 92px; border: 2px dashed #B9C3C0; border-radius: 14px; background: #F6F8F7; font-weight: 700; font-size: 14px; cursor: pointer; color: var(--ink); text-align: center; }
.pt-camera label.pri { border-style: solid; border-color: var(--ink); background: var(--ink); color: #FFF; }
.pt-camera label:focus-within { outline: 3px solid var(--mint); outline-offset: 2px; }
.pt-camera input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.pt-camera svg { width: 26px; height: 26px; }
.pt-miniaturas { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.pt-miniaturas:empty { display: none; }
.pt-miniatura { position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: #F3F5F4; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; color: var(--red-text); }
.pt-miniatura img { width: 100%; height: 100%; object-fit: cover; }
.pt-miniatura button { position: absolute; top: 3px; right: 3px; width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(11, 21, 19, .78); color: #FFF; cursor: pointer; display: grid; place-items: center; font-size: 16px; line-height: 1; }
.pt-resultado { display: flex; gap: 10px; align-items: flex-start; border-radius: 12px; padding: 12px 14px; font-size: 14px; font-weight: 600; }
.pt-resultado.simples { background: var(--brand-soft); color: var(--brand-dark); }
.pt-resultado.tecnico { background: #EEF0FF; color: #3730A3; }
.pt-progresso { height: 8px; border-radius: 4px; background: var(--line-2); overflow: hidden; }
.pt-progresso span { display: block; height: 100%; width: 0; background: var(--brand); transition: width .2s; }

/* aviso (toast) com desfazer */
.pt-avisos { position: fixed; left: 12px; right: 12px; bottom: 86px; z-index: 70; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
@media (min-width: 900px) { .pt-avisos { left: auto; right: 24px; bottom: 24px; width: 420px; } }
.pt-aviso { pointer-events: auto; display: flex; align-items: center; gap: 12px; background: var(--ink); color: #FFF; border-radius: 14px; padding: 12px 12px 12px 16px; box-shadow: 0 10px 30px rgba(0, 0, 0, .3); font-weight: 600; font-size: 15px; position: relative; overflow: hidden; }
.pt-aviso.erro { background: #7A1D12; }
.pt-aviso span { flex: 1; }
.pt-aviso button { min-height: 44px; padding: 8px 14px; border-radius: 10px; border: 0; background: var(--mint); color: #062E2A; font: 700 15px Barlow, sans-serif; cursor: pointer; }
.pt-aviso .tempo { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--mint); animation: pt-tempo linear forwards; }
@keyframes pt-tempo { from { width: 100%; } to { width: 0; } }

/* linha do tempo e evidências */
.pt-tempo { list-style: none; margin: 0; padding: 0 0 0 22px; position: relative; }
.pt-tempo::before { content: ''; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.pt-tempo li { position: relative; padding: 0 0 18px; }
.pt-tempo li::before { content: ''; position: absolute; left: -21px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--card); border: 3px solid var(--muted); }
.pt-tempo li.bom::before { border-color: var(--brand); background: var(--brand); }
.pt-tempo li.ruim::before { border-color: var(--red); }
.pt-tempo li.envio::before { border-color: #4F46E5; }
.pt-tempo .quando { font-size: 12px; color: var(--muted); }
.pt-tempo .oque { font-weight: 700; }
.pt-tempo blockquote { margin: 6px 0 0; padding: 8px 10px; background: var(--ground); border-radius: 8px; font-size: 14px; color: var(--muted-2); white-space: pre-line; }
.pt-galeria { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin-top: 8px; }
.pt-galeria a { display: block; aspect-ratio: 1; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: #F3F5F4; }
.pt-galeria img { width: 100%; height: 100%; object-fit: cover; }
.pt-galeria .pdf { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; font-weight: 800; color: var(--red-text); font-size: 13px; text-decoration: none; gap: 4px; }
.pt-galeria .pdf small { color: var(--muted); font-weight: 600; font-size: 10px; max-width: 90%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pt-tela-cheia { position: fixed; inset: 0; z-index: 80; background: rgba(5, 10, 9, .94); display: flex; align-items: center; justify-content: center; padding: 16px; }
.pt-tela-cheia img { max-width: 100%; max-height: 100%; border-radius: 6px; }
.pt-tela-cheia button { position: absolute; top: 12px; right: 12px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .15); color: #FFF; font-size: 24px; cursor: pointer; }

/* menu do usuário e topo */
.pt-top-acoes { display: flex; align-items: center; gap: 8px; }
.pt-icone-btn { cursor: pointer; }
.pt-icone-btn svg { width: 20px; height: 20px; }
.pt-menu-user { position: relative; }
.pt-menu-user summary { list-style: none; }
.pt-menu-user summary::-webkit-details-marker { display: none; }
.pt-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--brand); color: #FFF; display: grid; place-items: center; font: 800 16px var(--display); cursor: pointer; border: 2px solid var(--mint); }
.pt-menu-lista { position: absolute; right: 0; top: 52px; z-index: 30; min-width: 240px; background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 16px 40px rgba(0, 0, 0, .22); padding: 6px; }
.pt-menu-lista a, .pt-menu-lista button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 12px; border-radius: 10px; border: 0; background: transparent; color: var(--ink); font: 600 15px Barlow, sans-serif; text-decoration: none; cursor: pointer; text-align: left; }
.pt-menu-lista a:hover, .pt-menu-lista button:hover { background: var(--ground); color: var(--ink); }
.pt-menu-lista .quem { padding: 8px 12px 10px; border-bottom: 1px solid var(--line-2); margin-bottom: 4px; font-size: 13px; color: var(--muted); }
.pt-menu-lista .quem b { display: block; color: var(--ink); font-size: 15px; }

/* busca Ctrl+K */
.pt-paleta { position: fixed; inset: 0; z-index: 75; background: rgba(11, 21, 19, .55); display: flex; align-items: flex-start; justify-content: center; padding: 10vh 12px 12px; }
.pt-paleta[hidden] { display: none; }
.pt-paleta-caixa { width: 100%; max-width: 620px; background: var(--card); color: var(--ink); border-radius: 16px; box-shadow: 0 24px 60px rgba(0, 0, 0, .35); overflow: hidden; }
.pt-paleta-caixa input { width: 100%; border: 0; border-bottom: 1px solid var(--line-2); padding: 18px 18px; font: 400 18px Barlow, sans-serif; background: transparent; color: var(--ink); outline: 0; }
.pt-paleta ul { list-style: none; margin: 0; padding: 6px; max-height: 60vh; overflow-y: auto; }
.pt-paleta li a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 8px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; }
.pt-paleta li a[aria-selected="true"], .pt-paleta li a:hover { background: var(--ground); }
.pt-paleta .tipo { font: 800 11px var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--brand-dark); background: var(--brand-soft); padding: 2px 7px; border-radius: 5px; flex-shrink: 0; }
.pt-paleta .rodape { padding: 10px 16px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line-2); }
kbd { font: 600 12px var(--mono); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 1px 5px; background: var(--card); color: var(--muted-2); }

/* esqueleto de carregamento */
.pt-esq { display: block; border-radius: 8px; background: linear-gradient(90deg, var(--line-2) 0%, var(--ground) 50%, var(--line-2) 100%); background-size: 200% 100%; animation: pt-esq 1.2s ease-in-out infinite; }
@keyframes pt-esq { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .pt-esq, .pt-aviso .tempo { animation: none; } }
.pt-visor-caixa { position: relative; }
.pt-visor-caixa .pt-esq { position: absolute; inset: 0; border-radius: 12px; }
.pt-visor-caixa.pronto .pt-esq { display: none; }

/* tour do primeiro acesso */
.pt-tour { position: fixed; inset: 0; z-index: 90; background: rgba(11, 21, 19, .7); display: flex; align-items: flex-end; justify-content: center; padding: 16px; }
.pt-tour[hidden] { display: none; }
@media (min-width: 900px) { .pt-tour { align-items: center; } }
.pt-tour-caixa { width: 100%; max-width: 440px; background: var(--card); color: var(--ink); border-radius: 18px; padding: 22px; box-shadow: 0 24px 60px rgba(0, 0, 0, .35); }
.pt-tour-caixa h2 { margin: 6px 0 6px; font: 800 24px/1.1 var(--display); text-transform: uppercase; }
.pt-tour-pontos { display: flex; gap: 6px; }
.pt-tour-pontos span { width: 22px; height: 5px; border-radius: 3px; background: var(--line); }
.pt-tour-pontos span.on { background: var(--brand); }

/* textos legais */
.pt-legal-texto { line-height: 1.6; font-size: 15px; }
.pt-legal-texto h2 { font: 800 18px var(--display); text-transform: uppercase; letter-spacing: .04em; margin: 22px 0 6px; }
.pt-rodape-links { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; font-size: 12px; }
.pt-rodape-links a { color: var(--muted); }

/* tabela simples (pacotes, convites, acessos) */
.pt-tabela { width: 100%; border-collapse: collapse; font-size: 14px; }
.pt-tabela th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 8px 6px; border-bottom: 1px solid var(--line); }
.pt-tabela td { padding: 10px 6px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
@media (max-width: 480px) {  /* documento com 3 ações: os botões descem para a linha de baixo */
  .pt-doc { flex-wrap: wrap; }
  .pt-doc > span:nth-child(2) { flex: 1 1 calc(100% - 50px) !important; }  /* vence o style="flex:1" dos itens */
  .pt-doc > .pt-btn:first-of-type { margin-left: 46px; }
}
@media (max-width: 599px) {  /* no celular a tabela vira lista (sem rolagem horizontal) */
  .pt-tabela thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .pt-tabela tr { display: block; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
  .pt-tabela td { display: block; border: 0; padding: 2px 0; }
  .pt-tabela td:empty { display: none; }
}

/* cartão público do QR */
.pt-qr-situacao { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: var(--radius); font-weight: 700; }
.pt-qr-situacao.ok { background: var(--brand-soft); color: var(--brand-dark); }
.pt-qr-situacao.vence { background: var(--amber-soft); color: var(--amber-text); }
.pt-qr-situacao.vencido { background: var(--red-soft); color: var(--red-text); }
.pt-qr-situacao.sem { background: #F3F5F4; color: var(--muted-2); }
.pt-qr-situacao svg { width: 34px; height: 34px; flex-shrink: 0; }
.pt-qr-situacao b { display: block; font: 800 22px/1.05 var(--display); text-transform: uppercase; }

/* ---- modo escuro (data-tema="escuro"; "auto" segue o sistema) ---- */
html[data-tema="escuro"] {
  --ground: #0D1514; --grid: #142120; --card: #15211F; --line: #2C3E3B; --line-2: #22332F;
  --muted: #9DB0AB; --muted-2: #C4D2CE; --brand: #14B8A6; --brand-dark: #7FE0CF; --brand-soft: #0F3B36;
  --amber-text: #FCD58A; --amber-soft: #3B2A0B; --red-text: #FCA5A5; --red-soft: #3F1712;
  color-scheme: dark;
}
html[data-tema="escuro"] body { color: #E6EEEC; }
html[data-tema="escuro"] .pt-btn, html[data-tema="escuro"] .pt-chip, html[data-tema="escuro"] .pt-abas a,
html[data-tema="escuro"] .pt-busca, html[data-tema="escuro"] .pt-doc, html[data-tema="escuro"] .pt-info,
html[data-tema="escuro"] .pt-field input, html[data-tema="escuro"] .pt-field select, html[data-tema="escuro"] .pt-field textarea,
html[data-tema="escuro"] .pt-filtros select { background: var(--card); color: #E6EEEC; border-color: var(--line); }
html[data-tema="escuro"] .pt-btn.pri, html[data-tema="escuro"] .pt-abas a[aria-current="page"], html[data-tema="escuro"] .pt-chip[aria-current="true"] { background: var(--mint); border-color: var(--mint); color: #062E2A; }
html[data-tema="escuro"] .pt-card, html[data-tema="escuro"] .pt-pend { background: var(--card); }
html[data-tema="escuro"] .pt-placa { background: linear-gradient(180deg, #1B2A27, #142220); color: #E6EEEC; box-shadow: none; }
html[data-tema="escuro"] .pt-kpi, html[data-tema="escuro"] .pt-kpi b, html[data-tema="escuro"] .pt-linha-data,
html[data-tema="escuro"] .pt-rec, html[data-tema="escuro"] .pt-pend-titulo, html[data-tema="escuro"] .pt-vazio b,
html[data-tema="escuro"] .pt-cal b, html[data-tema="escuro"] .pt-busca input, html[data-tema="escuro"] .pt-trilha li.atual { color: #E6EEEC; }
html[data-tema="escuro"] .pt-mini { background: #1C2B28; border-color: var(--line); color: var(--muted-2); }
html[data-tema="escuro"] .pt-mini.vencido { background: var(--red-soft); border-color: #7A2A1F; color: var(--red-text); }
html[data-tema="escuro"] .pt-mini.vence { background: var(--amber-soft); border-color: #6B4E12; color: var(--amber-text); }
html[data-tema="escuro"] .pt-mini.ok { background: var(--brand-soft); border-color: #1F5C55; color: var(--brand-dark); }
html[data-tema="escuro"] .pt-selo.engenheiro, html[data-tema="escuro"] .pt-espera, html[data-tema="escuro"] .pt-resultado.tecnico { background: #23224A; color: #C7C4FF; }
html[data-tema="escuro"] .pt-camera label { background: #1C2B28; color: #E6EEEC; border-color: var(--line); }
html[data-tema="escuro"] .pt-camera label.pri { background: var(--mint); color: #062E2A; border-color: var(--mint); }
html[data-tema="escuro"] .pt-dias { background: #1C2B28; color: var(--muted-2); }
html[data-tema="escuro"] a { color: var(--mint); }
/* PM-805 (21/10/2026): Portal Fase 3 — acompanhamento da OS em 4 etapas e aba Serviços */
.pt-trilha.pt-trilha-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.pt-os { padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.pt-os:last-child { border-bottom: 0; }
.pt-nav { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (min-width: 900px) { .pt-nav { grid-template-columns: 1fr; } }

/* FALE-1 (27/10/2026): "Fale com" — cartões de assunto (rádio), mensagens e respostas. */
.pt-assuntos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
@media (min-width: 700px) { .pt-assuntos { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.pt-assunto { position: relative; display: flex; flex-direction: column; gap: 4px; min-height: 112px; padding: 14px; border: 1px solid #B9C3C0; border-radius: 12px; background: #FFF; color: var(--ink); cursor: pointer; text-decoration: none; }
.pt-assunto b { font-size: 16px; }
.pt-assunto .pt-muted { font-size: 13px; line-height: 1.3; }
.pt-assunto input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pt-assunto:hover { border-color: var(--muted); color: var(--ink); }
.pt-assunto:focus-within { outline: 3px solid var(--mint); outline-offset: 2px; }
.pt-assunto:has(input:checked) { border: 2px solid var(--ink); background: var(--brand-soft); }
.pt-assunto-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: #F1F4F3; color: var(--brand); }
.pt-assunto-ic svg { width: 22px; height: 22px; }
.pt-assunto[data-assunto="reclamacao"] .pt-assunto-ic { background: var(--red-soft); color: var(--red-text); }
.pt-assunto[data-assunto="elogio"] .pt-assunto-ic { background: var(--amber-soft); color: var(--amber-text); }
[data-so][hidden] { display: none !important; }
.pt-msg-item { padding: 12px 0; border-bottom: 1px solid var(--line-2); display: grid; gap: 4px; }
.pt-msg-item:last-child { border-bottom: 0; }
.pt-resposta { margin-top: 6px; padding: 10px 12px; border-left: 3px solid var(--brand); background: var(--brand-soft); border-radius: 0 10px 10px 0; color: var(--brand-dark); white-space: pre-line; }
.pt-selo.recebida { background: #F1F4F3; color: var(--muted-2); }
.pt-selo.em_analise { background: var(--amber-soft); color: var(--amber-text); }
.pt-selo.respondida { background: var(--brand-soft); color: var(--brand-dark); }
html[data-tema="escuro"] .pt-assunto { background: var(--card); color: #E6EEEC; border-color: var(--line); }
html[data-tema="escuro"] .pt-assunto:has(input:checked) { border-color: var(--mint); background: #16302C; }
html[data-tema="escuro"] .pt-assunto-ic { background: #1C2B28; }
html[data-tema="escuro"] .pt-resposta { background: #16302C; color: #E6EEEC; }

/* Tiago 28/10/2026: foto principal do equipamento — cartão da lista e topo da ficha */
.pt-placa .pt-foto-mini { width: 84px; flex-shrink: 0; align-self: stretch; border-radius: 8px; overflow: hidden; position: relative;
  border: 1px solid #B9C3C0; background: #DDE3E1; box-shadow: inset 0 0 0 3px #FFF; }
.pt-placa .pt-foto-mini img { width: 100%; height: 100%; min-height: 84px; object-fit: cover; display: block; }
.pt-placa .pt-foto-mini.vazia { display: grid; place-items: center; border-style: dashed; box-shadow: none; color: var(--muted);
  font: 700 10px Barlow, sans-serif; letter-spacing: .08em; text-align: center; min-height: 84px; }
.pt-hero { position: relative; margin: 0 0 14px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--ink); }
.pt-hero img { width: 100%; aspect-ratio: 16 / 9; max-height: 420px; object-fit: cover; display: block; }
.pt-hero .faixa { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 14px 12px; color: #FFF; display: flex;
  justify-content: space-between; align-items: flex-end; gap: 10px; background: linear-gradient(180deg, rgba(11,21,19,0), rgba(11,21,19,.88)); }
.pt-hero .faixa b { font: 600 22px var(--mono); letter-spacing: .04em; display: block; }
.pt-hero .faixa small { color: #C9D6D3; font-size: 12px; }
.pt-hero .selo-luz { display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; color: #FFF; border-radius: 999px;
  padding: 4px 10px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25);
  font: 800 12px var(--display); letter-spacing: .06em; text-transform: uppercase; }
.pt-hero .selo-luz .pt-lamp { width: 10px; height: 10px; }
.pt-hero .ampliar { position: absolute; top: 10px; right: 10px; background: rgba(11,21,19,.6); color: #FFF; border-radius: 8px;
  padding: 6px 9px; font: 600 12px Barlow, sans-serif; }
html[data-tema="escuro"] .pt-placa .pt-foto-mini { border-color: var(--line); box-shadow: none; }

/* Tiago 29/10/2026: o atributo hidden sempre esconde — antes .pt-check/.pt-btn (display:flex) venciam e a busca do
   convite "não funcionava" (filtrava, mas nada sumia). */
[hidden] { display: none !important; }

/* Convite do portal: listas de Grupos e de Clientes com busca */
.pt-unidades-titulo { font: 800 14px var(--display); letter-spacing: .06em; text-transform: uppercase; margin: 14px 0 6px; color: var(--muted-2); }
.pt-unidades-titulo small { font: 500 12px Barlow, sans-serif; letter-spacing: 0; text-transform: none; color: var(--muted); }
.pt-unidades-lista { max-height: 280px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; padding: 2px 10px; background: var(--card); }
.pt-unidade { padding: 8px 0; border-bottom: 1px dashed var(--line-2); }
.pt-unidade:last-of-type { border-bottom: 0; }
.pt-unidade input { margin-top: 3px; width: 18px; height: 18px; flex-shrink: 0; }
.pt-unidades-marcadas { margin: 8px 0 2px; font-size: 14px; color: var(--muted); }
.pt-unidades-marcadas .pt-btn { min-height: 34px; padding: 4px 10px; margin: 2px 4px 2px 0; font-size: 13px; }
.pt-unidade-link { display: flex; flex-direction: column; gap: 2px; text-decoration: none; color: var(--ink); padding: 10px 6px; border-radius: 8px; }
.pt-unidade-link:hover, .pt-unidade-link:focus { background: var(--brand-soft); color: var(--ink); }
.pt-unidade-link small { font-size: 12px; }


/* ATIVOS-3 (Tiago 05/11/2026): fora de operação, seções da lista e parcelas do mostrador */
.pt-lamp.fora { background: repeating-linear-gradient(45deg, #56645F 0 3px, #9AA6A3 3px 6px); box-shadow: 0 0 0 3px rgba(86, 100, 95, .2); }
.pt-st.fora { color: var(--muted); }
.pt-secao-cab { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 6px 0 8px; }
.pt-parcelas { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 6px; }
.pt-parcelas li { display: grid; gap: 1px; border-top: 1px solid var(--line-2); padding-top: 6px; }
.pt-parcelas li span { color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.pt-parcelas li b { font-size: 15px; }
[data-faixas-ativos] p { margin: 0; }
.pt-faixa-info { border-left: 4px solid var(--amber); background: var(--amber-soft, #FEF3C7); color: var(--ink); padding: 10px 12px; border-radius: 0 10px 10px 0; font-size: 14px; }
.pt-faixa-info b { display: block; }

/* RECORTE-1 (Tiago 11/11/2026): "Só parte dos equipamentos" — convite e ficha do usuário do portal */
.pt-recorte { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--card); }
.pt-recorte > summary { cursor: pointer; line-height: 1.45; min-height: 28px; }
.pt-recorte[open] > summary { margin-bottom: 8px; }
.pt-recorte-ajuda { font-size: 13px; margin: 0 0 12px; }
.pt-recorte-bloco { border: 0; padding: 0; margin: 0 0 12px; min-width: 0; }
.pt-recorte-bloco legend { margin-bottom: 6px; }
.pt-recorte-tipos { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.pt-recorte-tipos .pt-check { align-items: center; font-weight: 600; }
.pt-recorte-tipos .pt-check input { min-height: 0; width: 20px; height: 20px; padding: 0; margin: 0; }
.pt-recorte-acoes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
/* BAIXAR-1 (11/11/2026): só ver / sem link de auditor (convite e ficha) e as páginas como imagem */
.pt-permissoes { display: grid; gap: 10px; }
.pt-permissoes .pt-check { align-items: flex-start; line-height: 1.45; }
.pt-permissoes .pt-check input { min-height: 0; width: 20px; height: 20px; padding: 0; margin: 2px 0 0; flex: none; }
.pt-paginas { display: grid; gap: 12px; margin-top: 10px; justify-items: center; }
.pt-paginas img { display: block; width: 100%; max-width: 900px; height: auto; background: #fff; border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 1px 3px rgba(0,0,0,.08); -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
/* VENCIDO-CHIP no tema escuro (a regra geral do .pt-chip escuro é mais específica) */
html[data-tema="escuro"] .pt-chip.vencido { background: var(--red-soft); border-color: #7A2A1F; color: var(--red-text); }
html[data-tema="escuro"] .pt-chip.vencido[aria-current="true"] { background: var(--red); border-color: var(--red); color: #FFF; }

/* Ajuda do portal (13/11/2026): página do manual (css/manual.css) com as cores do portal e o tema escuro. */
.mn-portal { --mn-acc: var(--brand-dark, #0f766e); }
.mn-portal .mn-doc > * { max-width: 76ch; }
html[data-tema="escuro"] .mn-portal { --mn-tinta: #E6EEEC; --mn-txt: #C4D2CE; --mn-suave: #9DB0AB; --mn-linha: var(--line); --mn-acc: #14B8A6; }
html[data-tema="escuro"] .mn-portal .mn-doc, html[data-tema="escuro"] .mn-portal .mn-tabela th,
html[data-tema="escuro"] .mn-portal .mn-passos > li { background: var(--card); }
html[data-tema="escuro"] .mn-portal .mn-botao { background: var(--brand-soft); color: #7FE0CF; }
html[data-tema="escuro"] .mn-portal .mn-dica { background: #0F3B36; color: #CDEFE8; }
html[data-tema="escuro"] .mn-portal .mn-atencao { background: #3B2A0B; color: #FCD58A; }
html[data-tema="escuro"] .mn-portal .mn-porque { background: #1E2448; color: #C7CDFB; }
.mn-portal .mn-doc > .mn-h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
