/* Estilos generales */
.bbs-client-booking-form-container {
    background: #fff;
    padding: 20px;
    margin: 20px 0;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding-top: 20px;
}

.booking-details-summary {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.booking-steps {
    margin-top: 20px;
}

.booking-step {
    display: none;
    margin-bottom: 20px;
    margin-top: 20px;
    padding-top: 20px;
}

.booking-step.active {
    display: block;
}

.booking-step h3 {
    margin-top: 0;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

/* Filtros y búsqueda */
.services-filters {
    display: none !important;
}

.services-filters input,
.services-filters select {
    flex: 1;
    min-width: 0;
}

/* Lista de servicios */
.services-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
    margin-top: 20px;
}

.service-item {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 15px;
    transition: all 0.3s ease;
}

.service-item:hover {
    border-color: #2271b1;
}

.service-item.selected {
    background-color: #f0f6fc;
    border-color: #2271b1;
}

.service-item label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
}

.service-info {
    flex: 1;
    min-width: 0;
}

.service-info h4 {
    margin: 0 0 5px 0;
    font-size: 16px;
}

.service-meta {
    display: flex;
    gap: 15px;
    color: #666;
    font-size: 0.9em;
}

/* Resumen de servicios */
.services-summary {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    margin-bottom: 20px;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #eee;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.services-summary h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
    border-bottom: none;
    padding-bottom: 0;
}

.summary-content {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.summary-content p {
    margin: 0;
}

/* Controles de cantidad */
.service-quantity {
    margin-top: 12px;
    padding: 8px 12px;
    background: #f0f6fc;
    border-radius: 4px;
    max-width: 150px;
    display: none;
}

.service-item.selected .service-quantity {
    display: flex;
    align-items: center;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.quantity-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    padding: 0;
    background: #fff;
    border: 1px solid #2271b1;
    border-radius: 4px;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    color: #2271b1;
    transition: all 0.2s ease;
}

.quantity-btn:hover:not(:disabled) {
    background: #f6f7f7;
    border-color: #135e96;
    color: #135e96;
}

.quantity-btn:active:not(:disabled) {
    background: #f0f0f1;
    border-color: #135e96;
    box-shadow: inset 0 2px 5px -3px rgba(0, 0, 0, 0.5);
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: #c3c4c7;
    color: #a7aaad;
}

.service-quantity-input {
    width: 45px !important;
    height: 28px !important;
    text-align: center !important;
    border: 1px solid #2271b1 !important;
    border-radius: 4px !important;
    padding: 0 !important;
    margin: 0 !important;
    font-size: 14px !important;
    line-height: 28px !important;
    -moz-appearance: textfield !important;
}

.service-quantity-input::-webkit-outer-spin-button,
.service-quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Zonas de envío */
.shipping-zone-wrapper {
    margin-bottom: 15px;
}

.shipping-zone-wrapper select {
    width: 100%;
    max-width: 400px;
}

.shipping-zone-wrapper .description {
    margin-top: 5px;
    color: #666;
    font-style: italic;
}

.zone-message {
    margin-top: 10px;
    padding: 10px;
    border-radius: 4px;
}

.zone-message.success {
    background-color: #f0f9eb;
    color: #67c23a;
    border: 1px solid #c2e7b0;
}

.zone-message.error {
    background-color: #fef0f0;
    color: #f56c6c;
    border: 1px solid #fbc4c4;
}

/* Lista de empleados */
.employee-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.employee-card {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 15px;
    background: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.employee-card:hover {
    border-color: #2271b1;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.employee-card.selected {
    background-color: #f0f6fc;
    border-color: #2271b1;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.employee-info h3 {
    margin: 0 0 10px 0;
    padding: 0;
    border: none;
    font-size: 16px;
}

.employee-schedule {
    margin-top: 10px;
    font-size: 0.9em;
    color: #666;
}

/* Calendario y selección de hora */
.date-selection {
    display: none;
}

.date-time-selection {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 15px;
}

.date-picker-wrapper {
    min-width: 280px;
}

.booking-calendar-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
}

.time-slots {
    flex: 1;
    min-width: 280px;
}

.time-slots h4 {
    margin-top: 0;
    margin-bottom: 15px;
}

.time-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    gap: 10px;
}

