/* Bookings - Request cards, filters, detail page */

/* ===========================================================================
   BOOKING REQUESTS â€” Premium card system (Stripe/Linear style)
   =========================================================================== */

/* â”€â”€ Page header â”€â”€ */
.br-page { max-width: 920px; margin: 0 auto; }
.br-page-title {
    font-size: var(--text-3xl);
    font-weight: var(--font-bold);
    color: var(--color-neutral-900);
    letter-spacing: var(--tracking-tight);
    margin-bottom: var(--space-1);
    line-height: var(--leading-tight);
}
.br-page-subtitle {
    font-size: var(--text-base);
    color: var(--color-neutral-500);
    line-height: var(--leading-normal);
}

/* â”€â”€ Filter tabs â€” Linear-style underline tabs â”€â”€ */
.br-filter-bar {
    display: flex;
    gap: var(--space-1);
    border-bottom: 1px solid var(--color-neutral-200);
    margin-bottom: var(--space-6);
    margin-top: var(--space-6);
}
.br-filter-tab {
    padding: var(--space-2-5) var(--space-4);
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    color: var(--color-neutral-500);
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    transition: color var(--duration-normal) var(--ease-out),
                border-color var(--duration-normal) var(--ease-out);
    white-space: nowrap;
    position: relative;
    bottom: -1px;
}
.br-filter-tab:hover {
    color: var(--color-neutral-700);
}
.br-filter-tab.active {
    color: var(--color-neutral-900);
    border-bottom-color: var(--color-neutral-900);
    font-weight: var(--font-semibold);
}
.br-filter-count {
    font-size: var(--text-xs);
    font-weight: var(--font-medium);
    color: var(--color-neutral-400);
    margin-left: var(--space-1-5);
    background: var(--color-neutral-100);
    padding: 1px 6px;
    border-radius: var(--radius-full);
    vertical-align: 1px;
}
.br-filter-tab.active .br-filter-count {
    background: var(--color-neutral-900);
    color: var(--color-neutral-0);
}
.br-filter-tab[data-filter="rescheduled"].active {
    color: var(--purple-700, #7e22ce);
    border-bottom-color: var(--purple-600, #9333ea);
}
.br-filter-tab[data-filter="rescheduled"].active .br-filter-count {
    background: var(--purple-600, #9333ea);
    color: #fff;
}

/* â”€â”€ Request card â”€â”€ */
.br-card {
    background: var(--color-neutral-0);
    border: 1px solid var(--color-neutral-200);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: border-color var(--duration-moderate) var(--ease-out),
                box-shadow var(--duration-moderate) var(--ease-out);
}
.br-card:hover {
    border-color: var(--color-neutral-300);
    box-shadow: var(--shadow-sm);
}
.br-card + .br-card { margin-top: var(--space-3); }

/* Status accent â€” colored top border */
.br-card[data-status="confirmed"] { border-top: 2px solid var(--color-primary-500); }
.br-card[data-status="pending"]   { border-top: 2px solid var(--color-warning-500); }
.br-card[data-status="cancelled"] { border-top: 2px solid var(--color-error-500); }
.br-card[data-status="declined"] { border-top: 2px solid var(--color-error-500); }
.br-card[data-status="customer_cancelled"] { border-top: 2px solid #f87171; }
.br-card[data-status="rescheduled"] { border-top: 2px solid var(--purple-500, #a855f7); }
.br-card[data-status="callback"]  { border-top: 2px solid var(--color-primary-400); }
.br-card[data-status="completed"] { border-top: 2px solid var(--color-primary-600); }

/* Card header */
.br-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-5) var(--space-5) var(--space-4);
}
.br-card-identity {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    min-width: 0;
}
.br-avatar {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-lg);
    background: var(--color-neutral-900);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-neutral-0);
    font-weight: var(--font-bold);
    font-size: var(--text-sm);
    flex-shrink: 0;
    letter-spacing: 0.02em;
}
.br-card-name {
    font-weight: var(--font-semibold);
    font-size: var(--text-md);
    color: var(--color-neutral-900);
    line-height: var(--leading-tight);
}
.br-card-meta {
    font-size: var(--text-xs);
    color: var(--color-neutral-400);
    margin-top: 2px;
}

/* Reschedule info banner */
.br-reschedule-banner {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 0 var(--space-5);
    padding: 10px 12px;
    background: var(--purple-50, #faf5ff);
    border: 1px solid #e9d5ff;
    border-radius: var(--radius-lg, 8px);
    color: var(--purple-700, #7e22ce);
    font-size: var(--text-sm);
}

/* Status badge */
.br-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: 3px var(--space-2-5);
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: var(--font-semibold);
    letter-spacing: 0.02em;
    line-height: 1;
    flex-shrink: 0;
    text-transform: uppercase;
}
.br-badge--confirmed {
    background: var(--color-primary-50);
    color: var(--color-primary-700);
}
.br-badge--pending {
    background: var(--color-warning-50);
    color: var(--color-warning-700);
}
.br-badge--cancelled {
    background: var(--color-error-50);
    color: var(--color-error-700);
}
.br-badge--declined {
    background: var(--color-error-50);
    color: var(--color-error-700);
}
.br-badge--customer_cancelled {
    background: #fef2f2;
    color: #dc2626;
}
.br-badge--rescheduled {
    background: var(--purple-50, #faf5ff);
    color: var(--purple-700, #7e22ce);
}
.br-badge--callback {
    background: var(--color-info-50);
    color: var(--color-primary-600);
}
.br-badge--completed {
    background: var(--color-primary-50);
    color: var(--color-primary-700);
}
.br-badge--noshow {
    background: var(--color-warning-50, #fffbeb);
    color: var(--color-warning-700, #a16207);
}
.br-badge--expired {
    background: var(--color-neutral-100, #f3f4f6);
    color: var(--color-neutral-500, #6b7280);
}
.br-badge--default {
    background: var(--color-neutral-100);
    color: var(--color-neutral-600);
}

/* Card body â€” info grid */
.br-card-body {
    padding: 0 var(--space-5) var(--space-4);
}
.br-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2-5) var(--space-5);
}
.br-info-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    color: var(--color-neutral-700);
    min-width: 0;
}
.br-info-item i,
.br-info-item svg {
    width: 14px;
    height: 14px;
    color: var(--color-neutral-400);
    flex-shrink: 0;
}
.br-info-item a {
    color: var(--color-primary-600);
    text-decoration: none;
    transition: color var(--duration-fast) var(--ease-out);
}
.br-info-item a:hover {
    color: var(--color-primary-500);
    text-decoration: underline;
}
.br-info-span2 { grid-column: span 2; }

/* Notes block */
.br-notes {
    margin-top: var(--space-3);
    padding: var(--space-3) var(--space-3-5);
    background: var(--color-neutral-50);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-neutral-100);
}
.br-notes-label {
    font-size: 10px;
    font-weight: var(--font-bold);
    color: var(--color-neutral-400);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: var(--space-1);
}
.br-notes-text {
    font-size: var(--text-sm);
    color: var(--color-neutral-700);
    line-height: var(--leading-relaxed);
}

/* Source / type metadata */
.br-source-row {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-3);
    font-size: var(--text-xs);
    color: var(--color-neutral-400);
}
.br-source-item {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
}
.br-source-item i,
.br-source-item svg {
    width: 12px;
    height: 12px;
}

/* Card footer / actions */
.br-card-footer {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-5);
    border-top: 1px solid var(--color-neutral-100);
    background: var(--color-neutral-25);
}
.br-card-footer .br-actions-right {
    margin-left: auto;
    display: flex;
    gap: var(--space-2);
}

/* Approve button â€” brand primary */
.btn-approve {
    background: var(--color-primary-600);
    color: var(--color-neutral-0);
    border: none;
}
.btn-approve:hover {
    background: var(--color-primary-500);
}

/* Empty state */
.br-empty {
    text-align: center;
    padding: var(--space-16) var(--space-6);
}
.br-empty-icon {
    width: 48px;
    height: 48px;
    color: var(--color-neutral-300);
    margin: 0 auto var(--space-3);
    display: block;
}
.br-empty-title {
    font-weight: var(--font-semibold);
    color: var(--color-neutral-500);
    font-size: var(--text-md);
    margin-bottom: var(--space-1);
}
.br-empty-desc {
    font-size: var(--text-sm);
    color: var(--color-neutral-400);
}

/* Stagger animation for cards */
.br-card { animation: br-card-in 0.25s var(--ease-out) both; }
.br-card:nth-child(1) { animation-delay: 0.02s; }
.br-card:nth-child(2) { animation-delay: 0.06s; }
.br-card:nth-child(3) { animation-delay: 0.10s; }
.br-card:nth-child(4) { animation-delay: 0.14s; }
.br-card:nth-child(5) { animation-delay: 0.18s; }
.br-card:nth-child(6) { animation-delay: 0.22s; }

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

/* Transcript modal â€” premium chat bubbles */
.br-transcript-bubble {
    max-width: 82%;
    padding: var(--space-3) var(--space-3-5);
    border-radius: var(--radius-lg);
    font-size: var(--text-sm);
    color: var(--color-neutral-800);
    line-height: var(--leading-normal);
    white-space: pre-wrap;
}
.br-transcript-bubble--bot {
    align-self: flex-start;
    background: var(--color-neutral-100);
    border: 1px solid var(--color-neutral-200);
    border-bottom-left-radius: var(--radius-xs);
}
.br-transcript-bubble--user {
    align-self: flex-end;
    background: var(--color-primary-50);
    border: 1px solid #c7d2f0;
    border-bottom-right-radius: var(--radius-xs);
}
.br-transcript-role {
    font-size: 10px;
    font-weight: var(--font-bold);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-neutral-400);
    margin-bottom: var(--space-1);
}

/* Responsive: stack info grid on mobile */
@media (max-width: 640px) {
    .br-info-grid { grid-template-columns: 1fr; }
    .br-info-span2 { grid-column: span 1; }
    .br-card-header { flex-wrap: wrap; gap: var(--space-3); }
    .br-card-footer { flex-wrap: wrap; }
    .br-card-footer .br-actions-right { margin-left: 0; width: 100%; }
    .br-card-footer .br-actions-right .btn { flex: 1; }
    .br-filter-bar { overflow-x: auto; -webkit-overflow-scrolling: touch; }
}


/* Clean Sidebar â€” deep navy */
.sidebar {
    width: 260px;
    background: #f2efe9;
    border-right: 1px solid rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 40;
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1), transform var(--transition-slow);
}

.sidebar-header {
    padding: 1.5rem 1.25rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

/* Collapse toggle button */
.sidebar-collapse-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: rgba(0, 0, 0, 0.35);
    cursor: pointer;
    transition: all 0.15s;
    flex-shrink: 0;
    padding: 0;
}

.sidebar-collapse-btn:hover {
    background: rgba(0, 0, 0, 0.06);
    color: rgba(0, 0, 0, 0.7);
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0.75rem;
    overflow-y: auto;
}

/* Smooth scrollbar for sidebar */
.sidebar-nav::-webkit-scrollbar {
    width: 6px;
}

.sidebar-nav::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.12);
    border-radius: 3px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    color: #78716c;
    text-decoration: none;
    margin-bottom: 2px;
    transition: color 0.15s, background 0.15s;
    position: relative;
    font-weight: 450;
    font-size: 0.875rem;
}

