:root{
  --bg:#0b0d0a; --amber:#f0b429; --dim:#b09c52;
  --green:#7ec96b; --red:#e0685a; --cyan:#63c7c0; --grey:#98a294;
}
*{box-sizing:border-box}
html,body{height:100%;margin:0}
body{
  background:radial-gradient(ellipse at 50% 0%,#151a14 0%,var(--bg) 70%);
  color:var(--amber);
  font-family:"SF Mono",ui-monospace,Menlo,Consolas,"DejaVu Sans Mono",monospace;
  font-size:15px; line-height:1.55;
  display:flex; justify-content:center; padding:20px;
}
#shell{
  width:min(880px,100%); height:calc(100vh - 40px);
  display:flex; flex-direction:column;
  border:1px solid #2a3226; border-radius:8px;
  background:linear-gradient(180deg,#0e120d,#0a0c09);
  box-shadow:0 0 0 1px #000 inset, 0 20px 60px rgba(0,0,0,.6);
  overflow:hidden; position:relative;
}
#shell:after{
  content:""; position:absolute; inset:0; pointer-events:none;
  background:repeating-linear-gradient(180deg,rgba(255,255,255,.025) 0 1px,transparent 1px 3px);
}
@media (prefers-reduced-motion: reduce){ #shell:after{ display:none } }
@media (prefers-contrast: more){ #shell:after{ display:none } .sys{ color:#c7d0c3 } }

.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;
}
input:focus-visible{ outline:2px solid var(--green); outline-offset:2px }
header{
  padding:10px 16px; border-bottom:1px solid #2a3226;
  display:flex; justify-content:space-between; align-items:center;
  font-size:12px; letter-spacing:.14em; color:var(--dim); flex-wrap:wrap; gap:8px;
}
header b{color:var(--amber); letter-spacing:.24em}
#hud{display:flex; gap:14px; font-size:11px}
#hud span{color:var(--grey)}
#hud i{font-style:normal; color:var(--amber)}
#hud i.low{color:var(--red)}
#out{flex:1; overflow-y:auto; padding:18px 20px; white-space:pre-wrap; word-wrap:break-word}
#out::-webkit-scrollbar{width:8px}
#out::-webkit-scrollbar-thumb{background:#2a3226; border-radius:4px}
form{display:flex; gap:10px; border-top:1px solid #2a3226; padding:12px 16px; background:#0c0f0b}
#prompt{color:var(--green)}
input{flex:1; background:transparent; border:0; outline:0; color:var(--amber); font:inherit; caret-color:var(--green)}
.sys{color:var(--grey)}
.room{color:var(--cyan)}
.npc{color:var(--green)}
.warn{color:var(--red)}
.good{color:var(--green)}
.you{color:var(--dim)}
.title{color:var(--amber); font-weight:700; letter-spacing:.2em}
.card{border-left:2px solid var(--dim); padding-left:12px; color:#d8c58a}
