/* ----------- RESET E BASE ----------- */
body, html {
    max-width: 100%;
    overflow-x: hidden;
    font-size: 16px;
    font-family: Arial, sans-serif;
    background: #f9f9f9;
    margin: 0;
    padding: 0;
}

/* ----------- NAVBAR ----------- */
.navbar, .navbar-nav, .navbar-collapse {
    background-color: #004aad !important;
}

.navbar-nav .nav-link {
    color: #fff !important;
    font-weight: bold;
    font-size: 1.08em;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
    border-radius: 6px;
    display: flex;
    align-items: center;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s;
}
.navbar-nav .nav-link i {
    margin-right: 5px;
    font-size: 1.1em;
    opacity: 0.8;
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
    background: rgba(255,255,255,0.11) !important;
    color: #fff !important;
    text-decoration: none;
}
.navbar-brand {
    color: #fff !important;
    font-weight: bold;
    font-size: 1.5rem;
    letter-spacing: 0.5px;
    margin-right: 26px;
}
@media (max-width: 991.98px) {
    .navbar-brand {
        width: 100%;
        text-align: center;
        margin: 0 auto 8px auto;
        font-size: 1.3rem;
    }
    .navbar-nav.flex-row {
        flex-direction: column !important;
        gap: 0;
    }
    .navbar-nav .nav-link {
        justify-content: flex-start;
        padding-left: 20px !important;
    }
    .navbar .container {
        justify-content: center !important;
    }
}
.navbar-nav {
    gap: 10px !important;
}
.navbar-toggler {
    border-color: #fff;
}
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255,255,255,0.7)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: #004aad !important;
    }
}

/* ----------- LAYOUT E CONTAINERS ----------- */
.container {
    width: 90%;
    max-width: 960px;
    margin: 30px auto;
    padding: 0;
    box-sizing: border-box;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}
.card, .form-box, .login-box, .usuarios-box {
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.09);
    padding: 28px 25px;
    box-sizing: border-box;
    margin-bottom: 30px;
}
@media (max-width: 600px) {
    .container, .form-box, .card, .login-box, .usuarios-box {
        padding: 8px !important;
        margin: 8px auto !important;
        width: 100% !important;
        max-width: 100% !important;
    }
}

/* ----------- TÍTULOS ----------- */
h2 {
    margin-top: 0;
    color: #2070e0;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 700;
}

/* ----------- BOTÕES ----------- */
button,
input[type="submit"] {
    width: 100%;
    padding: 10px;
    background-color: #004aad;
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
button:hover,
input[type="submit"]:hover {
    background-color: #00388a;
}
.btn-menor {
    background-color: #dc3545;
}
.btn-menor:hover {
    background-color: #c82333;
}
.btn-maior {
    background-color: #28a745;
}
.btn-maior:hover {
    background-color: #218838;
}

/* ----------- INPUTS ----------- */
input[type="text"],
input[type="password"],
input[type="file"],
select, textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1em;
    box-sizing: border-box;
}
textarea { resize: vertical; }

/* ----------- ERROS ----------- */
.erro {
    color: red;
    font-weight: bold;
    text-align: center;
    margin-bottom: 15px;
}

/* ----------- PRODUTOS COM + E - ----------- */
#produtos ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.produto-item {
    padding: 16px 10px;
    border-bottom: 1px solid #ececec;
    background: none;
}
#produtos ul li.produto-item:last-child {
    border-bottom: none !important;
}

/* ALINHAMENTO E DISTRIBUIÇÃO */
.produto-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    /* Aumenta o espaço do nome */
}
.produto-nome {
    flex: 2.5 1 0;
    font-size: 1.13em;
    word-break: break-word;
    padding-right: 14px;
    min-width: 0;
    max-width: 70vw;
    line-height: 1.38;
}
.quantidade-box {
    display: flex;
    flex-direction: row;
    align-items: center;  /* Mantém tudo no meio na vertical */
    gap: 4px;
    min-width: 82px;
    max-width: 120px;
    margin-left: 10px;
    height: 38px; /* Deixa altura igual para todos */
}

