:root {
  --bg: #000000;
  --fg: #cccccc;
  --green: #3fb950;
  --blue: #58a6ff;
  --dim: #7a7a7a;
  --red: #f85149;
  --font-mono: Consolas, "Cascadia Code", "Cascadia Mono", "Segoe UI Mono", "Courier New", monospace;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  height: 100dvh;
  width: 100%;
  width: 100vw;
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.35;
  overflow: hidden;
}

#termWrapper {
  width: 100%;
  height: 100%;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

#term {
  flex: 1;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 12px;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.35;
}

#term::-webkit-scrollbar {
  width: 14px;
}
#term::-webkit-scrollbar-track {
  background: var(--bg);
}
#term::-webkit-scrollbar-thumb {
  background: #333333;
}
#term::-webkit-scrollbar-thumb:hover {
  background: #4d4d4d;
}

.line {
  white-space: pre-wrap;
  word-break: break-word;
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.35;
  animation: termIn 0.05s ease-out;
}

.user { color: var(--green); }
.colon { color: var(--fg); }
.path { color: var(--blue); }
.dollar { color: var(--fg); }
.dim { color: var(--dim); }
.err { color: var(--red); }
.ok { color: var(--green); }
.info { color: var(--blue); }

.msg {
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.35;
  animation: termIn 0.05s ease-out;
}

.md {
  font-size: 14px;
  line-height: 1.35;
}

.md h1, .md h2, .md h3, .md h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--fg);
  margin: 0;
  line-height: 1.35;
}

.md p {
  margin: 0;
  font-size: 14px;
  line-height: 1.35;
}

.md ul, .md ol {
  margin: 0;
  padding-left: 20px;
  font-size: 14px;
  line-height: 1.35;
}

.md li {
  margin: 0;
  font-size: 14px;
  line-height: 1.35;
}

.md a {
  color: var(--blue);
  text-decoration: underline;
  font-size: 14px;
}

.md code {
  font-family: inherit;
  font-size: 14px;
  line-height: 1.35;
  color: var(--fg);
}

.md pre {
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.35;
  overflow-x: auto;
}

.md pre code {
  padding: 0;
  font-size: 14px;
  line-height: 1.35;
}

.md blockquote {
  margin: 0;
  padding-left: 8px;
  border-left: 2px solid #333333;
  color: var(--dim);
  font-size: 14px;
  line-height: 1.35;
}

.md table {
  border-collapse: collapse;
  margin: 0;
  font-size: 14px;
  line-height: 1.35;
}

.md th, .md td {
  border: 1px solid #333333;
  padding: 2px 6px;
  font-size: 14px;
  line-height: 1.35;
}

.copy {
  display: inline-block;
  margin-left: 6px;
  background: #1f1f1f;
  color: var(--dim);
  border: 1px solid #333333;
  font-family: inherit;
  font-size: 12px;
  padding: 0 4px;
  cursor: pointer;
}
.copy:hover {
  color: var(--fg);
}

.thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0;
}

.thumbs img {
  max-height: 100px;
  max-width: 160px;
  border: 1px solid #333333;
}

#promptRow {
  display: flex;
  align-items: flex-start;
  margin: 0;
  padding: 0;
  line-height: 1.35;
  font-size: 14px;
}

#promptRow.row-enter {
  animation: rowEnter 0.08s ease-out;
}

#ps1 {
  white-space: pre;
  font-size: 14px;
  line-height: 1.35;
  user-select: none;
}

#input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  color: var(--fg);
  font-family: inherit;
  font-size: 14px;
  resize: none;
  caret-color: var(--fg);
  padding: 0;
  margin: 0;
  overflow: hidden;
  line-height: 1.35;
}

#chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0;
}

.chip {
  background: #1a1a1a;
  border: 1px solid #333333;
  padding: 0 4px;
  cursor: pointer;
  color: var(--blue);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.35;
}

.chip:hover {
  color: var(--red);
  border-color: var(--red);
}

#status {
  font-size: 14px;
  line-height: 1.35;
  color: var(--dim);
  margin: 0;
  padding: 0;
}



@keyframes rowEnter {
  0% { opacity: 0.3; }
  100% { opacity: 1; }
}

@keyframes termIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

#drop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  color: var(--green);
  font-family: inherit;
  font-size: 14px;
  border: 1px dashed var(--green);
  z-index: 99;
}
