/* ============================================================
   Bonjuk Suites — Frontend Styles
   Brand: dark, earthy, refined editorial  (bon.lumino1.com)
   v1.0.2 — fixes: pink theme bleed, arrow hover, mobile layout
   ============================================================ */

/* ── Reset & base ─────────────────────────────────────── */
.bsuites-section *,
.bsuites-section *::before,
.bsuites-section *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Hard-reset ALL buttons inside the plugin to prevent theme bleed */
.bsuites-section button,
.bsuites-section button:hover,
.bsuites-section button:focus,
.bsuites-section button:focus-visible,
.bsuites-section button:active {
    -webkit-appearance: none;
    appearance: none;
    outline: none !important;
    box-shadow: none !important;
    border-radius: 0;
    background-color: transparent;
    color: inherit;
    font-family: inherit;
    line-height: inherit;
}

.bsuites-section {
    background: var(--bs-bg, #0d0d0b);
    color: var(--bs-text, #f0ede6);
    font-family: var(--bs-font-body, system-ui, sans-serif);
    padding: 80px 24px;
    width: 100%;
}

/* ── Section header ───────────────────────────────────── */
.bsuites-section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 56px;
}

.bsuites-section-title {
    font-family: var(--bs-font-head, Georgia, serif);
    font-size: clamp(28px, 4vw, 44px);
    font-weight: 400;
    color: var(--bs-text, #f0ede6);
    line-height: 1.15;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.bsuites-section-sub {
    font-size: 16px;
    color: var(--bs-muted, #9e9b92);
    line-height: 1.75;
    max-width: 560px;
    margin: 0 auto;
}

/* ── Badge ────────────────────────────────────────────── */
.bsuites-badge {
    display: inline-block;
    background: var(--bs-badge-bg, #1D9E75);
    color: var(--bs-badge-text, #fff);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 3px 9px;
    border-radius: 3px;
    line-height: 1.5;
}

/* ── CTA button ───────────────────────────────────────── */
.bsuites-btn {
    display: inline-block;
    background: var(--bs-accent, #1D9E75);
    color: #fff !important;
    text-decoration: none !important;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.05em;
    padding: 12px 28px;
    border-radius: 3px;
    transition: background 0.2s;
    border: none !important;
    box-shadow: none !important;
    cursor: pointer;
}

.bsuites-btn:hover,
.bsuites-btn:focus {
    background: var(--bs-accent-hover, #0F6E56) !important;
    color: #fff !important;
    text-decoration: none !important;
    box-shadow: none !important;
    outline: none !important;
}

/* ── Empty state ──────────────────────────────────────── */
.bsuites-empty {
    text-align: center;
    color: var(--bs-muted, #9e9b92);
    padding: 40px;
    font-size: 15px;
}

.bsuites-empty a { color: var(--bs-accent, #1D9E75); }

/* ============================================================
   SIDEBAR + GRID LAYOUT (desktop tab mode)
   ============================================================ */

.bsuites-sg-wrap {
    max-width: 1120px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 0;
    align-items: start;
}

/* ── Sidebar ──────────────────────────────────────────── */
.bsuites-sg-sidebar {
    display: flex;
    flex-direction: column;
    background: var(--bs-card-bg, #1a1a17);
    padding: 8px 0;
    position: sticky;
    top: 80px;
}

.bsuites-sg-cat {
    display: block;
    width: 100%;
    padding: 14px 24px;
    text-align: left;
    background: transparent !important;
    border: none !important;
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
    box-shadow: none !important;
    outline: none !important;
    -webkit-appearance: none;
    appearance: none;
    border-radius: 0 !important;
    font-family: var(--bs-font-body, system-ui, sans-serif);
    font-size: 13px;
    font-weight: 500;
    color: var(--bs-muted, #9e9b92) !important;
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
    letter-spacing: 0.02em;
    position: relative;
}

.bsuites-sg-cat::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--bs-accent, #1D9E75);
    transition: width 0.2s;
}

.bsuites-sg-cat:hover {
    color: var(--bs-text, #f0ede6) !important;
    background: rgba(255,255,255,0.04) !important;
}

.bsuites-sg-cat:focus,
.bsuites-sg-cat:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}

.bsuites-sg-cat.bsuites-sg-cat-active {
    color: var(--bs-text, #f0ede6) !important;
}

.bsuites-sg-cat.bsuites-sg-cat-active::after {
    width: 100%;
}

/* ── Grid ─────────────────────────────────────────────── */
.bsuites-sg-main {
    padding-left: 2px;
}

.bsuites-sg-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2px;
}

.bsuites-sg-card {
    background: var(--bs-card-bg, #1a1a17);
    cursor: pointer;
    transition: opacity 0.15s;
    position: relative;
}

.bsuites-sg-card:hover { opacity: 0.88; }

.bsuites-sg-img {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #2a2a26;
    flex-shrink: 0;
    /* Force consistent height — no aspect-ratio, no padding tricks */
    height: 220px !important;
    max-height: 220px !important;
    min-height: 220px !important;
}

.bsuites-sg-img img {
    display: block !important;
    width: 100% !important;
    height: 220px !important;
    max-height: 220px !important;
    object-fit: cover !important;
    object-position: center center !important;
    position: static !important;
    transition: transform 0.4s ease;
}

.bsuites-sg-card:hover .bsuites-sg-img img {
    transform: scale(1.05);
}

.bsuites-sg-no-img {
    width: 100%;
    height: 220px;
    background: #2a2a26;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bsuites-sg-badge {
    position: absolute;
    top: 8px;
    right: 8px;
}

.bsuites-sg-card-body {
    padding: 12px 14px 16px;
}

.bsuites-sg-card-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--bs-text, #f0ede6);
    margin-bottom: 4px;
    letter-spacing: 0.01em;
}

.bsuites-sg-card-meta {
    font-size: 12px;
    color: var(--bs-muted, #9e9b92);
}

/* ── Modal overlay ────────────────────────────────────── */
.bsuites-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.82);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    backdrop-filter: blur(4px);
}

.bsuites-modal-box {
    background: var(--bs-card-bg, #1a1a17);
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    border-radius: 4px;
}

.bsuites-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    width: 32px;
    height: 32px;
    background: rgba(0,0,0,0.5) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 50% !important;
    box-shadow: none !important;
    outline: none !important;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-appearance: none;
    appearance: none;
    padding: 0 !important;
    line-height: 1;
}

.bsuites-modal-close:hover { background: rgba(0,0,0,0.9) !important; }

.bsuites-modal-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 480px;
}

.bsuites-modal-gallery {
    position: relative;
    background: #111;
    min-height: 480px;
    overflow: hidden;
}

.bsuites-modal-slider {
    position: absolute;
    inset: 0;
}

.bsuites-modal-slides {
    display: flex;
    height: 100%;
    transition: transform 0.4s ease;
}

.bsuites-modal-slide {
    min-width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.bsuites-modal-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 2;
}

.bsuites-modal-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
    cursor: pointer;
    display: block;
    border: none !important;
    padding: 0 !important;
}

.bsuites-modal-dot.active { background: var(--bs-accent, #1D9E75); }

/* Modal right column — proper spacing */
.bsuites-modal-layout .bsuites-panel-info {
    overflow-y: auto;
    max-height: 90vh;
    padding: 36px 36px 40px;
    gap: 16px;
    display: flex;
    flex-direction: column;
}

.bsuites-modal-layout .bsuites-panel-title {
    font-size: 28px;
    margin-bottom: 8px;
}

.bsuites-modal-layout .bsuites-meta-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.bsuites-modal-layout .bsuites-meta-pill {
    font-size: 12px;
    padding: 5px 12px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    color: var(--bs-muted, #9e9b92);
    letter-spacing: 0.04em;
}

.bsuites-modal-layout .bsuites-panel-desc {
    font-size: 14px;
    color: var(--bs-muted, #9e9b92);
    line-height: 1.75;
    border-top: 1px solid rgba(255,255,255,0.07);
    padding-top: 16px;
}

.bsuites-modal-layout .bsuites-panel-features {
    border-top: 1px solid rgba(255,255,255,0.07);
    padding-top: 16px;
}

.bsuites-modal-layout .bsuites-features-label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--bs-muted, #9e9b92);
    margin-bottom: 12px;
}

.bsuites-modal-layout .bsuites-features-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px;
    list-style: none;
}

.bsuites-modal-layout .bsuites-feature-item {
    font-size: 13px;
    color: var(--bs-text, #f0ede6);
    display: flex;
    align-items: flex-start;
    gap: 7px;
    line-height: 1.5;
}

.bsuites-modal-layout .bsuites-feature-check {
    color: var(--bs-accent, #1D9E75);
    font-weight: 700;
    flex-shrink: 0;
    font-size: 12px;
    margin-top: 1px;
}

.bsuites-modal-layout .bsuites-panel-cta {
    margin-top: auto;
    padding-top: 4px;
}

.bsuites-modal-layout .bsuites-btn {
    padding: 13px 32px;
    font-size: 13px;
    letter-spacing: 0.06em;
}

/* ============================================================
   GRID LAYOUT
   ============================================================ */

.bsuites-grid {
    max-width: 1120px;
    margin: 0 auto;
    display: grid;
    gap: 2px;
}

.bsuites-grid-2 { grid-template-columns: repeat(2, 1fr); }
.bsuites-grid-3 { grid-template-columns: repeat(3, 1fr); }
.bsuites-grid-4 { grid-template-columns: repeat(4, 1fr); }

.bsuites-grid-card {
    background: var(--bs-card-bg, #1a1a17);
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.2s;
}

.bsuites-grid-card:hover { transform: translateY(-2px); }

.bsuites-badge-abs {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 1;
}

.bsuites-grid-img {
    height: 220px;
    background-size: cover;
    background-position: center;
}

.bsuites-no-img {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #2a2a26;
}

.bsuites-no-img .dashicons {
    font-size: 36px;
    width: 36px;
    height: 36px;
    color: #444;
}

.bsuites-grid-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.bsuites-grid-title {
    font-family: var(--bs-font-head, Georgia, serif);
    font-size: 20px;
    font-weight: 400;
    color: var(--bs-text, #f0ede6);
    letter-spacing: -0.01em;
}

.bsuites-grid-tag {
    font-size: 12px;
    color: var(--bs-accent, #1D9E75);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-weight: 600;
}

.bsuites-grid-desc {
    font-size: 14px;
    color: var(--bs-muted, #9e9b92);
    line-height: 1.7;
}

.bsuites-feature-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 4px;
}

.bsuites-feature-list li {
    font-size: 13px;
    color: var(--bs-muted, #9e9b92);
    padding-left: 14px;
    position: relative;
}

.bsuites-feature-list li::before {
    content: '—';
    position: absolute;
    left: 0;
    color: var(--bs-accent, #1D9E75);
}

.bsuites-grid-body .bsuites-btn { margin-top: auto; }

/* ============================================================
   LIST LAYOUT
   ============================================================ */

.bsuites-list {
    max-width: 1120px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.bsuites-list .bsuites-panel { display: block; }
.bsuites-list .bsuites-panel-inner { grid-template-columns: 420px 1fr; }

/* ============================================================
   MOBILE CARDS (< 640px) — simple static stack, no JS needed
   ============================================================ */

.bsuites-mobile-cards {
    display: none; /* shown only on mobile via breakpoint below */
    flex-direction: column;
    gap: 2px;
    max-width: 1120px;
    margin: 0 auto;
}

.bsuites-mobile-card {
    background: var(--bs-card-bg, #1a1a17);
    overflow: hidden;
}

/* ── Mobile slider ────────────────────────────────────── */
.bsuites-mc-slider {
    position: relative;
    height: 260px;
    overflow: hidden;
    background: #111;
}

.bsuites-mc-slides {
    display: flex;
    height: 100%;
    transition: transform 0.4s ease;
}

.bsuites-mc-slide {
    min-width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.bsuites-mc-no-img {
    height: 200px;
    background: #2a2a26;
}

.bsuites-mc-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.2) !important;
    background: rgba(0,0,0,0.55) !important;
    color: #fff !important;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    box-shadow: none !important;
    outline: none !important;
    padding: 0 !important;
    -webkit-appearance: none;
    appearance: none;
    touch-action: manipulation;
}

.bsuites-mc-btn:hover,
.bsuites-mc-btn:focus { background: rgba(0,0,0,0.85) !important; outline: none !important; box-shadow: none !important; }
.bsuites-mc-prev { left: 10px; }
.bsuites-mc-next { right: 10px; }

.bsuites-mc-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 2;
}

.bsuites-mc-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
    display: block;
}

.bsuites-mc-dot.active { background: var(--bs-accent, #1D9E75); }

/* ── Mobile card body ─────────────────────────────────── */
.bsuites-mc-body {
    padding: 22px 20px 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bsuites-mc-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.bsuites-mc-title {
    font-family: var(--bs-font-head, Georgia, serif);
    font-size: 22px;
    font-weight: 400;
    color: var(--bs-text, #f0ede6);
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.bsuites-mc-tag {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--bs-accent, #1D9E75);
    margin-top: -4px;
}

.bsuites-mc-desc {
    font-size: 14px;
    color: var(--bs-muted, #9e9b92);
    line-height: 1.7;
}

.bsuites-mc-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 7px;
    border-top: 1px solid rgba(255,255,255,0.07);
    padding-top: 14px;
}

.bsuites-mc-features li {
    font-size: 13px;
    color: var(--bs-text, #f0ede6);
    display: flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.5;
}

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

@media (max-width: 1024px) {
    .bsuites-sg-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
    /* Sidebar goes horizontal on tablet */
    .bsuites-sg-wrap { grid-template-columns: 1fr; }
    .bsuites-sg-sidebar {
        flex-direction: row;
        flex-wrap: wrap;
        position: static;
        gap: 2px;
        padding: 0;
        margin-bottom: 2px;
    }
    .bsuites-sg-cat {
        flex: 0 0 auto;
        padding: 10px 16px;
        border-bottom: none !important;
        font-size: 12px;
    }
    .bsuites-sg-cat::after { bottom: 0; height: 2px; }
    .bsuites-sg-grid { grid-template-columns: repeat(3, 1fr); }
    .bsuites-sg-main { padding-left: 0; }

    /* Modal goes single column */
    .bsuites-modal-layout { grid-template-columns: 1fr; }
    .bsuites-modal-gallery { min-height: 260px; }
    .bsuites-modal-slider { position: relative; height: 260px; }

    /* Panel resets */
    .bsuites-panel-inner,
    .bsuites-list .bsuites-panel-inner { grid-template-columns: 1fr; }
    .bsuites-panel-gallery { min-height: 240px; }
    .bsuites-slider { position: relative; height: 240px; }
    .bsuites-panel-info { padding: 28px 24px; }
    .bsuites-features-grid { grid-template-columns: 1fr; }

    /* Grid layout */
    .bsuites-grid-2,
    .bsuites-grid-3,
    .bsuites-grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .bsuites-section { padding: 48px 16px; }

    /* Hide desktop tab/sidebar layout entirely, show mobile cards */
    .bsuites-sg-wrap,
    .bsuites-tabs-nav,
    .bsuites-panels {
        display: none !important;
    }
    .bsuites-mobile-cards { display: flex; }

    /* Grid goes single column */
    .bsuites-grid-2,
    .bsuites-grid-3,
    .bsuites-grid-4 { grid-template-columns: 1fr; }

    /* Modal full screen on mobile */
    .bsuites-modal-overlay { padding: 0; }
    .bsuites-modal-box { max-height: 100vh; border-radius: 0; }
}
