/**
 * Brasserio Portal - Book Table Styles
 * Material Design 3 based styling for table reservation flow
 *
 * @package BrasserioPortal
 * @version 1.0.0
 */

/* ===== ROOT VARIABLES ===== */
:root {
    --br-primary: #1B3C57;
    --br-primary-light: #2B5277;
    --br-primary-dark: #0B2C47;
    --br-on-primary: #ffffff;

    --br-secondary: #6AA3D2;
    --br-on-secondary: #ffffff;

    --br-success: #2E7D32;
    --br-success-light: #EDF7ED;
    --br-error: #D32F2F;
    --br-error-light: #FDEDED;

    --br-surface: #ffffff;
    --br-surface-variant: #F4F6FA;
    --br-on-surface: #1B3C57;
    --br-on-surface-variant: #6B7280;
    --br-surface-card: #F4F6FA;
    --br-outline: #E5E7EB;
    --br-outline-variant: #D1D5DB;

    --br-shadow: 0 2px 8px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
    --br-shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 0.06);

    --br-radius: 12px;
    --br-radius-sm: 8px;
    --br-radius-lg: 16px;

    --br-transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);

     --dp-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);

     --dp-color-bg: #ffffff;
     --dp-color-surface: #ffffff;
     --dp-color-border: #e3e3e7;
     --dp-color-border-strong: #c4c4ce;
     --dp-color-text: #1B3C57;
     --dp-color-muted: #8a8fa3;

     --dp-color-primary: #1B3C57;
     --dp-color-primary-soft: #2B5277;
     --dp-color-primary-contrast: #ffffff;

     --dp-color-hover: #f3f4f6;
     --dp-color-disabled: #e5e7eb;
     --dp-color-today-border: #1B3C57;

     --dp-z-index: 1000;
}

/* ===== CONTAINER ===== */
.br-book-table-container {
    max-width: 80%;
    min-height: 100vh;
    margin: 100px auto 50px auto;
    padding: 24px;
    position: relative;
}

.general-card {
    background: var(--br-surface-card);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius-lg);
    padding: 24px;
    box-shadow: var(--br-shadow);
    transition: var(--br-transition);
}

.general-card:hover {
    box-shadow: var(--br-shadow-lg);
}

/* ===== HEADER ===== */
.br-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--br-outline);
}

.br-back-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: var(--br-on-surface);
    border-radius: var(--br-radius-sm);
    cursor: pointer;
    transition: var(--br-transition);
}

.br-back-btn:hover {
    background: var(--br-surface-variant);
}

.br-back-btn.hidden {
    display: none;
}

.br-step-title {
    flex: 1;
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: var(--br-on-surface);
}

/* Progress Dots */
.br-progress {
    display: flex;
    gap: 8px;
}

.br-progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--br-outline);
    transition: var(--br-transition);
}

.br-progress-dot.active {
    background: var(--br-primary);
    transform: scale(1.25);
}

/* ===== TOAST NOTIFICATION ===== */
.br-toast {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    z-index: 1000;
    background: var(--br-on-surface);
    color: var(--br-on-primary);
    padding: 12px 24px;
    border-radius: var(--br-radius);
    box-shadow: var(--br-shadow-lg);
    font-size: 14px;
    font-weight: 500;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.br-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.br-toast.error {
    background: var(--br-error);
}

/* ===== LOADING OVERLAY ===== */
.br-loader {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.br-loader.hidden {
    display: none;
}

.br-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--br-outline);
    border-top-color: var(--br-primary);
    border-radius: 50%;
    animation: br-spin 0.8s linear infinite;
}

@keyframes br-spin {
    to { transform: rotate(360deg); }
}

.br-loader-text {
    color: var(--br-on-surface-variant);
    font-size: 14px;
    font-weight: 500;
}

/* ===== STEPS ===== */
.br-step {
    animation: br-fade-in 0.3s ease-out;
}

.br-step.hidden {
    display: none;
}

@keyframes br-fade-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== STEP 0: SEARCH ===== */
.br-search-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.br-search-input-wrapper {
    position: relative;
    flex: 1;
}

.br-search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--br-on-surface-variant);
    pointer-events: none;
}

.br-search-input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    background: var(--br-surface);
    font-size: 16px;
    color: var(--br-on-surface);
    transition: var(--br-transition);
}

.br-search-input:focus {
    outline: none;
    border-color: var(--br-primary);
    box-shadow: 0 0 0 3px rgba(27, 60, 87, 0.1);
}

.br-location-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 56px;
    height: 56px;
    border: 2px solid var(--br-outline);
    border-radius: var(--br-radius);
    background: var(--br-surface);
    color: var(--br-primary);
    cursor: pointer;
    transition: var(--br-transition);
}

.br-location-btn:hover {
    background: var(--br-surface-variant);
    border-color: var(--br-primary);
}

.br-filter-label {
    font-size: 14px;
    font-weight: 500;
    line-height: 16px;
    margin-bottom:0;
    color: var(--br-on-surface-variant);
}

.br-filter-select {
    padding: 12px 16px;
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    background: var(--br-surface);
    font-size: 14px;
    color: var(--br-on-surface);
    cursor: pointer;
    transition: var(--br-transition);
}

.br-filter-select:focus {
    outline: none;
    border-color: var(--br-primary);
    box-shadow: 0 0 0 3px rgba(27, 60, 87, 0.1);
}

