/* Tema escuro do Horus, no mesmo padrão do Axis (paleta slate + azul). */

.brand { font-family: 'Space Grotesk', ui-sans-serif, system-ui, sans-serif; font-weight: 700; letter-spacing: -0.02em; }
.tabular { font-variant-numeric: tabular-nums; }

.card { background-color: rgb(15 23 42 / 0.6); border: 1px solid rgb(30 41 59); border-radius: 0.75rem; }
.card-glow {
    background-color: rgb(15 23 42 / 0.6);
    border: 1px solid rgb(59 130 246 / 0.35);
    border-radius: 0.75rem;
    box-shadow: 0 0 0 1px rgb(59 130 246 / 0.08), 0 0 18px 0 rgb(59 130 246 / 0.18);
    transition: box-shadow .2s ease, border-color .2s ease;
}
.card-glow:hover { border-color: rgb(59 130 246 / 0.6); box-shadow: 0 0 0 1px rgb(59 130 246 / .12), 0 0 26px 2px rgb(59 130 246 / .28); }

.btn-primary, .btn-secondary, .btn-danger {
    display: inline-flex; align-items: center; justify-content: center; gap: .375rem;
    font-size: .875rem; font-weight: 500; padding: .5rem 1rem; border-radius: .75rem;
    transition: background-color .15s ease;
}
.btn-primary { background-color: rgb(37 99 235); color: #fff; }
.btn-primary:hover { background-color: rgb(59 130 246); }
.btn-primary:disabled { opacity: .6; }
.btn-secondary { background: transparent; color: rgb(226 232 240); border: 1px solid rgb(51 65 85); }
.btn-secondary:hover { background-color: rgb(51 65 85); }
.btn-danger { background: transparent; color: rgb(248 113 113); border: 1px solid rgb(127 29 29); }
.btn-danger:hover { background-color: rgb(69 10 10); }

/* Campos de formulário */
input[type=date], input[type=time], input[type=month] { color-scheme: dark; }
select option { background: rgb(15 23 42); color: rgb(241 245 249); }

/* Rolagem escura */
* { scrollbar-width: thin; scrollbar-color: rgb(51 65 85) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background-color: rgb(51 65 85); border-radius: 9999px; }
::-webkit-scrollbar-thumb:hover { background-color: rgb(71 85 105); }

@media (min-width: 1024px) {
    main section.rounded-2xl, main section.rounded-xl, main .card-glow { backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
}

/* Impressão: volta ao papel branco */
@media print {
    .nao-imprimir, #fundo-brilho { display: none !important; }
    body { background: #fff !important; color: #0f172a !important; }
}

/* Campos sem classe de fundo própria (selects e inputs soltos nas telas) seguem o tema escuro.
   :where() deixa a especificidade zero: qualquer classe da tela ainda vence. */
:where(select, textarea, input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]):not([type=submit]):not([type=button])) {
    background-color: rgb(15 23 42); color: rgb(241 245 249); border-color: rgb(51 65 85);
}

/* Controles nativos (bolinhas, listas, calendário, barras) sempre no modo escuro, mesmo com o
   celular/Windows no modo claro. */
:root { color-scheme: dark; }

/* Preenchimento automático do navegador (login, nome...) pinta o campo de claro e o texto some.
   Mantém o fundo escuro e o texto claro. */
input:-webkit-autofill, input:-webkit-autofill:hover, input:-webkit-autofill:focus,
textarea:-webkit-autofill, select:-webkit-autofill {
    -webkit-text-fill-color: rgb(241 245 249);
    caret-color: rgb(241 245 249);
    -webkit-box-shadow: 0 0 0 1000px rgb(15 23 42) inset;
    box-shadow: 0 0 0 1000px rgb(15 23 42) inset;
    transition: background-color 9999s ease-out 0s;
}

@media print { :root { color-scheme: light; } }
