:root {
  --bg: #08090d;
  --panel: #0e1017;
  --panel-2: #12151e;
  --line: #252936;
  --text: #f1f1f5;
  --muted: #85899b;
  --dim: #555b6d;
  --violet: #a78bfa;
  --violet-bright: #c4b5fd;
  --green: #8bf0bd;
  --mono: "DM Mono", monospace;
  --sans: "Space Grotesk", sans-serif;
}
* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--sans); }
button, textarea { font: inherit; }
button { cursor: pointer; }
.noise { position: fixed; inset: 0; pointer-events: none; z-index: 5; opacity: .035; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E"); }
.app-shell { display: flex; min-height: 100vh; }
.sidebar { width: 260px; flex-shrink: 0; border-right: 1px solid var(--line); padding: 28px 17px 20px; display: flex; flex-direction: column; background: #0a0b10; }
.brand { display: flex; align-items: center; gap: 10px; margin: 0 0 35px 7px; color: var(--text); text-decoration: none; font-weight: 700; letter-spacing: .12em; font-size: 13px; }
.brand-mark { color: var(--violet); font-size: 25px; line-height: 1; text-shadow: 0 0 20px #a78bfa77; }
.brand-ai { color: var(--violet); }
.status-card { background: #10121a; border: 1px solid var(--line); border-radius: 9px; padding: 14px; margin-bottom: 30px; }
.status-top { display: flex; align-items: center; gap: 8px; font: 10px var(--mono); letter-spacing: .07em; color: var(--green); }
.status-dot { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: #656b7c; flex-shrink: 0; }
.status-dot.online { background: var(--green); box-shadow: 0 0 10px #8bf0bd99; }
.status-dot.busy { background: #f4c66a; box-shadow: 0 0 10px #f4c66a77; }
.status-card p { color: var(--muted); font-size: 11px; line-height: 1.6; margin: 11px 0 14px; }
.button { border-radius: 5px; padding: 10px 12px; border: 1px solid var(--line); background: transparent; color: var(--text); font-size: 11px; transition: .2s; }
.button:hover { border-color: var(--violet); color: var(--violet-bright); }
.button-full { width: 100%; }
.sidebar-section { margin-bottom: 29px; }
.section-label { color: #656b7d; font: 10px var(--mono); letter-spacing: .12em; margin: 0 0 12px 8px; }
.entity-option { display: flex; align-items: center; width: 100%; text-align: left; gap: 10px; background: transparent; color: var(--text); border: 1px solid transparent; border-radius: 7px; padding: 11px 9px; margin: 4px 0; }
.entity-option:hover { background: #12141c; }
.entity-option.active { background: #171522; border-color: #39304e; }
.entity-icon { color: var(--violet); width: 24px; font-size: 20px; text-align: center; }
.entity-option strong, .entity-option small { display: block; }
.entity-option strong { font-size: 12px; font-weight: 500; }
.entity-option small { color: var(--muted); font-size: 10px; margin-top: 4px; }
.entity-check { margin-left: auto; color: var(--violet); opacity: 0; font-size: 12px; }
.entity-option.active .entity-check { opacity: 1; }
.quick-action { width: 100%; text-align: left; padding: 10px 9px; background: none; border: 0; color: #a8abba; font-size: 11px; border-radius: 5px; }
.quick-action span { display: inline-block; width: 25px; color: var(--violet); font-size: 15px; }
.quick-action:hover { background: #141620; color: var(--text); }
.sidebar-footer { display: flex; gap: 11px; margin-top: auto; border-top: 1px solid var(--line); padding: 18px 4px 0; }
.privacy-icon { display: grid; place-items: center; border: 1px solid #32493e; background: #13231d; color: var(--green); width: 30px; height: 30px; border-radius: 7px; flex-shrink: 0; }
.sidebar-footer strong, .sidebar-footer small { display: block; }
.sidebar-footer strong { font: 9px var(--mono); letter-spacing: .06em; color: var(--green); margin: 1px 0 6px; }
.sidebar-footer small { color: var(--muted); font-size: 10px; line-height: 1.5; }
.main-panel { flex: 1; min-width: 0; }
.topbar { height: 65px; padding: 0 35px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); color: #777c8e; font: 10px var(--mono); letter-spacing: .08em; }
.breadcrumb span { color: #414657; margin: 0 9px; }
.breadcrumb strong { color: #b8bbca; font-weight: 400; }
.topbar-right { display: flex; align-items: center; gap: 8px; }
.live-indicator { width: 6px; height: 6px; background: var(--green); border-radius: 50%; }
.mobile-brand { display: none; }
.workspace { width: min(900px, calc(100% - 56px)); margin: 0 auto; padding: 52px 0 22px; }
.intro { text-align: center; margin-bottom: 30px; }
.eyebrow { display: flex; align-items: center; justify-content: center; gap: 12px; color: var(--violet); font: 9px var(--mono); letter-spacing: .17em; }
.eyebrow-line { width: 25px; height: 1px; background: #62517d; }
h1 { margin: 18px 0 13px; font-size: clamp(42px, 5vw, 62px); letter-spacing: -.065em; line-height: .98; font-weight: 600; }
.title-accent { color: var(--violet-bright); text-shadow: 0 0 35px #a78bfa25; }
.intro-copy { color: #8e92a3; font-size: 12px; line-height: 1.8; }
.chat-card { border: 1px solid #2a2d3b; background: linear-gradient(145deg, #0e1017, #0c0e14 80%); border-radius: 12px; overflow: hidden; box-shadow: 0 20px 90px #0004, 0 0 50px #a78bfa08; }
.chat-header { display: flex; align-items: center; gap: 12px; padding: 16px 19px; border-bottom: 1px solid var(--line); background: #10121a; }
.entity-avatar { display: grid; place-items: center; width: 37px; height: 37px; border-radius: 9px; background: #211b30; border: 1px solid #47375d; color: var(--violet-bright); font-size: 23px; box-shadow: inset 0 0 20px #a78bfa0a; }
.chat-identity { min-width: 0; }
.chat-identity strong { display: block; font: 10px var(--mono); letter-spacing: .1em; color: #e2dcf4; }
.chat-identity small { display: block; color: var(--muted); font-size: 10px; margin-top: 5px; }
.model-pill { display: flex; align-items: center; gap: 7px; margin-left: auto; border: 1px solid #303442; border-radius: 20px; padding: 7px 9px; font: 9px var(--mono); color: #8f94a6; white-space: nowrap; }
.messages { min-height: 285px; max-height: 430px; overflow-y: auto; padding: 22px 20px 15px; scrollbar-color: #353044 transparent; scrollbar-width: thin; }
.message-row { display: flex; gap: 11px; margin-bottom: 20px; animation: fade-in .25s ease-out; }
.message-row.user-row { flex-direction: row-reverse; }
.message-avatar { width: 28px; height: 28px; flex-shrink: 0; display: grid; place-items: center; border: 1px solid #433454; background: #211a2b; color: var(--violet-bright); border-radius: 7px; font-size: 16px; }
.user-row .message-avatar { border-color: #345247; background: #14231e; color: var(--green); }
.message-content { max-width: min(82%, 620px); }
.user-row .message-content { text-align: right; }
.message-meta { font: 9px var(--mono); color: #b3a1d9; letter-spacing: .08em; margin: 2px 0 8px; }
.user-row .message-meta { color: var(--green); }
.message-meta span { color: #5e6274; letter-spacing: 0; margin-left: 5px; }
.bubble { display: inline-block; max-width: 100%; border: 1px solid #292d3b; background: #141620; color: #d6d7e1; font-size: 12px; line-height: 1.75; text-align: left; padding: 12px 14px; border-radius: 2px 10px 10px 10px; overflow-wrap: anywhere; white-space: pre-wrap; }
.user-row .bubble { background: #171c1e; border-color: #2b4039; border-radius: 10px 2px 10px 10px; }
.dim-text { color: #858094; font-style: italic; }
.typing-dots { display: inline-flex; gap: 4px; padding: 5px 0; }
.typing-dots span { width: 5px; height: 5px; background: var(--violet); border-radius: 50%; animation: pulse 1s infinite; }
.typing-dots span:nth-child(2) { animation-delay: .15s; }
.typing-dots span:nth-child(3) { animation-delay: .3s; }
.suggestions { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 20px 16px 59px; }
.suggestion { background: #10121a; border: 1px solid #292d3b; color: #9fa3b4; border-radius: 5px; padding: 8px 10px; font-size: 10px; transition: .2s; }
.suggestion:hover { border-color: #655183; color: var(--violet-bright); background: #171522; }
.composer { display: flex; align-items: flex-end; gap: 10px; margin: 0 15px; padding: 11px 12px 11px 14px; border: 1px solid #373344; border-radius: 8px; background: #0a0b11; transition: border-color .2s; }
.composer:focus-within { border-color: #79619f; box-shadow: 0 0 0 3px #a78bfa0b; }
.composer-prefix { color: var(--violet); font: 12px var(--mono); padding-bottom: 8px; }
textarea { resize: none; flex: 1; min-width: 0; max-height: 130px; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 12px; line-height: 1.6; padding: 4px 0; }
textarea::placeholder { color: #64697a; }
.send-button { display: flex; align-items: center; gap: 10px; background: var(--violet); border: 0; color: #100d18; border-radius: 5px; padding: 10px 12px; font: 9px var(--mono); letter-spacing: .06em; font-weight: 500; transition: .2s; }
.send-button:hover { background: var(--violet-bright); transform: translateY(-1px); }
.send-button:disabled { opacity: .5; cursor: wait; transform: none; }
.send-button b { font-size: 15px; }
.composer-foot { display: flex; justify-content: space-between; gap: 10px; padding: 9px 19px 14px; color: #5c6172; font: 8px var(--mono); letter-spacing: .04em; }
.page-footer { display: flex; justify-content: space-between; gap: 15px; margin-top: 23px; color: #555a6b; font: 8px var(--mono); letter-spacing: .05em; }
.footer-separator { color: #a78bfa; padding: 0 5px; }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translate(-50%, 15px); opacity: 0; pointer-events: none; background: #171522; border: 1px solid #514268; color: #e7defa; padding: 12px 16px; border-radius: 7px; font-size: 12px; box-shadow: 0 10px 35px #0007; transition: .25s; z-index: 10; max-width: calc(100% - 30px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@keyframes fade-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 60%, 100% { opacity: .3; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-3px); } }
@media (max-width: 850px) {
  .sidebar { width: 220px; padding-inline: 12px; }
  .topbar { padding: 0 20px; }
  .workspace { width: calc(100% - 36px); padding-top: 40px; }
  .suggestions { padding-left: 20px; }
}
@media (max-width: 650px) {
  .sidebar { display: none; }
  .topbar { height: 58px; padding: 0 16px; }
  .mobile-brand { display: flex; align-items: center; gap: 5px; color: var(--text); font: 700 11px var(--sans); letter-spacing: .1em; }
  .mobile-brand .brand-mark { font-size: 20px; }
  .breadcrumb { display: none; }
  .topbar-right { font-size: 8px; }
  .workspace { width: calc(100% - 24px); padding-top: 35px; }
  .intro { margin-bottom: 24px; }
  h1 { font-size: 48px; }
  .intro-copy { font-size: 11px; padding: 0 6px; }
  .desktop-break { display: none; }
  .chat-header { padding: 13px; gap: 9px; }
  .model-pill { padding: 6px 7px; font-size: 8px; }
  .messages { padding: 17px 12px 12px; min-height: 300px; max-height: 48vh; }
  .message-content { max-width: 86%; }
  .bubble { font-size: 11px; padding: 10px 11px; }
  .suggestions { padding: 0 12px 14px; gap: 6px; }
  .suggestion { font-size: 9px; }
  .composer { margin: 0 9px; padding: 8px; gap: 7px; }
  .send-button { padding: 10px; gap: 6px; }
  .send-button span { display: none; }
  .composer-foot { padding-inline: 12px; font-size: 7px; }
  .page-footer { flex-direction: column; text-align: center; font-size: 7px; }
}
