/* Painel "Veltro Sul Climatização" (CRM de limpeza, demonstração da Thriven, 29/11/2026). Pensado pro celular do técnico. */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --azul: #0F172A; --azul-2: #0369A1; --azul-2-escuro: #075985; --ceu: #F1F5F9; --ceu-2: #E0F2FE;
  --fundo: #F4F7FA; --texto: #13202E; --suave: #4F6072; --borda: #D5E1EC;
  --ok: #157347; --ok-fundo: #E3F4EA; --alerta: #9A5B00; --alerta-fundo: #FFF3DC; --atraso: #B42318; --atraso-fundo: #FDE8E7;
  --fonte: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--fonte); font-size: 16px; line-height: 1.5; color: var(--texto); background: var(--fundo); -webkit-font-smoothing: antialiased; padding-bottom: 84px; }
button { font: inherit; color: inherit; }
a { color: var(--azul-2); }
:focus-visible { outline: 3px solid #7DB6EE; outline-offset: 2px; }

/* Topo */
.p-topo { position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--borda); }
.p-topo-in { max-width: 720px; margin: 0 auto; height: 56px; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; }
.p-marca { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 18px; color: var(--azul); text-decoration: none; }
.p-marca span { color: var(--azul-2); }
.p-topo-dir { display: flex; align-items: center; gap: 8px; }
.chip-demo { font-size: 13px; font-weight: 600; background: var(--ceu-2); color: var(--azul); border-radius: 999px; padding: 4px 10px; }
.p-recomecar { background: none; border: 0; color: var(--azul-2); font-size: 15px; font-weight: 600; min-height: 44px; padding: 0 6px; cursor: pointer; }

.p-main { max-width: 720px; margin: 0 auto; padding: 20px 16px 24px; }
.p-main:focus { outline: none; }

