:root{
  --primary:#2c3e50;
  --secondary:#34495e;
  --info:#3498db;
  --success:#27ae60;
  --warning:#f39c12;
  --danger:#e74c3c;
  --light:#ecf0f1;
  --dark:#2c3e50;
  --white:#fff;
  --border:#bdc3c7;
  --text:#2c3e50;
  --muted:#7f8c8d;
  --shadow:0 2px 4px rgba(0,0,0,.1);
  --shadow-lg:0 4px 8px rgba(0,0,0,.15);
}

*{box-sizing:border-box;margin:0;padding:0}
body{
  font-family:'Segoe UI',Tahoma,Geneva,Verdana,sans-serif;
  background:#f8f9fa;
  color:var(--text);
}

/* Layout helpers */
.container{max-width:1100px;margin:0 auto;padding:16px}
.card{
  background:var(--white);
  border:1px solid var(--border);
  border-radius:10px;
  box-shadow:var(--shadow);
  padding:16px;
}
.row{display:flex;gap:12px;flex-wrap:wrap}
.col{flex:1;min-width:220px}

/* Typography */
.h1{font-size:22px;font-weight:800;margin-bottom:10px}
.h2{font-size:16px;font-weight:800;margin-bottom:8px}
.muted{color:var(--muted)}
.small{font-size:12px}

/* Inputs */
input,select,textarea{
  width:100%;
  border:1px solid var(--border);
  border-radius:8px;
  padding:10px 12px;
  font-size:14px;
  background:var(--white);
}
input:focus,select:focus,textarea:focus{
  outline:none;
  border-color:var(--info);
  box-shadow:0 0 0 2px rgba(52,152,219,.18);
}

