:root {
  --green-bg: #001406;
  --green-dark: #000d04;
  --green-mid: #001f0b;
  --green-light: #46ff8a;
  --white: #ffffff;
  --soft-white: #f2fff6;
  --danger: #ff5f6d;
  --shadow: rgba(0,0,0,.38);
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--green-bg);
  color: var(--white);
  font-family: 'Ubuntu Mono', 'DejaVu Sans Mono', 'Liberation Mono', 'Courier New', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  overflow: hidden;
}
button, input, select {
  font: inherit;
}
button, select, input {
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 0;
}
button {
  background: linear-gradient(180deg, rgba(255,255,255,.15), rgba(255,255,255,.04));
  color: var(--white);
  cursor: pointer;
  padding: .50rem .68rem;
  box-shadow: 0 2px 10px var(--shadow);
}
button:hover { border-color: var(--white); background: rgba(255,255,255,.18); }
button:active { transform: translateY(1px); }
input, select {
  background: rgba(0,0,0,.28);
  color: var(--white);
  padding: .52rem .62rem;
  outline: none;
}
select option { color: #111; }
.hidden { display: none !important; }

.loginView {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 1rem;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,.18), transparent 35%),
    linear-gradient(135deg, #002713, #000d05 72%);
}
.loginCard {
  width: min(460px, 100%);
  background: rgba(0,20,7,.94);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 0;
  padding: 2rem;
  box-shadow: 0 24px 70px var(--shadow);
}
.logo {
  font-family: 'Ubuntu Mono', 'DejaVu Sans Mono', 'Liberation Mono', 'Courier New', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: .12em;
  font-size: 1rem;
  color: var(--green-light);
}
.loginCard h1 { margin: .5rem 0 0; font-size: 1.65rem; }
.loginCard p { color: var(--soft-white); line-height: 1.45; }
.loginCard form { display: grid; gap: .75rem; margin-top: 1.2rem; }
.loginCard button { margin-top: .35rem; font-weight: 700; }
.errorText { color: var(--danger); min-height: 1.2rem; margin-top: .7rem; font-weight: 700; }

.appView {
  height: 100vh;
  width: 100vw;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  background: var(--green-bg);
}
.topBar {
  display: flex;
  gap: .45rem;
  align-items: center;
  padding: .38rem;
  background: rgba(0,16,6,.96);
  border-bottom: 1px solid rgba(255,255,255,.18);
  min-height: 50px;
  overflow-x: auto;
}
.brand {
  flex: 0 0 auto;
  font-family: 'Ubuntu Mono', 'DejaVu Sans Mono', 'Liberation Mono', 'Courier New', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 800;
  letter-spacing: .05em;
  color: var(--green-light);
  padding: .35rem .55rem;
}
#favoriteSelect { min-width: 230px; max-width: 340px; }
.statusLine {
  height: 30px;
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: 0 .8rem;
  background: rgba(0,22,8,.88);
  border-bottom: 1px solid rgba(255,255,255,.12);
  font-family: 'Ubuntu Mono', 'DejaVu Sans Mono', 'Liberation Mono', 'Courier New', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--soft-white);
}
.dot { width: .72rem; height: .72rem; border-radius: 0; display: inline-block; background: #b6b6b6; box-shadow: 0 0 10px currentColor; }
.dot.idle { background: #d8d8d8; }
.dot.connecting { background: #ffd45a; }
.dot.connected { background: var(--green-light); }
.dot.error { background: var(--danger); }
.terminalWrap {
  min-height: 0;
  padding: .38rem;
  background: var(--green-bg);
}
#terminal {
  height: 100%;
  width: 100%;
  border-radius: 0;
  overflow: hidden;
  background: var(--green-dark);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.15), 0 16px 45px var(--shadow);
}
.xterm .xterm-viewport { background-color: var(--green-dark) !important; }
.xterm { padding: .42rem; height: 100%; }

.projectFooter {
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 .7rem;
  background: #000d04;
  border-top: 1px solid rgba(255,255,255,.18);
  color: rgba(255,255,255,.88);
  font-family: 'Ubuntu Mono', 'DejaVu Sans Mono', 'Liberation Mono', 'Courier New', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .78rem;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.loginFooter {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
}

.favDialog {
  width: min(720px, calc(100vw - 2rem));
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 0;
  color: var(--white);
  background: #001b0b;
  box-shadow: 0 24px 80px rgba(0,0,0,.55);
}
.favDialog::backdrop { background: rgba(0,0,0,.55); }
.favDialog form { display: grid; gap: .85rem; }
.favDialog h2 { margin: 0 0 .2rem; }
.favDialog label { display: grid; gap: .35rem; color: var(--soft-white); }
.gridTwo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem; }
.hint { color: var(--soft-white); line-height: 1.4; margin: .2rem 0; }
.hint code { color: #fff; background: rgba(0,0,0,.22); padding: .12rem .25rem; border-radius: 0; }
.favDialog menu { display: flex; justify-content: flex-end; gap: .65rem; padding: 0; margin: .4rem 0 0; }

@media (max-width: 760px) {
  .topBar { flex-wrap: nowrap; }
  .brand { display: none; }
  button { padding: .48rem .58rem; }
  #favoriteSelect { min-width: 190px; }
  .gridTwo { grid-template-columns: 1fr; }
}


/* v1.2: bewusst eckiger Terminal-Look ohne Rundungen */
button, input, select, dialog, .loginCard, #terminal, .dot, .hint code, .projectFooter {
  border-radius: 0 !important;
}