.nav-item:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #44403c;
}

.nav-item.active {
    background: rgba(0, 0, 0, 0.06);
    color: #1c1917;
    font-weight: 550;
}

.nav-item i {
    width: 19px;
    height: 19px;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 0.75rem;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.sidebar-footer > div {
    transition: background 0.15s;
    border-radius: 8px;
}

.sidebar-footer > div:hover {
    background: rgba(0, 0, 0, 0.04);
}

/* Layout */
.app-layout {
    display: flex;
    min-height: 100vh;
}

/* â”€â”€ Collapsed sidebar state (desktop) â”€â”€ */
.sidebar.collapsed {
    width: 64px;
}

.sidebar.collapsed .sidebar-logo-full {
    display: none;
}

.sidebar.collapsed .sidebar-header {
    padding: 1.25rem 0.875rem;
    justify-content: center;
}

.sidebar.collapsed .sidebar-collapse-btn i {
    transform: rotate(180deg);
}

.sidebar.collapsed .sidebar-nav {
    padding: 0.75rem 0.5rem;
}

.sidebar.collapsed .nav-item {
    justify-content: center;
    padding: 0.75rem;
    gap: 0;
}

.sidebar.collapsed .nav-item span {
    display: none;
}

.sidebar.collapsed .nav-item .badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    font-size: 0.625rem;
}



