/* ============================================================
   BOXIN ELEMENTOR WIDGET
   ============================================================ */

.bxw-wrapper {
    --bxw-primary:      #8B0000;
    --bxw-primary-dk:   #6b0000;
    --bxw-text:         #1a1a1a;
    --bxw-muted:        #6b6b6b;
    --bxw-border:       #e2e2e2;
    --bxw-bg-light:     #f8f8f8;
    font-family: inherit;
    width: 100%;
}

/* ── Location tabs ──────────────────────────────────────── */
.bxw-loc-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.bxw-loc-tab {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 9px 20px;
    background: #fff;
    border: 1.5px solid var(--bxw-border);
    border-radius: 6px;
    font-size: 13.5px; font-weight: 600;
    color: #555;
    cursor: pointer; transition: all .18s;
}
.bxw-loc-tab:hover  { border-color: var(--bxw-primary); color: var(--bxw-primary); }
.bxw-loc-tab.active {
    background: var(--bxw-primary);
    border-color: var(--bxw-primary);
    color: #fff;
}

.bxw-loc-panel { display: none; }
.bxw-loc-panel.active { display: block; }

/* ── Group tabs (size selector pills) ───────────────────── */
.bxw-group-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 22px;
}
.bxw-group-tab {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 9px 18px;
    background: #fff;
    border: 2px solid var(--bxw-border);
    border-radius: 8px;
    font-size: 14px; font-weight: 700;
    color: #333;
    cursor: pointer; transition: all .18s;
}
.bxw-group-tab:hover:not([disabled]) {
    border-color: var(--bxw-primary);
    color: var(--bxw-primary);
}
.bxw-group-tab.active {
    background: var(--bxw-primary);
    border-color: var(--bxw-primary);
    color: #fff;
}
.bxw-group-tab.active .bxw-avail-badge {
    background: rgba(255,255,255,.3);
    color: #fff;
}
.bxw-group-tab.unavailable { opacity: .4; cursor: not-allowed; }

/* ── Size panel (detail card, one per group) ────────────── */
.bxw-size-panel { display: none; }
.bxw-size-panel.active { display: block; }

.bxw-panel-card {
    background: #fff;
    border: 1px solid var(--bxw-border);
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,.07);
    overflow: hidden;
    width: 100%;
}

.bxw-panel-heading {
    text-align: center;
    padding: 30px 32px 24px;
    border-bottom: 1px solid #f0f0f0;
}
.bxw-size-title {
    font-size: 2.6rem;
    font-weight: 900;
    color: var(--bxw-text);
    margin: 0;
    line-height: 1;
    letter-spacing: -1px;
}

.bxw-panel-inner {
    display: grid;
    grid-template-columns: minmax(200px, 280px) 1fr;
    align-items: stretch;
    width: 100%;
}
.bxw-panel-inner.bxw-has-map {
    grid-template-columns: minmax(180px, 240px) 1fr minmax(200px, 280px);
}

.bxw-panel-img {
    background: var(--bxw-bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px 28px;
    border-right: 1px solid #f0f0f0;
}
.bxw-panel-img img {
    width: 100%;
    max-width: 260px;
    border-radius: 8px;
    display: block;
    object-fit: contain;
    max-height: 260px;
}

.bxw-panel-info {
    padding: 32px 36px;
    min-width: 0;
}

/* ── Column wrappers ────────────────────────────────────── */
.bxw-image-column {
    display: flex;
    flex-direction: column;
    background: var(--bxw-bg-light);
    border-right: 1px solid #f0f0f0;
}
.bxw-content-column {
    min-width: 0;
    display: flex;
    flex-direction: column;
}
.bxw-map-column {
    border-left: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
}

/* ── Image button ───────────────────────────────────────── */
.bxw-image-button {
    display: block;
    width: calc(100% - 56px);
    margin: 0 28px 28px;
    padding: 11px 16px;
    background: var(--bxw-primary);
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
    text-decoration: none !important;
    border-radius: 6px;
    letter-spacing: .5px;
    transition: background .18s;
    flex-shrink: 0;
}
.bxw-image-button:hover { background: var(--bxw-primary-dk); }

/* ── Location map ───────────────────────────────────────── */
.bxw-location-map {
    width: 100%;
    height: 100%;
    min-height: 300px;
    overflow: hidden;
}
.bxw-location-map iframe {
    width: 100% !important;
    height: 100%;
    min-height: 300px;
    max-width: 100% !important;
    border: none;
    display: block;
}

/* ── Panel info content ─────────────────────────────────── */
.bxw-size-desc {
    font-size: 15px;
    color: var(--bxw-muted);
    margin: 0 0 22px;
    line-height: 1.65;
}

.bxw-price-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}
.bxw-price {
    font-size: 34px;
    font-weight: 900;
    color: var(--bxw-text);
}
.bxw-price-suffix {
    font-size: 14px;
    color: var(--bxw-muted);
}

