* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, sans-serif;
}

body {
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* ====== LOGIN / REGISTRO ====== */
.auth-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    width: 100%;
    max-width: 420px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-container h2 {
    text-align: center;
    color: #333;
    margin-bottom: 10px;
    font-size: 28px;
}

.auth-container .subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
    font-size: 14px;
}

.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s;
    background: #f9f9f9;
}

.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn {
    width: 100%;
    padding: 13px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    margin-top: 10px;
}

.links {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
}

.links a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.links a:hover {
    text-decoration: underline;
}

/* ====== MENSAJES ====== */
.alert {
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-error {
    background: #fee;
    color: #c33;
    border-left: 4px solid #c33;
}

.alert-success {
    background: #efe;
    color: #3a3;
    border-left: 4px solid #3a3;
}

.error-field {
    color: #c33;
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

.input-error {
    border-color: #c33 !important;
}

/* ====== DASHBOARD ====== */
.dashboard {
    width: 100%;
    min-height: 100vh;
    background: #f4f6f9;
}

.navbar {
    background: linear-gradient(135deg, #667eea, #764ba2);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.navbar h1 {
    color: white;
    font-size: 22px;
}

.navbar .user-info {
    color: white;
    display: flex;
    align-items: center;
    gap: 15px;
}

.navbar a {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    background: rgba(255,255,255,0.2);
    border-radius: 8px;
    transition: all 0.3s;
}

.navbar a:hover {
    background: rgba(255,255,255,0.3);
}

.menu-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 40px 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.menu-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s;
    cursor: pointer;
    text-decoration: none;
    color: #333;
}

.menu-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.2);
}

.menu-card .icon {
    font-size: 50px;
    margin-bottom: 15px;
}

.menu-card h3 {
    color: #333;
    margin-bottom: 10px;
}

.menu-card p {
    color: #777;
    font-size: 14px;
}

/* ====== TABLAS ====== */
.content-box {
    background: white;
    margin: 30px;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
}

.content-box h2 {
    margin-bottom: 20px;
    color: #333;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table th, table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

table th {
    background: #667eea;
    color: white;
    font-weight: 600;
}

table tr:hover {
    background: #f9f9f9;
}

.badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-success { background: #d4edda; color: #155724; }
.badge-warning { background: #fff3cd; color: #856404; }

/* ====== RESPONSIVE ====== */
@media (max-width: 768px) {
    .auth-container {
        padding: 30px 20px;
    }
    
    .navbar {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .navbar h1 {
        font-size: 18px;
    }
    
    .content-box {
        margin: 15px;
        padding: 20px;
    }
    
    table {
        font-size: 13px;
    }
    
    table th, table td {
        padding: 8px;
    }
    
    .menu-container {
        padding: 20px 15px;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .auth-container h2 {
        font-size: 22px;
    }
    
    .btn {
        font-size: 14px;
        padding: 11px;
    }
}
/* Estilos adicionales para el POS */
.codigo-display {
    font-family: 'Courier New', monospace;
    font-size: 16px;
    letter-spacing: 1px;
}

.scanner-input {
    width: 100%;
    padding: 20px;
    font-size: 24px;
    border: 3px solid #667eea;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 15px;
}

.cantidad-input {
    width: 150px;
    padding: 15px;
    font-size: 20px;
    border: 2px solid #ddd;
    border-radius: 10px;
    text-align: center;
}