.embbk-booking-wrap {
    --embbk-brown: #8a5a35;
    --embbk-brown-dark: #6f4526;
    --embbk-green: #3f8f48;
    --embbk-red: #c84b40;
    --embbk-yellow: #d6aa3a;
    --embbk-soft: #f8f4ef;
    --embbk-border: #e4ddd4;
    --embbk-text: #2b2520;
    color: var(--embbk-text);
    display: grid;
    gap: 24px;
    max-width: 1360px;
    margin: 0 auto 32px;
}

.embbk-calendar-card,
.embbk-form-card,
.embbk-alert {
    background: #fff;
    border: 1px solid var(--embbk-border);
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .06);
}

.embbk-calendar-card,
.embbk-form-card {
    padding: 22px;
}

.embbk-alert {
    max-width: 1360px;
    margin: 0 auto 18px;
    padding: 14px 18px;
    font-weight: 600;
}

.embbk-alert-success { border-left: 5px solid var(--embbk-green); }
.embbk-alert-warning { border-left: 5px solid #d99c28; }
.embbk-alert-error { border-left: 5px solid var(--embbk-red); }

.embbk-calendar-header {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 18px;
}

.embbk-calendar-header h3,
.embbk-form-card h3 {
    margin: 0 0 6px;
    font-size: 1.35rem;
}

.embbk-calendar-header p,
.embbk-form-intro {
    margin: 0;
    opacity: .78;
}

.embbk-apartment-switch {
    display: grid;
    gap: 6px;
    min-width: 240px;
    font-weight: 600;
}

.embbk-fixed-apartment-name {
    background: var(--embbk-soft);
    border-radius: 999px;
    padding: 9px 14px;
    font-weight: 700;
}

.embbk-calendar-toolbar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 8px 0 18px;
}

.embbk-submit-button {
    background: var(--embbk-brown);
    color: #fff;
    border: 0;
    cursor: pointer;
    transition: transform .15s ease, background .15s ease;
}

.embbk-submit-button:hover {
    background: var(--embbk-brown-dark);
    transform: translateY(-1px);
}

.embbk-nav-button {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 48px !important;
    min-width: 48px !important;
    height: 48px !important;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 12px !important;
    border: 1px solid var(--embbk-border) !important;
    background: #fff !important;
    color: var(--embbk-text) !important;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .06);
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
    font-size: 28px !important;
    font-weight: 700;
    line-height: 1 !important;
    vertical-align: middle;
}

.embbk-nav-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, .1);
    border-color: #d5cbbf !important;
}

.embbk-nav-button:focus-visible,
.embbk-booking-wrap select:focus,
.embbk-request-form input:focus,
.embbk-request-form textarea:focus,
.embbk-day:focus-visible {
    outline: 2px solid var(--embbk-brown);
    outline-offset: 2px;
}

.embbk-month-jump {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(120px, auto);
    gap: 10px;
    width: min(100%, 360px);
}

.embbk-booking-wrap select,
.embbk-request-form input,
.embbk-request-form textarea {
    width: 100% !important;
    max-width: 100% !important;
    border: 1px solid var(--embbk-border);
    border-radius: 10px;
    padding: 12px 14px;
    background: #fff;
    font: inherit;
    color: var(--embbk-text);
    box-sizing: border-box;
    display: block;
}

.embbk-request-form input[type="date"],
.embbk-request-form input.embbk-start-date,
.embbk-request-form input.embbk-end-date {
    width: 100% !important;
    max-width: 100% !important;
    min-height: 54px;
}

.embbk-month-jump select {
    min-width: 0;
}

.embbk-calendar-status {
    min-height: 22px;
    text-align: center;
    font-size: .95rem;
    opacity: .75;
}

.embbk-calendar-status-error {
    color: var(--embbk-red);
    opacity: 1;
}

.embbk-calendars {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

.embbk-month {
    background: var(--embbk-soft);
    border-radius: 12px;
    padding: 14px;
}

.embbk-month h4 {
    margin: 0 0 12px;
    text-align: center;
    font-size: 1.08rem;
}

.embbk-days-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 8px;
}

.embbk-weekday {
    text-align: center;
    font-weight: 700;
    font-size: .85rem;
    opacity: .7;
    padding: 4px 0;
}

