/* ===== Booking Modal (bm-*) — DARK MODE ===== */
:root {
    /* base dark palette */
    --bm-bg: #1f2937;
    /* requested dark */
    --bm-panel: #111827;
    /* panel surface */
    --bm-panel-2: #0b1220;
    /* deeper surface */
    --bm-text: #e5e7eb;
    /* primary text */
    --bm-muted: #9ca3af;
    /* secondary text */
    --bm-border: #374151;
    /* strokes */
    --bm-overlay: rgba(0, 0, 0, .65);

    /* brand */
    --bm-primary: #6366f1;
    --bm-primary-600: #4f46e5;
    --bm-primary-700: #4338ca;

    /* states */
    --bm-success-bg: #062e27;
    --bm-success-fg: #a7f3d0;
    --bm-error-bg: #2a0d0d;
    --bm-error-fg: #fecaca;

    --bm-accent: #f59e0b;
    --bm-shadow: 0 18px 60px rgba(0, 0, 0, .45);
}

/* overlay */
.bm-overlay {
    position: fixed;
    inset: 0;
    background: var(--bm-overlay);
    display: none;
    /* JS toggles to block */
    z-index: 1000;
    padding: 20px;
    overflow-y: auto;
}

/* panel */
.bm-panel {
    max-width: 1000px;
    margin: 32px auto;
    background: var(--bm-panel);
    color: var(--bm-text);
    border: 1px solid var(--bm-border);
    border-radius: 16px;
    box-shadow: var(--bm-shadow);
    overflow: hidden;
    transform: translateY(8px);
    animation: bm-pop .18s ease-out forwards;
}

@keyframes bm-pop {
    to {
        transform: translateY(0);
    }
}

/* header */
.bm-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #0f172a;
    border-bottom: 1px solid var(--bm-border);
}

.bm-title {
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: .2px;
}

.bm-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--bm-border);
    background: transparent;
    color: var(--bm-muted);
    cursor: pointer;
    transition: all .15s ease;
}

.bm-close:hover {
    background: #0b1220;
    color: #fff;
    border-color: #475569;
}

/* body/layout */
.bm-body {
    padding: 16px;
}

.bm-content {
    width: 100%;
}

.bm-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 900px) {
    .bm-columns {
        grid-template-columns: 1.1fr 1.4fr;
        gap: 20px;
    }
}

.bm-col {
    background: transparent;
}

.bm-col--summary {
    border-right: none;
}

@media (min-width: 900px) {
    .bm-col--summary {
        border-right: 1px dashed var(--bm-border);
        padding-right: 16px;
    }

    .bm-col--form {
        padding-left: 8px;
    }
}

/* typography */
.bm-subtitle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .95rem;
    font-weight: 800;
    margin: 0 0 10px;
    color: #f3f4f6;
}

.bm-muted {
    color: var(--bm-muted);
    font-size: .9rem;
}

/* list/summary */
.bm-list {
    display: grid;
    gap: 10px;
}

.bm-empty {
    padding: 14px;
    border: 1px dashed var(--bm-border);
    border-radius: 12px;
    text-align: center;
    color: var(--bm-muted);
    background: rgba(17, 24, 39, .35);
}

.bm-summary {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--bm-border);
}

.bm-summary__row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    color: #e5e7eb;
    font-weight: 500;
}

.bm-summary__total {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-weight: 900;
    color: #fff;
}

.bm-note {
    margin: 6px 0 0;
    color: var(--bm-muted);
    font-size: .85rem;
}

/* form */
.bm-form {
    display: grid;
    gap: 12px;
}

.bm-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media (min-width: 600px) {
    .bm-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.bm-field {
    display: grid;
    gap: 6px;
}

.bm-label {
    font-size: .9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #d1d5db;
}

.bm-label__icon {
    display: inline-flex;
    width: 18px;
    height: 18px;
    align-items: center;
    justify-content: center;
}

.bm-input {
    width: 100%;
    border: 1px solid var(--bm-border);
    border-radius: 10px;
    padding: 10px 12px;
    font-size: .95rem;
    outline: none;
    transition: border-color .15s, box-shadow .15s, background .15s, color .15s;
    background: #0b1220;
    color: #e5e7eb;
}

.bm-input::placeholder {
    color: #6b7280;
}

.bm-input:focus {
    border-color: var(--bm-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, .22);
    background: #0e1730;
}

.bm-textarea {
    min-height: 96px;
    resize: vertical;
}

/* callout */
.bm-callout {
    border: 1px solid #7c2d12;
    background: rgba(124, 45, 18, .15);
    border-radius: 12px;
    padding: 12px;
}

.bm-callout__title {
    margin: 0 0 6px;
    font-weight: 900;
    color: #fb923c;
}

.bm-callout__list {
    margin: 0;
    padding-left: 18px;
    color: #e5e7eb;
}

.bm-accent {
    color: var(--bm-accent);
    font-weight: 800;
}

/* actions/buttons */
.bm-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 6px;
}

.bm-btn {
    appearance: none;
    border: 1px solid var(--bm-border);
    border-radius: 10px;
    padding: 10px 14px;
    font-weight: 700;
    cursor: pointer;
    background: #0b1220;
    color: #e5e7eb;
    transition: all .15s ease;
}

.bm-btn:hover {
    background: #0e1730;
    border-color: #475569;
}

.bm-btn--primary {
    background: var(--bm-primary);
    border-color: var(--bm-primary);
    color: #0b0f1a;
}

.bm-btn--primary:hover {
    background: var(--bm-primary-600);
    border-color: var(--bm-primary-600);
    color: #fff;
}

.bm-btn--ghost {
    background: transparent;
}

/* alerts */
.bm-alert {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    border-radius: 12px;
    padding: 14px;
    border: 1px solid var(--bm-border);
    background: #0b1220;
}

.bm-alert--success {
    background: var(--bm-success-bg);
    color: var(--bm-success-fg);
    border-color: #065f46;
}

.bm-alert--error {
    background: var(--bm-error-bg);
    color: var(--bm-error-fg);
    border-color: #7f1d1d;
}

.bm-alert__icon {
    font-size: 18px;
    line-height: 1;
}

.bm-alert__title {
    margin: 0 0 4px;
    font-weight: 900;
    color: #fff;
}

/* spinner */
.bm-spin {
    animation: bm-rot 1s linear infinite;
}

@keyframes bm-rot {
    to {
        transform: rotate(360deg);
    }
}

/* accessibility/focus */
.bm-panel:focus-visible,
.bm-close:focus-visible,
.bm-btn:focus-visible,
.bm-input:focus-visible {
    outline: 2px solid var(--bm-primary);
    outline-offset: 2px;
}

/* utility: let inline style display:block reveal it */
.bm-overlay[style*="display: block"] {
    display: block;
}

/* respect reduced motion */
@media (prefers-reduced-motion: reduce) {
    .bm-panel {
        animation: none;
    }

    .bm-spin {
        animation-duration: 2s;
    }
}