/* BOTÕES DE QUANTIDADE REDUZIDOS */
.btn-quantidade {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    border: 1px solid #eee;
    font-size: 1.08em;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    background: #fff;
    font-weight: 700;
    transition: background 0.16s;
    margin: 0; /* Remove espaço extra */
}
.btn-quantidade.mais {
    background: #29c851;
    color: #fff;
    border-color: #29c851;
}
.btn-quantidade.mais:hover {
    background: #1ea63c;
}
.btn-quantidade.menos {
    background: #e74c3c;
    color: #fff;
    border-color: #e74c3c;
}
.btn-quantidade.menos:hover {
    background: #c0392b;
}
.quantidade-input {
    width: 38px !important;
    height: 34px !important;
    text-align: center;
    font-size: 1.10em;
    padding: 0;
    background: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-weight: bold;
    margin: 0 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    -moz-appearance: textfield;
}
.quantidade-input::-webkit-inner-spin-button,
.quantidade-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ----------- RESPONSIVIDADE ----------- */
@media (max-width: 900px) {
    .produto-nome { max-width: 63vw; }
}
@media (max-width: 700px) {
    .produto-nome { max-width: 56vw; }
    .quantidade-box { max-width: 90px; }
}
@media (max-width: 600px) {
    .produto-row {
        gap: 8px;
    }
    .produto-nome {
        font-size: 1em;
        max-width: 100vw;
        padding-right: 4px;
    }
    .quantidade-box {
        min-width: 74px;
        max-width: 90px;
        margin-left: 2px;
        height: 32px;
    }
    .btn-quantidade.quantidade-input {
        height: 28px !important;
        width: 28px !important;
        font-size: 0.98em;
    }
}
@media (max-width: 400px) {
    .produto-nome {
        font-size: 0.96em;
        max-width: 95vw;
    }
}

/* ----------- OUTROS ----------- */
.list-group-item {
    border-radius: 10px !important;
    margin-bottom: 8px !important;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
    border: 1px solid #e4e4e4 !important;
}

::-webkit-scrollbar-thumb { background: #c3d1e3; border-radius: 10px; }
::-webkit-scrollbar { width: 8px; background: #eee; }
::-webkit-input-placeholder { color: #888 !important; }
:-ms-input-placeholder { color: #888 !important; }
::placeholder { color: #888 !important; }

footer {
    background: #f9f9f9;
    color: #444;
    border-top: 1px solid #ececec;
    padding: 15px 0;
    font-size: 0.97em;
    text-align: center;
}
/* Produto selecionado visualmente */
.produto-item.selecionado {
    background: #e7fbe8 !important;
    transition: background 0.18s;
}

/* Mudancas visual */
.pedido-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.pedido-info {
    flex: 2;
    min-width: 340px;
    max-width: 800px;
    font-size: 1.13em;
    word-break: break-word;
}

.pedido-actions {
    flex: 0 0 110px;
    text-align: right;
    min-width: 90px;
}

@media (max-width: 800px) {
    .pedido-row {
        flex-direction: column;
        gap: 6px;
    }
    .pedido-info {
        width: 100% !important;
        min-width: 0 !important;
    }
    .pedido-actions {
        width: 100% !important;
        text-align: left;
        min-width: 0 !important;
        margin-top: 12px;
    }
}


/* Ajusta ações dos pedidos só para admin (botão apagar) */
.pedido-actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    min-width: 80px;
    margin-top: 6px;
    margin-bottom: 0;
    width: 100%;
    gap: 6px;
}

.pedido-actions .btn {
    width: auto;
    min-width: 90px;
    font-size: 0.99em;
    padding: 7px 18px;
}

/* No mobile, o botão ocupa 100% da largura só dentro do bloco de ações */
@media (max-width: 600px) {
    .pedido-actions {
        width: 100%;
        justify-content: flex-start;
        margin-top: 8px;
    }
    .pedido-actions .btn {
        width: 100%;
        min-width: 0;
        padding: 10px 0;
    }
}
/* Informações extras do produto, pequenas, alinhadas, discretas  ADD 19-05-25*/
.info-produto-extra {
    font-size: 11px;
    color: #888;
    margin-top: 1px;
    margin-bottom: -1px;
    letter-spacing: 0.01em;
    font-weight: 400;
    line-height: 1.20;
    display: block;
}

.info-produto-extra .info-data {
    color: #e05240;
    font-weight: 600;
}
.info-produto-extra .info-qtd {
    color: #c96e14;
    font-weight: 600;
}

/* ----------- RESET E BASE ----------- */
body, html {
    max-width: 100%;
    overflow-x: hidden;
    font-size: 16px;
    font-family: Arial, sans-serif;
    background: #f9f9f9;
    margin: 0;
    padding: 0;
}

/* ----------- NAVBAR ----------- */
.navbar, .navbar-nav, .navbar-collapse {
    background-color: #004aad !important;
}

.navbar-nav .nav-link {
    color: #fff !important;
    font-weight: bold;
    font-size: 1.08em;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
    border-radius: 6px;
    display: flex;
    align-items: center;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s;
}
.navbar-nav .nav-link i {
    margin-right: 5px;
    font-size: 1.1em;
    opacity: 0.8;
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
    background: rgba(255,255,255,0.11) !important;
    color: #fff !important;
    text-decoration: none;
}
.navbar-brand {
    color: #fff !important;
    font-weight: bold;
    font-size: 1.5rem;
    letter-spacing: 0.5px;
    margin-right: 26px;
}
@media (max-width: 991.98px) {
    .navbar-brand {
        width: 100%;
        text-align: center;
        margin: 0 auto 8px auto;
        font-size: 1.3rem;
    }
    .navbar-nav.flex-row {
        flex-direction: column !important;
        gap: 0;
    }
    .navbar-nav .nav-link {
        justify-content: flex-start;
        padding-left: 20px !important;
    }
    .navbar .container {
        justify-content: center !important;
    }
}
.navbar-nav {
    gap: 10px !important;
}
.navbar-toggler {
    border-color: #fff;
}
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255,255,255,0.7)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: #004aad !important;
    }
}

/* ----------- LAYOUT E CONTAINERS ----------- */
.container {
    width: 90%;
    max-width: 960px;
    margin: 30px auto;
    padding: 0;
    box-sizing: border-box;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}
.card, .form-box, .login-box, .usuarios-box {
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.09);
    padding: 28px 25px;
    box-sizing: border-box;
    margin-bottom: 30px;
}
@media (max-width: 600px) {
    .container, .form-box, .card, .login-box, .usuarios-box {
        padding: 8px !important;
        margin: 8px auto !important;
        width: 100% !important;
        max-width: 100% !important;
    }
}

