
/* =====================================================
   TECFLUX | CADASTRO RÁPIDO DE PRODUTO
   Padrão visual igual à tela REGISTRAR VENDA
   Arquivo: app/lib/include/css/produto.css
   ===================================================== */

:root {
    --prod-blue: #2164b5;
    --prod-blue-dark: #174b8b;
    --prod-blue-light: #edf5ff;
    --prod-green: #12a765;
    --prod-green-dark: #07864e;
    --prod-text: #263e5a;
    --prod-muted: #6c8099;
    --prod-border: #dce6f2;
    --prod-bg: #f4f7fc;
    --prod-white: #ffffff;
}

/* =====================================================
   1. JANELA / MODAL
   ===================================================== */

.twindow:has(#form_ExpressProdutoForm),
.window_modal:has(#form_ExpressProdutoForm),
.modal:has(#form_ExpressProdutoForm),
.ui-dialog:has(#form_ExpressProdutoForm) {
    border: 1px solid var(--prod-border) !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    background: var(--prod-white) !important;
    box-shadow: 0 14px 40px rgba(24, 54, 91, .16) !important;
}

/* Cabeçalho azul corporativo */
.twindow:has(#form_ExpressProdutoForm) .twindow-title,
.window_modal:has(#form_ExpressProdutoForm) .twindow-title,
.modal:has(#form_ExpressProdutoForm) .modal-header,
.ui-dialog:has(#form_ExpressProdutoForm) .ui-dialog-titlebar {
    background: linear-gradient(110deg, #174b8b, #2875cf) !important;
    color: #fff !important;
    border: 0 !important;
    border-bottom: 1px solid rgba(255,255,255,.15) !important;
    min-height: 58px;
    padding: 15px 24px !important;
    box-sizing: border-box;
}

/* Título e elementos do cabeçalho */
.twindow:has(#form_ExpressProdutoForm) .twindow-title *,
.window_modal:has(#form_ExpressProdutoForm) .twindow-title *,
.modal:has(#form_ExpressProdutoForm) .modal-header *,
.ui-dialog:has(#form_ExpressProdutoForm) .ui-dialog-titlebar {
    color: #fff !important;
    font-weight: 700 !important;
}

/* Corpo da janela */
.twindow:has(#form_ExpressProdutoForm) .twindow-content,
.window_modal:has(#form_ExpressProdutoForm) .twindow-content,
.modal:has(#form_ExpressProdutoForm) .modal-body,
.ui-dialog:has(#form_ExpressProdutoForm) .ui-dialog-content {
    background: var(--prod-bg) !important;
}

/* =====================================================
   2. FORMULÁRIO PRINCIPAL
   ===================================================== */

#form_ExpressProdutoForm {
    width: 100%;
    box-sizing: border-box;
    padding: 24px 28px 20px !important;
    background: var(--prod-bg) !important;
    color: var(--prod-text) !important;
    font-family: "Segoe UI", Arial, sans-serif !important;
    font-size: 13px !important;
}

/* Espaçamento entre linhas */
#form_ExpressProdutoForm .row {
    margin-bottom: 12px;
}

/* Grupos de campos */
#form_ExpressProdutoForm .form-group {
    margin-bottom: 14px !important;
}

/* =====================================================
   3. RÓTULOS
   ===================================================== */

#form_ExpressProdutoForm label,
#form_ExpressProdutoForm .control-label {
    display: inline-block;
    margin-bottom: 6px !important;
    color: #365879 !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.4;
}

/* =====================================================
   4. CAMPOS DE ENTRADA
   ===================================================== */

#form_ExpressProdutoForm input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
#form_ExpressProdutoForm select,
#form_ExpressProdutoForm textarea {
    min-height: 42px;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 12px !important;
    border: 1px solid #d6e2f0 !important;
    border-radius: 9px !important;
    background: #fff !important;
    color: #29415e !important;
    font-family: "Segoe UI", Arial, sans-serif !important;
    font-size: 13px !important;
    box-shadow: 0 1px 2px rgba(31, 59, 92, .035) !important;
    transition: border-color .18s ease,
                box-shadow .18s ease;
}

/* Descrição do produto */
#form_ExpressProdutoForm input[name="nomeproduto"] {
    min-height: 44px;
    font-size: 14px !important;
    font-weight: 500;
}

/* Valor de custo */
#form_ExpressProdutoForm input[name="valor_custo"] {
    font-size: 14px !important;
    font-weight: 600;
}

/* Quantidade */
#form_ExpressProdutoForm input[name="quantidade"] {
    font-size: 14px !important;
    font-weight: 600;
}

/* Texto de orientação */
#form_ExpressProdutoForm input::placeholder,
#form_ExpressProdutoForm textarea::placeholder {
    color: #9aaabe !important;
    opacity: 1;
}

/* Foco */
#form_ExpressProdutoForm input:focus,
#form_ExpressProdutoForm select:focus,
#form_ExpressProdutoForm textarea:focus {
    outline: none !important;
    border-color: #4387d3 !important;
    box-shadow: 0 0 0 3px rgba(33, 100, 181, .10) !important;
}

/* Data de entrada, somente leitura */
#form_ExpressProdutoForm input[readonly],
#form_ExpressProdutoForm input:disabled {
    background: #edf2f8 !important;
    color: #6c8099 !important;
    cursor: default;
}

/* =====================================================
   5. BOTÃO CADASTRAR
   ===================================================== */

#form_ExpressProdutoForm .btn {
    min-height: 40px;
    padding: 10px 17px !important;
    border-radius: 9px !important;
    font-family: "Segoe UI", Arial, sans-serif !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.3;
    box-shadow: none !important;
    transition: background-color .18s ease,
                border-color .18s ease,
                box-shadow .18s ease;
}

/* Botão principal */
#form_ExpressProdutoForm .btn-primary {
    color: #fff !important;
    background: var(--prod-blue) !important;
    border-color: var(--prod-blue) !important;
    box-shadow: 0 2px 5px rgba(33, 100, 181, .12) !important;
}