.embbk-day {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    border-radius: 9px;
    font-weight: 700;
    font-size: 1rem;
    line-height: 1;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    text-align: center;
    padding: 0;
    height: clamp(54px, 5vw, 74px);
    min-height: 54px;
}

.embbk-day-empty {
    background: transparent;
}

.embbk-available {
    background: var(--embbk-green);
    cursor: pointer;
}

.embbk-booked {
    background: var(--embbk-red);
    cursor: not-allowed;
}

.embbk-reserved {
    background: var(--embbk-yellow);
    cursor: not-allowed;
}

.embbk-past {
    background: var(--embbk-past);
    color: #fff;
    cursor: not-allowed;
}

.embbk-selected {
    outline: 3px solid var(--embbk-brown);
    outline-offset: 2px;
}

.embbk-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 16px;
    font-weight: 600;
}

.embbk-legend span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.embbk-dot {
    width: 14px;
    height: 14px;
    display: inline-block;
    border-radius: 50%;
}

.embbk-dot-available { background: var(--embbk-green); }
.embbk-dot-booked { background: var(--embbk-red); }
.embbk-dot-reserved { background: var(--embbk-yellow); }
.embbk-dot-selected { background: var(--embbk-brown); }

.embbk-form-card {
    background: var(--embbk-soft);
}

.embbk-request-form {
    margin-top: 18px;
}

.embbk-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.embbk-request-form label {
    display: grid;
    gap: 6px;
    font-weight: 700;
    min-width: 0;
}

.embbk-request-form label span {
    font-size: .95rem;
}

.embbk-full {
    grid-column: 1 / -1;
}

.embbk-privacy {
    display: flex !important;
    align-items: flex-start;
    gap: 10px !important;
    font-weight: 500 !important;
}

.embbk-privacy input {
    width: auto !important;
    max-width: none !important;
    margin-top: 4px;
}

.embbk-submit-button {
    margin-top: 18px;
    padding: 12px 28px;
    border-radius: 9px;
    font-weight: 800;
    font-size: 1rem;
}

.embbk-hp {
    position: absolute !important;
    left: -9999px !important;
    opacity: 0 !important;
}

@media (max-width: 780px) {
    .embbk-calendar-header {
        align-items: stretch;
        flex-direction: column;
    }

    .embbk-apartment-switch {
        min-width: 0;
        width: 100%;
    }

    .embbk-calendar-toolbar {
        display: grid;
        grid-template-columns: 44px minmax(0, 1fr) minmax(0, 1fr) 44px;
        gap: 10px;
        align-items: center;
    }

    .embbk-month-jump {
        display: contents;
        width: auto;
    }

    .embbk-month-select {
        grid-column: 2;
    }

    .embbk-year-select {
        grid-column: 3;
    }

    .embbk-form-grid {
        grid-template-columns: 1fr;
    }

    .embbk-day {
        height: 52px;
        min-height: 52px;
        font-size: .96rem;
    }
}

@media (max-width: 520px) {
    .embbk-calendar-card,
    .embbk-form-card {
        padding: 16px;
    }

    .embbk-day {
        height: 44px;
        min-height: 44px;
        font-size: .92rem;
    }

    .embbk-nav-button {
        width: 44px !important;
        min-width: 44px !important;
        height: 44px !important;
        font-size: 24px !important;
    }
}

/* v1.0.4: bündige Formular-Datumsfelder und eigener größerer Kalender */
.embbk-date-field {
    position: relative;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
}

.embbk-date-display {
    appearance: none !important;
    -webkit-appearance: none !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    inline-size: 100% !important;
    box-sizing: border-box !important;
    cursor: pointer;
    background: #fff !important;
}

.embbk-date-display::placeholder {
    color: rgba(43, 37, 32, .58);
    opacity: 1;
}

.embbk-start-date,
.embbk-end-date {
    display: none !important;
}

.embbk-selected,
.embbk-day.embbk-selected,
.embbk-picker-day.embbk-selected {
    background: var(--embbk-brown) !important;
    color: #fff !important;
    outline: 0 !important;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .2), 0 6px 14px rgba(138, 90, 53, .24);
}

