/* Estilos personalizados para el Sistema de Cotizaciones */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

.jumbotron {
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease-in-out;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.btn:hover {
    transform: translateY(-1px);
}

.form-control {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: border-color 0.2s ease-in-out;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.table {
    border-radius: 10px;
    overflow: hidden;
}

.table thead th {
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.5px;
}

.badge {
    font-size: 0.75rem;
    padding: 0.5em 0.75em;
}

/* Estilos específicos para cotizaciones */
.cotizacion-header {
    border-bottom: 3px solid var(--danger-color);
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.empresa-logo {
    color: var(--danger-color);
    font-weight: bold;
    font-size: 2rem;
    line-height: 1.2;
}

.cotizacion-info {
    background-color: var(--light-color);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    border-left: 4px solid var(--primary-color);
}

.servicios-table {
    border: 2px solid #000;
    border-radius: 8px;
    overflow: hidden;
    border-collapse: collapse;
}

.servicios-table th {
    background-color: var(--light-color);
    border: none;
    border-bottom: 1px solid #000;
    border-right: 1px solid #000;
    text-align: center;
    font-weight: bold;
    padding: 12px;
}

.servicios-table td {
    border: none;
    border-right: 1px solid #000;
    padding: 12px;
    vertical-align: middle;
}

.servicios-table th:last-child,
.servicios-table td:last-child {
    border-right: none;
}

.totales {
    margin-top: 20px;
}

.total-row {
    font-weight: bold;
    font-size: 1.1rem;
    background-color: var(--light-color);
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 350px;
}

.toast {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
    overflow: hidden;
    transform: translateX(100%);
    transition: all 0.3s ease-in-out;
    border-left: 4px solid var(--primary-color);
}

.toast.show {
    transform: translateX(0);
}

.toast.hide {
    transform: translateX(100%);
    opacity: 0;
}

.toast-success {
    border-left-color: var(--success-color);
}

.toast-danger {
    border-left-color: var(--danger-color);
}

.toast-warning {
    border-left-color: var(--warning-color);
}

.toast-info {
    border-left-color: var(--info-color);
}

.toast-header {
    background: rgba(0, 0, 0, 0.03);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.toast-icon {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 12px;
    color: white;
}

.toast-success .toast-icon {
    background-color: var(--success-color);
}

.toast-danger .toast-icon {
    background-color: var(--danger-color);
}

.toast-warning .toast-icon {
    background-color: var(--warning-color);
}

.toast-info .toast-icon {
    background-color: var(--info-color);
}

.toast-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--dark-color);
    margin: 0;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--secondary-color);
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.toast-close:hover {
    color: var(--dark-color);
}

.toast-body {
    padding: 12px 16px;
    font-size: 14px;
    color: var(--dark-color);
    line-height: 1.4;
}

.toast-progress {
    height: 3px;
    background: rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.toast-progress-bar {
    height: 100%;
    background: var(--primary-color);
    width: 100%;
    transform-origin: left;
    animation: toast-progress 5s linear forwards;
}

.toast-success .toast-progress-bar {
    background: var(--success-color);
}

.toast-danger .toast-progress-bar {
    background: var(--danger-color);
}

.toast-warning .toast-progress-bar {
    background: var(--warning-color);
}

.toast-info .toast-progress-bar {
    background: var(--info-color);
}

@keyframes toast-progress {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

/* Responsive toast */
@media (max-width: 768px) {
    .toast-container {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .toast {
        margin-bottom: 8px;
    }
}

/* Estilos para formularios dinámicos */
.servicio-item {
    background-color: white;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    margin-bottom: 15px;
    transition: all 0.2s ease-in-out;
}

.servicio-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.remove-servicio {
    margin-top: 32px;
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .empresa-logo {
        font-size: 1.5rem;
        text-align: center;
    }
    
    .cotizacion-header {
        text-align: center;
    }
    
    .btn-group {
        flex-direction: column;
    }
    
    .btn-group .btn {
        margin-bottom: 5px;
    }
}

/* Estilos para impresión */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        background-color: white;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .btn {
        display: none;
    }
}

/* Estilos para alertas personalizadas */
.alert {
    border-radius: 10px;
    border: none;
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1, #bee5eb);
    color: #0c5460;
}

.alert-success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    color: #155724;
}

.alert-warning {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    color: #856404;
}

.alert-danger {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    color: #721c24;
}

/* Efectos de hover para botones */
.btn-primary:hover {
    background-color: #0056b3;
    border-color: #004085;
}

.btn-success:hover {
    background-color: #157347;
    border-color: #146c43;
}

.btn-danger:hover {
    background-color: #bb2d3b;
    border-color: #b02a37;
}

/* Estilos para loading */
.loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* Estilos específicos para cotización */
.cotizacion-header {
    border-bottom: 3px solid #dc3545;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.empresa-logo {
    color: #dc3545;
    font-weight: bold;
    font-size: 2rem;
}

.cotizacion-info {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}



.totales {
    margin-top: 20px;
}

.total-row {
    font-weight: bold;
}

@media print {
    .no-print {
        display: none;
    }
}