/* Navegação de baixo */
.p-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff; border-top: 1px solid var(--borda); display: flex; justify-content: center; padding-bottom: env(safe-area-inset-bottom); }
.p-nav a { position: relative; flex: 1; max-width: 180px; min-height: 64px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-decoration: none; color: #5B6B7C; font-size: 13px; font-weight: 600; }
.p-nav svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.p-nav a[aria-current="page"] { color: var(--azul-2); }
.p-nav a[aria-current="page"]::before { content: ""; position: absolute; top: 0; left: 25%; right: 25%; height: 3px; border-radius: 0 0 3px 3px; background: var(--azul-2); }
.p-badge { position: absolute; top: 6px; left: calc(50% + 6px); min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--atraso); color: #fff; font-size: 12px; line-height: 20px; text-align: center; }

/* Títulos e textos */
.t-data { font-size: 15px; color: var(--suave); }
.t-tela { font-size: 26px; font-weight: 800; color: var(--azul); line-height: 1.2; margin: 2px 0 16px; }
.t-secao { font-size: 18px; font-weight: 700; color: var(--azul); margin: 28px 0 10px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.t-secao small { font-size: 14px; font-weight: 600; color: var(--suave); }
.suave { color: var(--suave); }
.vazio { background: #fff; border: 1px dashed var(--borda); border-radius: 12px; padding: 20px; color: var(--suave); text-align: center; }

/* Destaque principal */
.destaque { display: block; text-decoration: none; background: var(--azul); color: #fff; border-radius: 16px; padding: 20px; margin-bottom: 12px; }
.destaque-num { font-size: 40px; font-weight: 800; line-height: 1; }
.destaque-txt { font-size: 18px; font-weight: 700; margin-top: 6px; }
.destaque-sub { font-size: 15px; color: #C9DCEF; margin-top: 4px; }
.destaque-acao { display: inline-block; margin-top: 14px; font-weight: 700; color: #fff; text-decoration: underline; text-underline-offset: 3px; }

.alerta-novo { display: flex; align-items: center; justify-content: space-between; gap: 12px; text-decoration: none; background: var(--atraso-fundo); color: var(--atraso); border-radius: 12px; padding: 14px 16px; font-weight: 600; margin-bottom: 12px; min-height: 52px; }
.alerta-novo .ponto { width: 10px; height: 10px; border-radius: 50%; background: var(--atraso); flex-shrink: 0; }
.alerta-novo .alerta-texto { flex: 1; }

.numeros { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.numero { background: #fff; border-radius: 12px; padding: 14px 16px; border: 1px solid var(--borda); }
.numero b { display: block; font-size: 26px; color: var(--azul); line-height: 1.1; }
.numero span { font-size: 14px; color: var(--suave); }

/* Filtros */
.filtros { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 14px; scrollbar-width: none; }
.filtros::-webkit-scrollbar { display: none; }
.filtro { flex-shrink: 0; min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--borda); background: #fff; font-size: 15px; font-weight: 600; color: var(--suave); cursor: pointer; }
.filtro[aria-pressed="true"] { background: var(--azul-2); border-color: var(--azul-2); color: #fff; }

/* Cartões de lista */
.lista { display: grid; gap: 10px; }
.item { display: block; width: 100%; text-align: left; background: #fff; border: 1px solid var(--borda); border-radius: 12px; padding: 14px 16px; text-decoration: none; color: inherit; cursor: pointer; }
.item:hover { border-color: #A8C6E4; }
.item-topo { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.item-nome { font-weight: 700; font-size: 17px; }
.item-linha { font-size: 15px; color: var(--suave); margin-top: 2px; }
.item-acoes { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }

.selo { flex-shrink: 0; font-size: 13px; font-weight: 700; border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.selo-novo { background: var(--atraso-fundo); color: var(--atraso); }
.selo-respondido { background: var(--ceu-2); color: var(--azul); }
.selo-visita { background: var(--alerta-fundo); color: var(--alerta); }
.selo-fechado { background: var(--ok-fundo); color: var(--ok); }
.selo-atraso { background: var(--atraso-fundo); color: var(--atraso); }
.selo-mes { background: var(--alerta-fundo); color: var(--alerta); }
.selo-depois { background: var(--ceu); color: var(--suave); }
.selo-enviado { background: var(--ok-fundo); color: var(--ok); }

/* Botões */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 10px 16px; border-radius: 10px; border: 2px solid var(--azul-2); background: var(--azul-2); color: #fff; font-weight: 700; font-size: 15px; cursor: pointer; text-decoration: none; }
.btn:hover { background: var(--azul-2-escuro); border-color: var(--azul-2-escuro); }
.btn-contorno { background: #fff; color: var(--azul-2); }
.btn-contorno:hover { background: var(--ceu); color: var(--azul-2-escuro); }
.btn-largo { width: 100%; }
.btn-texto { background: none; border: 0; color: var(--azul-2); font-weight: 700; min-height: 44px; padding: 0 4px; cursor: pointer; }

/* Detalhe */
.voltar { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 700; text-decoration: none; color: var(--azul-2); margin-bottom: 4px; }
.cartao { background: #fff; border: 1px solid var(--borda); border-radius: 12px; padding: 16px; margin-bottom: 12px; }
.cartao h3 { font-size: 15px; font-weight: 700; color: var(--suave); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 10px; }
.dados { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 16px; }
.dados dt { color: var(--suave); }
.dados dd { font-weight: 600; }
.historico { list-style: none; display: grid; gap: 8px; }
.historico li { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; border-bottom: 1px solid var(--borda); padding-bottom: 8px; }
.historico li:last-child { border-bottom: 0; padding-bottom: 0; }
.acoes-coluna { display: grid; gap: 10px; margin-top: 4px; }

.busca { width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 10px; border: 1.5px solid var(--borda); font: 16px var(--fonte); margin-bottom: 14px; background: #fff; }

/* Modal */
.modal-fundo { position: fixed; inset: 0; z-index: 60; background: rgba(10,25,40,.55); display: flex; align-items: flex-end; justify-content: center; padding: 16px; }
.modal-fundo[hidden] { display: none; }
.modal { background: #fff; width: 100%; max-width: 520px; border-radius: 16px; padding: 20px; max-height: 90vh; overflow-y: auto; }
.modal h2 { font-size: 20px; color: var(--azul); margin-bottom: 12px; }
.mensagem { width: 100%; min-height: 150px; border: 1.5px solid var(--borda); border-radius: 10px; padding: 12px; font: 16px/1.5 var(--fonte); color: var(--texto); background: var(--ceu); resize: vertical; }
.modal-nota { font-size: 14px; color: var(--suave); margin: 10px 0 14px; }
.modal-botoes { display: grid; gap: 10px; }
.campo-modal { margin-bottom: 14px; }
.campo-modal label { display: block; font-weight: 600; margin-bottom: 6px; }
.campo-modal input, .campo-modal select { width: 100%; min-height: 48px; padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--borda); font: 16px var(--fonte); background: #fff; }

/* Aviso */
.aviso { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); z-index: 70; background: #13202E; color: #fff; border-radius: 10px; padding: 12px 16px; font-size: 15px; display: flex; gap: 14px; align-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.25); max-width: calc(100% - 32px); }
.aviso[hidden] { display: none; }
.aviso button { background: none; border: 0; color: #9CC8F5; font-weight: 700; cursor: pointer; min-height: 36px; }

@media (min-width: 720px) {
  .modal-fundo { align-items: center; }
  .numeros { grid-template-columns: repeat(4, 1fr); }
}
