/* ============================================
   Sistema OS - Modern Dashboard Theme
   ============================================ */

:root {
    --primary: #4f46e5;
    --primary-light: #6366f1;
    --primary-dark: #4338ca;
    --secondary: #0ea5e9;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #06b6d4;
    --dark: #1e293b;
    --darker: #0f172a;
    --light: #f1f5f9;
    --body-bg: #f8fafc;
    --card-bg: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --radius: 0.75rem;
    --transition: all 0.2s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--body-bg);
    color: var(--text-primary);
    min-height: 100vh;
}

/* Área do Cliente (portal) — fundo com leve tom azul pra nunca confundir
   com o painel do administrador (fundo neutro cinza-claro padrão). */
body.portal-body {
    background: #eef4fc;
}
body.portal-body .navbar-app {
    background: #f5f9ff;
    border-bottom-color: #cfe0f7;
}

/* ============================================
   Painel Administrativo — tema escuro
   (contraste forte com o portal do cliente, claro/azulado, pra nunca
   confundir qual área está aberta)
   ============================================ */
body.admin-body {
    --body-bg: #0f172a;
    --card-bg: #1e293b;
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --border-color: #334155;
    /* O Bootstrap usa as próprias variáveis (--bs-*) pra cor/fundo de vários
       componentes prontos (card, table, dropdown-menu, modal, form-control) —
       sobrescrever só --body-bg/--card-bg acima não alcança esses componentes,
       então alinhamos as variáveis do Bootstrap à mesma paleta aqui. */
    --bs-body-bg: #0f172a;
    --bs-body-color: #e2e8f0;
    --bs-card-bg: #1e293b;
    --bs-card-cap-bg: transparent;
    --bs-border-color: #334155;
    --bs-border-color-translucent: rgba(255,255,255,0.08);
    --bs-emphasis-color: #f1f5f9;
    --bs-secondary-color: #94a3b8;
    --bs-secondary-bg: #1e293b;
    --bs-tertiary-color: #94a3b8;
    --bs-tertiary-bg: #16233a;
}

body.admin-body .navbar-app {
    background: #1e293b;
    border-bottom-color: #334155;
}

body.admin-body .navbar-app .dropdown-item:hover,
body.admin-body .navbar-app .dropdown-item.active {
    background: #334155;
    color: #a5b4fc;
}
body.admin-body .navbar-app .dropdown-item:hover i,
body.admin-body .navbar-app .dropdown-item.active i {
    color: #a5b4fc;
}

@media (max-width: 991.98px) {
    body.admin-body .navbar-app .nav-link.active {
        background: #334155;
    }
}

body.admin-body .dropdown-menu {
    background-color: #1e293b;
    border-color: #334155;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
}
body.admin-body .dropdown-item {
    color: var(--text-primary);
}
body.admin-body .dropdown-item:hover,
body.admin-body .dropdown-item:focus {
    background-color: #334155;
    color: #fff;
}
body.admin-body .dropdown-divider {
    border-color: #334155;
}

body.admin-body .table thead th {
    background: #16233a;
    color: #94a3b8;
    border-bottom-color: #334155;
}
body.admin-body .table tbody td {
    border-bottom-color: #263449;
}
body.admin-body .table tbody tr:hover {
    background: #263449;
}

body.admin-body .form-control,
body.admin-body .form-select {
    background-color: #16233a;
    border-color: #334155;
    color: var(--text-primary);
}
body.admin-body .form-control::placeholder {
    color: #64748b;
}
body.admin-body .form-control:focus,
body.admin-body .form-select:focus {
    background-color: #16233a;
    color: var(--text-primary);
}
body.admin-body .form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
}
body.admin-body .input-group-text {
    background-color: #16233a;
    border-color: #334155;
    color: var(--text-secondary);
}

body.admin-body .modal-content {
    background-color: #1e293b;
    color: var(--text-primary);
}
body.admin-body .modal-header,
body.admin-body .modal-footer {
    border-color: #334155;
}
body.admin-body .btn-close {
    filter: invert(1) grayscale(100%);
}

