/* CSS específico para el sistema de reserva de citas - NO interfiere con main.css */

/* Solo aplicar estilos a elementos dentro de contenedores específicos de citas */
.booking-slots {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.booking-slot-card {
    background: var(--card-bg-color);
    border: 1px solid var(--primary-l-color);
    border-radius: 10px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.booking-slot-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-color: var(--primary-color);
}

.booking-slot-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.booking-slot-card:hover::before {
    transform: translateX(0);
}

.booking-slot-title {
    color: var(--primary-t-color);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.booking-slot-info {
    margin-bottom: 20px;
}

.booking-slot-info p {
    margin: 5px 0;
    color: var(--primary-p-color);
    font-size: 0.95rem;
}

.booking-slot-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding: 10px;
    background: var(--primary-bg-color-3);
    border-radius: 6px;
}

.booking-slot-button {
    width: 100%;
    padding: 12px 20px;
    background: var(--primary-color);
    color: var(--white-color);
    border: none;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
}

.booking-slot-button:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.booking-loading-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--primary-p-color);
    grid-column: 1 / -1;
}

.booking-form-card {
    background: var(--card-bg-color);
    border: 1px solid var(--primary-l-color);
    border-radius: 10px;
    padding: 30px;
    margin-top: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.booking-selected-info {
    background: var(--primary-bg-color-3);
    border: 1px solid var(--primary-color);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    position: relative;
}

.booking-selected-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.booking-selected-info h4 {
    color: var(--primary-t-color);
    margin-bottom: 15px;
}

.booking-selected-info p {
    margin: 5px 0;
    color: var(--primary-t-color);
    font-weight: 500;
}

.booking-form-group {
    margin-bottom: 20px;
}

.booking-form-label {
    display: block;
    margin-bottom: 8px;
    color: var(--primary-t-color);
    font-weight: 600;
}

.booking-form-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--primary-l-color);
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    background: var(--primary-bg-color);
    color: var(--primary-t-color);
}

.booking-form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-bg-color-3);
}

.booking-form-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--primary-l-color);
    border-radius: 4px;
    font-size: 1rem;
    resize: vertical;
    min-height: 100px;
    background: var(--primary-bg-color);
    color: var(--primary-t-color);
    transition: border-color 0.3s ease;
}

.booking-form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-bg-color-3);
}

.booking-form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 25px;
}

