/* ============================================
   GJ Booking - Beratungstermin Buchungssystem
   Farben: Hellgrün #bad52b, Dunkelgrün #0a5a0c,
           Magenta #ec008c, Grau #454545
   ============================================ */

.gj-booking {
    max-width: 720px;
    margin: 0 auto;
    font-family: inherit;
    color: #454545;
}

/* Progress Bar */
.gj-booking-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding: 0;
    counter-reset: step;
}

.gj-booking-progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    opacity: 0.4;
    transition: opacity 0.3s;
}

.gj-booking-progress-step.active,
.gj-booking-progress-step.done {
    opacity: 1;
}

.gj-booking-progress-step::after {
    content: '';
    position: absolute;
    top: 18px;
    left: calc(50% + 18px);
    width: calc(100% - 36px);
    height: 2px;
    background: #ccc;
}

.gj-booking-progress-step:last-child::after {
    display: none;
}

.gj-booking-progress-step.done::after {
    background: #bad52b;
}

.gj-booking-progress-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 0;
    background: #e0e0e0;
    color: #666;
    font-weight: 600;
    font-size: 17px;
    position: relative;
    z-index: 1;
    transition: all 0.3s;
}

.gj-booking-progress-step.active .gj-booking-progress-number {
    background: #0a5a0c;
    color: #fff;
}

.gj-booking-progress-step.done .gj-booking-progress-number {
    background: #bad52b;
    color: #fff;
}

.gj-booking-progress-label {
    display: block;
    margin-top: 0.5rem;
    font-size: 14px;
    color: #666;
}

.gj-booking-progress-step.active .gj-booking-progress-label {
    color: #454545;
    font-weight: 600;
}

/* Errors */
.gj-booking-errors {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.gj-booking-error {
    color: #dc2626;
    margin: 0.25rem 0;
    font-size: 17px;
}

/* Steps */
.gj-booking-step h3 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: #0a5a0c;
}

.gj-booking-step h4 {
    font-size: 1.4rem;
    margin: 1.5rem 0 1rem;
    color: #454545;
}

/* Reason Cards */
.gj-booking-reasons {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.gj-booking-reason-option {
    cursor: pointer;
    display: flex;
}

.gj-booking-reason-option input[type="radio"] {
    display: none;
}

.gj-booking-reason-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 0;
    text-align: center;
    transition: all 0.2s;
    background: #fff;
}

/* Optional: auto-height (no equal heights) */
.gj-booking-reasons.auto-height .gj-booking-reason-option {
    display: block;
}
.gj-booking-reasons.auto-height .gj-booking-reason-card {
    display: block;
}

