* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #f4f5f7;
    color: #161616;
}

a {
    text-decoration: none;
}

/* LOGIN */

.login-body {
    min-height: 100vh;
    background: linear-gradient(135deg, #120000, #310000, #000);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-container {
    width: 100%;
    max-width: 420px;
}

.login-card {
    background: #fff;
    border-radius: 26px;
    padding: 28px 22px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
}

.login-logo {
    text-align: center;
    margin-bottom: 25px;
}

.logo-circle {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d10000, #740000);
    color: #fff;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 24px;
    box-shadow: 0 10px 25px rgba(209,0,0,0.35);
}

.login-logo h1 {
    font-size: 26px;
    color: #111;
    margin-bottom: 5px;
}

.login-logo p {
    font-size: 14px;
    color: #666;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.login-form label {
    font-size: 14px;
    font-weight: 700;
    color: #333;
    margin-top: 8px;
}

.login-form input {
    width: 100%;
    height: 52px;
    border: 1px solid #ddd;
    border-radius: 14px;
    padding: 0 15px;
    font-size: 16px;
    outline: none;
    background: #f8f8f8;
}

.login-form input:focus {
    border-color: #c60000;
    background: #fff;
}

.login-form button {
    height: 54px;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, #d10000, #850000);
    color: #fff;
    font-size: 16px;
    font-weight: 800;
    margin-top: 15px;
    cursor: pointer;
}

.alert-error {
    background: #ffe8e8;
    color: #a40000;
    border: 1px solid #ffb8b8;
    padding: 12px;
    border-radius: 14px;
    font-size: 14px;
    margin-bottom: 15px;
    text-align: center;
}

.login-footer {
    margin-top: 22px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.login-footer span {
    font-weight: 800;
    color: #111;
}

.login-footer small {
    color: #777;
}

/* APP */

.app-body {
    padding-bottom: 80px;
    background: #f4f5f7;
}

.app-header {
    background: linear-gradient(135deg, #b90000, #5c0000);
    color: #fff;
    padding: 24px 18px 28px;
    border-radius: 0 0 26px 26px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.app-header span {
    font-size: 14px;
    opacity: 0.85;
}

.app-header h1 {
    font-size: 22px;
    margin: 4px 0;
}

.app-header p {
    font-size: 13px;
    opacity: 0.9;
}

.logout-btn {
    background: rgba(255,255,255,0.18);
    color: #fff;
    padding: 9px 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
}

.dashboard {
    padding: 18px;
}

.status-card {
    background: #fff;
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.06);
    margin-top: -35px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.status-card span {
    display: block;
    font-size: 13px;
    color: #777;
    margin-bottom: 4px;
}

.status-card strong {
    font-size: 20px;
    color: #111;
}

.status-dot {
    width: 16px;
    height: 16px;
    background: #00b84a;
    border-radius: 50%;
    box-shadow: 0 0 0 6px rgba(0,184,74,0.12);
}

.grid-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 18px;
}

.info-card {
    background: #fff;
    border-radius: 20px;
    padding: 16px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.05);
    min-height: 92px;
}

.info-card span {
    display: block;
    font-size: 13px;
    color: #777;
    margin-bottom: 8px;
}

.info-card strong {
    font-size: 19px;
    color: #111;
}

.quick-actions {
    margin-top: 24px;
}

.quick-actions h2 {
    font-size: 18px;
    margin-bottom: 14px;
}

.action-btn {
    display: block;
    background: #fff;
    color: #111;
    padding: 17px;
    border-radius: 18px;
    margin-bottom: 11px;
    font-weight: 800;
    box-shadow: 0 8px 22px rgba(0,0,0,0.05);
    border-left: 5px solid #b90000;
}

.action-btn.danger {
    border-left-color: #000;
    color: #b90000;
}

.bottom-menu {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    height: 62px;
    background: #111;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: space-around;
    box-shadow: 0 12px 30px rgba(0,0,0,0.25);
}

.bottom-menu a {
    color: #aaa;
    font-size: 12px;
    font-weight: 700;
}

.bottom-menu a.active {
    color: #fff;
}
.status-dot.closed {
    background: #b90000;
    box-shadow: 0 0 0 6px rgba(185,0,0,0.12);
}
.alert-success {
    background: #e7fff0;
    color: #007a32;
    border: 1px solid #a9efc2;
    padding: 12px;
    border-radius: 14px;
    font-size: 14px;
    margin-bottom: 15px;
    text-align: center;
    font-weight: 700;
}

.form-section {
    background: #fff;
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.06);
    margin-top: 22px;
}

.form-section h2 {
    font-size: 18px;
    margin-bottom: 16px;
}

.app-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.app-form label {
    font-size: 14px;
    font-weight: 800;
    color: #333;
    margin-top: 8px;
}

.app-form input,
.app-form select,
.app-form textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 14px;
    padding: 14px;
    font-size: 16px;
    background: #f8f8f8;
    outline: none;
    font-family: Arial, Helvetica, sans-serif;
}

.app-form textarea {
    min-height: 90px;
    resize: vertical;
}

