:root{
  --bg1:#0b0f1a;
  --bg2:#22103b;
  --card:rgba(255,255,255,.08);
  --stroke:rgba(255,255,255,.14);
  --text:rgba(255,255,255,.92);
  --muted:rgba(255,255,255,.65);
  --shadow: 0 24px 80px rgba(0,0,0,.45);
  --radius: 22px;
  /* Базовая палитра, привязанная к цветам Док */
  --bg0:#050713;          /* глубоко-тёмный, чуть синеватый */
  --bg1:#050816;
  --bg2:#020617;

  --panel:#0b1024;        /* фон панелей – ближе к синему, как её голограммы */
  --panel-soft:#101633;
  --panel-bright:#1b2143;
  /* --stroke-soft:rgba(120,144,255,.22); */

  --text:rgba(244,244,255,.96);
  --muted:rgba(195,204,255,.75);

  /* цвета Док */
  --purple:#c084fc;
  --purple-strong:#a855f7;
  --cyan:#38bdf8;
  --sky:#60a5fa;
  --lime:#a3e635;

  --accent-grad: linear-gradient(135deg, var(--purple-strong), var(--cyan));
  --accent-soft: linear-gradient(135deg, rgba(168,85,247,.55), rgba(56,189,248,.55));

  --shadow-soft: 0 26px 90px rgba(0,0,0,.60);
  --r:24px;
  --r2:18px;
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Arial;
  color:var(--text);
  overflow:hidden;
}
a{color:#d8b4fe; text-decoration:none}
a:hover{text-decoration:underline}

.bg{
  min-height:100%;
  background:
    radial-gradient(1200px 800px at 80% 0%, rgba(37, 99, 235, .22), transparent 60%), 
    radial-gradient(1100px 900px at 10% 15%, rgba(168, 85, 247, .18), transparent 65%), 
    radial-gradient(1900px 700px at 20% 100%, rgb(155 99 241 / 16%), transparent 55%), 
    linear-gradient(145deg, var(--bg0), var(--bg2));
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
}

.auth-card{
  width:min(440px, 94vw);
  background:var(--card);
  border:1px solid var(--stroke);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:26px;
  backdrop-filter: blur(14px);
}
.brand{font-weight:800; letter-spacing:.4px; font-size:20px; opacity:.95}
h1{margin:10px 0 18px 0; font-size:28px}
label{display:block; margin:12px 0 6px; font-size:13px; color:var(--muted)}
input, textarea{
  width:100%;
  padding:12px 12px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.18);
  background:rgba(0,0,0,.25);
  color:var(--text);
  outline:none;
}
input:focus, textarea:focus{border-color:rgba(216,180,254,.6)}
.btn{
  width:100%;
  margin-top:14px;
  padding:12px 14px;
  border:0;
  border-radius:14px;
  background: linear-gradient(135deg, rgba(168,85,247,.9), rgba(59,130,246,.85));
  color:white; font-weight:800;
  cursor:pointer;
  box-shadow: 0 14px 38px rgba(59,130,246,.22);
}
.btn:hover{filter:brightness(1.05)}
.muted{margin-top:14px; color:var(--muted)}
.err{
  background: rgba(239,68,68,.18);
  border:1px solid rgba(239,68,68,.35);
  padding:10px 12px;
  border-radius:14px;
  color: rgba(255,255,255,.92);
}

.shell{
  width:min(1100px, 96vw);
  height:min(760px, 92vh);
  display:grid;
  grid-template-columns: 320px 1fr;
  gap:16px;
}

.panel{
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  overflow:hidden;
}

.side{
  padding:18px;
  display:flex;
  flex-direction:column;
  gap:12px;
}
.nav a{display:block; padding:10px 12px; border-radius:14px; color:var(--text); opacity:.9}
.nav a:hover{background: rgba(255,255,255,.06); text-decoration:none}
.kv{font-size:13px; color:var(--muted)}
.badge{
  display:inline-flex; align-items:center; gap:8px;
  padding:8px 10px; border-radius:999px;
  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  font-size:13px;
}

.chat{
  display:flex; flex-direction:column; height:100%;
}
.chat-head{
  padding:16px 18px;
  border-bottom:1px solid rgba(255,255,255,.10);
  display:flex; align-items:center; justify-content:space-between;
}
.chat-title{font-weight:800}
.messages{
  flex:1; padding:18px;
  overflow:auto;
  display:flex; flex-direction:column; gap:10px;
}
.msg{
  max-width: 78%;
  padding:12px 14px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.25);
  line-height:1.45;
  white-space:pre-wrap;
}
.msg.me{margin-left:auto; background: rgba(59,130,246,.16); border-color: rgba(59,130,246,.22)}
.msg.her{margin-right:auto; background: rgba(168,85,247,.14); border-color: rgba(168,85,247,.20)}
.composer{
  padding:14px;
  border-top:1px solid rgba(255,255,255,.10);
  display:flex; gap:10px;
}
.composer textarea{resize:none; height:52px}
.composer button{
  width:120px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.08);
  color:var(--text);
  font-weight:800;
  cursor:pointer;
}
.composer button:hover{background: rgba(255,255,255,.11)}
.typing{color:var(--muted); font-size:13px; padding:0 18px 12px}
@media (max-width: 900px){
  .shell{grid-template-columns: 1fr; height:auto}
  .panel{height:auto}
}