.sidebar.collapsed .sidebar-nav > div > div {
    /* Hide section labels ("Main", "Support") */
    display: none;
}

.sidebar.collapsed .sidebar-footer {
    padding: 0.5rem;
}

.sidebar.collapsed .sidebar-footer .flex-1,
.sidebar.collapsed .sidebar-footer button[data-action="logout"],
.sidebar.collapsed .sidebar-footer > div:last-child {
    display: none;
}

.sidebar.collapsed .sidebar-footer .flex.items-center {
    justify-content: center;
    padding: 0.5rem !important;
}

/* â”€â”€ Settings folder sub-nav in sidebar â”€â”€ */
.nav-folder {
    position: relative;
}

.nav-folder .nav-item {
    margin-bottom: 0;
}

.nav-folder-chevron {
    width: 14px;
    height: 14px;
    margin-left: auto;
    opacity: 0.4;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.nav-folder.expanded .nav-folder-chevron {
    transform: rotate(180deg);
    opacity: 0.6;
}

.settings-sub-nav,
.help-sub-nav {
    display: none;
    flex-direction: column;
    padding: 0.125rem 0 0.375rem 0;
    overflow: hidden;
}

.nav-folder.expanded .settings-sub-nav,
.nav-folder.expanded .help-sub-nav {
    display: flex;
}

.nav-sub-item,
.nav-sub-item:link,
.nav-sub-item:visited {
    display: block;
    padding: 0.375rem 0.75rem 0.375rem 2.75rem;
    color: #93908a;
    font-size: 0.8125rem;
    font-weight: 400;
    text-decoration: none;
    cursor: pointer;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s;
    margin: 1px 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background: transparent;
}

.nav-sub-item:hover,
.nav-sub-item:focus {
    color: #44403c !important;
    background: rgba(0, 0, 0, 0.04) !important;
    text-decoration: none;
}

.nav-sub-item.active,
.nav-sub-item.active:link,
.nav-sub-item.active:visited {
    color: #1c1917;
    background: rgba(0, 0, 0, 0.06);
    font-weight: 500;
}

/* Collapsed sidebar: hide sub-nav & chevron */
.sidebar.collapsed .settings-sub-nav,
.sidebar.collapsed .help-sub-nav {
    display: none !important;
}

.sidebar.collapsed .nav-folder-chevron {
    display: none;
}

/* =========================================================================
   PHONE SETUP WIZARD
   ========================================================================= */

/* Option cards (phone / carrier selection) */
.wizard-option-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    padding: 1.25rem 0.75rem;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    background: white;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: center;
}
.wizard-option-card:hover {
    border-color: var(--gray-400);
    background: var(--gray-50);
}
.wizard-option-card.wizard-option-selected {
    border-color: var(--gray-900);
    background: var(--gray-50);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}
