:root { --ink:#162033; --muted:#6e7b90; --line:#e7ebf1; --surface:#fff; --bg:#f6f8fb; --blue:#356df3; --blue-soft:#eef3ff; }
* { box-sizing:border-box; }
body { margin:0; min-height:100vh; background:var(--bg); color:var(--ink); font-family:Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.shell { width:100%; height:100vh; height:100dvh; min-height:0; margin:0; padding:20px; display:flex; flex-direction:column; }
.topbar { display:flex; align-items:center; justify-content:space-between; }
.brand { display:flex; align-items:center; }
.brand-logo { display:block; width:min(24vw, 210px); max-height:125px; height:auto; object-fit:contain; object-position:left center; }
.hero { padding:84px 0 35px; text-align:center; }
.eyebrow, .section-kicker { color:var(--blue); font-size:10px; letter-spacing:.16em; font-weight:800; }
h1 { margin:17px 0 15px; font-size:clamp(38px, 6vw, 64px); line-height:1.04; letter-spacing:-.06em; font-weight:780; }
h1 span { color:#93a1b8; }
.subtitle { max-width:500px; margin:0 auto; color:var(--muted); font-size:15px; line-height:1.6; }
.query-card, .result-card { background:var(--surface); border:1px solid var(--line); border-radius:19px; box-shadow:0 12px 34px rgba(35,54,86,.06); }
.conversation { display:grid; flex:1; min-height:0; grid-template-columns:minmax(280px, 40%) minmax(0, 1fr); grid-template-areas:"chat ."; gap:16px; align-items:stretch; margin-top:16px; }
.query-card { width:100%; min-width:0; min-height:0; height:100%; }
query-chat { display:block; }
.conversation .query-card { grid-area:chat; }
.conversation.has-grid { grid-template-areas:"chat result"; }
.conversation.has-grid .result-card { grid-area:result; width:100%; }
.query-card { padding:21px; display:flex; flex-direction:column; }
.query-label { color:#57667e; font-size:12px; font-weight:750; margin-bottom:12px; }
.spark { color:var(--blue); font-size:15px; margin-right:5px; }
textarea { resize:vertical; display:block; width:100%; min-height:94px; border:1px solid #dfe5ee; border-radius:13px; padding:15px 16px; font:inherit; font-size:15px; color:var(--ink); outline:none; transition:.2s; }
textarea:focus { border-color:#98b1ff; box-shadow:0 0 0 4px var(--blue-soft); }
.query-footer { display:flex; justify-content:space-between; align-items:center; margin-top:13px; gap:14px; }
.hint, .section-heading small, .example-card small { color:var(--muted); font-size:12px; }
.primary-button { border:0; border-radius:10px; color:#fff; background:var(--blue); padding:11px 17px; font:inherit; font-size:13px; font-weight:720; cursor:pointer; box-shadow:0 7px 16px rgba(53,109,243,.22); }
.primary-button:hover { background:#275bdb; transform:translateY(-1px); }
.primary-button:disabled { opacity:.6; cursor:wait; }
.secondary-button { border:1px solid #dfe5ee; border-radius:10px; color:#43516a; background:#fff; padding:10px 14px; font:inherit; font-size:13px; font-weight:700; cursor:pointer; }
.secondary-button:hover { border-color:#b7c8ff; background:#fbfcff; }
.logout-control { display:block; }
.auth-button { display:inline-flex; align-items:center; justify-content:center; gap:8px; }
.auth-button:disabled { opacity:.75; cursor:wait; }
.button-icon { font-size:14px; line-height:1; }
.button-spinner { display:none; width:14px; height:14px; border:2px solid currentColor; border-right-color:transparent; border-radius:50%; animation:button-spin .7s linear infinite; }
.auth-button.is-loading .button-icon { display:none; }
.auth-button.is-loading .button-spinner { display:inline-block; }
@keyframes button-spin { to { transform:rotate(360deg); } }
.login-shell { min-height:100vh; min-height:100dvh; display:grid; place-items:center; padding:20px; }
.login-card { width:min(100%, 430px); padding:34px; background:var(--surface); border:1px solid var(--line); border-radius:19px; box-shadow:0 12px 34px rgba(35,54,86,.08); }
.login-logo { display:block; width:207px; max-width:100%; height:auto; margin:0 auto 30px; }
.login-card .section-kicker { margin-bottom:24px; }
.login-form { display:grid; gap:9px; }
.login-form label { font-size:13px; font-weight:700; color:#43516a; }
.login-form input { width:100%; min-height:45px; border:1px solid #dfe5ee; border-radius:10px; padding:10px 12px; font:inherit; font-size:15px; color:var(--ink); outline:none; margin-bottom:9px; }
.login-form input:focus { border-color:#98b1ff; box-shadow:0 0 0 4px var(--blue-soft); }
.login-form .auth-button { width:100%; min-height:45px; margin-top:9px; }
.login-error { color:#9d2536; background:#fff1f3; border:1px solid #ffd7dd; border-radius:10px; padding:11px 12px; margin:0 0 18px; font-size:13px; }
.chat-thread { display:grid; align-content:start; gap:12px; flex:1; min-height:0; overflow-y:auto; overscroll-behavior:contain; margin:0 0 14px; padding:2px 4px 10px 0; }
.chat-thread:empty { display:none; }
.chat-message { max-width:min(78%, 760px); width:fit-content; padding:12px 15px; border-radius:15px; font-size:14px; line-height:1.5; white-space:pre-wrap; overflow-wrap:anywhere; }
.chat-message.user { justify-self:end; color:#fff; background:var(--blue); border-bottom-right-radius:5px; }
.chat-message.assistant { justify-self:start; color:var(--ink); background:#f3f6fb; border:1px solid var(--line); border-bottom-left-radius:5px; }
.examples { padding:38px 0 12px; }
.section-heading { display:flex; justify-content:space-between; align-items:center; margin-bottom:13px; font-size:13px; font-weight:750; }
.example-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; }
.example-card { display:grid; grid-template-columns:auto 1fr auto; align-items:center; gap:12px; text-align:left; background:transparent; border:1px solid var(--line); border-radius:14px; padding:15px; cursor:pointer; color:var(--ink); transition:.2s; }
.example-card:hover { border-color:#b7c8ff; background:#fbfcff; transform:translateY(-2px); }
.example-card b, .example-card small { display:block; }
.example-card b { font-size:13px; margin-bottom:4px; }
.example-card i { color:#9aa7b9; font-style:normal; font-size:17px; }
.example-icon { display:grid; place-items:center; width:32px; height:32px; border-radius:10px; font-size:17px; }
.blue { background:#edf3ff; color:#4775f1; } .violet { background:#f2efff; color:#8066e8; } .green { background:#eaf9f2; color:#30a977; }
.result-card { display:flex; flex-direction:column; padding:22px; margin-top:0; min-width:0; min-height:0; height:100%; overflow:auto; }
.result-head { display:flex; justify-content:space-between; gap:20px; align-items:flex-start; }
h2 { margin:7px 0 0; font-size:22px; letter-spacing:-.03em; }
.intent-tag { color:#4f6aa1; background:var(--blue-soft); border-radius:99px; padding:7px 10px; font-size:11px; font-weight:700; white-space:nowrap; }
.note { margin-top:15px; color:#8a6b19; background:#fff9e8; border:1px solid #f8eabd; border-radius:10px; padding:10px 12px; font-size:12px; }
.table-wrap { flex:1 1 auto; min-width:0; min-height:0; overflow:auto; margin-top:20px; border:1px solid var(--line); border-radius:12px; }
.table-pagination { position:sticky; left:0; display:flex; align-items:center; justify-content:flex-end; gap:12px; min-width:fit-content; padding:10px 12px; border-top:1px solid var(--line); background:var(--surface); color:#58677d; font-size:12px; }
.table-page-button { border:1px solid var(--line); border-radius:8px; padding:7px 10px; background:var(--surface); color:#244d97; cursor:pointer; font:inherit; }
.table-page-button:disabled { opacity:.45; cursor:default; }
.empty-table { padding:15px; color:#7a879a; font-size:12px; }
table { width:100%; border-collapse:collapse; font-size:12px; min-width:540px; } th, td { text-align:left; padding:11px 13px; border-bottom:1px solid var(--line); white-space:nowrap; } th { color:#7a879a; font-size:10px; text-transform:uppercase; letter-spacing:.08em; background:#fafbfc; } tr:last-child td { border-bottom:0; }
.hidden { display:none !important; }
@media (max-width:900px) { .shell { height:auto; min-height:100vh; min-height:100dvh; } .conversation { min-height:calc(100dvh - 112px); grid-template-columns:minmax(0, 1fr); grid-template-areas:"chat"; } .conversation.has-grid { flex:none; grid-template-columns:minmax(0, 1fr); grid-template-rows:minmax(calc(100dvh - 70px), auto) auto; grid-template-areas:"chat" "result"; } .query-card, .conversation.has-grid .result-card { width:100%; } .conversation.has-grid .result-card { height:auto; max-height:none; } }
@media (max-width:760px) { .shell { padding:14px 12px; } .topbar { min-height:42px; } .brand-logo { width:min(42vw, 170px); max-height:100px; } .logout-control .secondary-button { width:auto; } .login-card { padding:25px; } .conversation { margin-top:12px; } .query-card { padding:15px; } .result-card { padding:17px; } .result-head { flex-direction:column; gap:10px; } h2 { font-size:19px; } .chat-message { max-width:92%; } .query-footer { align-items:center; } .primary-button, .secondary-button { width:100%; } }
