html, body {
    font-family: "DM Sans", "Segoe UI", sans-serif;
    background: #070b14;
    color: #e8eef8;
}

.ht-muted { color: #9aa8c0; }

.ht-appbar { border-bottom: 1px solid #1e2a3d; }
.ht-brand { letter-spacing: 0.04em; font-weight: 700; }
.ht-chip { border-color: #2ee6a6 !important; color: #2ee6a6 !important; }
.ht-drawer { border-right: 1px solid #1e2a3d; }
.ht-main { padding: 24px; min-height: calc(100vh - 48px); }

.ht-stat {
    background: linear-gradient(180deg, #121b2c, #0d1522);
    border: 1px solid #1e2a3d;
    border-radius: 16px;
}

.ht-inbox {
    display: grid;
    grid-template-columns: 300px 1fr;
    min-height: calc(100vh - 96px);
    border: 1px solid #1e2a3d;
    border-radius: 16px;
    overflow: hidden;
    background: #0b1220;
}

.ht-thread-list { border-right: 1px solid #1e2a3d; overflow: auto; }
.ht-thread {
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    color: inherit;
    border: 0;
    border-bottom: 1px solid #1e2a3d;
    padding: 12px 16px;
    cursor: pointer;
}
.ht-thread.active, .ht-thread:hover { background: #142033; }
.ht-thread-name { display: flex; justify-content: space-between; font-weight: 600; }
.ht-thread-meta { color: #9aa8c0; font-size: 12px; margin-top: 4px; }
.ht-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: #2ee6a6; display: inline-block; margin-top: 6px;
}

.ht-chat { display: flex; flex-direction: column; min-height: 0; }
.ht-chat-head {
    display: flex; justify-content: space-between; align-items: center;
    padding: 12px 16px; border-bottom: 1px solid #1e2a3d;
}
.ht-bubbles { flex: 1; overflow: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.ht-bubble {
    max-width: 72%;
    padding: 10px 12px;
    border-radius: 14px;
    line-height: 1.4;
    white-space: pre-wrap;
}
.ht-bubble.in { align-self: flex-start; background: #182433; }
.ht-bubble.out { align-self: flex-end; background: #123d32; }
.ht-bubble.staff { align-self: flex-end; background: #1a2f55; }
.ht-bubble-meta { font-size: 11px; color: #9aa8c0; margin-bottom: 4px; }
.ht-composer {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding: 12px;
    border-top: 1px solid #1e2a3d;
}
.ht-empty { margin: auto; color: #9aa8c0; }

.ht-kanban {
    display: grid;
    grid-template-columns: repeat(5, minmax(180px, 1fr));
    gap: 12px;
    overflow: auto;
}
.ht-column {
    background: #0d1522;
    border: 1px solid #1e2a3d;
    border-radius: 14px;
    padding: 12px;
    min-height: 420px;
}
.ht-column header {
    display: flex; justify-content: space-between;
    font-weight: 700; margin-bottom: 12px; color: #d7e2f2;
}
.ht-deal { background: #121b2c; border: 1px solid #243044; border-radius: 12px; }

.ht-login-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 20% 20%, rgba(46, 230, 166, 0.12), transparent 35%),
        radial-gradient(circle at 80% 0%, rgba(76, 141, 255, 0.16), transparent 32%),
        #070b14;
}
.ht-login-card {
    width: min(420px, 92vw);
    background: #101826;
    border: 1px solid #1e2a3d;
    border-radius: 20px;
    padding: 32px;
}
.ht-login-form { display: flex; flex-direction: column; gap: 8px; }
.ht-login-form label { font-size: 13px; color: #9aa8c0; }
.ht-login-form input {
    background: #0b1220;
    border: 1px solid #243044;
    color: #e8eef8;
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 8px;
}
.ht-login-form button {
    margin-top: 8px;
    border: 0;
    border-radius: 10px;
    padding: 12px;
    background: #2ee6a6;
    color: #062016;
    font-weight: 700;
    cursor: pointer;
}

#blazor-error-ui {
    background: #1a2436;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .reload { color: #2ee6a6; }
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }

@media (max-width: 900px) {
    .ht-inbox { grid-template-columns: 1fr; }
    .ht-kanban { grid-template-columns: 1fr; }
}