.br-filter-select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}



 /* Custom Select Dropdown */
 .br-custom-select-wrapper {
     position: relative;
     user-select: none;
 }

 .br-custom-select {
     position: relative;
 }

 .br-custom-select-trigger {
     position: relative;
     display: flex;
     align-items: center;
     justify-content: space-between;
     padding: 12px 16px;
     font-size: 14px;
     font-weight: 500;
     color: var(--br-on-surface);
     background: var(--br-surface);
     border-radius: var(--br-radius);
     border: 2px solid var(--br-outline);
     cursor: pointer;
     transition: var(--br-transition);
 }

 .br-custom-select.open .br-custom-select-trigger {
     border-color: var(--br-primary);
     box-shadow: 0 0 0 3px rgba(27, 60, 87, 0.1);
 }

 .br-custom-select.disabled .br-custom-select-trigger {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: var(--br-surface-variant);
 }

 .br-custom-select-trigger .br-arrow {
     position: relative;
     height: 10px;
     width: 10px;
 }

 .br-custom-select-trigger .br-arrow::before,
 .br-custom-select-trigger .br-arrow::after {
     content: "";
     position: absolute;
     bottom: 0px;
     width: 0.15rem;
     height: 100%;
     transition: all 0.3s;
 }

 .br-custom-select-trigger .br-arrow::before {
     left: -3px;
     transform: rotate(-45deg);
     background-color: var(--br-on-surface-variant);
 }

 .br-custom-select-trigger .br-arrow::after {
     left: 3px;
     transform: rotate(45deg);
     background-color: var(--br-on-surface-variant);
 }

 .br-custom-select.open .br-arrow::before {
     transform: rotate(45deg);
 }

 .br-custom-select.open .br-arrow::after {
     transform: rotate(-45deg);
 }

 .br-custom-options {
     position: absolute;
     display: block;
     top: 100%;
     left: 0;
     right: 0;
     border: 1px solid var(--br-outline);
     border-radius: var(--br-radius);
     background: var(--br-surface);
     transition: all 0.2s;
     opacity: 0;
     visibility: hidden;
     pointer-events: none;
     z-index: 2;
     margin-top: 8px;
     max-height: calc(5 * 41px); /* 5 items visible */
     overflow-y: auto;
 }

 .br-custom-select.open .br-custom-options {
     opacity: 1;
     visibility: visible;
     pointer-events: all;
 }

 .br-custom-option {
     position: relative;
     display: block;
     padding: 12px 16px;
     font-size: 14px;
     color: var(--br-on-surface);
     cursor: pointer;
     transition: var(--br-transition);
     border-bottom: 1px solid var(--br-outline);
 }

 .br-custom-option:last-child {
     border-bottom: none;
 }

 .br-custom-option:hover {
     background-color: var(--br-surface-variant);
 }

 .br-custom-option.selected {
     color: var(--br-on-primary);
     background-color: var(--br-primary);
 }


 /* Results Title */
 .br-results-title {
     font-size: 20px;
     font-weight: 600;
     color: var(--br-on-surface);
     margin: 0 0 16px 0;
 }



/* Search Results */
.br-search-results {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 24px;
    min-height: 200px;
}

.br-no-results {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    color: var(--br-on-surface-variant);
    text-align: center;
}

/* Restaurant Card */
.br-restaurant-card {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius-lg);
    padding: 24px;
    box-shadow: var(--br-shadow);
    transition: var(--br-transition);
}

.br-restaurant-card:hover {
    box-shadow: var(--br-shadow-lg);
}

.br-restaurant-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--br-outline);
}

.br-restaurant-image {
    width: 80px;
    height: 80px;
    border-radius: var(--br-radius);
    object-fit: cover;
}

.br-restaurant-info {
    flex: 1;
}

.br-restaurant-name {
    font-size: 20px;
    font-weight: 600;
    color: var(--br-on-surface);
    margin: 0 0 8px 0;
    transition: color 0.2s;
}

.br-restaurant-name:hover {
    text-decoration: underline;
    color: var(--br-primary);
}

.br-cuisine-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--br-surface-variant);
    color: var(--br-primary);
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
}

 /* Branches List */
.br-branches-list {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 12px; /* Space for scrollbar */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

/* Custom scrollbar for branches list */
.br-branches-list::-webkit-scrollbar {
    height: 6px;
}
.br-branches-list::-webkit-scrollbar-track {
    background: var(--br-surface-variant);
    border-radius: 3px;
}
.br-branches-list::-webkit-scrollbar-thumb {
    background: var(--br-outline-variant);
    border-radius: 3px;
}

.br-branch-card {
    display: flex;
    justify-content: space-between;
    padding: 16px;
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    transition: var(--br-transition);
    min-width: 280px; /* Ensure cards don't shrink in flex row */
    cursor: pointer;
}

.br-branch-card:hover {
    box-shadow: 0 4px 12px rgba(27, 60, 87, 0.1);
}

.br-branch-card.selected {
    border-color: var(--br-primary);
    border-width: 2px;
    background: rgba(27, 60, 87, 0.05);
}

.br-branch-details {
    flex: 1;
    min-width: 0;
}

.br-branch-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--br-on-surface);
    margin-bottom: 2px;
    line-height: 20px;
    margin-top: 0;
}

.br-branch-address {
    font-size: 10px;
    color: var(--br-on-surface-variant);
    margin-bottom: 4px;
    margin-top: 2px;
    line-height: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.br-branch-hours {
    font-size: 12px;
    margin-top: 0;
    line-height: 16px;
    color: var(--br-success);
    font-weight: 500;
}


.br-branch-reserve-text {
    font-size: 12px;
    color: var(--br-primary);
    font-weight: 600;
    margin-top: 8px;
}

/* ===== STEP 1: DATE & TIME ===== */
/* ... existing styles ... */

/* ===== STEP 2: SUMMARY CARD ===== */
.br-summary-card {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--br-shadow);
}

