/* Google Calendar Booking - Estilos Frontend */

.gcb-booking-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
}

.gcb-booking-form-wrapper {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 40px;
}

.gcb-form-title {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
    font-size: 28px;
}

.gcb-form-step {
    display: none;
}

.gcb-form-step.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

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

.gcb-form-step h3 {
    color: #4CAF50;
    margin-bottom: 20px;
    font-size: 20px;
}

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

.gcb-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
}

.gcb-form-group input[type="text"],
.gcb-form-group input[type="email"],
.gcb-form-group input[type="tel"],
.gcb-form-group input[type="date"],
.gcb-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.gcb-form-group input:focus,
.gcb-form-group textarea:focus {
    outline: none;
    border-color: #4CAF50;
}

.gcb-form-group textarea {
    resize: vertical;
}

.gcb-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
}

.gcb-btn-primary {
    background-color: #4CAF50;
    color: white;
}

.gcb-btn-primary:hover {
    background-color: #45a049;
}

.gcb-btn-next,
.gcb-btn-check {
    background-color: #2196F3;
    color: white;
    width: 100%;
}

.gcb-btn-next:hover,
.gcb-btn-check:hover {
    background-color: #0b7dda;
}

.gcb-btn-back {
    background-color: #f5f5f5;
    color: #333;
    margin-right: 10px;
}

.gcb-btn-back:hover {
    background-color: #e0e0e0;
}

.gcb-loader {
    text-align: center;
    padding: 20px;
    color: #666;
}

/* Calendario interactivo */
.gcb-calendar-wrapper {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    max-width: 100%;
    box-sizing: border-box;
}

.gcb-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.gcb-calendar-header h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.gcb-calendar-nav {
    background: transparent;
    color: #2196F3;
    border: none;
    padding: 0;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
}

.gcb-calendar-nav span {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    line-height: 1;
    margin: 0;
    padding: 0;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
}

.gcb-calendar-nav:hover {
    background: transparent;
    opacity: 0.7;
    transform: scale(1.1);
}

.gcb-calendar-nav:active {
    transform: scale(1.0);
}

.gcb-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
}

.gcb-calendar-day-name {
    text-align: center;
    font-weight: 600;
    color: #666;
    padding: 10px 0;
    font-size: 14px;
}

.gcb-calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
    color: #333;
    background: #fff;
}

.gcb-calendar-day:hover:not(.gcb-calendar-day-disabled):not(.gcb-calendar-day-empty) {
    background: #e8f5e9;
    border-color: #4CAF50;
    transform: scale(1.05);
}

.gcb-calendar-day-empty {
    border: none;
    cursor: default;
}

.gcb-calendar-day-disabled {
    background: #f5f5f5;
    color: #bbb;
    cursor: not-allowed;
    border-color: #f0f0f0;
}

.gcb-calendar-day-today {
    border-color: #2196F3;
    font-weight: 700;
}

.gcb-calendar-day-selected {
    background: #4CAF50 !important;
    color: white !important;
    border-color: #4CAF50 !important;
    transform: scale(1.05);
}

.gcb-time-slots {
    margin-top: 20px;
}

.gcb-time-slots h4 {
    color: #333;
    margin-bottom: 15px;
}

.gcb-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.gcb-time-slot {
    padding: 12px;
    background-color: #f5f5f5;
    border: 2px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
    font-weight: 500;
}

.gcb-time-slot:hover {
    background-color: #e8f5e9;
    border-color: #4CAF50;
}

.gcb-time-slot.selected {
    background-color: #4CAF50;
    color: white;
    border-color: #4CAF50;
}

.gcb-no-slots {
    text-align: center;
    color: #999;
    padding: 20px;
}

.gcb-summary {
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.gcb-summary-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

.gcb-summary-item:last-child {
    border-bottom: none;
}

.gcb-summary-item strong {
    color: #555;
}

.gcb-summary-item span {
    color: #333;
    font-weight: 500;
}

.gcb-form-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.gcb-success {
    text-align: center;
    padding: 40px;
}

.gcb-success-icon {
    width: 80px;
    height: 80px;
    background-color: #4CAF50;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 56px;
    font-weight: bold;
    margin: 0 auto 20px;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
    animation: gcbSuccessPop 0.5s ease-out;
}

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

.gcb-success h3 {
    color: #4CAF50;
    margin-bottom: 15px;
}

.gcb-success p {
    color: #666;
    margin-bottom: 30px;
}

#gcb-messages {
    margin-bottom: 20px;
}

.gcb-message {
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 15px;
}

.gcb-message-error {
    background-color: #ffebee;
    color: #c62828;
    border: 1px solid #ef5350;
}

.gcb-message-success {
    background-color: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #4CAF50;
}

.gcb-message-info {
    background-color: #e3f2fd;
    color: #1565c0;
    border: 1px solid #2196F3;
}

/* Responsive */
@media (max-width: 768px) {
    .gcb-booking-form-wrapper {
        padding: 15px;
    }
    
    /* Calendario responsive */
    .gcb-calendar-wrapper {
        padding: 15px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .gcb-calendar-header h4 {
        font-size: 16px;
    }
    
    .gcb-calendar-nav {
        padding: 6px 12px;
        font-size: 16px;
    }
    
    .gcb-calendar-grid {
        gap: 4px;
        min-width: 280px; /* Evita que se comprima demasiado */
    }
    
    .gcb-calendar-day-name {
        font-size: 11px;
        padding: 8px 0;
    }
    
    .gcb-calendar-day {
        font-size: 13px;
        min-height: 35px;
    }
    
    /* Slots de horario responsive */
    .gcb-slots-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 8px;
    }
    
    /* Formulario responsive */
    .gcb-form-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .gcb-btn-back {
        margin-right: 0;
    }
    
    /* Botones más grandes en móvil */
    .gcb-btn {
        min-height: 44px;
        font-size: 15px;
    }
}

/* Extra responsive para pantallas muy pequeñas */
@media (max-width: 480px) {
    .gcb-booking-form-wrapper {
        padding: 10px;
    }
    
    .gcb-calendar-wrapper {
        padding: 10px;
    }
    
    .gcb-calendar-grid {
        gap: 3px;
    }
    
    .gcb-calendar-day {
        font-size: 12px;
        min-height: 32px;
        border-width: 1px;
    }
    
    .gcb-calendar-day-name {
        font-size: 10px;
        padding: 6px 0;
    }
    
    .gcb-slots-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .gcb-form-step h3 {
        font-size: 18px;
    }
}

/* Estilos para campos personalizados */
.gcb-radio-group,
.gcb-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.gcb-radio-label,
.gcb-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.gcb-radio-label:hover,
.gcb-checkbox-label:hover {
    border-color: #2196F3;
    background: #f5f5f5;
}

.gcb-radio-label input[type="radio"],
.gcb-checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.gcb-radio-label input[type="radio"]:checked + span,
.gcb-checkbox-label input[type="checkbox"]:checked + span {
    font-weight: 600;
    color: #2196F3;
}

.gcb-radio-label input[type="radio"]:checked,
.gcb-checkbox-label input[type="checkbox"]:checked {
    accent-color: #2196F3;
}

.gcb-field-help {
    font-size: 13px;
    color: #666;
    font-style: italic;
    margin-top: 5px;
}

/* Responsive para radio/checkbox */
@media (max-width: 768px) {
    .gcb-radio-label,
    .gcb-checkbox-label {
        padding: 8px;
        font-size: 14px;
    }
}
