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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8fafc;
    color: #334155;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

header h1 {
    color: #1e293b;
    font-size: 24px;
    font-weight: 700;
}

.user-info {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* Grid */
.grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

@media (max-width: 1024px) {
    .grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .grid {
        grid-template-columns: 1fr;
    }
}

/* Cards */
.card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    border: 1px solid #e2e8f0;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.card-header h3 {
    color: #1e293b;
    font-size: 18px;
    font-weight: 600;
}

/* Formularios */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #374151;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Botones */
.btn {
    padding: 10px 16px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background-color: #ff0000;
    color: white;
}

.btn-primary:hover {
    background-color: #2563eb;
}

.btn-secondary {
    background-color: #6b7280;
    color: white;
}

.btn-secondary:hover {
    background-color: #4b5563;
}

.btn-danger {
    background-color: #ef4444;
    color: white;
}

.btn-danger:hover {
    background-color: #dc2626;
}

.btn-block {
    width: 100%;
}

/* Badges */
.badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.badge.online {
    background-color: #dcfce7;
    color: #16a34a;
}

.badge.offline {
    background-color: #fecaca;
    color: #dc2626;
}

/* Tabs */
.admin-tabs,
.catalog-tabs,
.product-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 4px;
}

.tab-button {
    padding: 8px 12px;
    background: none;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    font-size: 13px;
    color: #64748b;
    transition: all 0.2s;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .admin-tabs {
        gap: 3px;
    }
    .admin-tabs .tab-button {
        padding: 6px 10px;
        font-size: 12px;
    }
}

.tab-button:hover {
    background-color: #f1f5f9;
    color: #334155;
}

.tab-button.active {
    background-color: #3b82f6;
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Catálogo */
.catalog {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    max-height: 400px;
    overflow-y: auto;
}

.product-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.product-card:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.product-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: #1e293b;
}

.product-code {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 4px;
}

.product-price {
    font-weight: 700;
    color: #059669;
}

.product-type {
    font-size: 10px;
    background: #dbeafe;
    color: #1d4ed8;
    padding: 2px 6px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 4px;
}

/* Carrito */
.cart-items {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 16px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

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

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.cart-item-employee {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 2px;
}

.cart-item-price {
    font-size: 12px;
    color: #059669;
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border: 1px solid #d1d5db;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.qty-btn:hover {
    background: #f8fafc;
}

.qty-display {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
}

.cart-total {
    border-top: 2px solid #e2e8f0;
    padding-top: 16px;
}

.total-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-weight: 500;
}

.total-row.commission {
    color: #d97706;
}

.total-row.main {
    font-size: 18px;
    font-weight: 700;
    color: #059669;
    border-top: 1px solid #e2e8f0;
    padding-top: 8px;
}

/* Listas */
.list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 12px;
    background: white;
}

.list-item-info {
    flex: 1;
}

.list-item-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: #1e293b;
}

.list-item-meta {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 4px;
}

.list-item-description {
    font-size: 14px;
    color: #6b7280;
}

.list-item-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    margin-top: 4px;
}

.list-item-status.active {
    background: #dcfce7;
    color: #16a34a;
}

.list-item-status.inactive {
    background: #fef3c7;
    color: #d97706;
}

.list-item-totals {
    text-align: right;
    margin-right: 16px;
}

.total-amount {
    font-weight: 700;
    font-size: 16px;
    color: #059669;
}

.total-amount.expense {
    color: #dc2626;
}

.commission-amount {
    font-size: 12px;
    color: #d97706;
}

.list-item-actions {
    display: flex;
    gap: 8px;
}

/* Estadísticas */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.stat-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1e293b;
}

.stat-label {
    color: #64748b;
    font-size: 14px;
}

/* Gráficos */
.chart-item {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    padding: 8px;
    background: #f8fafc;
    border-radius: 6px;
}

.chart-label {
    flex: 0 0 120px;
    font-weight: 500;
}

.chart-bar-container {
    flex: 1;
    background: #e2e8f0;
    border-radius: 4px;
    height: 20px;
    margin: 0 12px;
    overflow: hidden;
}