.gj-booking-reason-card:hover {
    border-color: var(--reason-color, #bad52b);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.gj-booking-reason-option input:checked + .gj-booking-reason-card {
    border-color: var(--reason-color, #0a5a0c);
    background: color-mix(in srgb, var(--reason-color, #bad52b) 10%, white);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
}

.gj-booking-reason-title {
    display: block;
    font-weight: 600;
    font-size: 19px;
    color: #454545;
}

.gj-booking-reason-desc {
    display: block;
    font-size: 17px;
    color: #666;
    margin-top: 0.25rem;
}

/* Calendar */
.gj-booking-calendar {
    margin-bottom: 1rem;
}

.gj-booking-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.gj-booking-calendar-header h4 {
    margin: 0;
    font-size: 1.3rem;
}

.gj-booking-calendar-nav {
    background: none;
    border: 1px solid #ddd;
    border-radius: 0;
    padding: 0.4rem 0.8rem;
    cursor: pointer;
    font-size: 17px;
    transition: background 0.2s;
}

.gj-booking-calendar-nav:hover {
    background: #f0f0f0;
}

.gj-booking-calendar-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

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

.gj-booking-calendar-weekday {
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: #888;
    padding: 0.5rem 0;
}

.gj-booking-calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
    font-size: 17px;
    cursor: default;
    border: none;
    background: none;
    color: #ccc;
    transition: all 0.2s;
}

.gj-booking-calendar-day.available {
    color: #454545;
    background: #f0f7d4;
    cursor: pointer;
    font-weight: 500;
}

.gj-booking-calendar-day.available:hover {
    background: #bad52b;
    color: #fff;
}

.gj-booking-calendar-day.selected {
    background: #0a5a0c;
    color: #fff;
    font-weight: 700;
}

.gj-booking-calendar-day.today {
    box-shadow: inset 0 0 0 2px #ec008c;
}

.gj-booking-calendar-day.other-month {
    visibility: hidden;
}

/* Time Slots */
.gj-booking-timeslots {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.gj-booking-timeslot {
    padding: 0.75rem;
    border: 2px solid #e0e0e0;
    border-radius: 0;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: #fff;
    font-size: 17px;
}

.gj-booking-timeslot:hover {
    border-color: #bad52b;
    background: #f8fce8;
}

.gj-booking-timeslot.selected {
    border-color: #0a5a0c;
    background: #0a5a0c;
    color: #fff;
}

.gj-booking-timeslot-remaining {
    display: block;
    font-size: 11px;
    color: #888;
    margin-top: 2px;
}

.gj-booking-timeslot.selected .gj-booking-timeslot-remaining {
    color: rgba(255, 255, 255, 0.8);
}

.gj-booking-timeslots-loading {
    text-align: center;
    padding: 2rem;
    color: #888;
}

/* Form Fields */
.gj-booking-field {
    margin-bottom: 1rem;
}

.gj-booking-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 17px;
    color: #454545;
}

.gj-booking-field input[type="text"],
.gj-booking-field input[type="email"],
.gj-booking-field input[type="tel"],
.gj-booking-field textarea {
    width: 100%;
    padding: 0.6rem 0.8rem;
    border: 1px solid #ddd;
    border-radius: 0;
    font-size: 17px;
    font-family: inherit;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.gj-booking-field input:focus,
.gj-booking-field textarea:focus {
    outline: none;
    border-color: #bad52b;
    box-shadow: 0 0 0 3px rgba(186, 213, 43, 0.25);
}

.gj-booking-field input.error,
.gj-booking-field textarea.error {
    border-color: #dc2626;
    background-color: #fef2f2;
}
.gj-booking-field input.error:focus,
.gj-booking-field textarea.error:focus {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
    outline: none;
}
.gj-booking-field-error {
    color: #dc2626;
    font-size: 12px;
    margin-top: 4px;
    line-height: 1.3;
}
.gj-booking-checkbox-label input[type="checkbox"].error + span {
    color: #dc2626;
}
.gj-booking-toggle-label input[type="checkbox"].error + span {
    color: #dc2626;
}

.required {
    color: #ec008c;
}

/* Layout helpers */
.gj-booking-row {
    display: flex;
    gap: 1rem;
}

.gj-booking-half {
    flex: 1;
}

.gj-booking-third {
    flex: 0 0 30%;
}

.gj-booking-twothird {
    flex: 1;
}

/* Checkboxes */
.gj-booking-checkbox-label,
.gj-booking-toggle-label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 17px;
    font-weight: normal;
}

.gj-booking-checkbox-label input,
.gj-booking-toggle-label input {
    margin-top: 3px;
    flex-shrink: 0;
    accent-color: #0a5a0c;
}

.gj-booking-divider {
    border: none;
    border-top: 1px solid #eee;
    margin: 1.5rem 0;
}

/* Actions */
.gj-booking-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

.gj-booking-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.gj-booking-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.gj-booking-btn-next,
.gj-booking-btn-submit {
    background: #bad52b;
    color: #fff;
    margin-left: auto;
}

.gj-booking-btn-next:hover:not(:disabled),
.gj-booking-btn-submit:hover {
    background: #0a5a0c;
}

.gj-booking-btn-back {
    background: #f5f5f5;
    color: #454545;
    margin-right: auto;
    margin-left: 0;
}

.gj-booking-btn-back:hover {
    background: #e0e0e0;
}

.gj-booking-btn-cancel {
    background: #ec008c;
    color: #fff;
}

.gj-booking-btn-cancel:hover {
    background: #c50074;
}

/* Summary */
.gj-booking-summary {
    background: #fafafa;
    border: 1px solid #eee;
    border-radius: 0;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.gj-booking-summary-section {
    margin-bottom: 1.5rem;
}

.gj-booking-summary-section:last-child {
    margin-bottom: 0;
}

.gj-booking-summary-section h4 {
    font-size: 17px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #888;
    margin: 0 0 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee;
}

.gj-booking-summary dl {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 0.4rem 1rem;
    margin: 0;
}

.gj-booking-summary dt {
    font-weight: 600;
    font-size: 17px;
    color: #454545;
}

.gj-booking-summary dd {
    margin: 0;
    font-size: 17px;
}

/* Success */
.gj-booking-success {
    text-align: center;
    padding: 2rem 0;
}

.gj-booking-success-icon {
    width: 64px;
    height: 64px;
    border-radius: 0;
    background: #bad52b;
    color: #fff;
    font-size: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.gj-booking-cancel-icon {
    background: #ec008c;
}

.gj-booking-success-details {
    background: #f5f5f5;
    border-radius: 0;
    padding: 1rem 1.5rem;
    display: inline-block;
    text-align: left;
    margin: 1rem 0;
}

.gj-booking-success-info {
    color: #666;
    font-size: 17px;
    margin-top: 1.5rem;
}

/* Cancel */
.gj-booking-cancel-details {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    border-radius: 0;
    padding: 1rem 1.5rem;
    margin: 1rem 0;
}

.gj-booking-cancel-expired {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0;
    padding: 1rem 1.5rem;
}

.gj-booking-cancel-error {
    text-align: center;
    padding: 2rem;
}

.gj-booking-cancel-success {
    text-align: center;
    padding: 2rem 0;
}

/* Links */
.gj-booking a {
    color: #0a5a0c;
}

.gj-booking a:hover {
    color: #ec008c;
}

/* Responsive */
@media (max-width: 600px) {
    .gj-booking-row {
        flex-direction: column;
        gap: 0;
    }

    .gj-booking-third,
    .gj-booking-twothird {
        flex: 1;
    }

    .gj-booking-reasons {
        grid-template-columns: 1fr;
    }

    .gj-booking-timeslots {
        grid-template-columns: repeat(2, 1fr);
    }

    .gj-booking-summary dl {
        grid-template-columns: 1fr;
    }

    .gj-booking-summary dt {
        margin-top: 0.5rem;
    }

    .gj-booking-progress-label {
        font-size: 10px;
    }

    .gj-booking-actions {
        flex-direction: column-reverse;
    }

    .gj-booking-btn {
        width: 100%;
        text-align: center;
    }
}