.br-summary-header {
    margin-bottom: 16px;
}

.br-summary-rest-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--br-on-surface);
    margin: 0 0 4px 0;
}

.br-summary-branch-name {
    font-size: 15px;
    font-weight: 500;
    color: var(--br-primary);
    margin-bottom: 4px;
}

.br-summary-address {
    font-size: 13px;
    color: var(--br-on-surface-variant);
}

.br-summary-divider {
    height: 1px;
    background: var(--br-outline);
    margin: 10px 0;
}

.br-summary-details-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.br-summary-detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.br-summary-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--br-on-surface-variant);
    font-weight: 600;
}

.br-summary-value {
    font-size: 15px;
    font-weight: 600;
    color: var(--br-on-surface);
}

@media (min-width: 600px) {
    .br-summary-details-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ===== NEW ON BRASSERIO GRID ===== */
.br-newest-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}

.br-newest-card {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: var(--br-transition);
    display: flex;
    flex-direction: column;
}

.br-newest-card:hover {
    box-shadow: var(--br-shadow-lg);
    transform: translateY(-4px);
}

.br-newest-img {
    width: 100%;
    height: 180px; /* Approx 40% of a typical card height */
    object-fit: cover;
}

.br-newest-content {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Info Icon */
.br-info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border: 1px solid var(--br-on-surface-variant);
    border-radius: 50%;
    color: var(--br-on-surface-variant);
    font-size: 12px;
    font-weight: 700;
    margin-left: 8px;
    cursor: pointer;
}

@media (max-width: 900px) {
    .br-newest-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .br-newest-grid {
        grid-template-columns: 1fr;
    }
}



/* Form Grid */
.br-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.br-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.br-form-group-full {
    grid-column: 1 / -1;
}

.br-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--br-on-surface);
}

.br-required {
    color: var(--br-error);
}

/* Form Inputs */
.br-input,
.br-textarea,
.duy-datepicker-input {
    width: 100%;
    padding: 12px 16px;
    margin-bottom: 0px;
    border: 2px solid var(--br-outline);
    border-radius: var(--br-radius);
    background: var(--br-surface);
    font-size: 14px;
    font-weight: 500;
    color: var(--br-on-surface);
    font-family: inherit;
    transition: var(--br-transition);
    box-sizing: border-box; /* Ensures padding doesn't affect width */
}

.br-input:focus,
.br-textarea:focus,
.duy-datepicker-input:focus {
    outline: none;
    border-color: var(--br-primary);
    box-shadow: 0 0 0 3px rgba(27, 60, 87, 0.1);
}

.br-textarea {
    width: 100%;
    resize: vertical;
    min-height: 80px;
}

/* Time Picker */
.br-time-picker {
    display: flex;
    align-items: center;
    gap: 8px;
}

.br-time-picker .br-custom-select-wrapper {
    flex: 1;
    min-width: 0; /* Prevents overflow in flex containers */
}

.br-time-select {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    background: var(--br-surface);
    font-size: 14px;
    color: var(--br-on-surface);
    cursor: pointer;
    transition: var(--br-transition);
}

.br-time-select:focus {
    outline: none;
    border-color: var(--br-primary);
    box-shadow: 0 0 0 3px rgba(27, 60, 87, 0.1);
}

.br-time-separator {
    font-size: 18px;
    font-weight: 600;
    color: var(--br-on-surface);
}

/* ===== STEP 2: SEATING ===== */
.br-section {
    margin-bottom: 32px;
}

.br-section-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--br-on-surface);
    margin: 10px 0 16px 16px;
}

/* Chips Container */
.br-chips-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0 0 0 16px;
}

.br-chip {
    padding: 10px 20px;
    border: 1px solid var(--br-outline);
    border-radius: 24px;
    background: var(--br-surface);
    color: var(--br-on-surface);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--br-transition);
    opacity: 0;
    transform: translateY(8px);
    animation: br-chip-in 0.3s ease-out forwards;
}

@keyframes br-chip-in {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.br-chip:hover {
    background: var(--br-surface-variant);
    border-color: var(--br-primary);
}

.br-chip.selected {
    background: var(--br-primary);
    color: var(--br-on-primary);
    border-color: var(--br-primary);
}

/* Info/Error/Loading Messages */
.br-info-message,
.br-error-message,
.br-loading-message {
    padding: 16px;
    border-radius: var(--br-radius);
    font-size: 14px;
}

.br-info-message {
    background: var(--br-surface-variant);
    color: var(--br-on-surface-variant);
    border: 1px dashed var(--br-outline);
}

.br-info-message.hidden {
    display: none;
}

.br-error-message {
    background: var(--br-error-light);
    color: var(--br-error);
    border: 1px solid var(--br-error);
}

.br-loading-message {
    background: var(--br-surface-variant);
    color: var(--br-on-surface-variant);
    text-align: center;
}

/* ===== STEP 3: CONTACT ===== */
.br-summary-box {
    background: var(--br-surface-variant);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    padding: 16px;
    margin-bottom: 24px;
    font-size: 14px;
    line-height: 1.6;
    color: var(--br-on-surface);
}

.br-summary-box strong {
    color: var(--br-primary);
}

/* Checkbox Group */
.br-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.br-checkbox-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 12px;
    border-radius: var(--br-radius-sm);
    transition: var(--br-transition);
}

.br-checkbox-label:hover {
    background: var(--br-surface-variant);
}

.br-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--br-primary);
}

.br-checkbox-label span {
    font-size: 14px;
    color: var(--br-on-surface);
}

