.bh-booking {
    --bh-border: #d7dee8;
    --bh-text: #1f2937;
    --bh-muted: #667085;
    --bh-primary: #0f766e;
    color: var(--bh-text);
    max-width: 960px;
    width: 100%;
}

.bh-form {
    display: grid;
    gap: 16px;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.bh-booking-main,
.bh-booking-contacts {
    margin: 0;
}

.bh-form-wide {
    grid-column: 1 / -1;
}

.bh-dates-row {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.bh-dates-row.is-day-booking {
    grid-template-columns: 1fr;
}

.bh-dates-row > label[hidden] {
    display: none;
}

.bh-booking-main {
    align-content: start;
    display: grid;
    gap: 16px;
}

.bh-booking-main h3,
.bh-booking-contacts h3 {
    margin-top: 0;
}

.bh-booking-contacts {
    align-content: start;
    display: grid;
    gap: 12px;
}

.bh-selected-unit {
    background: #ecfdf5;
    border: 1px solid #86efac;
    border-radius: 8px;
    color: #15803d;
    font-size: 16px;
    padding: 10px 12px;
}

.bh-selected-unit strong {
    color: #15803d;
}

.bh-fieldset,
.bh-section {
    border: 1px solid var(--bh-border);
    border-radius: 8px;
    margin: 0 0 16px;
    padding: 16px;
}

.bh-fieldset {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.bh-booking label {
    display: grid;
    gap: 6px;
    font-size: 14px;
}

.bh-booking input,
.bh-booking select,
.bh-booking textarea {
    border: 1px solid var(--bh-border);
    border-radius: 6px;
    min-height: 40px;
    padding: 8px 10px;
    width: 100%;
}

.bh-button {
    align-self: end;
    background: #ffffff;
    border: 1px solid var(--bh-primary);
    border-radius: 6px;
    color: var(--bh-primary);
    cursor: pointer;
    min-height: 40px;
    padding: 8px 14px;
}

.bh-button-primary {
    background: var(--bh-primary);
    color: #ffffff;
}

.bh-units,
.bh-services {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.bh-unit,
.bh-service {
    border: 1px solid var(--bh-border);
    border-radius: 8px;
    padding: 12px;
}

.bh-unit {
    background: #ffffff;
    color: var(--bh-text);
    cursor: pointer;
    text-align: left;
}

.bh-unit:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.bh-unit[aria-selected="true"] {
    border-color: var(--bh-primary);
    box-shadow: 0 0 0 2px rgba(15, 118, 110, 0.16);
}

.bh-unit img {
    aspect-ratio: 16 / 10;
    border-radius: 6px;
    object-fit: cover;
    width: 100%;
}

.bh-alert {
    border-radius: 8px;
    margin-bottom: 16px;
    padding: 12px;
}

.bh-alert[data-kind="error"] {
    background: #fff1f2;
    color: #9f1239;
}

.bh-alert[data-kind="success"] {
    background: #ecfdf5;
    color: #065f46;
}

.bh-booking .bh-check {
    align-items: center;
    display: flex;
    gap: 8px;
    margin: 10px 0;
}

.bh-booking .bh-check input {
    flex: 0 0 auto;
    margin: 0;
    min-height: auto;
    width: auto;
}

.bh-booking .bh-check span {
    line-height: 1.4;
}

.bh-modal[hidden] {
    display: none;
}

.bh-modal {
    align-items: center;
    display: flex;
    inset: 0;
    justify-content: center;
    padding: 24px;
    position: fixed;
    z-index: 100000;
}

.bh-modal-backdrop {
    background: rgba(15, 23, 42, 0.68);
    border: 0;
    cursor: pointer;
    inset: 0;
    padding: 0;
    position: absolute;
}

.bh-modal-panel {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.3);
    max-height: calc(100vh - 48px);
    max-width: 920px;
    overflow: auto;
    padding: 20px;
    position: relative;
    width: 100%;
    z-index: 1;
}

.bh-modal-header {
    align-items: center;
    display: flex;
    gap: 16px;
    justify-content: space-between;
    margin-bottom: 16px;
}

.bh-modal-header h3 {
    margin: 0;
}

.bh-modal-close {
    align-items: center;
    background: transparent;
    border: 0;
    color: var(--bh-muted);
    cursor: pointer;
    display: flex;
    font-size: 28px;
    height: 40px;
    justify-content: center;
    line-height: 1;
    padding: 0;
    width: 40px;
}

body.bh-modal-open {
    overflow: hidden;
}

@media (max-width: 720px) {
    .bh-form {
        grid-template-columns: 1fr;
    }

    .bh-form-wide {
        grid-column: auto;
    }

    .bh-dates-row {
        grid-template-columns: 1fr;
    }

    .bh-modal {
        padding: 12px;
    }

    .bh-modal-panel {
        max-height: calc(100vh - 24px);
        padding: 16px;
    }
}
