:root{
  --bg:#eef4fb;
  --card:#ffffff;
  --text:#1e293b;
  --muted:#64748b;
  --primary:#3b82f6;
  --soft:#dbeafe;
  --action:#0f766e;
}

body{
  margin:0;
  font-family:system-ui, -apple-system, Segoe UI, Roboto, Arial;
  background:var(--bg);
  color:var(--text);
}

.container{
  display:flex;
  height:100vh;
}

/* LEFT */
.left{
  width:40%;
  display:flex;
  align-items:center;
  justify-content:center;
}

.genie{
  width:260px;
  animation:
    float 6s ease-in-out infinite,
    breathe 4.5s ease-in-out infinite,
    glow 5.5s ease-in-out infinite;
  transition:opacity .25s ease, transform .25s ease, filter .25s ease;
  filter:drop-shadow(0 0 18px rgba(59,130,246,.22));
}

.genie.fade{
  opacity:.35;
  transform:scale(.96);
  filter:drop-shadow(0 0 8px rgba(59,130,246,.12));
}

@keyframes float{
  0%,100%{transform:translateY(0);}
  50%{transform:translateY(-12px);}
}

@keyframes breathe{
  0%,100%{scale:1;}
  50%{scale:1.025;}
}

@keyframes glow{
  0%,100%{filter:drop-shadow(0 0 14px rgba(59,130,246,.18));}
  50%{filter:drop-shadow(0 0 28px rgba(59,130,246,.32));}
}

/* RIGHT */
.right{
  width:60%;
  background:var(--card);
  display:flex;
  flex-direction:column;
  padding:20px;
}

.state{
  font-size:12px;
  color:var(--muted);
  margin-bottom:6px;
}

.chat{
  flex:1;
  overflow:auto;
  margin-bottom:10px;
}

.msg{
  margin:8px 0;
  padding:10px 14px;
  border-radius:14px;
  max-width:78%;
  line-height:1.4;
}

.bot{
  background:var(--soft);
}

.user{
  background:#e2e8f0;
  margin-left:auto;
}

/* CONTROLS */
.controls,
.followup-controls,
.action-controls{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:8px;
}

button{
  padding:10px 14px;
  border:none;
  border-radius:10px;
  background:var(--primary);
  color:white;
  cursor:pointer;
  font-size:14px;
}

button.secondary{
  background:#e2e8f0;
  color:#1e293b;
}

button.action{
  background:var(--action);
}

button:disabled{
  opacity:.7;
  cursor:default;
}

/* INTAKE */
.intake{
  display:none;
  margin-top:10px;
  padding:12px;
  border-radius:14px;
  background:#f8fafc;
  border:1px solid #dbe3ef;
}

.intake h3{
  margin:0 0 8px;
  font-size:16px;
}

.intake input,
.intake select,
.intake textarea{
  width:100%;
  margin:6px 0;
  padding:10px;
  border:1px solid #cbd5e1;
  border-radius:10px;
  font-family:inherit;
  font-size:14px;
  box-sizing:border-box;
}

.intake textarea{
  min-height:80px;
  resize:vertical;
}

/* MOBILE */
@media(max-width:800px){
  .container{
    flex-direction:column;
    height:auto;
    min-height:100vh;
  }

  .left,
  .right{
    width:100%;
  }

  .left{
    padding:24px 0 8px;
  }

  .genie{
    width:210px;
  }

  .right{
    min-height:60vh;
  }
}