.booking-btn-primary {
    padding: 15px 30px;
    background: var(--primary-color);
    color: var(--white-color);
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.booking-btn-primary:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.booking-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.booking-btn-secondary {
    padding: 15px 30px;
    background: transparent;
    color: var(--primary-t-color);
    border: 2px solid var(--primary-l-color);
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
}

.booking-btn-secondary:hover {
    background: var(--primary-l-color);
    transform: translateY(-2px);
}

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

.booking-message {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.booking-message-success {
    background: var(--primary-bg-color-3);
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.booking-message-error {
    background: rgba(227, 79, 79, 0.1);
    color: var(--invalid-color);
    border: 1px solid var(--invalid-color);
}

.booking-no-slots {
    text-align: center;
    padding: 60px 20px;
    color: var(--primary-p-color);
    grid-column: 1 / -1;
}

.booking-no-slots h3 {
    color: var(--primary-t-color);
    margin-bottom: 15px;
}

.booking-contact-info {
    text-align: center;
    padding: 30px 20px;
    transition: transform 0.3s ease;
}

.booking-contact-info:hover {
    transform: translateY(-5px);
}

.booking-contact-info h4 {
    color: var(--primary-t-color);
    margin-bottom: 15px;
}

.booking-contact-info p {
    margin: 0;
    color: var(--primary-p-color);
}

.booking-contact-info a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.booking-contact-info a:hover {
    text-decoration: underline;
}

/* Estados de carga específicos para botones */
.booking-btn-text {
    display: inline;
}

.booking-btn-loading {
    display: none;
}

.booking-btn-primary:disabled .booking-btn-text {
    display: none;
}

.booking-btn-primary:disabled .booking-btn-loading {
    display: inline;
}

/* Responsive específico para el sistema de citas */
@media (max-width: 768px) {
    .booking-slots {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .booking-slot-card {
        padding: 20px;
    }
    
    .booking-form-card {
        padding: 20px;
    }
    
    .booking-form-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .booking-btn-primary,
    .booking-btn-secondary {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .booking-selected-info {
        padding: 15px;
    }
    
    .booking-slot-price {
        font-size: 1.2rem;
    }
    
    .booking-btn-primary,
    .booking-btn-secondary {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
}
/* Mensaje de éxito mejorado */
.booking-message-success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    border: 2px solid var(--primary-color);
    color: var(--primary-t-color);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    text-align: center;
    animation: slideInFromTop 0.5s ease-out;
}

.booking-message-success h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.booking-message-success p {
    margin: 10px 0;
    font-size: 1.1rem;
}

.booking-message-success small {
    color: var(--primary-p-color);
    font-style: italic;
}

.booking-message-success i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    display: block;
}

/* Animación para el mensaje */
@keyframes slideInFromTop {
    0% {
        transform: translateY(-50px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Mejorar el scroll hacia el mensaje */
.messages-container {
    scroll-margin-top: 20px;
}
/* Precio destacado en la información seleccionada */
.booking-selected-info #selected-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    background: var(--primary-bg-color-3);
    padding: 8px 16px;
    border-radius: 6px;
    display: inline-block;
    margin-top: 10px;
}

/* Mejorar la visualización del precio en las tarjetas */
.booking-slot-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
    background: var(--primary-bg-color-3);
    padding: 12px;
    border-radius: 8px;
    margin: 15px 0;
    border: 2px solid var(--primary-color);
}

/* Asegurar que el texto del precio se centre */
.text-center .booking-slot-price {
    margin: 10px auto;
}
/* Estilos para mensajes */
#messages-section {
    padding: 20px 0;
}

.message {
    padding: 15px 20px;
    border-radius: 5px;
    margin: 10px 0;
    display: flex;
    align-items: center;
    font-weight: 500;
}

.message i {
    margin-right: 10px;
    font-size: 1.2em;
}

.message-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.message-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Estilos para elemento de tarjeta */
#card-element {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: white;
    margin-bottom: 10px;
}

#card-errors {
    color: #fa755a;
    font-size: 14px;
    margin-top: 10px;
}

/* Loading state mejorado */
.booking-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.booking-btn-primary:disabled .booking-btn-text {
    display: none;
}

.booking-btn-primary:disabled .booking-btn-loading {
    display: inline;
}

.booking-btn-loading {
    display: none;
}

/* ===== PÁGINA DE CONFIRMACIÓN ===== */
.confirmation-success-icon {
    margin: 20px 0;
}

.confirmation-card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    padding: 30px;
    margin: 20px 0;
}

.confirmation-header {
    text-align: center;
    border-bottom: 2px solid #28a745;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.confirmation-header h3 {
    color: #28a745;
    font-size: 1.5em;
    margin: 0;
}

.confirmation-details {
    margin: 30px 0;
}

.detail-item {
    display: flex;
    align-items: center;
    margin: 12px 0;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.detail-item i {
    color: #007bff;
    width: 25px;
    margin-right: 10px;
}

.location-info {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 8px;
    padding: 20px;
    margin: 25px 0;
    border-left: 5px solid #007bff;
}

.location-info h4 {
    color: #007bff;
    margin-bottom: 15px;
}

.location-details p {
    margin: 8px 0;
    font-weight: 500;
}

.booking-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin: 20px 0;
}

.booking-info p {
    margin: 5px 0;
    font-size: 0.9em;
    color: #666;
}

.confirmation-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.confirmation-actions .btn {
    padding: 12px 24px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-width: 150px;
}

.confirmation-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
}

.btn-info {
    background: linear-gradient(135deg, #17a2b8 0%, #6f42c1 100%);
    border: none;
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
    border: none;
}

.confirmation-note {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 5px;
    padding: 15px;
    margin: 20px 0;
    text-align: center;
}

.confirmation-note i {
    color: #856404;
    margin-right: 8px;
}

/* Responsivo */
@media (max-width: 768px) {
    .confirmation-card {
        padding: 20px;
        margin: 10px;
    }
    
    .confirmation-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .confirmation-actions .btn {
        width: 100%;
        max-width: 250px;
    }
    
    .detail-item {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }
    
    .detail-item i {
        margin-bottom: 5px;
    }
}

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

#confirmation-section {
    animation: slideInUp 0.6s ease-out;
}

.confirmation-success-icon i {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}