.app-form input:focus,
.app-form select:focus,
.app-form textarea:focus {
    border-color: #b90000;
    background: #fff;
}

.app-form button {
    height: 54px;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, #d10000, #850000);
    color: #fff;
    font-size: 16px;
    font-weight: 800;
    margin-top: 14px;
    cursor: pointer;
}

.danger-btn {
    background: linear-gradient(135deg, #111, #000) !important;
}
.list-section {
    margin-top: 24px;
}

.list-section h2 {
    font-size: 18px;
    margin-bottom: 14px;
}

.empty-card {
    background: #fff;
    border-radius: 18px;
    padding: 18px;
    color: #777;
    text-align: center;
    box-shadow: 0 8px 22px rgba(0,0,0,0.05);
}

.product-card {
    background: #fff;
    border-radius: 22px;
    padding: 16px;
    margin-bottom: 13px;
    box-shadow: 0 8px 22px rgba(0,0,0,0.05);
}

.product-top {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.product-top strong {
    display: block;
    font-size: 15px;
    color: #111;
    margin-bottom: 4px;
}

.product-top span {
    display: block;
    font-size: 12px;
    color: #777;
}

.product-top small {
    font-size: 11px;
    color: #999;
    font-weight: 800;
}

.product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.product-tags span {
    background: #f2f2f2;
    color: #333;
    border-radius: 999px;
    padding: 6px 9px;
    font-size: 11px;
    font-weight: 700;
}

.price-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    background: #f8f8f8;
    border-radius: 16px;
    overflow: hidden;
}

.price-row div {
    padding: 10px 6px;
    text-align: center;
    border-right: 1px solid #e5e5e5;
}

.price-row div:last-child {
    border-right: none;
}

.price-row small {
    display: block;
    font-size: 10px;
    color: #777;
    margin-bottom: 3px;
}

.price-row b {
    font-size: 12px;
    color: #111;
}
.card-note {
    background: #f8f8f8;
    border-radius: 12px;
    padding: 10px;
    color: #555;
    font-size: 13px;
    margin-bottom: 10px;
    line-height: 1.4;
}

.card-date {
    display: block;
    font-size: 11px;
    color: #999;
    font-weight: 700;
}

.search-form button {
    margin-top: 4px;
}

.clear-search {
    display: block;
    text-align: center;
    background: #f1f1f1;
    color: #333;
    padding: 13px;
    border-radius: 14px;
    font-weight: 800;
    font-size: 14px;
}

.estoque-actions {
    margin-top: 18px;
}

.estoque-card {
    border-left: 5px solid #00a846;
}

.estoque-card.baixo {
    border-left-color: #e6a100;
}

.estoque-card.zerado {
    border-left-color: #b90000;
}

.stock-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1.3fr;
    background: #f8f8f8;
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 12px;
}

.stock-row div {
    padding: 10px 6px;
    text-align: center;
    border-right: 1px solid #e5e5e5;
}

.stock-row div:last-child {
    border-right: none;
}

.stock-row small {
    display: block;
    font-size: 10px;
    color: #777;
    margin-bottom: 3px;
}

.stock-row b {
    font-size: 13px;
    color: #111;
}

.stock-status.ok {
    color: #008f3a;
}

.stock-status.baixo {
    color: #c48600;
}

.stock-status.zerado {
    color: #b90000;
}

.estoque-price {
    margin-bottom: 12px;
}

.mini-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.mini-actions a {
    display: block;
    background: #111;
    color: #fff;
    text-align: center;
    padding: 12px;
    border-radius: 14px;
    font-size: 13px;
    font-weight: 800;
}

.mini-actions a:first-child {
    background: #b90000;
}
.sale-preview,
.sale-total {
    background: #111;
    color: #fff;
    border-radius: 18px;
    padding: 16px;
    margin: 10px 0;
}

.sale-preview span,
.sale-total span {
    display: block;
    font-size: 13px;
    color: #ccc;
    margin-bottom: 5px;
}

.sale-preview strong,
.sale-total strong {
    display: block;
    font-size: 24px;
    color: #fff;
    margin-bottom: 4px;
}

.sale-preview small {
    color: #aaa;
    font-size: 12px;
}
.cart-box {
    background: #f8f8f8;
    border-radius: 18px;
    padding: 14px;
    margin-top: 14px;
}

.cart-box h3 {
    font-size: 16px;
    margin-bottom: 12px;
}

.empty-cart {
    color: #777;
    font-size: 14px;
    text-align: center;
    padding: 12px;
}

.cart-item {
    background: #fff;
    border-radius: 16px;
    padding: 12px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    box-shadow: 0 5px 14px rgba(0,0,0,0.04);
}

.cart-item strong {
    display: block;
    font-size: 14px;
    color: #111;
    margin-bottom: 4px;
}

.cart-item span {
    font-size: 12px;
    color: #666;
}

.cart-item b {
    display: block;
    font-size: 13px;
    color: #111;
    margin-bottom: 6px;
    text-align: right;
}

.cart-item button {
    border: none;
    background: #b90000;
    color: #fff;
    padding: 7px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 800;
}