#form_ExpressProdutoForm .btn-primary:hover {
    background: var(--prod-blue-dark) !important;
    border-color: var(--prod-blue-dark) !important;
    box-shadow: 0 3px 8px rgba(33, 100, 181, .18) !important;
}

/* Ícone do botão Cadastrar */
#form_ExpressProdutoForm .btn-primary .fa,
#form_ExpressProdutoForm .btn-primary .fas,
#form_ExpressProdutoForm .btn-primary i {
    color: #fff !important;
    margin-right: 4px;
}

/* =====================================================
   6. BOTÃO LIMPAR FORMULÁRIO
   ===================================================== */

/* Botão secundário, visual discreto */
#form_ExpressProdutoForm .btn:not(.btn-primary) {
    color: #536b85 !important;
    background: #fff !important;
    border: 1px solid #dce6f2 !important;
    box-shadow: 0 1px 2px rgba(31, 59, 92, .035) !important;
}

#form_ExpressProdutoForm .btn:not(.btn-primary):hover {
    color: #29415e !important;
    background: #edf4fc !important;
    border-color: #b9cee5 !important;
}

/* Ícone de limpar com destaque vermelho discreto */
#form_ExpressProdutoForm .btn:not(.btn-primary) .fa-eraser,
#form_ExpressProdutoForm .btn:not(.btn-primary) .fas.fa-eraser {
    color: #d45a5a !important;
}

/* =====================================================
   7. ÁREA DE AÇÕES / RODAPÉ
   ===================================================== */

#form_ExpressProdutoForm .tformaction,
#form_ExpressProdutoForm .tformfooter,
#form_ExpressProdutoForm .form-actions,
#form_ExpressProdutoForm .card-footer {
    padding: 13px 16px !important;
    background: #edf2f9 !important;
    border: 0 !important;
    border-radius: 10px !important;
}

/* =====================================================
   8. RESPONSIVIDADE
   ===================================================== */

@media (max-width: 768px) {
    #form_ExpressProdutoForm {
        padding: 14px !important;
    }

    #form_ExpressProdutoForm .btn {
        margin-bottom: 5px;
    }

    #form_ExpressProdutoForm input:not([type="hidden"]),
    #form_ExpressProdutoForm select {
        max-width: 100%;
    }
}