/* ===== STEP 4: CONFIRMATION ===== */
.br-confirmation-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px;
    width: 100%;
}

.br-confirmation-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--br-success-light);
    color: var(--br-success);
    margin-bottom: 24px;
    animation: br-scale-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes br-scale-in {
    from {
        transform: scale(0);
    }
    to {
        transform: scale(1);
    }
}

.br-confirmation-message {
    font-size: 18px;
    font-weight: 500;
    color: var(--br-on-surface);
    margin-bottom: 24px;
}

/* ===== NEW CONFIRMATION CARD DESIGN ===== */
.br-confirmation-card {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius-lg);
    padding: 40px 32px;
    text-align: center;
    box-shadow: var(--br-shadow-lg);
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    animation: br-fade-in 0.5s ease-out;
}

/* Success Animation */
.br-success-animation {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    position: relative;
}

.br-checkmark {
    width: 100%;
    height: 100%;
    display: block;
}

.br-checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: var(--br-success);
    fill: none;
    animation: br-stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.br-checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke-width: 3;
    stroke: var(--br-success);
    fill: none;
    animation: br-stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.6s forwards;
}

@keyframes br-stroke {
    100% { stroke-dashoffset: 0; }
}

.br-confirmation-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--br-on-surface);
    margin: 0 0 8px 0;
}

.br-order-number-wrapper {
    margin: 16px 0 24px 0;
}

.br-order-number-label {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--br-on-surface-variant);
    margin-bottom: 4px;
}

.br-order-number-text {
    font-size: 42px;
    font-weight: 800;
    color: var(--br-primary);
    line-height: 1.1;
}

.br-payment-success-text {
    color: var(--br-success);
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 24px;
    padding: 8px 16px;
    background: var(--br-success-light);
    border-radius: 20px;
    display: inline-block;
}

.br-confirmation-card .br-summary-box {
    background: var(--br-surface-variant);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    padding: 20px;
    margin: 0 0 24px 0;
    text-align: left;
    font-size: 14px;
    line-height: 1.6;
}

.br-confirmation-footer-text {
    font-size: 13px;
    color: var(--br-on-surface-variant);
    line-height: 1.5;
}

.br-success-message {
    color: var(--br-success);
}

.br-error-message {
    color: var(--br-error);
}

/* ===== BUTTONS ===== */
.br-btn {
    padding: 14px 32px;
    border: none;
    border-radius: var(--br-radius);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--br-transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.br-btn-primary {
    background: var(--br-primary);
    color: var(--br-on-primary);
}

.br-btn-primary:hover {
    background: var(--br-primary-light);
    box-shadow: var(--br-shadow);
}

.br-btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.br-btn-secondary {
    background: transparent;
    color: var(--br-primary);
    border: 1px solid var(--br-primary);
}

.br-btn-secondary:hover {
    background: rgba(27, 60, 87, 0.05);
}

/* Step Actions */
.br-step-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 32px;
}


/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .br-book-table-container {
        padding: 16px;
        max-width: 95%;
        margin: 0px auto 20px auto;
    }

    .br-header {
        margin-bottom: 24px;
    }

    .br-step-title {
        font-size: 20px;
    }

    .br-progress {
        display: none;
    }

    .br-search-bar {
        flex-direction: column;
    }

    .br-restaurant-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .br-branches-list {
        grid-template-columns: 1fr;
    }

    .br-branch-card {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

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

    .br-chips-container {
        gap: 8px;
    }

    .br-chip {
        padding: 8px 16px;
        font-size: 13px;
    }

    .br-step-actions {
        flex-direction: column;
    }

    .br-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .br-book-table-container {
        padding: 12px;
        max-width: 95%;
        margin: 0px auto 20px auto;
    }

    .br-restaurant-card {
        padding: 16px;
    }

    .br-confirmation-container {
        padding: 16px 0;
    }

    .br-confirmation-card {
        padding: 24px 16px;
    }

    .br-confirmation-title {
        font-size: 20px;
    }

    .br-order-number-text {
        font-size: 32px;
    }

    .br-success-animation {
        width: 60px;
        height: 60px;
        margin-bottom: 16px;
    }

    .br-confirmation-card .br-summary-box {
        padding: 16px;
    }
}

/* ===== RTL SUPPORT ===== */
[dir="rtl"] .br-search-icon {
    left: auto;
    right: 16px;
}

[dir="rtl"] .br-search-input {
    padding: 14px 48px 14px 16px;
}

[dir="rtl"] .br-back-btn svg {
    transform: scaleX(-1);
}

/* ===== PRINT STYLES ===== */
@media print {
    .br-back-btn,
    .br-progress,
    .br-step-actions,
    .br-toast,
    .br-loader {
        display: none !important;
    }
}

/* ===== ACCESSIBILITY ===== */
.br-btn:focus,
.br-chip:focus,
.br-branch-card:focus {
    outline: 2px solid var(--br-primary);
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .br-branch-card,
    .br-restaurant-card,
    .general-card {
        border-width: 2px;
    }

    .br-chip.selected {
        border-width: 2px;
    }
}

/* Container */
.duy-datepicker {
  position: relative;
  display: inline-block;
  font-family: var(--dp-font-family);
  font-size: var(--dp-font-size);
}

/* Input */
.duy-datepicker-input {
  cursor: pointer;
}

/* Popup base */
.duy-datepicker-popup {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  background-color: var(--dp-color-surface);
  border-radius: var(--dp-radius);
  box-shadow: var(--dp-shadow);
  border: 1px solid var(--dp-color-border);
  padding: 8px;
  z-index: var(--dp-z-index);
  min-width: 100%;
}

