*{box-sizing:border-box}
html,body{margin:0;width:100%;height:100%;font-family:Arial,Helvetica,sans-serif;background:#0d0708;color:#fff}
button,input{font:inherit}
.hidden{display:none!important}

.login-page{min-height:100vh;display:flex;align-items:center;justify-content:center;background:#0d0708}
.login-box{width:360px;display:flex;flex-direction:column;align-items:flex-start}
.logo-wrap{width:310px;height:310px;border-radius:74px;background:#0a0a0a;display:flex;align-items:center;justify-content:center;margin-bottom:10px}
.logo{width:190px;height:190px;display:block}
.eyebrow{font-size:15px;font-weight:400;margin-top:0;color:#eee}
h1{font-size:31px;line-height:1;margin:8px 0 5px;font-weight:800;letter-spacing:-1px}
.subtitle{font-size:16px;margin:0 0 5px;color:#f1f1f1}
.google-login{font-size:16px;color:#7e4ca5;text-decoration:underline;cursor:pointer;display:inline-flex;align-items:center;gap:6px}
.google-g{font-weight:700;color:#4285f4}
.terms{font-size:13px;margin:5px 0 0;color:#eee}
.error{font-size:13px;color:#ff4652;margin:8px 0 0;min-height:18px}

.chat-page{min-height:100vh;background:#0d0708}
.topbar{height:68px;border-bottom:1px solid #241619;background:#10090a;display:flex;align-items:center;justify-content:space-between;padding:0 24px}
.brand{display:flex;align-items:center;gap:10px}
.brand img{width:40px;height:40px}
.brand strong{display:block;font-size:15px}
.brand span{display:block;font-size:10px;color:#999;margin-top:3px}
.top-actions{display:flex;align-items:center;gap:15px;font-size:13px;color:#ddd}
.top-actions button{background:transparent;border:1px solid #3a2024;color:#fff;border-radius:8px;padding:7px 12px;cursor:pointer}
.top-actions button:hover{border-color:#ff2633}

.chat-layout{height:calc(100vh - 68px);display:grid;grid-template-columns:280px 1fr}
.sidebar{border-right:1px solid #241619;padding:20px;background:#0f090a}
.sidebar-title{font-size:11px;letter-spacing:1px;color:#888;margin-bottom:14px}
.groups-list{display:flex;flex-direction:column;gap:7px}
.group-item{width:100%;border:1px solid #231517;background:#140b0d;color:#fff;text-align:left;padding:12px;border-radius:9px;cursor:pointer}
.group-item:hover,.group-item.active{border-color:#7e252d;background:#1a0d10}
.group-item strong{display:block;font-size:14px}
.group-item span{display:block;color:#888;font-size:11px;margin-top:4px}
.loading,.empty{color:#777;font-size:13px;padding:20px;text-align:center}

.conversation{min-width:0;display:flex;flex-direction:column}
.conversation-head{height:70px;border-bottom:1px solid #241619;padding:14px 20px}
.conversation-head h2{font-size:16px;margin:0 0 4px}
.conversation-head span{font-size:12px;color:#888}
.messages{flex:1;overflow:auto;padding:20px}
.message{max-width:700px;margin-bottom:12px}
.message .meta{font-size:11px;color:#888;margin-bottom:4px}
.message .body{display:inline-block;background:#181012;border:1px solid #29191c;padding:9px 12px;border-radius:10px;font-size:14px;line-height:1.4;white-space:pre-wrap;word-break:break-word}
.composer{border-top:1px solid #241619;padding:14px;display:flex;gap:9px;background:#10090a}
.composer input{flex:1;background:#170d0f;border:1px solid #302024;color:#fff;border-radius:9px;padding:12px;outline:none}
.composer input:focus{border-color:#743039}
.composer button{background:#ff2633;border:0;color:#fff;font-weight:700;border-radius:9px;padding:0 18px;cursor:pointer}
.composer button:hover{background:#e91d29}

@media(max-width:700px){
  .login-box{width:calc(100% - 42px)}
  .logo-wrap{width:260px;height:260px;border-radius:60px}
  .logo{width:160px;height:160px}
  .chat-layout{grid-template-columns:1fr}
  .sidebar{display:none}
  .topbar{padding:0 14px}
  .top-actions span{display:none}
}
