<style>
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

:root {
    --primary:        #2563eb;
    --primary-dark:   #1d4ed8;
    --primary-light:  #dbeafe;
    --accent:         #3b82f6;
    --accent-dark:    #2563eb;
    --accent-light:   #60a5fa;
    --secondary:      #1e40af;
    --secondary-dark: #1e3a8a;
    --secondary-light:#3b82f6;
    --success:        #16a34a;
    --warning:        #f97316;
    --danger:         #dc2626;
    --dark:           #020818;
    --gray:           #c0cfe8;
    --light:          #f1f5f9;
    --white:          #ffffff;
    --background:     #f0f4f8;
    --text-primary:   #1e293b;
    --text-secondary: #a8b8d0;
    --border:         #e2e8f0;
    --gradient-main:  linear-gradient(135deg, #1e40af 0%, #2563eb 50%, #3b82f6 100%);
    --gradient-accent:linear-gradient(135deg, #f97316 0%, #ea6c05 100%);
}

body {
    background: var(--background);
    min-height: 100vh;
    color: var(--text-primary);
}

/* Login */
/* ── LOGIN ───────────────────────────────────────────────── */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: linear-gradient(135deg, #020818 0%, #0a1628 30%, #0f2044 60%, #071530 100%);
    position: relative;
    overflow: hidden;
}

/* Partículas animadas */
.login-particles { position: absolute; inset: 0; pointer-events: none; }
.particle {
    position: absolute;
    border-radius: 50%;
    background: rgba(56,139,253,0.12);
    animation: floatParticle 12s infinite ease-in-out;
}
.p1 { width: 300px; height: 300px; top: -80px; left: -80px; animation-delay: 0s; }
.p2 { width: 200px; height: 200px; bottom: -60px; right: -40px; animation-delay: -4s; background: rgba(99,102,241,0.1); }
.p3 { width: 150px; height: 150px; top: 50%; left: 70%; animation-delay: -8s; background: rgba(56,189,248,0.08); }
.p4 { width: 80px; height: 80px; top: 20%; left: 15%; animation-delay: -6s; background: rgba(56,139,253,0.15); }

@keyframes floatParticle {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -20px) scale(1.05); }
    66% { transform: translate(-20px, 15px) scale(0.95); }
}

/* Tarjeta */
.login-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 380px;
    background: rgba(255,255,255,0.04);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 28px;
    padding: 44px 40px 36px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow:
        0 0 0 1px rgba(255,255,255,0.05) inset,
        0 32px 80px rgba(0,0,0,0.6),
        0 0 60px rgba(56,139,253,0.08);
}

/* Línea decorativa superior */
.login-card::before {
    content: '';
    position: absolute;
    top: 0; left: 20%; right: 20%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(99,179,253,0.6), transparent);
    border-radius: 1px;
}

/* Logo */
.login-logo-wrap {
    width: 82px;
    height: 82px;
    border-radius: 22px;
    overflow: hidden;
    margin-bottom: 22px;
    box-shadow: 0 8px 32px rgba(56,139,253,0.35), 0 0 0 1px rgba(255,255,255,0.1);
    background: linear-gradient(135deg, #1d4ed8, #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 900;
    color: #fff;
}

.login-logo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Texto */
.login-brand {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
    letter-spacing: -0.3px;
    text-align: center;
}

.login-tagline {
    font-size: 12px;
    color: rgba(148,163,184,0.7);
    margin: 0 0 32px;
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-style: italic;
}

/* Formulario */
.login-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.login-field-wrap {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    padding: 0 16px;
    transition: all 0.25s;
}

.login-field-wrap:focus-within {
    background: rgba(255,255,255,0.1);
    border-color: rgba(99,179,253,0.5);
    box-shadow: 0 0 0 3px rgba(56,139,253,0.12);
}

.login-field-ico {
    font-size: 16px;
    margin-right: 12px;
    opacity: 0.5;
    font-style: normal;
    flex-shrink: 0;
}

.login-field-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 15px 0;
    font-size: 15px;
    color: #fff;
    font-family: inherit;
}

.login-field-input::placeholder { color: rgba(148,163,184,0.5); }

/* Botón */
.login-submit {
    width: 100%;
    padding: 15px;
    margin-top: 4px;
    background: linear-gradient(135deg, #1e40af, #2563eb, #3b82f6);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    letter-spacing: 0.3px;
    transition: all 0.25s;
    box-shadow: 0 4px 20px rgba(37,99,235,0.45);
    position: relative;
    overflow: hidden;
}

.login-submit::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
    transition: left 0.4s;
}

