:root {
    --nexa-navy: #071827;
    --nexa-blue: #08aeea;
    --nexa-green: #22c55e;
    --nexa-orange: #ff7a1a;
}

body { font-family: Inter, system-ui, -apple-system, sans-serif; }
.app-sidebar { background: linear-gradient(180deg, #061725 0%, #0b2337 100%); }
.brand-link { min-height: 74px; border-bottom: 1px solid rgba(255,255,255,.1); }
.brand-symbol {
    display: inline-grid; width: 42px; height: 42px; place-items: center;
    border-radius: 12px; color: white; font-size: 21px; font-weight: 900;
    background: linear-gradient(135deg, var(--nexa-blue), #35d0ad 65%, var(--nexa-orange));
}
.brand-text strong { color: #fff; letter-spacing: .03em; }
.brand-text span { color: var(--nexa-blue); }
.brand-text small { display: block; color: #b8c8d7; font-size: .62rem; letter-spacing: .25em; }
.sidebar-menu .nav-link.active { background: rgba(8,174,234,.18); color: #fff; }
.sidebar-menu .nav-link.active::before {
    content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 3px;
    border-radius: 0 4px 4px 0; background: var(--nexa-blue);
}
.sidebar-menu .nav-link { position: relative; margin: 2px 10px; border-radius: 8px; }
.app-main { background: #f4f7fb; }
.page-title { color: #10233f; font-weight: 800; letter-spacing: -.025em; }
.card { border: 0; border-radius: 14px; box-shadow: 0 5px 20px rgba(21,52,87,.07); }
.card-header { border-bottom-color: #e9eef5; background: #fff; }
.btn-primary { border-color: #1273ea; background: #1273ea; }
.btn-primary:hover { border-color: #0c61ca; background: #0c61ca; }
.stat-card { min-height: 128px; overflow: hidden; }
.stat-card .icon { opacity: .14; }
.table thead th { color: #526476; font-size: .75rem; letter-spacing: .04em; text-transform: uppercase; }
.table td { vertical-align: middle; }
.form-label { color: #31455a; font-size: .83rem; font-weight: 700; }
.required::after { content: " *"; color: #dc3545; }
.money { font-variant-numeric: tabular-nums; }
.line-items-table input, .line-items-table select { min-width: 120px; }
.line-items-table .product-name { min-width: 250px; }
.product-thumb {
    display: inline-grid; width: 48px; height: 48px; flex: 0 0 48px;
    place-items: center; border: 1px solid #e3eaf2; border-radius: 9px;
    background: #f7f9fc; object-fit: contain;
}
.product-thumb-empty { color: #94a3b8; font-size: 1.2rem; }
.login-page {
    min-height: 100vh; background:
        radial-gradient(circle at 80% 15%, rgba(8,174,234,.18), transparent 32%),
        linear-gradient(135deg, #061421 0%, #0a253a 100%);
}
.login-box { width: min(430px, calc(100% - 30px)); }
.login-card { border-radius: 20px; box-shadow: 0 24px 65px rgba(0,0,0,.3); }
.login-logo-block { text-align: center; }
.login-logo-block .brand-symbol { width: 58px; height: 58px; margin-bottom: 12px; font-size: 28px; }
.login-logo-block h1 { margin: 0; color: #10233f; font-size: 1.65rem; font-weight: 900; }
.login-logo-block p { margin: 5px 0 0; color: #718096; }
@media (max-width: 767.98px) {
    .content-header .d-flex { align-items: flex-start !important; flex-direction: column; gap: 12px; }
    .table-responsive { border-radius: 10px; }
}
.global-product-search { width: clamp(180px, 24vw, 340px); }
.metric-card {
    height: 100%; padding: 20px; border: 1px solid #e5edf6; border-radius: 14px;
    background: linear-gradient(145deg, #fff, #f7faff); box-shadow: 0 5px 20px rgba(21,52,87,.06);
}
.metric-card small { display: block; color: #66788a; font-weight: 600; }
.metric-card strong { display: block; margin: 7px 0 4px; color: #10233f; font-size: clamp(1.3rem, 2vw, 1.8rem); }
.metric-card span { color: #8796a6; font-size: .78rem; }
.metric-card.metric-profit { border-left: 4px solid #22c55e; }
.metric-card.metric-alert { border-left: 4px solid #ef4444; }
.operation-card { height: 100%; padding: 16px; border: 1px solid #e3eaf2; border-radius: 12px; background: #fff; }
.operation-card .progress { height: 7px; background: #edf2f7; }
.alert-dot { width: 10px; height: 10px; flex: 0 0 auto; border-radius: 50%; background: #ef4444; box-shadow: 0 0 0 5px rgba(239,68,68,.12); }
.abc-badge { display: inline-grid; width: 34px; height: 34px; place-items: center; border-radius: 9px; font-weight: 800; }
.abc-a { color: #087443; background: #d9fbe9; }
.abc-b { color: #8a5b00; background: #fff1c2; }
.abc-c { color: #526171; background: #e8edf2; }
.simulator-results { top: 16px; }
.sim-result { display: flex; justify-content: space-between; gap: 20px; padding: 11px 0; border-bottom: 1px solid #edf1f5; }
.sim-result span { color: #66788a; }
.sim-result strong { text-align: right; color: #10233f; }
.sim-result.sim-highlight { margin: 4px -12px; padding: 13px 12px; border: 0; border-radius: 10px; background: #eef7ff; }
.sim-market { padding: 14px; border-radius: 10px; font-weight: 700; }
.sim-market.neutral { color: #526171; background: #edf2f7; }
.sim-market.positive { color: #087443; background: #d9fbe9; }
.sim-market.negative { color: #b42318; background: #fee4e2; }
@media (max-width: 575.98px) {
    .global-product-search { width: 150px; }
    .global-product-search input::placeholder { color: transparent; }
}