body.admin-body .text-muted {
    color: #94a3b8 !important;
}

/* .text-dark é usado em duas situações: (a) texto puro sobre o card claro
   original — precisa virar claro no tema escuro; (b) dentro de badges com
   fundo pastel (bg-warning/bg-light/bg-info) — precisa continuar escuro pro
   contraste com o próprio fundo do badge, que não muda de cor no tema
   escuro. O :not(.badge) cobre exatamente o caso (a) sem quebrar o (b). */
body.admin-body .text-dark:not(.badge) {
    color: var(--text-primary) !important;
}

body.admin-body ::-webkit-scrollbar-track { background: #0f172a; }

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #94a3b8; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #64748b; }

/* ---- Navbar ---- */
.navbar-app {
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    padding: 0.6rem 1.5rem;
    box-shadow: var(--shadow-sm);
    z-index: 1030;
}

.navbar-app .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.navbar-app .brand-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    flex-shrink: 0;
}

.navbar-app .brand-logo-img {
    max-height: 36px;
    max-width: 140px;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.navbar-app .nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.5rem 0.85rem !important;
    border-bottom: 2px solid transparent;
    transition: var(--transition);
}

.navbar-app .nav-link:hover {
    color: var(--primary);
}

.navbar-app .nav-link.active,
.navbar-app .nav-link.show {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.navbar-app .nav-link.dropdown-toggle::after {
    margin-left: 0.35rem;
    vertical-align: 0.1em;
}

.navbar-app .dropdown-menu {
    border: 1px solid var(--border-color);
    border-radius: 0.6rem;
    box-shadow: var(--shadow-lg);
    padding: 0.4rem;
    margin-top: 0.5rem;
}

.navbar-app .dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    border-radius: 0.4rem;
    padding: 0.5rem 0.75rem;
}

.navbar-app .dropdown-item i {
    width: 18px;
    text-align: center;
    color: var(--text-secondary);
}

.navbar-app .dropdown-item:hover {
    background: #eef2ff;
    color: var(--primary);
}

.navbar-app .dropdown-item:hover i {
    color: var(--primary);
}

.navbar-app .dropdown-item.active {
    background: #eef2ff;
    color: var(--primary);
    font-weight: 600;
}

.navbar-app .dropdown-item.active i {
    color: var(--primary);
}

.navbar-app .user-avatar-sm {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.78rem;
    flex-shrink: 0;
}

.navbar-app .navbar-toggler {
    border: none;
    padding: 0.35rem 0.5rem;
}

.navbar-app .navbar-toggler:focus {
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

/* ---- Main Content ---- */
.main-content {
    min-height: 100vh;
}

/* ---- Top Bar (título da página + ações) ---- */
.topbar {
    background: transparent;
    padding: 1.25rem 1.5rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.topbar .page-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
}

/* Menu colapsado (mobile/tablet) */
@media (max-width: 991.98px) {
    .navbar-app .navbar-collapse {
        margin-top: 0.75rem;
        border-top: 1px solid var(--border-color);
        padding-top: 0.5rem;
    }
    .navbar-app .nav-link {
        border-bottom: none !important;
        border-radius: 0.5rem;
    }
    .navbar-app .nav-link.active {
        background: #eef2ff;
    }
    .navbar-app .navbar-nav {
        gap: 0.15rem;
    }
}

/* ---- Content Area ---- */
.content-area {
    padding: 1.5rem;
}

/* PDV em tela cheia — sem margem/moldura clara ao redor do terminal escuro */
body.pdv-fullscreen-body {
    background: #0b1f3a;
}

.content-area-flush {
    padding: 0;
}

.content-area-flush .pdv-terminal {
    margin-bottom: 0;
    border-radius: 0;
    min-height: 100vh;
}

/* ---- Cards ---- */
.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow);
}

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
    font-weight: 600;
}