/* If you prefer the popup aligned to the right: */
/* .duy-datepicker-popup { right: 0; left: auto; } */

/* Header */
.duy-dp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.duy-dp-nav-btn {
  border: none;
  background: transparent;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--dp-color-muted);
}

.duy-dp-nav-btn:hover {
  background-color: var(--dp-color-hover);
  color: var(--dp-color-text);
}

.duy-dp-month-label {
  font-weight: 600;
  color: var(--dp-color-text);
  display: inline-flex;
  align-items: center;
  min-width: 100px;
  gap: 4px;
}

.duy-dp-month-select,
.duy-dp-year-select {
  border: none;
  background: transparent;
  font: inherit;
  padding: 2px 4px;
  border-radius: 4px;
  cursor: pointer;
}

/* Grid */
.duy-dp-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-top: 4px;
}

/* Weekday labels */
.duy-dp-weekday {
  text-align: center;
  font-size: 0.75em;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--dp-color-muted);
  padding: 4px 0;
}

/* Day cells */
.duy-dp-day-btn {
  border: none;
  background: transparent;
  padding: 6px 0;
  border-radius: 10px;
  cursor: pointer;
  font: inherit;
  text-align: center;
  color: var(--dp-color-text);
}

.duy-dp-day-btn:hover {
  background-color: var(--dp-color-hover);
}

.duy-dp-day-btn.is-today {
  border: 1px solid var(--dp-color-today-border);
}

.duy-dp-day-btn.is-selected {
  background-color: var(--dp-color-primary);
  color: var(--dp-color-primary-contrast);
}

.duy-dp-day-btn.is-outside-month {
  color: var(--dp-color-muted);
}

/* Disabled */
.duy-dp-day-btn:disabled,
.duy-dp-day-btn.is-disabled {
  cursor: default;
  opacity: 0.4;
  background-color: transparent;
}

/* Fade transition (optional) */
.duy-dp-popup-animate {
  animation: dp-fade-in 0.12s ease-out;
}

@keyframes dp-fade-in {
  from {
    opacity: 0;
    transform: translateY(-2px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Prevent background scroll when overlay is open */
html.br-overlay-open {
    overflow: hidden;
}
body.br-overlay-open {
    position: fixed;
    overflow: hidden;
    width: 100%;
    /* The `top` property will be set by JS to prevent scroll jump */
}

/* ===== Restaurant Page Overlay ===== */
.br-rp-overlay.hidden { display: none; }
.br-rp-overlay { position: fixed; inset: 0; z-index: 1200; }

.br-rp-backdrop {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.45);
}

.br-rp-sheet {
  position: absolute;
  top: 4vh; bottom: 4vh;
  left: 50%;
  transform: translateX(-50%);
  width: min(1200px, 95vw);
  background: var(--br-surface);
  border-radius: var(--br-radius-lg);
  box-shadow: var(--br-shadow-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.br-rp-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 40px; height: 40px;
  border: 1px solid var(--br-outline);
  border-radius: 999px;
  background: var(--br-surface);
  color: var(--br-on-surface);
  cursor: pointer;
  z-index: 2;
}

.br-rp-content { overflow: auto; height: 100%; }

/* Hero */
.br-rp-hero {
  position: relative;
  min-height: 240px;
  background: var(--br-surface-variant);
}
.br-rp-hero img {
  width: 100%; height: 240px;
  object-fit: cover;
  display: block;
}
.br-rp-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.1), rgba(0,0,0,0.65));
}

.br-rp-hero-inner {
  position: absolute;
  left: 20px; right: 20px; bottom: 18px;
  display: flex; gap: 14px; align-items: flex-end;
  color: #fff;
}

.br-rp-logo {
  width: 72px; height: 72px;
  max-width: 72px; max-height: 72px;
  border-radius: 18px;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.65);
  background: rgba(255,255,255,0.12);
}

.br-rp-title { margin: 0; font-size: 26px; font-weight: 700; }
.br-rp-sub { display:flex; gap: 4px; flex-wrap: wrap; opacity: 0.95; font-size: 14px; margin: 0 0; line-height: 12px;}

.br-rp-body { padding: 18px 20px 22px; }
.br-rp-row { display:flex; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.br-rp-pill {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--br-outline-variant);
  background: var(--br-surface-variant);
  font-size: 13px;
  color: var(--br-on-surface);
}

/* Tabs */
.br-rp-tabs {
    display: flex;
    gap: 12px;
    margin-top: 14px;
    border-bottom: 1px solid var(--br-outline);
    overflow-x: auto;
    padding-bottom: 0;
}
.br-rp-tab {
  background: none;
  border: none;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--br-on-surface-variant);
  cursor: pointer;
  position: relative;
  transition: var(--br-transition);
  white-space: nowrap;
}
.br-rp-tab.active {
    color: var(--br-primary);
}
.br-rp-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--br-primary);
    border-top-left-radius: 3px;
    border-top-right-radius: 3px;
}

.br-rp-section { margin-top: 18px; }
.br-rp-section h3 { margin: 0 0 12px; font-size: 18px; font-weight: 800; }

/* Branch cards */
.br-rp-branches { display:grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }

/* Ensure branch cards in overlay behave correctly */
.br-rp-branches .br-branch-card {
    min-width: 0; /* Override default min-width to fit grid */
    max-width: 50%;
     /* Equal height */
    background: var(--br-surface);
}

.br-rp-branch {
  border: 1px solid var(--br-outline);
  border-radius: var(--br-radius);
  padding: 14px;
  background: var(--br-surface);
}
.br-rp-branch-name { font-weight: 700; margin-bottom: 4px; }
.br-rp-branch-meta { color: var(--br-on-surface-variant); font-size: 13px; margin-bottom: 10px; }