/* ----------- TÍTULOS ----------- */
h2 {
    margin-top: 0;
    color: #2070e0;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 700;
}

/* ----------- BOTÕES ----------- */
button,
input[type="submit"] {
    width: 100%;
    padding: 10px;
    background-color: #004aad;
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
button:hover,
input[type="submit"]:hover {
    background-color: #00388a;
}
.btn-menor {
    background-color: #dc3545;
}
.btn-menor:hover {
    background-color: #c82333;
}
.btn-maior {
    background-color: #28a745;
}
.btn-maior:hover {
    background-color: #218838;
}

/* ----------- INPUTS ----------- */
input[type="text"],
input[type="password"],
input[type="file"],
select, textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1em;
    box-sizing: border-box;
}
textarea { resize: vertical; }

/* ----------- ERROS ----------- */
.erro {
    color: red;
    font-weight: bold;
    text-align: center;
    margin-bottom: 15px;
}

/* ----------- PRODUTOS COM + E - ----------- */
#produtos ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.produto-item {
    padding: 16px 10px;
    border-bottom: 1px solid #ececec;
    background: none;
}
#produtos ul li.produto-item:last-child {
    border-bottom: none !important;
}

/* ALINHAMENTO E DISTRIBUIÇÃO */
.produto-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    /* Aumenta o espaço do nome */
}
.produto-nome {
    flex: 2.5 1 0;
    font-size: 1.13em;
    word-break: break-word;
    padding-right: 14px;
    min-width: 0;
    max-width: 70vw;
    line-height: 1.38;
}
.quantidade-box {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 4px;
    min-width: 82px;
    max-width: 120px;
    margin-left: 10px;
    height: 38px;
}

.btn-quantidade {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    border: 1px solid #eee;
    font-size: 1.08em;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    background: #fff;
    font-weight: 700;
    transition: background 0.16s;
    margin: 0; /* Remove espaço extra */
}
.btn-quantidade.mais {
    background: #29c851;
    color: #fff;
    border-color: #29c851;
}
.btn-quantidade.mais:hover {
    background: #1ea63c;
}
.btn-quantidade.menos {
    background: #e74c3c;
    color: #fff;
    border-color: #e74c3c;
}
.btn-quantidade.menos:hover {
    background: #c0392b;
}
.quantidade-input {
    width: 38px !important;
    height: 34px !important;
    text-align: center;
    font-size: 1.10em;
    padding: 0;
    background: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-weight: bold;
    margin: 0 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    -moz-appearance: textfield;
}
.quantidade-input::-webkit-inner-spin-button,
.quantidade-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}