.login-submit:hover::before { left: 100%; }
.login-submit:hover { transform: translateY(-1px); box-shadow: 0 8px 28px rgba(37,99,235,0.55); }
.login-submit:active { transform: scale(0.98); }
.login-submit:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* Footer */
.login-footer {
    margin: 24px 0 0;
    font-size: 11px;
    color: rgba(148,163,184,0.4);
    letter-spacing: 0.5px;
    text-align: center;
}

/* neutralizar clases viejas */
.login-box, .login-brand-name, .login-brand-verse, .login-brand-ref,
.login-brand, .login-form-panel, .login-features, .login-feature-item,
.login-footer-text, .login-logo-wrap-old, .login-eye-btn,
.login-app-name, .login-field, .login-field-icon,
.login-input, .login-btn-old, .login-input-group { display: none !important; }

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-secondary);
    font-weight: 500;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 14px;
    box-sizing: border-box;
    transition: all 0.3s;
    box-sizing: border-box;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(46, 204, 113, 0.1);
}

.btn-primary {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(46, 204, 113, 0.3);
}

.app-container {
    display: none;
    min-height: 100vh;
}

.app-container.active {
    display: block;
}

/* Header */
.main-header {
    background: var(--gradient-main);
    padding: 0 24px;
    height: 56px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 12px rgba(26,111,196,0.25);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: .01em;
}

.logo span {
    color: var(--accent-light);
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-menu span {
    color: rgba(255,255,255,.85);
    font-size: 13px;
    background: rgba(255,255,255,.12);
    padding: 4px 12px;
    border-radius: 20px;
    white-space: nowrap;
}

.btn-logout {
    padding: 7px 16px;
    background: rgba(255,255,255,.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all .2s;
    white-space: nowrap;
}

.btn-logout:hover {
    background: rgba(255,255,255,.25);
}

/* Navegación */
.main-nav {
    background: var(--white);
    border-bottom: 2px solid var(--border);
    box-shadow: 0 1px 4px rgba(0,0,0,.04);
    position: sticky;
    top: 56px;
    z-index: 99;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.main-nav::-webkit-scrollbar { display: none; }

.nav-tabs {
    display: flex;
    list-style: none;
    padding: 0 16px;
    min-width: max-content;
}

.nav-tab {
    padding: 14px 16px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--text-secondary);
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
    white-space: nowrap;
    font-weight: 500;
}

.nav-tab:hover {
    color: #2ecc71;
}

.nav-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.content-area {
    padding: 0;
}

.tab-content {
    display: none;
}

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

/* Dashboard Cards */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: rgb(255, 177, 245);
    border-radius: 20px;
    padding: 25px;
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(46, 204, 113, 0.15);
}

.dashboard-card h3 {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 10px;
    font-weight: 500;
}

.dashboard-card .value {
    font-size: 32px;
    font-weight: bold;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.dashboard-card .change {
    font-size: 12px;
    color: var(--primary);
    background: rgba(46, 204, 113, 0.1);
    padding: 4px 10px;
    border-radius: 20px;
    display: inline-block;
}

/* Tablas */
.table-container {
    background: var(--white);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 1px solid var(--border);
    overflow-x: auto;
}

.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.table-header h2 {
    font-size: 20px;
    color: var(--text-primary);
}

.table-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

th {
    text-align: left;
    padding: 15px 12px;
    background: var(--light);
    color: var(--text-primary);
    font-weight: 600;
    font-size: 13px;
    border-bottom: 2px solid var(--primary);
}

td {
    padding: 12px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}

tr:hover {
    background: rgba(46, 204, 113, 0.05);
}

/* Badges */
.badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.badge-success {
    background: rgba(46, 204, 113, 0.15);
    color: var(--primary-dark);
}

.badge-warning {
    background: rgba(243, 156, 18, 0.15);
    color: var(--secondary-dark);
}

.badge-danger {
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger);
}

.badge-info {
    background: rgba(52, 152, 219, 0.15);
    color: #2980b9;
}

/* Botones */
.btn {
    padding: 10px 18px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 8px;
}

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

.btn-success:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(46, 204, 113, 0.3);
}

.btn-warning {
    background: var(--secondary);
    color: white;
}

.btn-warning:hover {
    background: var(--secondary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(243, 156, 18, 0.3);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.3);
}

.btn-info {
    background: #3498db;
    color: white;
}

.btn-info:hover {
    background: #2980b9;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-secondary);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(46, 204, 113, 0.05);
}

/* Buscador */
.search-box {
    min-width: 0;
    flex: 1;
}

