/* Class Booking - Front End Styles v2.1 */

.cb-booking-container {
    max-width: 650px;
    margin: 30px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cb-form-title {
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: #1e1e1e;
}

.cb-form-subtitle {
    font-size: 15px;
    color: #666;
    margin: 0 0 24px 0;
}

/* Form Fields */
.cb-form {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.cb-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.cb-field-group {
    display: flex;
    flex-direction: column;
}

.cb-field-group:nth-child(4) {
    grid-column: 1 / -1;
}

.cb-field-group label {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.cb-required {
    color: #e74c3c;
}

.cb-input {
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    font-family: inherit;
    width: 100%;
    box-sizing: border-box;
}

.cb-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
}

textarea.cb-input {
    resize: vertical;
}

.cb-field-error {
    font-size: 12px;
    color: #e74c3c;
    min-height: 16px;
    margin-top: 2px;
}

/* Selected Date */
.cb-date-section {
    margin-bottom: 20px;
}

.cb-date-section label {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    display: block;
    margin-bottom: 4px;
}

.cb-selected-date {
    padding: 10px 14px;
    background: #f5f5f5;
    border: 1px dashed #ccc;
    border-radius: 6px;
    font-size: 14px;
    color: #999;
}

.cb-selected-date.cb-date-chosen {
    background: #e8f5e9;
    border: 1px solid #4caf50;
    color: #2e7d32;
    font-weight: 600;
}

/* Calendar */
.cb-calendar-wrap {
    margin-bottom: 24px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.cb-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #2c3e50;
    color: #fff;
    padding: 14px 16px;
}

.cb-month-title {
    font-size: 16px;
    font-weight: 600;
}

.cb-cal-nav {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.cb-cal-nav:hover {
    background: rgba(255, 255, 255, 0.3);
}

.cb-day-headers {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: #f5f5f5;
    border-bottom: 1px solid #e0e0e0;
}

.cb-day-header {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    padding: 10px 0;
    text-transform: uppercase;
}

.cb-day-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    padding: 8px;
    background: #fff;
}

.cb-day-cell {
    text-align: center;
    padding: 4px 2px;
    border-radius: 6px;
    font-size: 14px;
    transition: background 0.15s ease, color 0.15s ease;
    min-height: 56px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
}

.cb-day-num {
    font-size: 14px;
    line-height: 1;
}

.cb-day-title {
    font-size: 8px;
    color: #1565c0;
    line-height: 1;
    font-weight: 600;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cb-day-time {
    font-size: 8px;
    color: #2e7d32;
    line-height: 1;
}

.cb-day-spots {
    font-size: 8px;
    color: #e65100;
    line-height: 1;
    font-weight: 500;
}

.cb-day-empty {
    background: transparent;
    min-height: 0;
}

.cb-day-available {
    cursor: pointer;
    color: #333;
    background: #f0faf0;
}

.cb-day-available:hover {
    background: #e3f2fd;
    color: #1565c0;
}

.cb-day-selected {
    background: #2c3e50 !important;
    color: #fff !important;
    font-weight: 700;
}

.cb-day-selected .cb-day-title {
    color: rgba(255, 255, 255, 0.9);
}

.cb-day-selected .cb-day-time {
    color: rgba(255, 255, 255, 0.8);
}

.cb-day-selected .cb-day-spots {
    color: rgba(255, 255, 255, 0.7);
}

.cb-day-blocked {
    background: #f5f5f5;
    color: #bbb;
    cursor: not-allowed;
}

.cb-day-blocked .cb-day-num {
    text-decoration: line-through;
}

.cb-day-past {
    color: #ccc;
    cursor: default;
}

/* Submit Button */
.cb-submit-wrap {
    margin-top: 8px;
}

.cb-submit-btn {
    width: 100%;
    padding: 14px;
    background: #2c3e50;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.cb-submit-btn:hover {
    background: #34495e;
}

.cb-submit-btn:disabled {
    background: #95a5a6;
    cursor: not-allowed;
}

/* Messages */
.cb-message {
    margin-top: 12px;
    padding: 0;
    border-radius: 6px;
    font-size: 14px;
}

.cb-message-error {
    padding: 12px 16px;
    background: #fdecea;
    color: #c0392b;
    border: 1px solid #e74c3c;
}

/* Success */
.cb-success {
    text-align: center;
    padding: 40px 30px;
    background: #e8f5e9;
    border: 1px solid #4caf50;
    border-radius: 10px;
}

.cb-success h2 {
    color: #2e7d32;
    margin: 0 0 12px 0;
    font-size: 26px;
}

.cb-success > p {
    color: #333;
    font-size: 15px;
    max-width: 400px;
    margin: 0 auto 20px auto;
}

/* Booking Summary on Success Page */
.cb-booking-summary {
    background: #fff;
    border: 1px solid #c8e6c9;
    border-radius: 8px;
    padding: 20px 24px;
    margin: 20px auto;
    max-width: 380px;
    text-align: left;
}

.cb-booking-summary h3 {
    margin: 0 0 12px 0;
    font-size: 16px;
    color: #2e7d32;
    text-align: center;
}

.cb-booking-summary p {
    margin: 6px 0;
    font-size: 14px;
    color: #333;
}

.cb-booking-summary strong {
    color: #555;
}

/* Download Confirmation Button */
.cb-download-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 28px;
    background: #2c3e50;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.cb-download-btn:hover {
    background: #34495e;
    transform: translateY(-1px);
}

.cb-download-btn:active {
    transform: translateY(0);
}

/* No Dates Available Message */
.cb-no-dates {
    text-align: center;
    padding: 50px 30px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.cb-no-dates-icon {
    font-size: 48px;
    margin-bottom: 16px;
    line-height: 1;
}

.cb-no-dates p {
    color: #555;
    font-size: 16px;
    max-width: 400px;
    margin: 0 auto;
    line-height: 1.5;
}

/* Responsive */
@media (max-width: 600px) {
    .cb-fields {
        grid-template-columns: 1fr;
    }

    .cb-form {
        padding: 20px;
    }

    .cb-form-title {
        font-size: 22px;
    }

    .cb-booking-summary {
        max-width: 100%;
    }
}