/* Horizontal Scroll Sections (Branches & Popular) */
.br-rp-scroll-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.br-rp-scroll-container {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding-bottom: 8px;
    width: 100%;
    scrollbar-width: none; /* Firefox */
}
.br-rp-scroll-container::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.br-rp-scroll-item {
    flex: 0 0 30%;
    min-width: 280px;
    max-width: 350px;
}

.br-rp-scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--br-shadow);
    color: var(--br-on-surface);
    font-size: 18px;
    transition: var(--br-transition);
}
.br-rp-scroll-btn:hover { background: var(--br-surface-variant); transform: translateY(-50%) scale(1.1); }
.br-rp-scroll-btn.left { left: -18px; }
.br-rp-scroll-btn.right { right: -18px; }

/* Popular Dish Card (New Design) */
.br-rp-popular-card {
    display: flex;
    flex-direction: row;
    gap: 16px;
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    padding: 16px;
    background: var(--br-surface);
    height: 100%;
    align-items: center;
}

.br-rp-popular-img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: var(--br-radius-sm);
    flex-shrink: 0;
}

.br-rp-popular-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.br-rp-popular-desc {
    font-size: 12px;
    color: var(--br-on-surface-variant);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-top: 6px;
    line-height: 1.4;
}

/* Menu */
.br-rp-categories { display:flex; gap: 8px; flex-wrap: wrap; }
.br-rp-cat-chip { padding: 8px 12px; border-radius: 999px; border: 1px solid var(--br-outline); background: var(--br-surface); cursor:pointer; font-weight: 600; font-size: 13px; }
.br-rp-cat-chip.active { background: var(--br-primary); color: var(--br-on-primary); border-color: var(--br-primary); }

.br-rp-menu-cat { margin-top: 18px; }
.br-rp-menu-item {
  display:flex; gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--br-outline);
}
.br-rp-menu-item:last-child { border-bottom: none; }
.br-rp-menu-img { width: 96px; height: 96px; border-radius: 14px; object-fit: cover; background: var(--br-surface-variant); }
.br-rp-menu-main { flex: 1; min-width: 0; }
.br-rp-menu-title { display:flex; justify-content: space-between; gap: 10px; font-weight: 700; }
.br-rp-menu-desc { color: var(--br-on-surface-variant); font-size: 13px; margin-top: 4px; }
.br-rp-tags { display:flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.br-rp-tag { font-size: 12px; padding: 4px 10px; border-radius: 999px; background: var(--br-surface-variant); border: 1px solid var(--br-outline); }

/* Mobile */
@media (max-width: 768px) {
  .br-rp-sheet { top: 0; bottom: 0; width: 100vw; left: 0; transform: none; border-radius: 0; }

  
  .br-rp-hero-inner {
      flex-wrap: wrap;
  }
  .br-rp-hero-inner > div {
      flex: 1 1 60%; /* Text container */
  }
  .br-rp-hero-inner .br-btn {
      flex: 1 1 100%;
      margin-top: 12px;
  }

  .br-rp-scroll-item {
      flex: 0 0 85%;
      max-width: none;
  }
  .br-rp-scroll-btn { display: none; }
  .br-rp-scroll-wrapper { margin: 0 -20px; padding: 0 20px; }
  .br-rp-scroll-container { padding-right: 20px; }
}

/* Gallery */
.br-rp-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
}
.br-rp-gallery-item {
  aspect-ratio: 1;
  border-radius: var(--br-radius);
  overflow: hidden;
  cursor: pointer;
  border: 1px solid var(--br-outline);
  background: var(--br-surface-variant);
}
.br-rp-gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.3s ease;
}
.br-rp-gallery-item:hover img { transform: scale(1.05); }

/* Lightbox */
.br-lightbox {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(0,0,0,0.9);
  display: flex; align-items: center; justify-content: center;
  opacity: 1; transition: opacity 0.2s;
}
.br-lightbox.hidden { display: none; opacity: 0; pointer-events: none; }
.br-lightbox-content { max-width: 90vw; max-height: 90vh; display:flex; align-items:center; justify-content:center; }
.br-lightbox-img { max-width: 100%; max-height: 90vh; object-fit: contain; border-radius: 4px; }

.br-lightbox-close {
  position: absolute; top: 20px; right: 20px;
  background: transparent; border: none; color: #fff; font-size: 40px; cursor: pointer; z-index: 2001; line-height: 1;
}
.br-lightbox-prev, .br-lightbox-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,0.1); border: none; color: #fff; font-size: 30px;
  width: 50px; height: 50px; border-radius: 50%; cursor: pointer; z-index: 2001;
  display:flex; align-items:center; justify-content:center; transition: background 0.2s;
}
.br-lightbox-prev:hover, .br-lightbox-next:hover { background: rgba(255,255,255,0.25); }
.br-lightbox-prev { left: 20px; } .br-lightbox-next { right: 20px; }