.search-box input {
    width: 100%;
    padding: 10px 18px;
    border: 2px solid var(--border);
    border-radius: 30px;
    font-size: 14px;
    transition: all 0.3s;
    box-sizing: border-box;
}

.search-box input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(46, 204, 113, 0.1);
    outline: none;
}

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

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 20px;
    padding: 30px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.modal-content h2 {
    margin-bottom: 20px;
    color: var(--text-primary);
    font-size: 24px;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 25px;
}

.modal-actions button {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s;
}

/* POS - Productos escritorio */
.pos-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 20px;
    align-items: start;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    max-height: calc(100vh - 200px);
    overflow-y: auto;
    padding-right: 5px;
}

.product-card {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: 16px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s;
}

.product-card:hover {
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(46, 204, 113, 0.15);
}

.product-card h3 {
    font-size: 15px;
    color: var(--text-primary);
    margin-bottom: 12px;
    font-weight: 600;
}

.product-price {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    gap: 5px;
}

.price-usd {
    background: rgba(46, 204, 113, 0.1);
    color: var(--primary-dark);
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 700;
}

.price-bs {
    background: rgba(243, 156, 18, 0.1);
    color: var(--secondary-dark);
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 700;
}

.product-stock {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 12px;
    padding-top: 12px;
    border-top: 2px dashed var(--border);
}

/* Carrito escritorio */
.cart-section {
    background: var(--white);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 2px solid var(--border);
    border-left: 4px solid var(--primary);
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.cart-items {
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 20px;
    padding-right: 5px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: var(--light);
    margin-bottom: 10px;
    border-radius: 12px;
    font-size: 12px;
    border-left: 4px solid var(--primary);
}

/* Tasa banner */
.tasa-banner {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    border-radius: 16px;
    font-size: 14px;
    flex-wrap: wrap;
    gap: 10px;
    box-shadow: 0 10px 20px rgba(46, 204, 113, 0.2);
}

.tasa-banner button {
    background: rgba(255,255,255,0.05);
    color: var(--primary-dark);
    border: none;
    font-weight: 600;
}

/* Recibo */
.recibo {
    background: #ffffff !important;
    padding: 25px;
    font-family: 'Courier New', monospace;
    max-width: 320px;
    margin: 0 auto;
    font-size: 13px;
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    color: #111827 !important;
    color-scheme: light;
}

.recibo,
.recibo *,
.recibo p,
.recibo span,
.recibo div {
    color: #111827 !important;
    background-color: transparent;
}

.recibo-header {
    text-align: center;
    border-bottom: 2px dashed #374151;
    padding-bottom: 15px;
    margin-bottom: 15px;
    color: #111827 !important;
}

/* Loading */
.loading {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.9);
    justify-content: center;
    align-items: center;
    z-index: 3000;
    backdrop-filter: blur(3px);
}

.loading.active {
    display: flex;
}