.wizard-option-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-500);
    margin-bottom: 0.125rem;
}
.wizard-option-selected .wizard-option-icon {
    background: var(--gray-200);
    color: var(--gray-900);
}
.wizard-carrier-card {
    padding: 1rem 0.625rem;
}

/* Step-by-step path (settings navigation) */
.wizard-path-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin: 0.5rem 0 0.25rem;
    position: relative;
}
.wizard-path-step {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.625rem 0;
    position: relative;
    padding-left: 0.125rem;
}
.wizard-path-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 11px;
    top: calc(0.625rem + 24px);
    bottom: 0;
    width: 2px;
    background: var(--gray-200);
}
.wizard-path-step-num {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gray-100);
    color: var(--gray-700);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.6875rem;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

/* Forwarding code rows */
.wizard-code-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.625rem 0.875rem;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    gap: 0.75rem;
}
.wizard-code-label {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--gray-600);
    white-space: nowrap;
    flex-shrink: 0;
}
.wizard-code-value {
    font-family: monospace;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-900);
    letter-spacing: 0.025em;
    word-break: break-all;
    text-align: right;
}

/* FAQ / details chevron rotation */
details > summary [data-lucide="chevron-down"] {
    transition: transform 0.2s ease;
}
details[open] > summary [data-lucide="chevron-down"] {
    transform: rotate(180deg);
}