/* ----------- RESPONSIVIDADE ----------- */
@media (max-width: 900px) {
    .produto-nome { max-width: 63vw; }
}
@media (max-width: 700px) {
    .produto-nome { max-width: 56vw; }
    .quantidade-box { max-width: 90px; }
}
@media (max-width: 600px) {
    .produto-row {
        gap: 8px;
    }
    .produto-nome {
        font-size: 1em;
        max-width: 100vw;
        padding-right: 4px;
    }
    .quantidade-box {
        min-width: 74px;
        max-width: 80px;
        margin-left: 2px;
        height: 32px;
    }
    .btn-quantidade,
    .quantidade-input {
        height: 28px !important;
        width: 28px !important;
        font-size: 0.98em;
    }
}
@media (max-width: 400px) {
    .produto-nome {
        font-size: 0.96em;
        max-width: 95vw;
    }
}

/* ----------- OUTROS ----------- */
.list-group-item {
    border-radius: 10px !important;
    margin-bottom: 8px !important;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
    border: 1px solid #e4e4e4 !important;
}

::-webkit-scrollbar-thumb { background: #c3d1e3; border-radius: 10px; }
::-webkit-scrollbar { width: 8px; background: #eee; }
::-webkit-input-placeholder { color: #888 !important; }
:-ms-input-placeholder { color: #888 !important; }
::placeholder { color: #888 !important; }

footer {
    background: #f9f9f9;
    color: #444;
    border-top: 1px solid #ececec;
    padding: 15px 0;
    font-size: 0.97em;
    text-align: center;
}
/* Produto selecionado visualmente */
.produto-item.selecionado {
    background: #e7fbe8 !important;
    transition: background 0.18s;
}
.quantidade-box {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    min-width: 90px;
    max-width: 120px;
    margin-left: 10px;
    height: 40px;
}

.btn-quantidade {
    width: 38px !important;
    height: 38px !important;
    border-radius: 6px;
    border: 1px solid #eee;
    font-size: 1.17em;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    background: #fff;
    font-weight: 700;
    transition: background 0.16s;
    margin: 0;
}

.quantidade-input {
    width: 38px !important;
    height: 38px !important;
    text-align: center;
    font-size: 1.13em;
    padding: 0;
    background: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-weight: bold;
    margin: 0 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

@media (max-width: 600px) {
    .quantidade-box {
        min-width: 80px;
        max-width: 95px;
        margin-left: 2px;
        gap: 4px;
        height: 34px;
    }
    .btn-quantidade,
    .quantidade-input {
        height: 32px !important;
        width: 32px !important;
        font-size: 1em;
    }
}
.produto-item.selecionado {
    background: #e7fbe8 !important;
    transition: background 0.18s;
}
/* ----------- botoes da pagina notas.html ----------- */
.status-btn {
  padding: 5px 10px;
  margin: 2px;
  border: none;
  color: white;
  border-radius: 5px;
  cursor: pointer;
}

.status-nao_liberada {
  background-color: red;
}

.status-liberada {
  background-color: green;
}

.status-chegou {
  background-color: blue;
}

.btn-excluir {
  background-color: #888;
  color: white;
  border: none;
  padding: 5px 8px;
  border-radius: 5px;
  cursor: pointer;
}
.nota-box {
  background: #f9f9f9;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 2px 2px 4px rgba(0,0,0,0.05);
}

.badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: bold;
  color: white;
}

.badge-red { background-color: #d9534f; }
.badge-green { background-color: #5cb85c; }
.badge-blue { background-color: #0275d8; }

.btn-excluir {
  background-color: #6c757d;
  color: white;
  border: none;
  padding: 6px 10px;
  border-radius: 5px;
  margin-top: 10px;
  cursor: pointer;
}
.nota-info {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  font-size: 14px;
  margin-bottom: 10px;
}
.nota-info span {
  display: inline-block;
}
.badge-yellow {
  background-color: #f0ad4e;  /* tom de amarelo bootstrap */
  color: black;
}
.status-linha {
  display: block;
  width: 100%;
  margin-top: 5px;
}