.embbk-date-picker {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    z-index: 9999;
    width: min(390px, 92vw);
    background: #fff;
    border: 1px solid var(--embbk-border);
    border-radius: 14px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, .18);
    padding: 14px;
}

.embbk-date-field:nth-of-type(even) .embbk-date-picker {
    left: auto;
    right: 0;
}

.embbk-picker-header {
    display: grid;
    grid-template-columns: 42px 1fr 42px;
    gap: 8px;
    align-items: center;
    margin-bottom: 10px;
}

.embbk-picker-header strong {
    text-align: center;
    font-size: 1.05rem;
}

.embbk-picker-nav {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--embbk-border);
    border-radius: 10px;
    background: var(--embbk-soft);
    color: var(--embbk-text);
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
}

.embbk-picker-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
}

.embbk-picker-weekday {
    text-align: center;
    font-weight: 700;
    font-size: .8rem;
    opacity: .7;
    padding: 4px 0;
}

.embbk-picker-empty {
    min-height: 42px;
}

.embbk-picker-day {
    appearance: none;
    -webkit-appearance: none;
    min-width: 0;
    min-height: 42px;
    border: 0;
    border-radius: 9px;
    color: #fff;
    font-weight: 800;
    background: var(--embbk-green);
    cursor: pointer;
}

.embbk-picker-day:disabled {
    cursor: not-allowed;
}

.embbk-picker-day.embbk-past {
    background: var(--embbk-past);
}

.embbk-picker-day.embbk-booked {
    background: var(--embbk-red);
}

.embbk-picker-day.embbk-reserved {
    background: var(--embbk-yellow);
}

@media (max-width: 780px) {
    .embbk-date-field,
    .embbk-date-display {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    .embbk-date-picker {
        width: 100%;
        max-width: 100%;
        left: 0 !important;
        right: auto !important;
    }
}

/* v1.0.5: robustes Formular- und Datepicker-Finishing */
.embbk-booking-wrap .embbk-request-form .embbk-date-field {
    position: relative !important;
    display: grid !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow: visible !important;
}

.embbk-booking-wrap .embbk-request-form .embbk-date-field .embbk-date-display {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.embbk-date-picker {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    transform: translate(-50%, -50%) !important;
    width: min(560px, calc(100vw - 32px)) !important;
    max-width: calc(100vw - 32px) !important;
    box-sizing: border-box !important;
    padding: 18px !important;
}

.embbk-date-field:nth-of-type(even) .embbk-date-picker {
    left: 50% !important;
    right: auto !important;
}

.embbk-date-picker .embbk-picker-header {
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) 48px !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.embbk-date-picker .embbk-picker-nav {
    appearance: none !important;
    -webkit-appearance: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 48px !important;
    min-width: 48px !important;
    max-width: 48px !important;
    height: 48px !important;
    min-height: 48px !important;
    max-height: 48px !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    position: static !important;
    transform: none !important;
    line-height: 1 !important;
    white-space: nowrap !important;
}

.embbk-date-picker .embbk-picker-header strong {
    min-width: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
}

.embbk-date-picker .embbk-picker-grid {
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 8px !important;
}

.embbk-date-picker .embbk-picker-day,
.embbk-date-picker .embbk-picker-empty {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: clamp(46px, 8vw, 64px) !important;
    min-height: 46px !important;
    box-sizing: border-box !important;
}

.embbk-date-picker .embbk-picker-day {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
    line-height: 1 !important;
}

.embbk-day.embbk-selected,
.embbk-picker-day.embbk-selected {
    background: var(--embbk-brown) !important;
    color: #fff !important;
    outline: none !important;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .25), 0 6px 14px rgba(138, 90, 53, .24) !important;
}

@media (max-width: 780px) {
    .embbk-date-picker {
        width: min(520px, calc(100vw - 28px)) !important;
        max-width: calc(100vw - 28px) !important;
        padding: 14px !important;
    }

    .embbk-date-picker .embbk-picker-grid {
        gap: 6px !important;
    }

    .embbk-date-picker .embbk-picker-day,
    .embbk-date-picker .embbk-picker-empty {
        height: 46px !important;
        min-height: 46px !important;
    }
}