/* Image placeholder (for future screenshots) */
.wizard-image-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding: 1.5rem 1rem;
    border: 2px dashed var(--gray-200);
    border-radius: 10px;
    background: var(--gray-50);
    color: var(--gray-400);
    font-size: 0.75rem;
    text-align: center;
}

/* Mobile responsive */
@media (max-width: 640px) {
    .wizard-code-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    .wizard-code-value {
        text-align: left;
        font-size: 0.8125rem;
    }
}

/* Main content transition */
.main-content {
    flex: 1;
    margin-left: 260px;
    padding: 2.5rem;
    min-height: 100vh;
    transition: margin-left 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.collapsed ~ .main-content,
.sidebar.collapsed ~ * .main-content {
    margin-left: 64px;
}

/* Use body class for main-content since sibling selector may not work with intermediary elements */
body.sidebar-collapsed .main-content {
    margin-left: 64px;
}

/* Mobile layout overrides — must live here (after the base rules above)
   so they aren't overridden by the later-loading bookings.css base rules */
@media (max-width: 768px) {
    .app-layout {
        flex-direction: column;
    }
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: fixed !important;
        top: 0;
        left: 0;
        height: 100vh;
        height: 100dvh;
        z-index: 1000;
        width: 280px;
        padding-top: env(safe-area-inset-top, 0px);
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }
    .sidebar.active {
        transform: translateX(0);
    }
    .main-content {
        margin-left: 0 !important;
        padding: 1rem !important;
        padding-top: calc(4rem + env(safe-area-inset-top, 0px)) !important;
        padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px)) !important;
    }
    body.sidebar-collapsed .main-content {
        margin-left: 0 !important;
    }
    .sidebar.collapsed ~ .main-content,
    .sidebar.collapsed ~ * .main-content {
        margin-left: 0 !important;
    }
    .mobile-header {
        display: flex !important;
        position: fixed !important;
        top: 0;
        left: 0;
        right: 0;
        z-index: 30;
        background: var(--color-neutral-50);
        border-bottom: 1px solid var(--color-neutral-200);
        padding: 0.75rem 1rem;
    }
    .sidebar-collapse-btn {
        display: none;
    }
}

.mobile-header {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: var(--color-neutral-50);
    border-bottom: 1px solid var(--color-neutral-200);
    position: sticky;
    top: 0;
    z-index: 30;
}

.mobile-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

/* KPI Card Enhancements - Icon support */
.kpi-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.kpi-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.kpi-icon.leads { background: var(--blue-100); color: var(--blue-600); }
.kpi-icon.bookings { background: var(--green-100); color: var(--green-600); }
.kpi-icon.status { background: var(--amber-100); color: var(--amber-600); }
.kpi-icon.revenue { background: var(--purple-100); color: var(--purple-600); }