/* Buttons */
.btn{
  border:none;
  border-radius:10px;
  padding:10px 14px;
  font-weight:800;
  cursor:pointer;
  box-shadow:var(--shadow);
  transition:.18s;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.btn:hover{transform:translateY(-1px);box-shadow:var(--shadow-lg)}
.btn.primary{background:var(--info);color:var(--white)}
.btn.light{background:#f4f6f7;border:1px solid var(--border);color:var(--text)}
.btn.danger{background:#fde0dd;border:1px solid #f1a9a0;color:#b03a2e}

/* Tables */
.table{
  width:100%;
  border-collapse:collapse;
  background:var(--white);
  border:1px solid var(--border);
  border-radius:10px;
  overflow:hidden;
}
.table th{
  text-align:left;
  font-size:11px;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.4px;
  background:#f8f9fa;
  padding:12px 10px;
  border-bottom:1px solid var(--border);
}
.table td{
  padding:10px;
  border-bottom:1px solid #eee;
  font-size:13px;
}
.table tr:hover{background:#f0f7ff}

/* Nav basic (si tu nav es simple) */
.navbar{
  height:50px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:10px 16px;
  background:var(--dark);
  color:var(--white);
  box-shadow:var(--shadow-lg);
}
.navbar a{color:var(--white);text-decoration:none;font-weight:800}
.navbar .links{display:flex;gap:14px;align-items:center}
:root { --primary: #2c3e50; --secondary: #34495e; --success: #27ae60; --warning: #f39c12; --danger: #e74c3c; --info: #3498db; --light: #ecf0f1; --dark: #2c3e50; --white: #ffffff; --border: #bdc3c7; --text: #2c3e50; --muted: #7f8c8d; --shadow: 0 2px 4px rgba(0,0,0,0.1); --shadow-lg: 0 4px 8px rgba(0,0,0,0.15); } * { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background: #f8f9fa; color: var(--text); height: 100vh; overflow: hidden; } .header { background: var(--dark); color: var(--white); padding: 10px 20px; display: flex; justify-content: space-between; align-items: center; height: 50px; box-shadow: var(--shadow-lg); } .header-left { font-size: 16px; font-weight: bold; } .header-right { display: flex; gap: 20px; font-size: 14px; } /* Barra inferior con altura fija */ .bottom-panel { grid-column: 1 / -1; background: var(--white); border-top: 2px solid var(--border); height: 58px; padding: 10px 20px; display: flex; gap: 12px; justify-content: flex-end; align-items: center; flex-shrink: 0; } .main-container { display: grid; grid-template-columns: 250px 1fr 300px; grid-template-rows: 1fr 58px; height: calc(100vh - 50px); gap: 0; } /* ── Panel Izquierdo ── */ .left-panel { background: var(--white); border-right: 1px solid var(--border); padding: 15px; display: flex; flex-direction: column; gap: 12px; overflow-y: auto; } .field-group { display: flex; flex-direction: column; gap: 6px; } .field-label { font-size: 12px; font-weight: bold; color: var(--muted); text-transform: uppercase; } /* Input con ícono lupa */ .input-with-icon { position: relative; display: flex; align-items: center; } .input-with-icon .field-input { padding-right: 36px; width: 100%; } .input-lupa { position: absolute; right: 8px; background: none; border: none; cursor: pointer; font-size: 16px; color: var(--muted); padding: 0; line-height: 1; transition: color 0.2s; } .input-lupa:hover { color: var(--info); } .field-input { padding: 10px; border: 1px solid var(--border); border-radius: 4px; font-size: 14px; background: var(--white); } .field-input:focus { outline: none; border-color: var(--info); box-shadow: 0 0 0 2px rgba(52,152,219,0.2); } .desc-display { padding: 10px; border: 1px solid var(--border); border-radius: 4px; font-size: 13px; font-weight: 600; background: #f0faf4; color: var(--dark); min-height: 38px; cursor: default; user-select: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .desc-display.empty { color: var(--border); font-weight: normal; font-style: italic; } .desc-display.found { color: var(--success); border-color: var(--success); } .desc-display.not-found { color: var(--danger); border-color: var(--danger); } .price-display { padding: 10px; border: 1px solid var(--border); border-radius: 4px; font-size: 16px; font-weight: bold; text-align: right; background: #eaf4fb; color: var(--dark); cursor: default; user-select: none; } .price-label-note { font-size: 10px; color: var(--muted); font-style: italic; margin-top: -4px; } .qty-input-plain { width: 100%; text-align: center; font-weight: bold; } /* ── Botones unificados ── */ .btn-row { display: flex; gap: 9px; } .ubtn { flex: 1; padding: 12px 6px; border-radius: 6px; font-weight: 600; cursor: pointer; transition: all 0.18s; font-size: 12px; text-align: center; line-height: 1.4; box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; gap: 3px; border: 1px solid transparent; } .ubtn .icon { font-size: 16px; } .ubtn:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); } .ubtn.borrar { background: #fef0ee; border-color: #f1a9a0; color: #b03a2e; } .ubtn.borrar:hover { background: #fde0dd; } .ubtn.cancelar { background: #f4f6f7; border-color: #bdc3c7; color: #5d6d7e; } .ubtn.cancelar:hover { background: #eaecee; } .ubtn.inicio-caja { background: #eafaf6; border-color: #a2d9ce; color: #1a7a65; } .ubtn.inicio-caja:hover { background: #d5f5ec; } .ubtn.fichar { background: #f5eef9; border-color: #c39bd3; color: #6c3483; } .ubtn.fichar:hover { background: #ead5f5; } .ubtn.egresos { background: #fef9ec; border-color: #f9e79f; color: #9a6400; } .ubtn.egresos:hover { background: #fdf2ce; } .ubtn.caja-fuerte { background: #eaf4fb; border-color: #aed6f1; color: #1a5276; } .ubtn.caja-fuerte:hover { background: #d6eaf8; } .ubtn.dividido { background: #fef9ec; border-color: #f9e79f; color: #9a6400; } .ubtn.dividido:hover { background: #fdf2ce; } .ubtn.mercadopago { background: #e8f6fd; border-color: #85c1e9; color: #1a6fa0; } .ubtn.mercadopago:hover { background: #d1eaf8; } .ubtn.tarjeta { background: #eaf4fb; border-color: #aed6f1; color: #1a5276; } .ubtn.tarjeta:hover { background: #d6eaf8; } .ubtn.efectivo { background: #eafaf6; border-color: #a2d9ce; color: #1a7a65; } .ubtn.efectivo:hover { background: #d5f5ec; } .ubtn.planilla { background: #f4f6f7; border-color: #bdc3c7; color: #2c3e50; flex:0; padding: 10px 24px; font-size: 13px; } .ubtn.planilla:hover { background: #eaecee; } .section-divider { display: flex; align-items: center; gap: 8px; color: var(--border); font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px; } .section-divider::before, .section-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); } /* ── Panel Central ── */ .center-panel { background: var(--white); border-right: 1px solid var(--border); display: flex; flex-direction: column; } .panel-header { background: var(--info); padding: 12px 20px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; } .panel-title { font-size: 15px; font-weight: bold; color: var(--white); } .item-count { background: rgba(255,255,255,0.25); color: var(--white); padding: 4px 10px; border-radius: 12px; font-size: 12px; font-weight: bold; } .table-container { height: calc(6 * 49px); overflow-y: auto; flex-shrink: 0; } .products-table { width: 100%; border-collapse: collapse; } .products-table thead th { background: #f8f9fa; padding: 12px 8px; text-align: left; font-size: 11px; font-weight: bold; color: var(--muted); text-transform: uppercase; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 1; } .products-table tbody td { padding: 8px; border-bottom: 1px solid #eee; font-size: 13px; } .products-table tbody tr { cursor: pointer; transition: background 0.15s; } .products-table tbody tr:hover { background: #f0f7ff; } .products-table tbody tr.selected { background: #d6eaf8; outline: 2px solid var(--info); outline-offset: -1px; } .products-table tbody tr.selected td { font-weight: 600; } .qty-cell { width: 55px; padding: 4px 6px; border: 1px solid transparent; border-radius: 4px; font-size: 13px; font-weight: bold; text-align: center; background: transparent; cursor: text; font-family: inherit; } .qty-cell:focus { outline: none; border-color: var(--info); background: var(--white); } .delete-item { color: var(--danger); cursor: pointer; padding: 2px 6px; border-radius: 3px; transition: all 0.2s; } .delete-item:hover { background: var(--danger); color: var(--white); } .center-notes { padding: 10px 20px; background: #fafbfc; border-top: 1px solid #eee; display: flex; flex-direction: column; gap: 5px; } .center-notes-label { font-size: 11px; color: var(--muted); font-weight: bold; text-transform: uppercase; } .center-notes textarea { width: 100%; height: 62px; border: 1px solid var(--border); border-radius: 4px; padding: 6px 8px; font-size: 12px; resize: none; font-family: inherit; background: var(--white); } .center-notes textarea:focus { outline: none; border-color: var(--info); } .total-section { background: var(--dark); color: var(--white); padding: 16px 20px; text-align: right; font-size: 20px; font-weight: bold; } .payment-bar { background: var(--white); border-top: 1px solid var(--border); padding: 12px 16px; display: flex; gap: 9px; } /* ── Panel Derecho ── */ .right-panel { background: var(--white); display: flex; flex-direction: column; overflow: hidden; } .right-panel-header { background: var(--info); padding: 10px 14px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-shrink: 0; } .btn-historial { padding: 5px 10px; background: rgba(255,255,255,0.2); border: 1px solid rgba(255,255,255,0.5); border-radius: 5px; color: var(--white); font-size: 11px; font-weight: bold; cursor: pointer; white-space: nowrap; transition: all 0.2s; } .btn-historial:hover { background: rgba(255,255,255,0.35); } /* Grid de accesos rápidos — altura calculada para que quede exacto */ .products-grid { flex: 1; padding: 12px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; overflow-y: auto; align-content: start; } .quick-product { background: var(--white); border: 1px solid var(--border); border-radius: 6px; padding: 8px; text-align: center; cursor: pointer; transition: all 0.2s; box-shadow: var(--shadow); height: 70px; display: flex; flex-direction: column; justify-content: center; font-size: 11px; position: relative; overflow: hidden; } .quick-product:hover { background: var(--info); color: var(--white); transform: translateY(-1px); box-shadow: var(--shadow-lg); } .quick-product-name { font-weight: bold; margin-bottom: 3px; line-height: 1.2; } .quick-product-price { color: var(--muted); font-size: 10px; } .quick-product:hover .quick-product-price { color: rgba(255,255,255,0.8); } /* Imagen de fondo del acceso rápido (opcional) */ .quick-product-img { position: absolute; inset: 0; object-fit: cover; width: 100%; height: 100%; opacity: 0.15; border-radius: 6px; pointer-events: none; } .quick-product:hover .quick-product-img { opacity: 0.08; } .quick-badge { position: absolute; top: 3px; right: 3px; background: var(--danger); color: var(--white); border-radius: 50%; width: 18px; height: 18px; font-size: 10px; font-weight: bold; display: none; align-items: center; justify-content: center; z-index: 2; } /* Botón + agregar acceso rápido */ .quick-add-btn { background: #f8f9fa; border: 2px dashed var(--border); border-radius: 6px; height: 70px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; cursor: pointer; transition: all 0.2s; font-size: 11px; color: var(--muted); } .quick-add-btn:hover { border-color: var(--info); color: var(--info); background: #eaf4fb; } .quick-add-btn .plus { font-size: 22px; line-height: 1; } /* ══ MODALES ══ */ .modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 1000; align-items: center; justify-content: center; } .modal-overlay.open { display: flex; } .modal { background: var(--white); border-radius: 8px; width: 680px; max-width: 95vw; max-height: 85vh; display: flex; flex-direction: column; box-shadow: 0 10px 40px rgba(0,0,0,0.25); overflow: hidden; } .modal.modal-sm { width: 460px; } .modal-header { background: var(--dark); color: var(--white); padding: 14px 20px; display: flex; justify-content: space-between; align-items: center; flex-shrink: 0; } .modal-header h2 { font-size: 15px; } .modal-close { background: none; border: none; color: var(--white); font-size: 20px; cursor: pointer; opacity: 0.8; transition: opacity 0.2s; } .modal-close:hover { opacity: 1; } /* Historial */ .modal-summary { background: #f8f9fa; padding: 12px 20px; display: flex; gap: 30px; border-bottom: 1px solid var(--border); flex-shrink: 0; } .summary-stat { display: flex; flex-direction: column; gap: 2px; } .summary-stat .lbl { font-size: 10px; color: var(--muted); text-transform: uppercase; font-weight: bold; } .summary-stat .val { font-size: 18px; font-weight: bold; color: var(--dark); } .modal-body { overflow-y: auto; flex: 1; padding: 16px 20px; display: flex; flex-direction: column; gap: 10px; } .sale-card { border: 1px solid var(--border); border-radius: 6px; overflow: hidden; box-shadow: var(--shadow); } .sale-card-header { background: #f8f9fa; padding: 10px 14px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; user-select: none; } .sale-card-header:hover { background: #edf2f7; } .sale-info { display: flex; gap: 14px; align-items: center; } .sale-num { font-weight: bold; font-size: 13px; } .sale-time { font-size: 12px; color: var(--muted); } .sale-method { padding: 2px 8px; border-radius: 10px; font-size: 11px; font-weight: bold; } .sale-method.efectivo { background: #d5f5e3; color: #1a7a65; } .sale-method.mercadopago { background: #d6eaf8; color: #1a5276; } .sale-method.tarjeta { background: #eaf4fb; color: #1a5276; } .sale-method.dividido { background: #fef9ec; color: #9a6400; } .sale-total { font-weight: bold; font-size: 14px; } .sale-chevron { color: var(--muted); font-size: 12px; transition: transform 0.2s; } .sale-card.expanded .sale-chevron { transform: rotate(180deg); } .sale-card-body { display: none; padding: 10px 14px; border-top: 1px solid #eee; } .sale-card.expanded .sale-card-body { display: block; } .sale-detail-table { width: 100%; border-collapse: collapse; font-size: 12px; } .sale-detail-table th { text-align: left; padding: 5px 6px; color: var(--muted); font-size: 10px; text-transform: uppercase; border-bottom: 1px solid #eee; } .sale-detail-table td { padding: 5px 6px; border-bottom: 1px solid #f5f5f5; } .sale-notes { margin-top: 8px; font-size: 11px; color: var(--muted); font-style: italic; } /* Modal búsqueda de producto (lupa y agregar acceso rápido) */ .prod-search-bar { padding: 14px 20px; border-bottom: 1px solid var(--border); display: flex; gap: 8px; flex-shrink: 0; } .prod-search-bar input { flex: 1; padding: 8px 12px; border: 1px solid var(--border); border-radius: 4px; font-size: 14px; } .prod-search-bar input:focus { outline: none; border-color: var(--info); } .prod-list { overflow-y: auto; flex: 1; } .prod-row { padding: 12px 20px; border-bottom: 1px solid #eee; display: flex; align-items: center; gap: 14px; cursor: pointer; transition: background 0.15s; } .prod-row:hover { background: #f0f7ff; } .prod-row.selected-row { background: #d6eaf8; } .prod-code { font-size: 11px; color: var(--muted); width: 44px; flex-shrink: 0; } .prod-name { flex: 1; font-size: 14px; font-weight: 500; } .prod-price { font-size: 13px; font-weight: bold; color: var(--dark); white-space: nowrap; } /* Modal agregar acceso rápido — zona de imagen */ .add-quick-body { padding: 20px; display: flex; flex-direction: column; gap: 16px; overflow-y: auto; flex: 1; } .add-quick-selected { background: #f8f9fa; border: 1px solid var(--border); border-radius: 6px; padding: 12px 16px; display: flex; align-items: center; gap: 12px; } .add-quick-selected .prod-emoji { font-size: 26px; } .add-quick-selected .prod-info { flex: 1; } .add-quick-selected .prod-info strong { display: block; font-size: 14px; } .add-quick-selected .prod-info span { font-size: 12px; color: var(--muted); } .img-upload-area { border: 2px dashed var(--border); border-radius: 6px; padding: 20px; text-align: center; cursor: pointer; transition: all 0.2s; position: relative; overflow: hidden; } .img-upload-area:hover { border-color: var(--info); background: #eaf4fb; } .img-upload-area input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; } .img-upload-area .upload-label { font-size: 13px; color: var(--muted); pointer-events: none; } .img-upload-area img { max-height: 100px; border-radius: 4px; display: none; } .img-upload-area.has-img img { display: block; margin: 0 auto; } .img-upload-area.has-img .upload-label { display: none; } .modal-footer { padding: 14px 20px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 10px; flex-shrink: 0; } .btn-modal { padding: 9px 20px; border-radius: 5px; border: none; font-weight: bold; font-size: 13px; cursor: pointer; transition: all 0.2s; } .btn-modal.primary { background: var(--info); color: var(--white); } .btn-modal.primary:hover { background: #2980b9; } .btn-modal.secondary { background: var(--light); color: var(--text); border: 1px solid var(--border); } .btn-modal.secondary:hover { background: var(--border); } ::-webkit-scrollbar { width: 6px; } ::-webkit-scrollbar-track { background: #f1f1f1; } ::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; } ::-webkit-scrollbar-thumb:hover { background: var(--muted); } @media (max-width: 1024px) { .main-container { grid-template-columns: 220px 1fr 280px; } .products-grid { grid-template-columns: repeat(2, 1fr); } }