/* ---- Stat Cards (tiles) ---- */
/* Data/color stays in the small icon chip + left accent; the card itself is a
   quiet white surface — a large saturated block is louder than the number it holds. */
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-left: 3px solid transparent;
    border-radius: var(--radius);
    padding: 1.1rem 1.25rem;
    box-shadow: var(--shadow-sm);
    color: var(--text-primary);
    transition: var(--transition);
}

.stat-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-1px);
}

.stat-card .stat-icon {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}

.stat-card .stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.3rem;
    font-variant-numeric: proportional-nums;
}

.stat-card .stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.stat-primary { border-left-color: var(--primary); }
.stat-primary .stat-icon { background: #eef2ff; color: #4338ca; }

.stat-success { border-left-color: #10b981; }
.stat-success .stat-icon { background: #dcfce7; color: #15803d; }

.stat-warning { border-left-color: #f59e0b; }
.stat-warning .stat-icon { background: #fef3c7; color: #b45309; }

.stat-danger { border-left-color: #ef4444; }
.stat-danger .stat-icon { background: #fee2e2; color: #b91c1c; }

.stat-info { border-left-color: #06b6d4; }
.stat-info .stat-icon { background: #cffafe; color: #0e7490; }

.stat-dark { border-left-color: #475569; }
.stat-dark .stat-icon { background: #e2e8f0; color: #1e293b; }

/* ---- Tables ---- */
.table-container {
    background: var(--card-bg);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.table {
    margin: 0;
    font-size: 0.875rem;
}

.table thead th {
    background: #f8fafc;
    border-bottom: 2px solid var(--border-color);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
    white-space: nowrap;
}

.table tbody td {
    padding: 0.75rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #f1f5f9;
}

.table tbody tr:hover {
    background: #f8fafc;
}

.table tbody tr:last-child td {
    border-bottom: none;
}

/* ---- Badges (estilo "tag" suave, tonalizado) ---- */
.badge {
    font-weight: 600;
    font-size: 0.7rem;
    padding: 0.4em 0.8em;
    border-radius: 999px;
    letter-spacing: 0.01em;
}

.badge.bg-primary   { background: #eef2ff !important; color: #4338ca; }
.badge.bg-secondary { background: #f1f5f9 !important; color: #475569; }
.badge.bg-success   { background: #dcfce7 !important; color: #15803d; }
.badge.bg-danger    { background: #fee2e2 !important; color: #b91c1c; }
.badge.bg-warning   { background: #fef3c7 !important; color: #b45309; }
.badge.bg-info      { background: #cffafe !important; color: #0e7490; }
.badge.bg-dark      { background: #e2e8f0 !important; color: #1e293b; }
.badge.bg-light     { background: #f8fafc !important; color: #475569; border: 1px solid var(--border-color); }

.bg-purple {
    background-color: #7c3aed !important;
    color: #fff;
}

/* ---- Buttons ---- */
.btn {
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

.btn-sm {
    padding: 0.3rem 0.6rem;
    font-size: 0.78rem;
    border-radius: 6px;
}

.btn-action {
    width: 32px;
    height: 32px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: none;
    font-size: 0.85rem;
    transition: var(--transition);
}

.btn-action:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-action.btn-view   { background: #eff6ff; color: #3b82f6; }
.btn-action.btn-edit   { background: #fef3c7; color: #d97706; }
.btn-action.btn-delete { background: #fee2e2; color: #ef4444; }
.btn-action.btn-download { background: #ecfdf5; color: #059669; }
.btn-action.btn-pago     { background: #eef2ff; color: #6366f1; }

.btn-action.btn-view:hover   { background: #3b82f6; color: #fff; }
.btn-action.btn-edit:hover   { background: #d97706; color: #fff; }
.btn-action.btn-delete:hover { background: #ef4444; color: #fff; }
.btn-action.btn-download:hover { background: #059669; color: #fff; }
.btn-action.btn-pago:hover     { background: #6366f1; color: #fff; }

/* ---- Forms ---- */
.form-control, .form-select {
    border-radius: 8px;
    border: 1.5px solid var(--border-color);
    padding: 0.55rem 0.85rem;
    font-size: 0.875rem;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.form-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.35rem;
}

/* ---- Login Page ---- */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    position: relative;
    overflow: hidden;
}

.login-page::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(79,70,229,0.15) 0%, transparent 70%);
    top: -100px;
    right: -100px;
}

.login-page::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(14,165,233,0.1) 0%, transparent 70%);
    bottom: -100px;
    left: -100px;
}

.login-card {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
    position: relative;
    z-index: 1;
}

.login-card .login-logo {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fff;
    margin: 0 auto 1.25rem;
}

.login-card h4 {
    text-align: center;
    font-weight: 800;
    margin-bottom: 0.25rem;
    color: var(--dark);
}

.login-card .login-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 2rem;
}

/* ---- Filter Bar ---- */
.filter-bar {
    background: var(--card-bg);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-sm);
}

/* ---- Empty State ---- */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.empty-state p {
    font-size: 0.9rem;
}

/* ---- Alert ---- */
.alert {
    border-radius: var(--radius);
    border: none;
    font-size: 0.85rem;
    font-weight: 500;
}

/* ---- Responsive ---- */
@media (max-width: 575.98px) {
    .content-area {
        padding: 1rem;
    }
    .stat-card .stat-value {
        font-size: 1.35rem;
    }
}

/* ---- Animations ---- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

/* ---- Chart Container ---- */
.chart-container {
    position: relative;
    height: 300px;
    width: 100%;
}

/* ---- Logo Preview ---- */
.logo-preview {
    max-width: 200px;
    max-height: 100px;
    object-fit: contain;
    border-radius: 8px;
    border: 2px dashed var(--border-color);
    padding: 0.5rem;
}

/* ---- Action Buttons Group ---- */
.action-buttons {
    display: flex;
    gap: 0.35rem;
    flex-wrap: nowrap;
}

/* ---- Input Group Custom ---- */
.input-group .btn-outline-primary {
    border: 1.5px solid var(--border-color);
    color: var(--primary);
}

.input-group .btn-outline-primary:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.input-group .form-select {
    border-right: none;
}

.input-group .btn-outline-primary {
    border-left: none;
}

/* ============================================
   PDV - Terminal estilo caixa registradora
   ============================================ */
.pdv-terminal {
    background: #0b1f3a;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    color: #e2e8f0;
}

.pdv-header {
    background: linear-gradient(90deg, #0f2f57, #123a6b);
    padding: 14px 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.pdv-header-left {
    font-weight: 700;
    letter-spacing: 0.03em;
    font-size: 0.95rem;
}

.pdv-header-left i {
    margin-right: 8px;
    color: #38bdf8;
}

.pdv-header-links {
    display: flex;
    gap: 16px;
}

.pdv-header-links a {
    color: #94a3b8;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.pdv-header-links a:hover {
    color: #f8fafc;
}

.pdv-header-clock {
    text-align: right;
}

.pdv-clock-time {
    font-size: 1.4rem;
    font-weight: 800;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.pdv-clock-date {
    font-size: 0.75rem;
    color: #94a3b8;
    text-transform: capitalize;
}

.pdv-body {
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 18px;
    padding: 20px 22px;
}

.pdv-entry-row {
    display: flex;
    gap: 14px;
}

.pdv-qtd-box {
    width: 110px;
}

.pdv-desc-box {
    flex: 1;
    position: relative;
}

.pdv-qtd-box label,
.pdv-desc-box label,
.pdv-field-label,
.pdv-field label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 4px;
}

.pdv-qtd-box input,
.pdv-desc-box input,
.pdv-field-input {
    width: 100%;
    background: #10294a;
    border: 1.5px solid rgba(255,255,255,0.12);
    color: #f8fafc;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 1.05rem;
    font-weight: 600;
    outline: none;
    transition: var(--transition);
}

.pdv-qtd-box input:focus,
.pdv-desc-box input:focus,
.pdv-field-input:focus {
    border-color: #38bdf8;
    box-shadow: 0 0 0 3px rgba(56,189,248,0.2);
}

.pdv-suggest-list {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #10294a;
    border: 1.5px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    z-index: 20;
    overflow: hidden;
    max-height: 280px;
    overflow-y: auto;
}

.pdv-suggest-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.pdv-suggest-item:last-child {
    border-bottom: none;
}

.pdv-suggest-item:hover,
.pdv-suggest-item.pdv-suggest-active {
    background: #16345c;
}

.pdv-suggest-nome {
    color: #f1f5f9;
    font-weight: 600;
    font-size: 0.92rem;
}

.pdv-suggest-preco {
    color: #34d399;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.pdv-cart-area {
    margin-top: 16px;
    background: #0f2745;
    border-radius: 10px;
    min-height: 160px;
    border: 1px solid rgba(255,255,255,0.06);
}

.pdv-cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 40px 20px;
    color: #64748b;
    text-align: center;
}

.pdv-cart-empty i {
    font-size: 2rem;
    opacity: 0.5;
}

.pdv-cart-empty strong {
    color: #cbd5e1;
    font-size: 1rem;
}

.pdv-cart-empty span {
    font-size: 0.8rem;
}

.pdv-cart-table {
    color: #e2e8f0;
    margin: 0;
}

.pdv-cart-table thead th {
    color: #94a3b8;
    font-size: 0.7rem;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    background: transparent;
}

.pdv-cart-table td {
    border-color: rgba(255,255,255,0.06);
    vertical-align: middle;
}

.pdv-cart-table input {
    background: #0b1f3a;
    border: 1px solid rgba(255,255,255,0.15);
    color: #f8fafc;
}

.pdv-qtd-stepper {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pdv-qtd-btn {
    width: 26px;
    height: 26px;
    flex: none;
    border: 1px solid rgba(255,255,255,0.15);
    background: #16345c;
    color: #f8fafc;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: var(--transition);
}

.pdv-qtd-btn:hover {
    background: #1d4a80;
}

.pdv-qtd-cart-input {
    width: 46px;
    text-align: center;
    background: #0b1f3a;
    border: 1px solid rgba(255,255,255,0.15);
    color: #f8fafc;
    border-radius: 6px;
    padding: 4px 2px;
    font-weight: 700;
}

.pdv-cart-item-total {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.pdv-side {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pdv-logo-box {
    background: #ffffff;
    border-radius: 10px;
    padding: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 90px;
}

.pdv-logo-box img {
    max-width: 100%;
    max-height: 70px;
    object-fit: contain;
}

.pdv-logo-placeholder {
    color: var(--primary);
    font-weight: 800;
    text-align: center;
    font-size: 0.95rem;
}

.pdv-total-box {
    background: linear-gradient(135deg, #059669, #10b981);
    border-radius: 10px;
    padding: 18px;
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.pdv-total-box span {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255,255,255,0.85);
}

.pdv-total-box strong {
    font-size: 2rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
}

.pdv-payment-row {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    padding: 0 22px 18px;
}

.pdv-field {
    flex: 1;
    min-width: 160px;
}

.pdv-troco-display {
    background: #10294a;
    border: 1.5px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    padding: 10px 12px;
    font-weight: 700;
    font-size: 1.05rem;
    color: #34d399;
    font-variant-numeric: tabular-nums;
}

.pdv-troco-display.pdv-troco-negativo {
    color: #f87171;
}

.pdv-bottom-row {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 14px;
    padding: 0 22px 20px;
    align-items: stretch;
}

.pdv-panel {
    background: #0f2745;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    padding: 12px 16px;
}

.pdv-panel-title {
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    color: #94a3b8;
    margin-bottom: 8px;
}

.pdv-shortcuts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 12px;
    font-size: 0.82rem;
    color: #cbd5e1;
}

.pdv-shortcuts-grid b {
    color: #38bdf8;
    margin-right: 4px;
}

.pdv-info-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 0.88rem;
}

.pdv-info-row span {
    color: #94a3b8;
}

.pdv-actions-box {
    display: flex;
    flex-direction: column;
    gap: 8px;
    justify-content: center;
    min-width: 190px;
}

.pdv-btn {
    border: none;
    border-radius: 8px;
    padding: 10px 14px;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.pdv-btn-secondary { background: #334155; color: #e2e8f0; }
.pdv-btn-secondary:hover { background: #475569; }
.pdv-btn-danger { background: #7f1d1d; color: #fecaca; }
.pdv-btn-danger:hover { background: #991b1b; }
.pdv-btn-success { background: linear-gradient(135deg, #059669, #10b981); color: #fff; }
.pdv-btn-success:hover { filter: brightness(1.08); }

.pdv-btn-lg {
    padding: 16px 32px;
    font-size: 1.05rem;
}

.pdv-idle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 70px 20px;
    text-align: center;
}

.pdv-idle i {
    font-size: 3rem;
    color: #38bdf8;
    opacity: 0.7;
    margin-bottom: 6px;
}

.pdv-idle h3 {
    color: #f1f5f9;
    font-size: 1.3rem;
    font-weight: 700;
    margin: 0;
}

.pdv-idle p {
    color: #94a3b8;
    font-size: 0.9rem;
    margin: 0 0 10px;
}

.pdv-idle kbd {
    background: #16345c;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    padding: 2px 7px;
    font-size: 0.82rem;
    color: #f8fafc;
}

.pdv-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(3, 10, 22, 0.72);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    padding: 20px;
}

.pdv-modal {
    background: #0f2745;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 12px;
    padding: 26px 28px;
    max-width: 420px;
    width: 100%;
    box-shadow: var(--shadow-lg);
    color: #e2e8f0;
}

.pdv-modal h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 10px;
    color: #f8fafc;
}

.pdv-modal h3 i {
    color: #38bdf8;
    margin-right: 8px;
}

.pdv-modal p {
    color: #94a3b8;
    font-size: 0.88rem;
    margin: 0 0 16px;
}

.pdv-modal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.pdv-modal-actions .pdv-btn {
    flex: 1;
    min-width: 120px;
}

.pdv-footer-bar {
    background: #081627;
    padding: 8px 22px;
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    color: #64748b;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.pdv-caixa-bar {
    display: flex;
    align-items: center;
    gap: 26px;
    padding: 12px 22px;
    background: #0f2745;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    flex-wrap: wrap;
}

.pdv-caixa-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pdv-caixa-item span {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
}

.pdv-caixa-item strong {
    font-size: 0.92rem;
    color: #f1f5f9;
}

.pdv-caixa-bar .pdv-btn {
    margin-left: auto;
}

.pdv-btn-sm {
    padding: 7px 14px;
    font-size: 0.78rem;
    flex: none;
}

.pdv-abrircaixa-box,
.pdv-fecharcaixa-box {
    padding: 20px 22px;
    background: #0f2745;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.pdv-abrircaixa-box p {
    color: #cbd5e1;
    margin-bottom: 14px;
    font-size: 0.9rem;
}

.pdv-fecharcaixa-box small {
    color: #94a3b8;
    display: block;
    margin-top: 4px;
    font-size: 0.72rem;
}

@media (max-width: 900px) {
    .pdv-body { grid-template-columns: 1fr; }
    .pdv-bottom-row { grid-template-columns: 1fr; }
    .pdv-side { flex-direction: row; }
    .pdv-total-box { order: -1; }
    .pdv-caixa-bar .pdv-btn { margin-left: 0; }
}