/* About Read More */
.br-rp-about-text {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: pre-line;
  line-height: 1.6;
  color: var(--br-on-surface-variant);
  margin-top: 8px;
}
.br-rp-about-text.expanded {
  -webkit-line-clamp: unset;
}
.br-rp-read-more {
  background: none; border: none; padding: 0;
  color: var(--br-primary); cursor: pointer; font-weight: 600;
  margin-top: 4px; font-size: 14px;
}
.br-rp-read-more:hover { text-decoration: underline; }


 /* Experiences */
 .br-rp-experiences-list {
   display: flex; flex-direction: column; gap: 16px;
 }
 .br-rp-experience-card {
   display: flex; gap: 16px;
   border: 1px solid var(--br-outline);
   border-radius: var(--br-radius);
   padding: 16px;
   background: var(--br-surface);
   align-items: flex-start;
 }
 .br-rp-experience-content {
   flex: 1; min-width: 0;
 }
 .br-rp-experience-title {
   margin: 0 0 8px 0; font-size: 18px; font-weight: 600;
   color: var(--br-on-surface);
 }
 .br-rp-experience-meta {
   display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
 }
 .br-rp-experience-desc {
   margin: 12px 0; font-size: 14px; color: var(--br-on-surface-variant);
   line-height: 1.5;
   white-space: pre-line;
   display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
 }
 .br-rp-experience-img {
   width: 120px; height: 120px; flex-shrink: 0;
 }
 .br-rp-experience-img img {
   width: 100%; height: 100%; object-fit: cover; border-radius: var(--br-radius);
 }
 @media (max-width: 600px) {
   .br-rp-experience-card { flex-direction: column-reverse; }
   .br-rp-experience-img { width: 100%; height: 160px; }
 }

/* ===== DEPOSIT UI ===== */
.br-deposit-warning {
    display: flex;
    gap: 16px;
    background: #FFF9C4; /* Light Yellow */
    border: 1px solid #FBC02D;
    border-radius: var(--br-radius);
    padding: 16px;
    margin-bottom: 24px;
    align-items: flex-start;
    animation: br-fade-in 0.3s ease-out;
}

.br-deposit-warning.hidden {
    display: none;
}

.br-deposit-icon {
    font-size: 24px;
    line-height: 1;
}

.br-deposit-content {
    flex: 1;
}

.br-deposit-title {
    margin: 0 0 4px 0;
    font-size: 16px;
    font-weight: 700;
    color: #F57F17;
}

.br-deposit-text {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: var(--br-on-surface);
}

.br-deposit-subtext {
    margin: 0;
    font-size: 12px;
    color: var(--br-on-surface-variant);
    font-style: italic;
}

/* ===== STATUS PAGE ===== */
.br-loader-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.br-loader-inline .br-spinner {
    width: 48px;
    height: 48px;
}

#br-status-result.hidden {
    display: none;
}

.br-loader-inline.hidden {
    display: none;
}

/* ===== HERO PILL DESIGN ===== */
.br-hero-pill-container {
    width: 100%;
    margin-bottom: 32px;
}

.br-hero-pill-inner {
    display: flex;
    align-items: stretch;
    background: var(--br-surface);
    border: 3px solid var(--br-primary);
    border-radius: 24px; /* Pill shape */
    padding: 8px 12px;
    box-shadow: var(--br-shadow-lg);
}

.br-pill-item {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4px 16px;
    flex: 1; /* Default grow factor */
    min-width: 0; /* Prevents content from overflowing flex item */
}

/* Give less space to smaller pickers */
.br-pill-time,
.br-pill-diners {
    flex-grow: 0.5;
}

/* Give more space to the search bar */
.br-pill-search {
    flex-grow: 2.5;
}

.br-pill-divider {
    width: 1px;
    background: var(--br-outline);
    margin: 12px 0;
}

/* Typography & Inputs */
.br-pill-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--br-on-surface-variant);
    margin-bottom: 2px;
}

.br-pill-input, .br-pill-select {
    border: none !important;
    background: transparent !important;
    font-size: 15px;
    font-weight: 600;
    color: var(--br-on-surface);
    padding: 0 !important;
    margin: 0 !important;
    width: 100%;
    outline: none;
}

.br-pill-time-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Submit Button */
.br-hero-btn {
    background: var(--br-primary);
    color: var(--br-on-primary);
    border: none;
    border-radius: 999px;
    padding: 0 32px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--br-transition);
    margin-left: 8px;
}

.br-hero-btn:hover {
    background: var(--br-secondary);
    transform: scale(1.02);
}

/* ===== RESPONSIVE MOBILE LOGIC ===== */
@media (max-width: 768px) {
    .br-hero-pill-inner {
        flex-direction: column; /* Split into rows */
        border-radius: 24px; /* Slightly less round on mobile for space */
        padding: 16px;
    }

    /* Top Row Container: Pickers */
    .br-hero-pill-inner {
        display: grid;
        grid-template-areas:
            "date hour minute diners"
            "search search search search";
        gap: 12px;
    }

    .br-pill-date { grid-area: date; }
    .br-pill-time { grid-area: hour; border: none; }
    /* Logic for hour/minute needs specific flex in mobile */

    .br-pill-search {
        grid-area: search;
        border-top: 1px solid var(--br-outline);
        padding-top: 12px;
    }

    .desktop-only { display: none; }
    .br-pill-divider { display: none; }
}

/* Secondary Actions (Location) */
.br-secondary-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: -16px;
    margin-bottom: 32px;
}

.br-location-pill {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    height: 36px;
    box-sizing: border-box;
}

/* Filter Pills */
.br-filter-pill-wrapper {
    min-width: 140px;
}

.br-filter-pill-wrapper.hidden {
    display: none;
}

/* Override custom select trigger for pills to match location button */
.br-secondary-actions .br-custom-select-trigger {
    border-radius: 999px;
    padding: 0 16px;
    height: 36px;
    font-size: 13px;
    border: 1px solid var(--br-outline);
    background: var(--br-surface);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
}

.br-secondary-actions .br-custom-select-trigger span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.br-secondary-actions .br-custom-select-trigger .br-arrow {
    flex-shrink: 0;
}