/* Enhanced Activity Feed */
.activity-feed {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
}

.activity-item {
    padding: 1.25rem 1.75rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: start;
    gap: 1.125rem;
    transition: all var(--transition-fast);
}

.activity-item:hover {
    background: var(--gray-50);
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: var(--shadow-xs);
}

.activity-icon.success {
    background: linear-gradient(135deg, var(--green-50), var(--green-100));
    color: var(--green-600);
}

.activity-icon.info {
    background: linear-gradient(135deg, var(--blue-50), var(--blue-100));
    color: var(--blue-600);
}

.activity-icon.warning {
    background: linear-gradient(135deg, var(--yellow-50), var(--yellow-100));
    color: var(--yellow-600);
}

.activity-content {
    flex: 1;
}

.activity-title {
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.375rem;
    font-size: 0.9375rem;
}

.activity-description {
    font-size: 0.875rem;
    color: var(--gray-600);
    line-height: 1.5;
}

.activity-time {
    font-size: 0.8125rem;
    color: var(--gray-500);
    font-weight: 500;
}

/* Status Widget */
.status-widget {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid var(--gray-200);
}

.status-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--green-600);
}

/* Professional Badge System */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem 0.625rem;
    background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 999px;
    margin-left: auto;
    box-shadow: var(--shadow-xs);
    letter-spacing: 0.01em;
}

/* Enhanced Table Styles */
.table-container {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: linear-gradient(180deg, var(--gray-50) 0%, var(--gray-100) 100%);
}

th {
    text-align: left;
    padding: 1rem 1.25rem;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--gray-700);
    border-bottom: 2px solid var(--gray-200);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

td {
    padding: 1.125rem 1.25rem;
    border-bottom: 1px solid var(--gray-200);
    font-size: 0.9375rem;
    color: var(--gray-700);
}

tr:last-child td {
    border-bottom: none;
}

tbody tr {
    transition: all var(--transition-fast);
}

tbody tr:hover {
    background: var(--gray-50);
    transform: scale(1.002);
}

/* Professional Empty State */
.empty-state {
    text-align: center;
    padding: 5rem 2rem;
    animation: fadeIn var(--transition-slow);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.empty-state-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 1.75rem;
    color: var(--gray-300);
    opacity: 0.7;
}

.empty-state-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
}

.empty-state-description {
    color: var(--gray-600);
    margin-bottom: 2rem;
    font-size: 1rem;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Professional Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    padding: 1rem;
    animation: fadeIn var(--transition-base);
}

.modal {
    background: white;
    border-radius: var(--radius-xl);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-2xl);
    animation: slideUp var(--transition-slow);
    border: 1px solid var(--gray-200);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 1.75rem 2rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(180deg, white 0%, var(--gray-50) 100%);
}

.modal-title {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--gray-900);
}

.modal-close {
    background: var(--gray-100);
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--gray-600);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--gray-200);
    color: var(--gray-900);
    transform: rotate(90deg);
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: var(--gray-50);
}

/* â”€â”€ Booking Detail Page (Stripe/Linear style) â”€â”€ */
.bdp {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 1.5rem 3rem;
}

/* Top bar */
.bdp-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0 1rem;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.bdp-back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    color: var(--gray-400);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    transition: color 0.15s ease;
}
.bdp-back:hover { color: var(--gray-700); }
.bdp-topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    flex-wrap: wrap;
}

