* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    color: #333;
}

/* Estilos para la página de Login */
.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    max-width: 400px;
    width: 100%;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-logo {
    width: 100px;
    height: 100px;
    margin-bottom: 20px;
    border-radius: 20px;
}

.login-box h2 {
    margin-bottom: 25px;
    color: #2c3e50;
    font-weight: 300;
}

.hidden {
    display: none;
}

.login-switch {
    margin-top: 20px;
    font-size: 0.9rem;
}

.btn-link {
    background: none;
    border: none;
    color: #3498db;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
    font-size: 0.9rem;
}

/* Estilos de la app principal */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 2.5rem;
    font-weight: 300;
}

.menu {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.menu-btn {
    flex: 1;
    text-align: center;
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.menu-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
}

.menu-btn.active {
    background: #2c3e50;
    box-shadow: 0 4px 15px rgba(44, 62, 80, 0.3);
}

.menu-btn.disabled {
    background: #bdc3c7;
    cursor: not-allowed;
    box-shadow: none;
    flex-grow: 1;
}

.menu-btn.disabled:hover {
    background: #bdc3c7;
    transform: none;
}

.section {
    display: none;
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

.section.active {
    display: block;
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    text-align: left;
}

input, textarea, select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e6ed;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 10px;
    margin-bottom: 10px;
}

.btn:hover {
    background: #2980b9;
    transform: translateY(-1px);
}

.btn-danger { background: #e74c3c; }
.btn-danger:hover { background: #c0392b; }
.btn-success { background: #27ae60; }
.btn-success:hover { background: #229954; }
.btn-small { padding: 8px 16px; font-size: 0.9rem; margin-right: 0; }

.cotizacion-container { display: grid; grid-template-columns: 1fr 1.2fr; gap: 30px; }
.cotizacion-form, .cotizacion-preview { background: #f8f9fa; padding: 20px; border-radius: 10px; }
.cotizacion-preview { display: flex; flex-direction: column; }
#cotizacion-lista-items { flex-grow: 1; border: 2px dashed #e0e6ed; border-radius: 8px; padding: 15px; margin-bottom: 20px; min-height: 200px; }
.cotizacion-item { display: flex; justify-content: space-between; align-items: center; padding: 10px; border-bottom: 1px solid #e9ecef; }
.cotizacion-item:last-child { border-bottom: none; }
.cotizacion-item-nombre { flex-grow: 1; }
.cotizacion-item-valor { font-weight: 600; margin-left: 15px; }
.cotizacion-item-eliminar { background: #e74c3c; color: white; border: none; border-radius: 50%; width: 25px; height: 25px; cursor: pointer; margin-left: 15px; font-weight: bold; line-height: 25px; text-align: center; }
#cotizacion-resumen { margin-bottom: 20px; border-top: 1px solid #e0e6ed; padding-top: 15px; }
.resumen-fila { display: flex; justify-content: space-between; padding: 8px 0; font-size: 1.1rem; }
.resumen-fila.total { font-size: 1.4rem; font-weight: bold; color: #27ae60; border-top: 2px solid #2c3e50; margin-top: 10px; padding-top: 10px; }
.cotizacion-actions { display: flex; justify-content: space-between; }
.cliente-item { background: white; border: 1px solid #e9ecef; border-radius: 10px; margin-bottom: 15px; overflow: hidden; transition: all 0.3s ease; }
.cliente-item:hover { box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); }
.cliente-header { display: flex; justify-content: space-between; align-items: center; padding: 20px; background: #f8f9fa; }
.cliente-numero { background: #3498db; color: white; width: 35px; height: 35px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 1.1rem; }
.cliente-nombre { flex: 1; margin: 0 20px; font-size: 1.2rem; font-weight: 600; color: #2c3e50; }
.btn-ver-info { background: #3498db; color: white; border: none; padding: 10px 20px; border-radius: 8px; font-size: 0.9rem; font-weight: 500; cursor: pointer; transition: all 0.3s ease; }
.btn-ver-info:hover { background: #2980b9; transform: translateY(-1px); }
.cliente-details { display: none; padding: 0; background: white; border-top: 1px solid #e9ecef; animation: slideDown 0.3s ease; }
.cliente-details.show { display: block; }
@keyframes slideDown { from { opacity: 0; max-height: 0; } to { opacity: 1; max-height: 1000px; } }
.cliente-info { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 15px; margin: 20px; }
.info-item { background: #f8f9fa; padding: 15px; border-radius: 8px; border-left: 4px solid #3498db; }
.info-label { font-weight: 600; color: #2c3e50; font-size: 0.9rem; margin-bottom: 5px; }
.info-value { color: #34495e; }
.observaciones { background: #f8f9fa; padding: 15px; border-radius: 8px; border-left: 4px solid #f39c12; margin: 0 20px 20px; }
.cliente-actions { padding: 20px; border-top: 1px solid #e9ecef; background: #f8f9fa; }
.producto-item { background: white; border: 1px solid #e9ecef; border-radius: 10px; padding: 20px; margin-bottom: 15px; display: flex; justify-content: space-between; align-items: center; transition: all 0.3s ease; }
.producto-item:hover { box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); transform: translateY(-1px); }
.producto-info { flex: 1; }
.producto-nombre { font-size: 1.2rem; font-weight: 600; color: #2c3e50; margin-bottom: 5px; }
.producto-valor { font-size: 1.1rem; color: #27ae60; font-weight: 600; }
.producto-actions { display: flex; gap: 10px; }
.modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.5); z-index: 1000; animation: fadeIn 0.3s ease; }
.modal.show { display: flex; align-items: center; justify-content: center; }
.modal-content { background: white; padding: 30px; border-radius: 15px; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2); text-align: center; max-width: 400px; width: 90%; animation: slideIn 0.3s ease; }
@keyframes slideIn { from { transform: translateY(-50px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal h3 { color: #27ae60; margin-bottom: 15px; font-size: 1.5rem; }
.modal p { color: #7f8c8d; margin-bottom: 25px; font-size: 1.1rem; }
.modal-buttons { display: flex; gap: 15px; justify-content: center; flex-wrap: wrap; }
.modal-btn { background: #3498db; color: white; border: none; padding: 12px 25px; border-radius: 8px; font-size: 1rem; font-weight: 500; cursor: pointer; transition: all 0.3s ease; min-width: 150px; }
.modal-btn:hover { transform: translateY(-2px); box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3); }
.modal-btn.secondary { background: #95a5a6; }
.modal-btn.secondary:hover { background: #7f8c8d; box-shadow: 0 4px 15px rgba(149, 165, 166, 0.3); }
.modal-edit { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.5); z-index: 1000; animation: fadeIn 0.3s ease; }
.modal-edit.show { display: flex; align-items: center; justify-content: center; }
.modal-edit-content { background: white; padding: 30px; border-radius: 15px; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2); max-width: 500px; width: 90%; animation: slideIn 0.3s ease; }
.modal-edit h3 { color: #2c3e50; margin-bottom: 20px; font-size: 1.3rem; text-align: center; }
.modal-edit .form-group { margin-bottom: 20px; }
.modal-edit-buttons { display: flex; gap: 15px; justify-content: center; margin-top: 25px; }
.modal-edit-btn { padding: 12px 25px; border: none; border-radius: 8px; font-size: 1rem; font-weight: 500; cursor: pointer; transition: all 0.3s ease; min-width: 120px; }
.modal-edit-btn.save { background: #27ae60; color: white; }
.modal-edit-btn.save:hover { background: #229954; transform: translateY(-1px); }
.modal-edit-btn.cancel { background: #95a5a6; color: white; }
.modal-edit-btn.cancel:hover { background: #7f8c8d; transform: translateY(-1px); }
.no-clientes { text-align: center; color: #7f8c8d; font-style: italic; padding: 40px 0; }
.search-box { margin-bottom: 20px; }
.search-box input { width: 100%; padding: 15px; border: 2px solid #e0e6ed; border-radius: 50px; font-size: 1rem; background: #f8f9fa; }
@media (max-width: 992px) { .cotizacion-container { grid-template-columns: 1fr; } }
@media (max-width: 768px) { .container { padding: 10px; } h1 { font-size: 2rem; } .menu { flex-direction: column; align-items: center; } .menu-btn { width: 100%; max-width: 300px; flex: auto; } .cliente-info { grid-template-columns: 1fr; } .modal-buttons { flex-direction: column; } .modal-btn { min-width: auto; width: 100%; } }