.br-secondary-actions .br-custom-options {
    margin-top: 0px;
    border-radius: 12px;
    min-width: 100%;
    width: max-content;
    max-width: 250px;
}

/* Container */
.br-faq-section {
    max-width: 100%;
    margin: 150px auto;
    padding: 0 24px;
}

/* Tab Navigation */
.br-faq-tabs {
    display: flex;
    justify-content: left;
    gap: 12px;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--br-outline);
    padding-bottom: 16px;
}

.br-faq-tab {
    background: none;
    border: none;
    padding: 10px 24px;
    font-size: 16px;
    font-weight: 600;
    color: var(--br-on-surface-variant);
    cursor: pointer;
    position: relative;
    transition: var(--br-transition);
}

.br-faq-tab.active {
    color: var(--br-primary);
}

.br-faq-tab.active::after {
    content: '';
    position: absolute;
    bottom: -17px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--br-primary);
}

/* Grid Layout */
.br-faq-panel {
    display: none;
    animation: br-fade-in 0.4s ease;
}

.br-faq-panel.active {
    display: block;
}

.br-faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    align-items: start;
}

/* Accordion Item */
.br-faq-item {
    background: var(--br-surface);
    border: 1px solid var(--br-outline);
    border-radius: var(--br-radius);
    overflow: hidden;
}

.br-faq-question {
    width: 100%;
    padding: 20px;
    text-align: left;
    background: none;
    border: none;
    font-size: 16px;
    font-weight: 600;
    color: var(--br-on-surface);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.3s ease, color 0.3s ease;
}

.br-faq-question:hover {
    background: var(--br-surface-variant);
}

.br-faq-question .br-icon::before {
    content: '+';
    font-size: 20px;
    color: var(--br-primary);
}

.br-faq-item.open .br-faq-question .br-icon::before {
    content: '−';
    color: var(--br-primary);
}

/* Answer Expansion */
/* 1. Reset the container to use a grid-row transition */
.br-faq-answer-wrapper {
    display: grid;
    grid-template-rows: 0fr; /* The "magic" starting point */
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 2. When open, change the fractional unit to 1 */
.br-faq-item.open .br-faq-answer-wrapper {
    grid-template-rows: 1fr;
}

/* 3. The inner content needs min-height: 0 to animate correctly */
.br-faq-answer-content {
    overflow: hidden;
    padding: 0 20px;
    transition: padding 0.4s ease;
}

.br-faq-item.open .br-faq-answer-content {
    padding-bottom: 20px;
}


@media (max-width: 768px) {
    .br-faq-grid { grid-template-columns: 1fr; }
    .br-faq-tabs { overflow-x: auto; justify-content: flex-start; }
    .br-faq-tab {
        padding: 6px 16px;
        font-size: 12px;
    }
}


.br-b2b-community-section {
    position: relative;
    margin: 150px 0 0 0;
    padding: 80px 0 40px 0;
    background-image: url('../images/b2b-community-back.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax effect */
    color: #ffffff;
    overflow: hidden;
}

/* Semi-transparent Overlay */
.br-b2b-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.6) 100%);
    z-index: 1;
}

.br-b2b-container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.br-b2b-content-row {
    display: flex;
    align-items: center;
    gap: 60px;
    margin-bottom: 60px;
}

/* Left Column (60%) */
.br-b2b-text-column {
    flex: 1;
}

.br-b2b-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.1;
    color: #cacbcc;
}

.br-b2b-description {
    font-size: 1.2rem;
    line-height: 1.6;
    margin-bottom: 32px;
    opacity: 0.9;
    max-width: 600px;
}

/* Right Column (40%) */
.br-b2b-image-column {
    flex: 0 0 40%;
    display: flex;
    justify-content: center;
}

.br-b2b-hero-img {
    width: 100%;
    max-width: 450px;
    height: auto;
    border-radius: var(--br-radius);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    animation: float 6s ease-in-out infinite;
}

/* Action Buttons */
.br-b2b-actions {
    display: flex;
    gap: 16px;
}

.br-btn-outline-white {
    background: transparent;
    border: 2px solid #ffffff;
    color: #ffffff;
}

.br-btn-outline-white:hover {
    background: #ffffff;
    color: var(--br-primary);
}

/* Bottom Footer */
.br-b2b-footer {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 30px;
}

.br-suggest-link {
    color: #ffffff;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
    transition: opacity 0.2s;
    margin-left: 8px;
}

.br-suggest-link:hover {
    opacity: 0.7;
}

/* Floating Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* Responsive */
@media (max-width: 992px) {
    .br-b2b-content-row {
        flex-direction: column;
        text-align: center;
    }
    .br-b2b-text-column { order: 2; }
    .br-b2b-image-column { order: 1; flex: 0 0 100%; }
    .br-b2b-actions { justify-content: center; }
    .br-b2b-title { font-size: 2.2rem; }
}

.br-faq-section-title {
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.1;
    color: var(--br-on-surface);
    margin: 10px 0 36px 0;
}

/* Mobile Datepicker Popup - Modal Style */
@media (max-width: 768px) {
    .duy-datepicker-popup {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 80vw;
        min-width: auto;
        max-width: 360px;
        box-shadow: 0 10px 25px rgba(0,0,0,0.2), 0 0 0 100vmax rgba(0,0,0,0.45);
        z-index: 2100;
    }
    @keyframes dp-fade-in-mobile { from { opacity: 0; transform: translate(-50%, -46%); } to { opacity: 1; transform: translate(-50%, -50%); } }
    .duy-datepicker-popup.duy-dp-popup-animate { animation-name: dp-fade-in-mobile; }
}