/* Estilos personalizados MINIMOS para el sistema de ventas */

/* Solo para componentes específicos que no pueden manejarse con Tailwind */
.cliente-autocomplete {
    position: relative;
}

.cliente-autocomplete-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: white;
    border: 1px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 0.5rem 0.5rem;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.cliente-autocomplete-result {
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #e5e7eb;
}

.cliente-autocomplete-result:hover {
    background-color: #f3f4f6;
}

.cliente-autocomplete-result:last-child {
    border-bottom: none;
}

.cliente-autocomplete-create {
    padding: 8px 12px;
    cursor: pointer;
    font-style: italic;
    color: #3b82f6;
    text-align: center;
    border-bottom: 1px solid #e5e7eb;
}

.cliente-autocomplete-create:hover {
    background-color: #f3f4f6;
}

/* Estilos para Modales */
.modal {
    display: none; /* Ocultos por defecto */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 20px;
    border: 1px solid #888;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    animation: slideIn 0.3s;
    max-height: 90vh;
    overflow-y: auto;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Animaciones personalizadas */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Tarjetas de pasajeros (solo si se necesitan) */
.pasajero-item {
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Estilos para sidebar colapsado */
#sidebar:not(.w-64) .sidebar-item {
    width: 48px;
    height: 48px;
    margin: 4px auto;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#sidebar:not(.w-64) .sidebar-item svg {
    width: 24px !important;
    height: 24px !important;
}

#sidebar:not(.w-64) .sidebar-content {
    text-align: center;
}

#sidebar:not(.w-64) .sidebar-content h1 {
    font-size: 0.875rem;
    margin-bottom: 8px;
}

/* Íconos para sidebar colapsado */
#sidebar:not(.w-64) .sidebar-icon-replacement {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 4px auto;
    border-radius: 12px;
    position: relative;
}

#sidebar:not(.w-64) .sidebar-icon-replacement svg {
    width: 24px !important;
    height: 24px !important;
}

/* Tooltip para sidebar colapsado */
#sidebar:not(.w-64) .sidebar-item,
#sidebar:not(.w-64) .sidebar-icon-replacement {
    position: relative;
}

#sidebar:not(.w-64) .sidebar-item::after,
#sidebar:not(.w-64) .sidebar-icon-replacement::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 8px;
    background-color: #1f2937;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    z-index: 1000;
}

#sidebar:not(.w-64) .sidebar-item:hover::after,
#sidebar:not(.w-64) .sidebar-icon-replacement:hover::after {
    opacity: 1;
}

/* Ocultar textos en sidebar colapsado */
#sidebar:not(.w-64) .sidebar-text {
    display: none;
}

#sidebar:not(.w-64) .bg-gray-700 {
    padding: 8px !important;
    text-align: center;
}

/* Mostrar íconos de reemplazo solo en sidebar colapsado */
.sidebar-icon-replacement {
    display: none;
}

#sidebar:not(.w-64) .sidebar-icon-replacement {
    display: flex;
}