/* Buttons */
.bdp-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 500;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.bdp-btn-primary { background: var(--gray-900); color: white; }
.bdp-btn-primary:hover { background: var(--gray-800); }
.bdp-btn-outline { background: white; border-color: var(--gray-200); color: var(--gray-600); }
.bdp-btn-outline:hover { background: var(--gray-50); border-color: var(--gray-300); color: var(--gray-700); }
.bdp-btn-danger-outline { background: white; border-color: var(--gray-200); color: var(--gray-500); }
.bdp-btn-danger-outline:hover { border-color: var(--color-error-200, #fecaca); color: var(--color-error-600); background: var(--color-error-50); }
.bdp-btn-danger-ghost { background: transparent; color: var(--gray-300); padding: 6px; }
.bdp-btn-danger-ghost:hover { color: var(--color-error-500); background: var(--color-error-50); }

/* Header */
.bdp-header {
    padding-bottom: 1.25rem;
    margin-bottom: 1.25rem;
    border-bottom: 1px solid var(--gray-100);
}
.bdp-header-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}
.bdp-customer-name {
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--gray-900);
    letter-spacing: -0.02em;
    line-height: 1.3;
}
.bdp-job-type {
    font-size: 0.8125rem;
    color: var(--gray-400);
    font-weight: 400;
    margin-top: 2px;
}
.bdp-badges {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
    flex-shrink: 0;
}
.bdp-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* At-a-glance summary */
.bdp-summary-line {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0;
    padding: 0.625rem 0;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--gray-100);
    font-size: 0.8125rem;
    color: var(--gray-500);
    font-weight: 500;
}
.bdp-summary-sep {
    margin: 0 0.375rem;
    color: var(--gray-200);
}

/* Alerts */
.bdp-alert {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    border: 1px solid;
    font-size: 0.8125rem;
    font-weight: 500;
    margin-bottom: 1rem;
}
.bdp-alert-purple { background: #faf5ff; border-color: #ede9fe; color: #6d28d9; }
.bdp-alert-blue { background: var(--color-primary-50); border-color: var(--color-primary-100); color: var(--color-primary-700); }
.bdp-alert-amber { background: #fffbeb; border-color: #fde68a; color: #92400e; }

/* Quick actions strip */
.bdp-quick-actions {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}
.bdp-quick-action {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    background: white;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--gray-600);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease;
}
.bdp-quick-action:hover {
    background: var(--gray-50);
    border-color: var(--gray-300);
    color: var(--gray-800);
}

/* Grid & cards */
.bdp-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}
.bdp-card {
    background: white;
    border: 1px solid var(--gray-100);
    border-radius: 10px;
    overflow: hidden;
}
.bdp-card-full { grid-column: 1 / -1; }
.bdp-card-title {
    padding: 0.625rem 1rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--gray-400);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* Fields */
.bdp-field-list { padding: 0; }
.bdp-field {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0.375rem 1rem;
    gap: 1rem;
}
.bdp-field:first-child { padding-top: 0; }
.bdp-field:last-child { padding-bottom: 0.625rem; }
.bdp-field-label {
    font-size: 0.8125rem;
    color: var(--gray-400);
    font-weight: 400;
    flex-shrink: 0;
    min-width: 80px;
}
.bdp-field-value {
    font-size: 0.8125rem;
    color: var(--gray-700);
    font-weight: 500;
    text-align: right;
    word-break: break-word;
}

/* Notes */
.bdp-notes-content { padding: 0.625rem 1rem; }
.bdp-notes-text {
    font-size: 0.8125rem;
    color: var(--gray-600);
    line-height: 1.6;
}
.bdp-empty {
    font-size: 0.8125rem;
    color: var(--gray-300);
    font-style: italic;
}
.bdp-notes-edit {
    padding: 0.625rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.bdp-textarea {
    width: 100%;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    font-size: 0.8125rem;
    font-family: inherit;
    color: var(--gray-700);
    background: var(--color-neutral-50);
    resize: vertical;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    outline: none;
    box-sizing: border-box;
}
.bdp-textarea:focus {
    border-color: var(--color-primary-400);
    box-shadow: 0 0 0 3px var(--color-primary-50);
    background: white;
}
.bdp-save-notes {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border: 1px solid var(--gray-200);
    background: white;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--gray-500);
    cursor: pointer;
    transition: all 0.15s ease;
}
.bdp-save-notes:hover {
    background: var(--gray-50);
    border-color: var(--gray-300);
    color: var(--gray-700);
}