.chart-bar {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.chart-value {
    flex: 0 0 80px;
    text-align: right;
    font-weight: 600;
    color: #1e293b;
}

/* Tablas */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

.data-table th,
.data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.data-table th {
    background: #f8fafc;
    font-weight: 600;
    color: #374151;
}

.data-table tr:hover {
    background: #f8fafc;
}

/* Modales */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #e2e8f0;
}

.modal-header h2 {
    color: #1e293b;
    font-size: 20px;
    font-weight: 600;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Login */
.login-body {
    background: linear-gradient(135deg, #002fff 0%, #ff0000 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-card {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.login-card h1 {
    text-align: center;
    color: #1e293b;
    margin-bottom: 8px;
    font-size: 28px;
}

.subtitle {
    text-align: center;
    color: #64748b;
    margin-bottom: 24px;
}

.admin-link {
    text-align: center;
    margin-top: 20px;
}

.admin-link a {
    color: #ff0000;
    text-decoration: none;
}

.admin-link a:hover {
    text-decoration: underline;
}

/* Search */
.search-box {
    position: relative;
}

.search-box input {
    padding-left: 40px;
}

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
}

/* Loading */
.loading {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e2e8f0;
    border-left: 4px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Estados vacíos */
.empty-state {
    text-align: center;
    color: #64748b;
    padding: 40px 20px;
    font-style: italic;
}

/* Mensajes */
.message {
    padding: 12px 16px;
    border-radius: 8px;
    margin: 16px 0;
    font-weight: 500;
    display: none;
}

.message.success {
    background: #dcfce7;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.message.error {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.message.warning {
    background: #fef3c7;
    color: #d97706;
    border: 1px solid #fde68a;
}

/* Checkout */
.checkout-summary {
    padding: 20px;
}

.checkout-items {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 20px;
}

.checkout-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

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

.checkout-item-details {
    flex: 1;
}

.checkout-item-meta {
    font-size: 12px;
    color: #64748b;
    margin-top: 2px;
}

.checkout-item-totals {
    text-align: right;
}

.checkout-totals {
    border-top: 2px solid #e2e8f0;
    padding-top: 16px;
}

/* Sale Detail */
.sale-detail {
    padding: 20px;
}

.sale-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.sale-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.sale-items {
    margin-bottom: 20px;
}

.sale-items h4 {
    margin-bottom: 12px;
    color: #374151;
}

.sale-totals {
    border-top: 2px solid #e2e8f0;
    padding-top: 16px;
}

/* Filtros */
.filters {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.filters select,
.filters input {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 12px;
    }
    
    header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    
    .user-info {
        width: 100%;
        justify-content: space-between;
    }
    
    .card-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    
    .list-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .list-item-totals {
        margin-right: 0;
        text-align: left;
    }
    
    .list-item-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
}

.payment-section {
    padding: 20px;
    border-top: 1px solid #e2e8f0;
}

.payment-methods {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.payment-methods label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
}

.cash-section {
    margin-top: 12px;
}

.cash-change {
    margin-top: 8px;
    font-weight: 600;
}

.change-amount {
    padding: 8px;
    border-radius: 6px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.action-buttons {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid #e2e8f0;
}

.pos-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: #f9fafb;
}

.pos-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: white;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.header-left h1 {
    margin: 0;
    font-size: 20px;
}

.header-right {
    display: flex;
    gap: 12px;
    align-items: center;
}

#posMessageBar {
    animation: slideDown 0.25s ease;
}

@keyframes slideDown {
    from { max-height: 0; opacity: 0; }
    to { max-height: 200px; opacity: 1; }
}

.pos-inputs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    padding: 16px 24px;
    background: white;
    border-bottom: 1px solid #e5e7eb;
}

.input-group {
    display: flex;
    flex-direction: column;
}

.input-group label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.input-group input,
.input-group select {
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
}

.search-group {
    grid-column: span 1;
}

.pos-content {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
    padding: 24px;
    overflow: hidden;
    flex: 1;
}

.catalog-section {
    overflow-y: auto;
    padding-right: 8px;
}

.catalog-header {
    margin-bottom: 16px;
}

.catalog-header h3 {
    margin: 0;
    font-size: 18px;
    color: #111827;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}

.product-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.product-card:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 6px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
}