.bxw-avail-indicator { margin-bottom: 20px; }

.bxw-badge {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px; font-weight: 600;
}
.bxw-badge.available   { background: #e8f5e9; color: #1b5e20; }
.bxw-badge.urgent      { background: #fff3e0; color: #bf360c; }
.bxw-badge.unavailable { background: #ffebee; color: #b71c1c; }

/* shared count badge (used in group tabs + m² tabs) */
.bxw-avail-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 20px; height: 20px; padding: 0 5px;
    border-radius: 10px; font-size: 10px; font-weight: 700;
    background: #2e7d32; color: #fff; line-height: 1;
}
.bxw-avail-badge.urgent { background: #e65100; }
.bxw-avail-badge.zero   { background: #bdbdbd; }

/* ── m² sub-tabs ────────────────────────────────────────── */
.bxw-m2-section { margin-bottom: 14px; }
.bxw-m2-label {
    font-size: 10.5px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .6px;
    color: var(--bxw-muted); margin: 0 0 7px;
}
.bxw-m2-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.bxw-m2-tab {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 6px 13px;
    background: #fff; border: 1.5px solid var(--bxw-border);
    border-radius: 6px; font-size: 12.5px; font-weight: 600;
    color: #555; cursor: pointer; transition: all .15s;
}
.bxw-m2-tab:hover:not([disabled]) { border-color: var(--bxw-primary); color: var(--bxw-primary); }
.bxw-m2-tab.active { background: var(--bxw-primary); border-color: var(--bxw-primary); color: #fff; }
.bxw-m2-tab.active .bxw-avail-badge { background: rgba(255,255,255,.3); }
.bxw-m2-tab.unavailable { opacity: .38; cursor: not-allowed; text-decoration: line-through; }
/* Single-size group: tab shows the assigned size as an informational indicator, not a choice */
.bxw-m2-tab.only-size { cursor: default; pointer-events: none; }
.bxw-m2-tab .bxw-avail-badge { font-size: 9.5px; min-width: 16px; height: 16px; padding: 0 3px; border-radius: 8px; }

/* ── Billing choice ─────────────────────────────────────── */
.bxw-billing-choice {
    margin-bottom: 14px;
}
.bxw-billing-title {
    font-size: 10.5px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .6px;
    color: var(--bxw-muted); margin: 0 0 8px;
}
.bxw-billing-option {
    display: flex; align-items: flex-start; gap: 9px;
    border: 1.5px solid var(--bxw-border);
    border-radius: 7px;
    padding: 11px 12px;
    cursor: pointer;
    transition: border-color .18s, background .18s;
    background: #fff;
    margin-bottom: 8px;
}
.bxw-billing-option:last-of-type { margin-bottom: 0; }
.bxw-billing-option:hover { border-color: var(--bxw-primary); background: rgba(139,0,0,.03); }
.bxw-billing-option:has(.bxw-billing-radio:checked) {
    border-color: var(--bxw-primary);
    background: rgba(139,0,0,.03);
}
.bxw-billing-radio {
    -webkit-appearance: none; appearance: none;
    flex-shrink: 0; width: 15px; height: 15px; margin-top: 2px;
    border: 1.5px solid #ccc; border-radius: 50%;
    background: #fff; cursor: pointer; transition: all .15s;
}
.bxw-billing-radio:checked {
    border-color: var(--bxw-primary);
    background: var(--bxw-primary);
    box-shadow: inset 0 0 0 3px #fff;
}
.bxw-billing-icon { font-size: 16px; flex-shrink: 0; line-height: 1.3; }
.bxw-billing-label { display: flex; flex-direction: column; gap: 1px; flex: 1; min-width: 0; }
.bxw-billing-label strong { font-size: 12px; font-weight: 700; color: var(--bxw-text); line-height: 1.3; }
.bxw-billing-label small  { font-size: 10.5px; color: var(--bxw-muted); line-height: 1.35; }
.bxw-billing-error {
    font-size: 11.5px; font-weight: 600;
    color: #c62828; background: #ffebee;
    border: 1px solid #ef9a9a; border-radius: 5px;
    padding: 7px 10px; margin: 8px 0 0;
}

/* ── Reserve CTA ────────────────────────────────────────── */
.bxw-reserve-btn {
    display: block; width: 100%;
    background: var(--bxw-primary); color: #fff !important;
    font-size: 14px; font-weight: 800; letter-spacing: 1.2px;
    padding: 14px; border: none; border-radius: 6px;
    cursor: pointer; text-transform: uppercase;
    transition: background .18s, transform .1s;
    text-decoration: none !important;
    margin-bottom: 0;
}
.bxw-reserve-btn:hover:not(:disabled) { background: var(--bxw-primary-dk); transform: translateY(-1px); }
.bxw-reserve-btn.disabled,
.bxw-reserve-btn:disabled { background: #bdbdbd; cursor: not-allowed; transform: none; }

/* ── Fits icons ─────────────────────────────────────────── */
.bxw-fits {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--bxw-border);
}
.bxw-fits-label {
    display: block;
    font-size: 13px; font-weight: 700;
    color: var(--bxw-text);
    margin-bottom: 12px;
}
.bxw-fits-icons { display: flex; gap: 10px; flex-wrap: wrap; }
.bxw-fit-icon {
    width: 48px; height: 48px;
    border: 2px solid var(--bxw-primary);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    transition: all .15s;
    background: #fff;
    flex-shrink: 0;
}
.bxw-fit-icon img {
    width: 26px; height: 26px;
    object-fit: contain; border-radius: 0;
}
.bxw-fit-icon > i,
.bxw-fit-icon > svg {
    width: 22px; height: 22px;
    color: var(--bxw-primary);
}
.bxw-fit-icon:hover {
    background: var(--bxw-primary);
    transform: scale(1.08);
}
.bxw-fit-icon:hover > i,
.bxw-fit-icon:hover > svg { color: #fff; }

/* ── Timer ──────────────────────────────────────────────── */
.bxw-timer-bar {
    margin-top: 18px;
    background: #fff3e0; border: 1px solid #ffe0b2;
    color: #e65100; font-weight: 700;
    padding: 12px 18px; border-radius: 6px; font-size: 14px;
}

/* ── Responsive ─────────────────────────────────────────── */
/* Tablet: 2 columns — image+content side by side, map moves below */
@media (max-width: 900px) {
    .bxw-panel-inner,
    .bxw-panel-inner.bxw-has-map {
        grid-template-columns: minmax(160px, 220px) 1fr;
    }
    .bxw-map-column {
        grid-column: 1 / -1;
        border-left: none;
        border-top: 1px solid #f0f0f0;
    }
    .bxw-location-map,
    .bxw-location-map iframe { min-height: 260px; }
}

/* Mobile: single column stack */
@media (max-width: 760px) {
    .bxw-panel-inner,
    .bxw-panel-inner.bxw-has-map {
        grid-template-columns: 1fr;
    }
    .bxw-image-column {
        border-right: none;
        border-bottom: 1px solid #f0f0f0;
    }
    .bxw-map-column {
        grid-column: auto;
        border-top: 1px solid #f0f0f0;
    }
    .bxw-panel-img {
        border-right: none;
        padding: 24px 20px;
    }
    .bxw-image-button {
        width: calc(100% - 40px);
        margin: 0 20px 20px;
    }
    .bxw-panel-info { padding: 24px 20px; }
    .bxw-price { font-size: 26px; }
    .bxw-size-title { font-size: 2rem; }
    .bxw-location-map,
    .bxw-location-map iframe { min-height: 220px; }
}

@media (max-width: 480px) {
    .bxw-group-tab { padding: 8px 13px; font-size: 13px; }
    .bxw-panel-heading { padding: 20px 20px 16px; }
    .bxw-reserve-btn { font-size: 13px; padding: 13px; }
}

/* ── Elementor overrides ─────────────────────────────────── */
.elementor-widget-boxin_reservation .bxw-wrapper,
.elementor-widget .bxw-wrapper {
    width: 100% !important; max-width: 100% !important; box-sizing: border-box;
}
