/* Dashboard (Account) - Calm Luxury */

.ui-dashboard-hero {
    padding: 72px 0 48px;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.04), rgba(15, 23, 42, 0.01));
}

.ui-dashboard-hero__card {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: clamp(1.5rem, 4vw, 2.5rem);
}

.ui-hero-title {
    font-size: clamp(2rem, 3vw, 2.6rem);
    font-weight: 700;
    margin-bottom: 8px;
}

.ui-hero-subtitle {
    color: var(--muted);
    font-size: 1.05rem;
    margin-bottom: 0;
}

.ui-admin-page-hero__top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 1rem;
}

.ui-admin-page-hero__eyebrow {
    color: var(--muted);
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: .5rem;
}

.ui-admin-page-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
}

.ui-dashboard-stats {
    margin-top: 24px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.ui-dashboard-stats--compact {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.ui-dashboard-stats--mini {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.ui-stat {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
}

.ui-stat--center {
    text-align: center;
}

.ui-stat--link {
    display: block;
    color: inherit;
    text-decoration: none;
    transition: border-color 160ms ease, box-shadow 160ms ease;
}

.ui-stat--link:hover,
.ui-stat--link:focus-visible {
    color: inherit;
    text-decoration: none;
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.ui-stat__label {
    color: var(--muted);
    font-size: 0.85rem;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.ui-stat__value {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text);
}

.ui-dashboard-section {
    padding: 56px 0 72px;
}

.dashboard-card {
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    background: var(--surface-raised);
}

.dashboard-card .card-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

.dashboard-card .card-header h4,
.dashboard-card .card-header h5 {
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.35;
}

.dashboard-card .card-title,
.dashboard-card h4,
.dashboard-card h5,
.dashboard-card h6 {
    color: var(--text);
}

.dashboard-card .table thead.bg-light,
.dashboard-card .table thead.ui-table-head {
    background: var(--surface) !important;
    color: var(--text);
    border-bottom: 1px solid var(--border);
}

.dashboard-icon {
    width: 64px;
    height: 64px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: rgba(var(--brand-rgb, 180, 95, 54), 0.08);
    color: var(--brand);
}

.dashboard-icon i {
    color: var(--brand) !important;
}

.table-hover tbody tr:hover {
    background-color: rgba(var(--brand-rgb, 180, 95, 54), 0.05);
}

.badge-light {
    background: var(--surface) !important;
    color: var(--text) !important;
    border: 1px solid var(--border);
}

.ui-dashboard-form .form-label {
    font-size: 0.85rem;
    color: var(--muted);
    font-weight: 600;
}

.no-inquiries,
.no-properties {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
}

.dashboard-inquiry-link {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease;
}

.dashboard-inquiry-link:hover,
.dashboard-inquiry-link:focus-visible {
    color: var(--brand);
    text-decoration: none;
}

.dashboard-section-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.dashboard-section-link:hover,
.dashboard-section-link:focus-visible {
    color: var(--brand);
    text-decoration: none;
}

.ui-dashboard-section a.text-dark.text-decoration-none {
    color: var(--text) !important;
    transition: color 0.2s ease;
}

.ui-dashboard-section a.text-dark.text-decoration-none:hover,
.ui-dashboard-section a.text-dark.text-decoration-none:focus-visible {
    color: var(--brand) !important;
    text-decoration: none !important;
}

.dashboard-inquiry-card .card-body {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
}

.dashboard-thread-card .card-body {
    background: var(--surface);
}

.dashboard-thread-log {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dashboard-thread-msg {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px 12px;
    background: var(--bg);
}

.dashboard-thread-msg--customer {
    background: rgba(var(--brand-rgb, 180, 95, 54), 0.08);
    border-color: rgba(var(--brand-rgb, 180, 95, 54), 0.28);
}

.dashboard-thread-msg--agency {
    background: rgba(15, 23, 42, 0.03);
}

.dashboard-thread-msg__meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.dashboard-thread-msg__author {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text);
}

.dashboard-thread-msg__time {
    font-size: 0.76rem;
    color: var(--muted);
}

.dashboard-thread-msg__body {
    color: var(--text);
    line-height: 1.45;
    word-break: break-word;
}

.dashboard-card--subsection {
    box-shadow: none;
    background: var(--surface);
}

.dashboard-empty-state__icon {
    width: 72px;
    height: 72px;
    margin: 0 auto;
    border-radius: 20px;
    background: rgba(var(--brand-rgb, 180, 95, 54), 0.1);
    color: var(--brand);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
}

.dashboard-empty-state__actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.account-overview-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.admin-resource-row {
    cursor: pointer;
}

.admin-resource-row:hover {
    background-color: rgba(15, 23, 42, 0.03);
}

.ui-resource-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
    gap: 1rem 1.25rem;
    width: 100%;
    min-width: 0;
}

.ui-resource-filter-field,
.ui-resource-filter-actions {
    min-width: 0;
}

.ui-resource-filter-field .form-control {
    width: 100%;
    max-width: 100%;
}

.ui-resource-filter-actions {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
}

.ui-resource-filter-actions .btn {
    margin: 0 !important;
}

.admin-inventory-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin: 0 0 1.25rem;
}

.admin-inventory-tabs a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: .55rem .9rem;
    border: 1px solid var(--border, #dfe3e8);
    border-radius: .75rem;
    background: #fff;
    color: var(--text, #10192a);
    font-weight: 700;
    text-decoration: none;
}

.admin-inventory-tabs a[aria-current="page"] {
    border-color: var(--brand);
    background: var(--brand);
    color: #fff;
}

.admin-inventory-pending { display: block; margin-top: .5rem; color: var(--brand-dark); font-size: .85rem; }
.admin-inventory-breakdown { margin-top: .75rem; color: var(--muted); font-size: .85rem; }
.admin-inventory-breakdown summary { cursor: pointer; padding-block: .3rem; }
.admin-inventory-breakdown p { margin: .5rem 0; max-width: 42ch; line-height: 1.5; }
.admin-inventory-breakdown dl { margin: 0; }
.admin-inventory-breakdown dl > div { display: flex; justify-content: space-between; gap: 1rem; }
.admin-inventory-breakdown dt { font-weight: 400; }
.admin-inventory-breakdown dd { margin: 0; font-variant-numeric: tabular-nums; }

@media (max-width: 991.98px) {
    .ui-dashboard-hero {
        padding: 56px 0 40px;
    }

    .ui-dashboard-hero__card {
        padding: 24px;
    }

    .account-overview-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .account-overview-grid {
        grid-template-columns: 1fr;
    }
}