/* Payment */
.bdp-payment-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    border-top: 1px solid var(--gray-100);
}
.bdp-charge-input-wrap { position: relative; }
.bdp-charge-input-wrap::before {
    content: '$';
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-400);
    pointer-events: none;
}
.bdp-charge-input {
    width: 100%;
    padding: 0.625rem 0.75rem 0.625rem 1.75rem;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 0.875rem;
    font-family: inherit;
    color: var(--gray-800);
    background: var(--color-neutral-50, #f8fafc);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.bdp-charge-input:focus {
    outline: none;
    border-color: var(--color-primary-400);
    box-shadow: 0 0 0 3px var(--color-primary-100);
    background: #fff;
}
.bdp-charge-input::placeholder { color: var(--gray-300); }
.bdp-charge-desc {
    margin: 0 0 16px;
    color: var(--color-neutral-500);
    font-size: 0.875rem;
    line-height: 1.5;
}
.bdp-charge-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-neutral-700);
    margin-bottom: 6px;
}

/* Photos */
.bdp-photos {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding: 0.625rem 1rem;
}
.bdp-photo {
    display: block;
    width: 96px;
    height: 96px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--gray-100);
    transition: transform 0.15s ease;
}
.bdp-photo:hover { transform: scale(1.04); }
.bdp-photo img { width: 100%; height: 100%; object-fit: cover; }

/* Transcript */
.bdp-transcript {
    padding: 0.625rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 500px;
    overflow-y: auto;
}
.bdp-msg {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    max-width: 85%;
}
.bdp-msg-customer { align-self: flex-start; }
.bdp-msg-ai { align-self: flex-end; flex-direction: row-reverse; }
.bdp-msg-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}
.bdp-msg-customer .bdp-msg-avatar { background: var(--color-primary-50); color: var(--color-primary-600); }
.bdp-msg-ai .bdp-msg-avatar { background: var(--gray-50); color: var(--gray-400); }
.bdp-msg-bubble { border-radius: 10px; padding: 0.375rem 0.75rem; }
.bdp-msg-customer .bdp-msg-bubble { background: var(--color-primary-50); border: 1px solid var(--color-primary-100); }
.bdp-msg-ai .bdp-msg-bubble { background: var(--gray-50); border: 1px solid var(--gray-100); }
.bdp-msg-meta { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1px; }
.bdp-msg-sender {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.bdp-msg-customer .bdp-msg-sender { color: var(--color-primary-600); }
.bdp-msg-ai .bdp-msg-sender { color: var(--gray-400); }
.bdp-msg-time { font-size: 0.625rem; color: var(--gray-400); }
.bdp-msg-text { font-size: 0.8125rem; color: var(--gray-700); line-height: 1.5; }

/* Meta footer */
.bdp-meta-footer {
    margin-top: 0.75rem;
    padding: 0.75rem 0 0;
    border-top: 1px solid var(--gray-100);
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 2rem;
}
.bdp-meta-item { display: flex; flex-direction: column; gap: 1px; }
.bdp-meta-label {
    font-size: 0.625rem;
    font-weight: 500;
    color: var(--gray-300);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.bdp-meta-value { font-size: 0.6875rem; color: var(--gray-400); }

@media (max-width: 640px) {
    .bdp { padding: 0 1rem 2rem; }
    .bdp-topbar { flex-direction: column; align-items: flex-start; }
    .bdp-topbar-actions { width: 100%; overflow-x: auto; }
    .bdp-header-top { flex-direction: column; }
    .bdp-customer-name { font-size: 1.25rem; }
    .bdp-grid { grid-template-columns: 1fr; }
    .bdp-field { flex-direction: column; gap: 2px; }
    .bdp-field-value { text-align: left; }
    .bdp-msg { max-width: 95%; }
    .bdp-meta-footer { flex-direction: column; gap: 0.75rem; }
    .bdp-quick-actions { flex-direction: column; }
}