.cart-section {
    display: flex;
    flex-direction: column;
}

.cart-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.cart-card h3 {
    margin: 0 0 16px 0;
    font-size: 18px;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    margin-bottom: 16px;
}

@media (max-width: 1200px) {
    .pos-content {
        grid-template-columns: 1fr;
    }
    
    .cart-section {
        max-height: 500px;
    }
}

.stock-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 4px;
	font-size: 11px;
	font-weight: 600;
	margin-left: 8px;
}

.stock-badge.low {
	background: #fef3c7;
	color: #d97706;
}

.stock-badge.out {
	background: #fee2e2;
	color: #dc2626;
}

.list-item.low-stock {
	border-left: 3px solid #d97706;
}

.list-item.out-of-stock {
	border-left: 3px solid #dc2626;
	background: #fef2f2;
}

.movement-badge {
	padding: 2px 8px;
	border-radius: 4px;
	font-size: 12px;
	font-weight: 500;
}

.movement-badge.entry {
	background: #dcfce7;
	color: #16a34a;
}

.movement-badge.exit {
	background: #fee2e2;
	color: #dc2626;
}

.stock-warning {
	font-size: 11px;
	font-weight: 600;
	padding: 4px 8px;
	border-radius: 4px;
	margin-top: 4px;
	display: inline-block;
}

.stock-warning.low {
	background: #fef3c7;
	color: #d97706;
}

.stock-warning.out {
	background: #fee2e2;
	color: #dc2626;
}

.logo-container img {
	transition: transform 0.3s ease;
}

.logo-container img:hover {
	transform: scale(1.05);
}

.mass-stock-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 12px;
	border-bottom: 1px solid #e5e7eb;
}

.mass-stock-item:last-child {
	border-bottom: none;
}

.mass-stock-info {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.mass-stock-info strong {
	font-size: 14px;
	color: #1e293b;
}

.mass-stock-info span {
	font-size: 12px;
	color: #64748b;
}

.mass-stock-input {
	display: flex;
	align-items: center;
}

.alert {
	padding: 16px;
	border-radius: 8px;
	margin-bottom: 12px;
}

.alert-danger {
	background: #fee2e2;
	color: #dc2626;
	border: 1px solid #fecaca;
}

.alert-warning {
	background: #fef3c7;
	color: #d97706;
	border: 1px solid #fde68a;
}

.alert ul {
	margin: 8px 0 0 20px;
	padding: 0;
}

.alert li {
	margin: 4px 0;
}

.current-week {
	border-left: 4px solid #059669 !important;
	background: #f0fdf4;
}

.week-selector {
	display: flex;
	align-items: center;
	gap: 12px;
	justify-content: center;
}

.week-display {
	font-weight: 600;
	font-size: 16px;
	min-width: 250px;
	text-align: center;
}

@keyframes slideIn {
	from {
		transform: translateX(100%);
		opacity: 0;
	}
	to {
		transform: translateX(0);
		opacity: 1;
	}
}

@keyframes slideOut {
	from {
		transform: translateX(0);
		opacity: 1;
	}
	to {
		transform: translateX(100%);
		opacity: 0;
	}
}

.sale-detail-modal .modal-content {
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
}

.sale-detail-header {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    padding: 20px;
    border-radius: 12px 12px 0 0;
}

.sale-detail-header h2 {
    color: white;
    margin: 0 0 8px 0;
    font-size: 22px;
}

.sale-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.sale-info-item {
    background: rgba(255, 255, 255, 0.15);
    padding: 8px 12px;
    border-radius: 6px;
    backdrop-filter: blur(10px);
}

.sale-info-label {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 2px;
}

.sale-info-value {
    font-weight: 600;
    font-size: 14px;
}

.sale-detail-body {
    padding: 20px;
    max-height: 400px;
    overflow-y: auto;
}

.sale-items-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.sale-items-table th {
    background: #f8fafc;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
}

.sale-items-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
}

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

.sale-items-table tr:hover {
    background: #f9fafb;
}

.item-name {
    font-weight: 500;
    color: #1f2937;
}

.item-meta {
    font-size: 12px;
    color: #6b7280;
    margin-top: 2px;
}

