body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f8fafc;
}

/* ==========================================================
   ORIGINAL APPBAR & HEADING STYLES (EXACT & UNCHANGED)
   ========================================================== */
.fixed-header {
    position: fixed;
    top: 0;
    width: 100%;
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    padding: 3px 0;
    font-size: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 22;
    padding-left: 10px;
    padding-right: 10px;
    box-sizing: border-box;
}

.header-left {
    display: flex;
    align-items: center;
}

.icon-button {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    margin-right: 10px;
    display: flex;
    align-items: center;
}

.home-icon {
    width: 24px;
    height: 24px;
}

.header-title {
    flex-grow: 1;
    text-align: center;
    font-size: 20px;
    margin-left: 35px;
}

.heading-background {
    background-color: lavender;
}

.heading-container {
    text-align: center;
    margin: 40px 0;
}

.heading-container h2 {
    margin: 0;
    font-size: 20px;
    color: royalblue;
}

#businessPersonsDetailsContainer {
    margin: 20px auto;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    background-color: white;
    max-width: 600px;
    box-sizing: border-box;
}

/* ==========================================================
   UNIFIED BUSINESS TILE (ALL-IN-ONE CARD)
   ========================================================== */
.business-tile-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    margin: 12px 0;
    overflow: hidden;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.business-tile-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* The Main Row containing Left Image + Center Content + Right Image */
.tile-main-row {
    display: flex;
    align-items: center;
    padding: 12px 14px;
    gap: 12px;
}

/* 1. Left Avatar */
.tile-left-avatar {
    flex: 0 0 62px;
    height: 62px;
}

.tile-left-avatar img {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    display: block;
}

/* 2. Center Content */
.tile-center-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.person-heading {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.2;
    word-break: break-word;
}

/* Business Information Block inside the same tile */
.biz-meta-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 1px;
}

.biz-title-line {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.biz-label-name {
    font-size: 14px;
    font-weight: 700;
    color: #1e3a8a;
    word-break: break-word;
}

.biz-tag {
    background-color: #fef3c7;
    color: #92400e;
    font-size: 10.5px;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: 9999px;
    border: 1px solid #fde68a;
    text-transform: capitalize;
}

.biz-addr-line {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #64748b;
    word-break: break-word;
}

/* Details Toggle Button */
.details-toggle-btn {
    align-self: flex-start;
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
    border-radius: 5px;
    padding: 3px 9px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 3px;
    transition: all 0.2s ease;
}

.details-toggle-btn:hover {
    background-color: #e2e8f0;
    color: #0f172a;
}

.details-toggle-btn.active {
    background-color: #2575fc;
    color: #ffffff;
    border-color: #2575fc;
}

/* 3. Right Storefront Image */
.tile-right-image {
    flex: 0 0 68px;
    height: 68px;
}

.tile-right-image img {
    width: 68px;
    height: 68px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    display: block;
}

.tile-right-placeholder {
    display: none;
}

/* ==========================================================
   EXPANDABLE PERSONAL DRAWER
   ========================================================== */
.member-expanded-details {
    padding: 12px 14px;
    background-color: #f8fafc;
    border-top: 1px solid #e2e8f0;
    animation: fadeIn 0.2s ease-out forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 10px;
}

.detail-field {
    display: flex;
    flex-direction: column;
}

.detail-field .label {
    font-size: 10.5px;
    font-weight: 600;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.4px;
    margin-bottom: 2px;
}

.detail-field .value {
    font-size: 12.5px;
    font-weight: 600;
    color: #1e293b;
}

.events-drawer-section {
    border-top: 1px dashed #cbd5e1;
    padding-top: 8px;
}

.events-drawer-title {
    margin: 0 0 6px 0;
    font-size: 10.5px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.event-details-list {
    margin: 0;
    padding-left: 16px;
}

.event-item-row {
    font-size: 12.5px;
    margin-bottom: 3px;
    color: #334155;
}

.event-name {
    font-weight: 600;
    color: #0f172a;
}

.event-role {
    color: #2563eb;
    margin-left: 3px;
}

.event-date {
    color: #64748b;
    font-size: 11.5px;
    margin-left: 3px;
}

.no-events-data {
    margin: 0;
    font-size: 11.5px;
    color: #94a3b8;
    font-style: italic;
}

.empty-state {
    text-align: center;
    padding: 25px 15px;
    font-size: 14px;
    color: #64748b;
}

.error-state {
    text-align: center;
    padding: 25px 15px;
    font-size: 14px;
    color: #dc2626;
}

@media (max-width: 420px) {
    .tile-left-avatar {
        flex: 0 0 52px;
        height: 52px;
    }
    .tile-left-avatar img {
        width: 52px;
        height: 52px;
    }
    .tile-right-image {
        flex: 0 0 56px;
        height: 56px;
    }
    .tile-right-image img {
        width: 56px;
        height: 56px;
    }
    .biz-label-name {
        font-size: 13px;
    }
}