.loading::after {
    content: '';
    width: 50px;
    height: 50px;
    border: 4px solid var(--light);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Mensajes flotantes */
.mensaje {
    position: fixed;
    bottom: 25px;
    right: 25px;
    padding: 15px 25px;
    border-radius: 50px;
    color: white;
    display: none;
    z-index: 2000;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.mensaje.exito { 
    background: var(--primary);
}
.mensaje.error { 
    background: var(--danger);
}
.mensaje.info { 
    background: #3498db;
}
.mensaje.advertencia {
    background: #f59e0b;
}

/* Métodos de pago */
.payment-method-btn {
    padding: 15px;
    border: 2px solid var(--border);
    border-radius: 12px;
    background: var(--white);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s;
}

.payment-method-btn:hover {
    border-color: var(--primary);
    background: rgba(46, 204, 113, 0.05);
    transform: translateY(-2px);
}

.payment-method-btn.selected {
    border-color: var(--primary);
    background: rgba(46, 204, 113, 0.1);
}

/* Tabs secundarios */
.secondary-tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
    flex-wrap: wrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.secondary-tab {
    padding: 12px 20px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
    font-weight: 500;
    transition: all 0.3s;
}

.secondary-tab:hover {
    color: var(--primary);
}

.secondary-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* Categorías */
.categorias-desktop {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.categorias-mobile {
    display: none;
    width: 100%;
}

.categorias-mobile select {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--primary);
    border-radius: 12px;
    font-size: 16px;
    background: var(--white);
    cursor: pointer;
}

/* Edición inline */
.editable {
    cursor: pointer;
    transition: background-color 0.2s;
}

.editable:hover {
    background-color: rgba(46, 204, 113, 0.05);
}

.editing-input {
    width: 100%;
    padding: 6px;
    border: 2px solid var(--primary);
    border-radius: 8px;
    font-size: 13px;
    outline: none;
    box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.1);
}

/* Badge pendientes */
.pendientes-badge {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: var(--secondary);
    color: white;
    padding: 15px 25px;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(243, 156, 18, 0.3);
    z-index: 100;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    border: none;
}

.pendientes-badge:hover {
    transform: scale(1.05);
    background: var(--secondary-dark);
}

/* ============================================= */
/* ESTILOS PARA VISTA MÓVIL - CON TABLA */
/* ============================================= */
.mobile-layout {
    display: none;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

.mobile-header {
    display: none;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: var(--gradient-main);
    border-bottom: none;
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 2px 10px rgba(26,111,196,0.3);
    min-height: 48px;
}

.mobile-logo {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.mobile-logo span {
    color: var(--primary);
}

.hamburger-btn {
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    padding: 4px 8px;
    color: #fff;
    line-height: 1;
    flex-shrink: 0;
}

/* Search inside mobile header */
.mobile-header input[type="text"] {
    flex: 1;
    min-width: 0;
    background: rgba(255,255,255,.15) !important;
    border-color: rgba(255,255,255,.3) !important;
    color: #fff !important;
}
.mobile-header input[type="text"]::placeholder { color: rgba(255,255,255,.6) !important; }
.mobile-header input[type="text"]:focus {
    background: rgba(255,255,255,.2) !important;
    border-color: rgba(255,255,255,.5) !important;
    outline: none;
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    background: var(--white);
    z-index: 1000;
    transition: left 0.3s ease;
    box-shadow: 2px 0 20px rgba(0,0,0,0.1);
    overflow-y: auto;
}

.mobile-menu.active {
    left: 0;
}

.mobile-menu-header {
    padding: 30px 20px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.mobile-menu-header .user-name {
    font-weight: bold;
    font-size: 18px;
    margin-bottom: 5px;
}

.mobile-menu-header .user-role {
    font-size: 14px;
    opacity: 0.9;
}

.mobile-menu-items {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-item {
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 16px;
    color: var(--text-primary);
    transition: all 0.2s;
}

.mobile-menu-item:hover {
    background: rgba(46, 204, 113, 0.05);
}

.mobile-menu-item.active {
    background: rgba(46, 204, 113, 0.1);
    color: var(--primary-dark);
    border-left: 4px solid var(--primary);
}

.mobile-menu-item span {
    font-size: 22px;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
    display: none;
    backdrop-filter: blur(3px);
}

.mobile-menu-overlay.active {
    display: block;
}

@media (max-width: 768px) {
    .main-header {
        display: none !important;
    }

    /* Ocultar barra de tabs de escritorio en móvil */
    .main-nav {
        display: none !important;
    }

    .mobile-header {
        display: flex !important;
    }

    .pos-layout {
        display: none;
    }

    .mobile-layout {
        display: block;
        padding: 0;
        width: 100%;
        overflow-x: hidden;
        box-sizing: border-box;
    }

    #mobileScreenProductos {
        width: 100%;
    }

    .products-mobile-grid {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin-bottom: 80px;
        width: 100%;
        box-sizing: border-box;
    }
    
    .product-mobile-card {
        background: var(--white);
        border-radius: 16px;
        padding: 15px 10px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
        cursor: pointer;
        transition: all 0.2s;
        border: 2px solid var(--border);
        width: 100%;
        box-sizing: border-box;
        display: flex;
        flex-direction: column;
    }
    
    .product-mobile-name {
        font-size: 14px;
        font-weight: 600;
        color: var(--text-primary);
        margin-bottom: 10px;
        white-space: normal;  /* CAMBIADO: ahora el texto puede wrap */
        overflow: visible;
        text-overflow: clip;
        line-height: 1.3;
        min-height: 36px;      /* Alto para 2 líneas */
        display: -webkit-box;
        -webkit-line-clamp: 2; /* Muestra hasta 2 líneas */
        -webkit-box-orient: vertical;
        word-break: break-word;
    }
    
    .product-mobile-price {
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 13px;
        gap: 5px;
        margin-bottom: 10px;
        flex-wrap: wrap;
    }
    
    .price-usd-mobile {
        background: rgba(46, 204, 113, 0.15);
        color: var(--primary-dark);
        padding: 5px 8px;
        border-radius: 20px;
        font-weight: 700;
        font-size: 12px;
        white-space: nowrap;
    }
    
    .price-bs-mobile {
        background: rgba(243, 156, 18, 0.15);
        color: var(--secondary-dark);
        padding: 5px 8px;
        border-radius: 20px;
        font-weight: 700;
        font-size: 12px;
        white-space: nowrap;
    }
    
    .product-mobile-stock {
        font-size: 11px;
        color: var(--text-secondary);
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding-top: 8px;
        border-top: 1px dashed var(--border);
        margin-top: auto;
    }
    
    .stock-badge {
        background: var(--light);
        padding: 3px 8px;
        border-radius: 20px;
        font-size: 10px;
        font-weight: 500;
    }
    
    .type-indicator {
        background: rgba(46, 204, 113, 0.1);
        color: var(--primary-dark);
        padding: 3px 8px;
        border-radius: 20px;
        font-size: 10px;
        font-weight: 600;
    }
    
    /* MOSTRAMOS LA TABLA */
    .mobile-table-container {
        background: var(--white);
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 4px 15px rgba(0,0,0,0.1);
        margin-bottom: 100px;
        border: 1px solid var(--border);
    }
    
    .mobile-table {
        width: 100%;
        border-collapse: collapse;
    }
    
    .mobile-table th {
        background: var(--primary);
        color: white;
        font-weight: 600;
        font-size: 13px;
        padding: 15px 10px;
        text-align: left;
        white-space: nowrap;
    }
    
    .mobile-table td {
        padding: 15px 10px;
        border-bottom: 1px solid var(--border);
        font-size: 13px;
        cursor: pointer;
    }
    
    .mobile-table tr:last-child td {
        border-bottom: none;
    }
    
    .mobile-table tr:active {
        background: rgba(46, 204, 113, 0.1);
    }
    
    .product-name-cell {
        font-weight: 600;
        color: var(--text-primary);
        max-width: 120px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .price-usd-cell {
        color: var(--primary-dark);
        font-weight: 700;
        white-space: nowrap;
    }
    
    .price-bs-cell {
        color: var(--secondary-dark);
        font-weight: 700;
        white-space: nowrap;
    }
    
    .stock-cell {
        text-align: center;
    }
    
    .stock-badge-mobile {
        background: var(--light);
        color: var(--text-secondary);
        padding: 4px 10px;
        border-radius: 20px;
        font-size: 11px;
        font-weight: 500;
        display: inline-block;
    }
    
    .type-badge {
        background: rgba(46, 204, 113, 0.1);
        color: var(--primary-dark);
        padding: 4px 10px;
        border-radius: 20px;
        font-size: 11px;
        font-weight: 600;
        display: inline-block;
    }
    
    /* Carrito flotante */
    .mobile-cart-fab {
        position: fixed;
        bottom: 20px;
        left: 15px;
        right: 15px;
        background: var(--primary);
        border-radius: 60px;
        padding: 15px 20px;
        box-shadow: 0 10px 30px rgba(46, 204, 113, 0.4);
        display: flex;
        justify-content: space-between;
        align-items: center;
        z-index: 100;
        border: 3px solid white;
        cursor: pointer;
        width: calc(100% - 30px);
        box-sizing: border-box;
    }
    
    .cart-info {
        display: flex;
        align-items: center;
        gap: 15px;
    }
    
    .cart-count {
        background: var(--secondary);
        color: white;
        width: 32px;
        height: 32px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: bold;
        font-size: 16px;
        box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    }
    
    .cart-total {
        font-weight: bold;
        color: white;
        font-size: 16px;
    }
    
    .cart-checkout {
        background: rgba(255,255,255,0.05);
        color: var(--primary-dark);
        padding: 8px 16px;
        border-radius: 30px;
        font-weight: 700;
        font-size: 14px;
        box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    }
    
    /* Modal del carrito */
    .mobile-cart-modal {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: var(--white);
        border-radius: 30px 30px 0 0;
        padding: 20px;
        max-height: 85vh;
        overflow-y: auto;
        z-index: 1000;
        transform: translateY(100%);
        transition: transform 0.3s ease-out;
        box-shadow: 0 -10px 30px rgba(0,0,0,0.15);
        width: 100%;
        box-sizing: border-box;
    }
    
    .mobile-cart-modal.active {
        transform: translateY(0);
    }
    
    .modal-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
        padding-bottom: 15px;
        border-bottom: 2px solid var(--border);
    }
    
    .modal-header h3 {
        font-size: 20px;
        color: var(--text-primary);
        margin: 0;
    }
    
    .close-modal {
        font-size: 28px;
        cursor: pointer;
        color: var(--gray);
    }
    
    .mobile-cart-items {
        max-height: 40vh;
        overflow-y: auto;
        margin-bottom: 20px;
    }
    
    .mobile-cart-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 15px;
        background: var(--light);
        border-radius: 16px;
        margin-bottom: 10px;
        border-left: 4px solid var(--primary);
    }
    
    .item-info {
        flex: 2;
    }
    
    .item-name {
        font-weight: 600;
        font-size: 15px;
        margin-bottom: 4px;
        color: var(--text-primary);
    }
    
    .item-price {
        font-size: 12px;
        color: var(--text-secondary);
    }
    
    .item-quantity {
        display: flex;
        align-items: center;
        gap: 10px;
        margin: 0 10px;
    }
    
    .qty-btn {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        border: none;
        background: var(--primary);
        color: white;
        font-weight: bold;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        box-shadow: 0 4px 10px rgba(46, 204, 113, 0.2);
    }
    
    .qty-btn.minus {
        background: var(--danger);
    }
    
    .qty-btn.delete {
        background: var(--gray);
    }
    
    .item-total {
        font-weight: bold;
        color: var(--primary-dark);
        min-width: 80px;
        text-align: right;
        font-size: 14px;
    }
    
    .cart-summary {
        background: var(--light);
        padding: 15px;
        border-radius: 16px;
        margin: 15px 0;
    }
    
    .summary-row {
        display: flex;
        justify-content: space-between;
        margin-bottom: 8px;
        font-size: 14px;
    }
    
    .summary-row.total {
        font-weight: bold;
        font-size: 18px;
        color: var(--primary-dark);
        border-top: 2px solid var(--border);
        padding-top: 12px;
        margin-top: 8px;
    }
    
    .cart-actions {
        display: flex;
        gap: 10px;
        margin-top: 15px;
    }
    
    .cart-actions button {
        flex: 1;
        padding: 16px;
        border: none;
        border-radius: 16px;
        font-weight: bold;
        cursor: pointer;
        font-size: 15px;
        transition: all 0.3s;
    }
    
    .btn-pay {
        background: var(--primary);
        color: white;
        box-shadow: 0 5px 15px rgba(46, 204, 113, 0.3);
    }
    
    .btn-hold {
        background: var(--secondary);
        color: white;
    }
    
    .btn-cancel {
        background: var(--danger);
        color: white;
    }
    
    .btn-credit {
        background: #9b59b6;
        color: white;
        width: 100%;
        padding: 16px;
        border: none;
        border-radius: 16px;
        font-weight: bold;
        cursor: pointer;
        font-size: 15px;
        margin-top: 10px;
        box-shadow: 0 5px 15px rgba(155, 89, 182, 0.3);
    }
    
    /* mobile-search moved to header */
    
    .weight-indicator {
        background: var(--secondary);
        color: white;
        padding: 3px 8px;
        border-radius: 12px;
        font-size: 11px;
        margin-left: 5px;
    }
}

/* Lista de productos móvil - override para vista lista */
@media (max-width: 768px) {
    .products-mobile-grid {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Sin fondo morado — pantalla completa blanca */
    body {
        background: #fff !important;
    }

    .app-container {
        background: rgba(255,255,255,0.05);
        min-height: 100vh;
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    /* Sin margen ni padding extra en contenedores raíz */
    .tab-content,
    #tab-pos,
    #tab-dashboard,
    #tab-ventas,
    #tab-productos,
    #tab-clientes,
    #tab-inventario,
    #tab-reportes,
    #tab-configuracion,
    #tab-usuarios {
        padding: 0 !important;
        margin: 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* ============================================= */
/* ESTILOS MODERNOS - MEJORAS VISUALES */
/* ============================================= */

/* Tarjetas más modernas */
.dashboard-card, .table-container, .cart-section {
    border-radius: 20px;
    border: none;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05), 0 8px 10px -6px rgba(0,0,0,0.02);
    transition: all 0.3s ease;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 30px -10px rgba(102, 126, 234, 0.15);
}

/* Tablas más elegantes */
th {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

/* Botones con gradientes */
.btn-success {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.btn-success:hover {
    background: linear-gradient(135deg, #5a67d8 0%, #6a3e8a 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(102, 126, 234, 0.4);
}

.btn-info {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border: none;
}

.btn-warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    border: none;
}

.btn-danger {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    border: none;
}

/* Badges más modernos */
.badge {
    padding: 6px 12px;
    border-radius: 30px;
    font-weight: 500;
    font-size: 11px;
}

.badge-success {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.badge-warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
}

/* Header más moderno */
.main-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-bottom: 1px solid rgba(102, 126, 234, 0.2);
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.logo span {
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* Tabs más elegantes */
.nav-tab {
    color: #7f8c8d;
}


.nav-tab.active {
    color: #2ecc71;
    border-bottom-color: #2ecc71;
}

.nav-tab.active::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 3px;
}

/* Product cards */
.product-card {
    border-radius: 16px;
    transition: all 0.3s ease;
}

.product-card:hover {
    border-color: #667eea;
    box-shadow: 0 10px 25px -5px rgba(102, 126, 234, 0.2);
}

.price-usd {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
}

.price-bs {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.1), rgba(230, 126, 34, 0.1));
}

/* Modales con efecto glassmorphism */
.modal-content {
    backdrop-filter: blur(10px);
    background: rgba(255,255,255,0.98);
    border: none;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
}

/* Inputs más modernos */
.form-group input, .form-group select, .form-group textarea {
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.3s;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

/* Scrollbar personalizado */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #5a67d8;
}

/* Animaciones suaves */
.tab-content, .modal-content, .dashboard-card {
    animation: fadeInUp 0.4s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Carrito mejorado */
.cart-section {
    background: linear-gradient(135deg, #ffffff 0%, #fefefe 100%);
    border: none;
}

.cart-item {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-left: 4px solid #667eea;
}

/* Botones del carrito */
.btn-pay, .btn-hold, .btn-cancel, .btn-credit {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: all 0.3s;
}

.btn-pay:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(102, 126, 234, 0.4);
}

/* ── Safe area para Android/iOS (barra de navegación) ── */
@media (max-width: 768px) {
    #mobileScreenCarrito,
    #mobileScreenPago {
        padding-bottom: max(16px, env(safe-area-inset-bottom));
    }

    /* Forzar que el contenido inferior no quede tapado */
    #mobileScreenCarrito > div:last-child,
    #mobileScreenPago > div:last-child {
        padding-bottom: max(18px, env(safe-area-inset-bottom));
    }
}

/* ── Dashboard: móvil vs desktop ── */
@media (max-width: 768px) {
    #dashboardMovil  { display: block !important; }
    #dashboardDesktop { display: none !important; }
}
@media (min-width: 769px) {
    #dashboardMovil  { display: none !important; }
    #dashboardDesktop { display: block !important; }
}

/* ── Configuración menu items ── */
.cfg-item {
    padding: 9px 12px;
    cursor: pointer;
    border-radius: 8px;
    font-size: 13px;
    color: #555;
    margin-bottom: 2px;
    transition: background .15s, color .15s;
}
.cfg-item:hover  { background: #f0f7ff; color: #2980b9; }
.cfg-item.active { background: #e8f5e9; color: #27ae60; font-weight: 600; }

/* ── Responsive productos tab ── */
@media (max-width: 768px) {
    .hide-mobile { display: none !important; }

    /* Toolbar: buscador full width, selects debajo */
    #tab-productos > div:first-child {
        flex-wrap: wrap !important;
    }
    #tab-productos .search-box {
        max-width: 100% !important;
        width: 100% !important;
        order: 1;
    }
    #selectCategoriaProducto,
    #filtroEstadoProducto {
        flex: 1;
        order: 2;
        min-width: 120px;
    }
    #tab-productos > div:first-child > div:last-child {
        order: 3;
        width: 100%;
        justify-content: flex-end;
    }
}

@media (min-width: 769px) {
    .hide-mobile { display: table-cell; }
}

/* ── Product row hover ── */
.prod-row:hover { background: #fafafa; }
.prod-row { transition: background .15s; }

/* ── Accent orange highlights ── */
.btn-warning, .btn-accent {
    background: var(--gradient-accent) !important;
    border-color: var(--accent-dark) !important;
    color: #fff !important;
}

/* Mobile cart FAB - orange */
.mobile-cart-fab {
    background: var(--gradient-accent) !important;
}

/* cfg-item hover blue */
.cfg-item:hover  { background: #eff6ff; color: var(--primary); }
.cfg-item.active { background: #dbeafe; color: var(--primary-dark); font-weight:600; }

/* Tab content area */
.tab-content {
    background: var(--background);
}

/* Cards and containers */
.dashboard-card {
    border-top: 3px solid var(--primary);
}

/* ── Responsive header & nav ──────────────────────────── */
.hide-sm { display: inline-block; }

/* Tablet */
@media (max-width: 1024px) {
    .main-header { padding: 0 16px; }
    .nav-tab { padding: 14px 12px; font-size: 11px; }
}

/* Mobile — hide desktop header, show mobile header */
@media (max-width: 768px) {
    .main-header  { display: none !important; }
    .main-nav     { display: none !important; }
    .mobile-header{ display: flex !important; }
    .hide-sm      { display: none !important; }

    /* Tab content full width */
    .tab-content  { padding: 12px 8px !important; }

    /* Tables scroll horizontal */
    .table-container { overflow-x: auto; }
    table { min-width: 500px; }

    /* Cards stack */
    .stats-grid,
    .dashboard-cards {
        grid-template-columns: 1fr 1fr !important;
    }
}

/* Small mobile */
@media (max-width: 480px) {
    .stats-grid,
    .dashboard-cards {
        grid-template-columns: 1fr !important;
    }
}

/* Login page keep gradient */
#loginContainer {
    background: var(--gradient-main);
    min-height: 100vh;
}
/* ── MÓDULO CRÉDITOS ──────────────────────────────────────── */
.cred-stat-card {
    background: rgba(15,32,68,0.8);
    border: 1px solid rgba(99,179,253,0.2);
    border-radius: 16px;
    padding: 18px 16px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.05) inset;
}
.cred-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 48px rgba(0,0,0,0.5), 0 0 0 1px rgba(99,179,253,0.2) inset;
}
.cred-stat-ico {
    width:40px;height:40px;border-radius:12px;
    display:flex;align-items:center;justify-content:center;
    font-size:18px;margin:0 auto 12px;
}
.cred-stat-val {
    font-size:26px;font-weight:900;color:#ffffff !important;
    line-height:1;
    text-shadow: 0 2px 8px rgba(0,0,0,0.6);
    letter-spacing:-0.5px;
}
.cred-stat-lbl {
    font-size:11px;color:rgba(148,163,184,0.9);
    margin-top:6px;text-transform:uppercase;letter-spacing:.06em;
    font-weight:600;
}
.cred-val-danger  { color:#ff6b6b !important; text-shadow: 0 2px 12px rgba(239,68,68,0.5) !important; }
.cred-val-success { color:#6ee7a0 !important; text-shadow: 0 2px 12px rgba(34,197,94,0.5) !important; }

.cred-filtro-btn {
    padding: 7px 14px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    color: #c0cfe8;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}
.cred-filtro-btn:hover { background: rgba(255,255,255,0.1); color: #e2e8f0; }
.cred-filtro-btn.active { background: linear-gradient(135deg,#1e40af,#2563eb); color: #fff; border-color: transparent; box-shadow: 0 4px 12px rgba(37,99,235,0.35); }

.cred-row { cursor: pointer; transition: background 0.15s; }
.cred-row:hover { background: rgba(56,139,253,0.08) !important; }

.cred-badge { display:inline-block;padding:3px 10px;border-radius:20px;font-size:11px;font-weight:700;letter-spacing:.03em; }
.cred-badge-ok     { background:rgba(34,197,94,0.15);color:#4ade80; }
.cred-badge-danger { background:rgba(239,68,68,0.15);color:#f87171; }
.cred-badge-warn   { background:rgba(245,158,11,0.15);color:#fbbf24; }
.cred-badge-info   { background:rgba(59,130,246,0.15);color:#60a5fa; }

.cred-btn-pago {
    padding: 5px 10px;
    background: linear-gradient(135deg,#16a34a,#22c55e);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    margin-right: 4px;
    font-family: inherit;
    white-space: nowrap;
}
.cred-btn-ver {
    padding: 5px 10px;
    background: rgba(59,130,246,0.2);
    color: #60a5fa;
    border: 1px solid rgba(59,130,246,0.3);
    border-radius: 8px;
    font-size: 12px;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}

/* Detalle modal */
.cred-detalle-header {
    padding: 20px 24px;
    background: rgba(37,99,235,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.07);
}
.cred-detalle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px,1fr));
    gap: 1px;
    background: rgba(255,255,255,0.05);
    border-top: 1px solid rgba(255,255,255,0.07);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    margin-bottom: 0;
}
.cred-mini-stat {
    padding: 16px 20px;
    background: rgba(10,22,40,0.5);
}
.cred-mini-label { font-size:11px;color:#a8b8d0;text-transform:uppercase;letter-spacing:.05em;margin-bottom:4px; }
.cred-mini-value { font-size:20px;font-weight:800;color:#f1f5f9; }

.cred-seccion {
    padding: 16px 24px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.cred-seccion-titulo {
    font-size: 12px;
    font-weight: 700;
    color: #a8b8d0;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-bottom: 12px;
}

.cred-pago-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.cred-pago-row:last-child { border-bottom: none; }

.cred-btn-pago-full {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg,#16a34a,#22c55e);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    box-shadow: 0 4px 20px rgba(34,197,94,0.3);
    transition: all 0.2s;
}
.cred-btn-pago-full:hover { transform: translateY(-1px); box-shadow: 0 8px 28px rgba(34,197,94,0.4); }