.time-slot {
    text-align: center;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.time-slot:hover:not(.disabled) {
    background-color: #f0f6fc;
    border-color: #2271b1;
}

.time-slot.selected {
    background-color: #2271b1;
    color: #fff;
    border-color: #2271b1;
}

.time-slot.disabled {
    background-color: #f5f5f5;
    color: #999;
    cursor: not-allowed;
    opacity: 0.7;
}

/* Botones de navegación */
.form-actions {
    position: sticky;
    top: 80px;
    z-index: 99;
    background: #fff;
    padding: 15px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.form-actions button {
    min-height: 40px;
}

/* Tabla de citas */
.bbs-client-bookings {
    margin-bottom: 40px !important;
    padding: 40px 30px !important;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    max-width: 1100px;
    margin-left: auto !important;
    margin-right: auto !important;
}

.bbs-bookings-table-wrapper {
    overflow-x: auto;
    margin-top: 30px !important;
    padding: 20px 0 20px 0 !important;
}

.woocommerce-orders-table {
    margin: 0 auto !important;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    background: #fafbfc;
    padding: 16px !important;
}

.woocommerce-orders-table th, .woocommerce-orders-table td {
    padding: 16px 20px !important;
}

.woocommerce-orders-table th {
    background: #f0f6fc;
    color: #333;
}

.woocommerce-orders-table tr {
    border-bottom: 1px solid #eaeaea;
}

.woocommerce-orders-table tr:last-child {
    border-bottom: none;
}

.booking-status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 0.85em;
    font-weight: 500;
}

.status-pending {
    background-color: #ffecb5;
    color: #805b00;
}

.status-confirmed {
    background-color: #cce5ff;
    color: #004085;
}

.status-completed {
    background-color: #d4edda;
    color: #155724;
}

.status-cancelled {
    background-color: #f8d7da;
    color: #721c24;
}

.status-on-hold {
    background-color: #e9ecef;
    color: #495057;
}

.status-blocked {
    background-color: #f8d7da;
    color: #721c24;
}

/* Responsive */
@media (max-width: 768px) {
    .services-filters {
        flex-direction: column;
    }
    
    .services-list {
        grid-template-columns: 1fr;
    }
    
    .date-time-selection {
        flex-direction: column;
        gap: 20px;
    }
    
    .form-actions {
        flex-direction: column-reverse;
    }
    
    .form-actions button {
        width: 100%;
    }
    
    .services-summary {
        position: relative;
        top: 0;
    }
    
    .form-actions {
        position: relative;
        top: 0;
    }
}

/* Estilos para acciones en la página de pedidos */
.bbs-booking-actions {
    margin-top: 30px;
    padding: 20px;
    border: 1px solid #e0e0e0;
    background: #f8f9fa;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.bbs-booking-actions h3 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    font-size: 18px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.bbs-booking-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.bbs-booking-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.bbs-booking-item p {
    margin-bottom: 8px;
}

.bbs-booking-item .button {
    margin-top: 10px;
    background-color: #2271b1;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.bbs-booking-item .button:hover {
    background-color: #135e96;
}

.bbs-booking-status {
    color: #777;
    font-style: italic;
    margin-top: 10px;
}

/* Botón en la tabla de pedidos */
.woocommerce-orders-table__cell-order-actions .button.edit_booking {
    background-color: #2271b1;
    color: white;
}

.woocommerce-orders-table__cell-order-actions .button.edit_booking:hover {
    background-color: #135e96;
} 

/* Estilos mejorados para el modal de pedidos */
.bbs-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    transition: opacity 0.3s ease;
}

.bbs-modal-content {
    position: relative;
    background-color: #fefefe;
    margin: 5% auto;
    padding: 0;
    width: 90%;
    max-width: 800px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s;
}

.bbs-modal-close {
    position: absolute;
    right: 15px;
    top: 10px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: color 0.2s ease;
}

.bbs-modal-close:hover,
.bbs-modal-close:focus {
    color: #000;
    text-decoration: none;
}

#bbs-order-modal-body {
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
}

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

@media (max-width: 768px) {
    .bbs-modal-content {
        width: 95%;
        margin: 10% auto;
    }
}

/* Estilos para pedidos extras */
.extra-orders {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 0.85em;
}

.extra-orders a {
    color: #2271b1;
    text-decoration: none;
}

.extra-orders a:hover {
    color: #135e96;
    text-decoration: underline;
}

/* Ajustar el ancho de la columna de pedido */
.woocommerce-orders-table th.booking-order,
.woocommerce-orders-table td.booking-order {
    min-width: 150px;
}

/* Asegurar que los controles de cantidad no interfieran */
.service-item.readonly .service-quantity,
.service-item.readonly .quantity-controls {
    display: none !important;
}

/* Evitar hover effects en servicios de solo lectura */
.service-item.readonly:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(34, 113, 177, 0.2);
}

/* Deshabilitar pointer events en checkboxes ocultos */
.service-item.readonly input[type="checkbox"] {
    pointer-events: none;
} 