.item-price, .item-subtotal, .item-commission {
    text-align: right;
    font-weight: 500;
}

.item-commission {
    color: #d97706;
    font-size: 12px;
}

.sale-totals {
    background: #f9fafb;
    border-radius: 8px;
    padding: 16px;
    margin-top: 20px;
    border: 1px solid #e5e7eb;
}

.total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.total-row:not(:last-child) {
    border-bottom: 1px solid #e5e7eb;
}

.total-label {
    font-weight: 500;
    color: #4b5563;
}

.total-value {
    font-weight: 600;
    color: #1f2937;
}

.total-row.main {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    margin: 8px -16px;
    padding: 12px 16px;
    border-radius: 6px;
}

.total-row.main .total-label {
    font-size: 16px;
    color: #0369a1;
}

.total-row.main .total-value {
    font-size: 18px;
    color: #0369a1;
}

.payment-details {
    background: #fef3c7;
    border-radius: 6px;
    padding: 12px 16px;
    margin-top: 16px;
    border: 1px solid #fde68a;
}

.payment-details .total-row {
    padding: 6px 0;
    border-bottom: none;
}

.payment-details .total-row:first-child {
    margin-top: 0;
}

.sale-detail-footer {
    display: flex;
    gap: 12px;
    padding: 16px 20px;
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
    border-radius: 0 0 12px 12px;
}

.badge-sale {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-left: 8px;
}

.badge-success {
    background: #dcfce7;
    color: #16a34a;
}

.badge-pending {
    background: #fef3c7;
    color: #d97706;
}

.commission-badge {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

/* Ocultar comisiones en todo el POS */
.cart-item-commission,
.total-row.commission,
.checkout-item-meta,
.commission-amount,
.item-commission {
    display: none !important;
}

.employee-selection-section {
    padding: 20px;
    border-bottom: 1px solid #e2e8f0;
    background: #fefce8;
}

.employee-selection-section h3 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #854d0e;
}

.employee-selection-section select {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #fbbf24;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    color: #1f2937;
    font-weight: 500;
}

.employee-selection-section select:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.1);
}

.form-group input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

.form-group label input[type="checkbox"] {
    display: inline-block;
    vertical-align: middle;
}

.inventory-item {
    display: flex;
}

.alert h4 {
    margin: 0 0 8px 0;
}

.catalog-code {
    font-size: 11px;
    color: #6b7280;
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 4px;
    font-weight: 600;
}

.empty-search {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
    font-size: 14px;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.catalog-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.catalog-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-color: #3b82f6;
}

.catalog-card-header {
    margin-bottom: 12px;
}

.catalog-card-header h4 {
    margin: 0 0 4px 0;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
}

.catalog-card-body {
    flex: 1;
    margin-bottom: 12px;
}

.catalog-price {
    font-size: 18px;
    font-weight: 700;
    color: #059669;
    margin-bottom: 4px;
}

.catalog-stock {
    font-size: 12px;
    color: #6b7280;
}

.stock-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    margin-top: 4px;
}

.stock-badge.out-stock {
    background: #fee2e2;
    color: #dc2626;
}

.stock-badge.low-stock {
    background: #fef3c7;
    color: #d97706;
}

.catalog-card {
    cursor: pointer;
    user-select: none;
}

.catalog-card:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.catalog-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    cursor: pointer;
    user-select: none;
    text-align: center;
}

.catalog-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-color: #3b82f6;
    background: #eff6ff;
}

.catalog-card:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.catalog-card-header {
    margin-bottom: 12px;
}

.catalog-card-header h4 {
    margin: 0 0 4px 0;
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
}

.catalog-card-body {
    flex: 1;
    margin-bottom: 0;
}

.catalog-price {
    font-size: 18px;
    font-weight: 700;
    color: #059669;
    margin-bottom: 4px;
}

.catalog-stock {
    font-size: 12px;
    color: #6b7280;
    font-weight: 600;
}

.stock-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    margin-top: 4px;
}

.stock-badge.out-stock {
    background: #fee2e2;
    color: #dc2626;
}

.stock-badge.low-stock {
    background: #fef3c7;
    color: #d97706;
}

.cart-item-quantity {
    width: 60px;
    padding: 6px 8px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
}