@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;600&family=VT323&display=swap");

:root {
  --bg: #071208;
  --panel: rgba(10, 30, 16, 0.92);
  --grid: rgba(30, 90, 50, 0.5);
  --accent: #45ff8a;
  --accent-dim: #2fb765;
  --text: #c6ffd9;
  --warn: #ffb347;
  --danger: #ff5d5d;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(circle at top left, #123220 0%, #071208 55%, #020603 100%);
  color: var(--text);
  font-family: "IBM Plex Mono", "VT323", monospace;
  font-size: 15px;
  min-height: 100vh;
}

.crt {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 24px;
  gap: 16px;
  position: relative;
}

.crt::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.02) 0,
    rgba(255, 255, 255, 0.02) 2px,
    transparent 2px,
    transparent 4px
  );
  mix-blend-mode: screen;
  pointer-events: none;
}

.frame {
  border: 1px solid var(--grid);
  padding: 16px;
  background: var(--panel);
  box-shadow: 0 0 18px rgba(64, 255, 140, 0.15);
  animation: boot 0.6s ease-out;
}

header.frame,
footer.frame {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  text-transform: uppercase;
  font-size: 13px;
}

header.frame {
  position: sticky;
  top: 0;
  z-index: 10;
}

footer.frame {
  position: sticky;
  bottom: 0;
  z-index: 10;
}

.header-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
}

.header-nav {
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 12px;
}

.login-lang {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  text-transform: uppercase;
}

.brand {
  font-family: "VT323", monospace;
  font-size: 24px;
  letter-spacing: 2px;
}

.blink {
  animation: blink 1s steps(2, jump-none) infinite;
}

main.frame {
  flex: 1;
}

.screen {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.toolbar {
  display: flex;
  gap: 8px;
}

.title {
  font-family: "VT323", monospace;
  font-size: 28px;
  letter-spacing: 2px;
  color: var(--accent);
}

.grid {
  display: grid;
  gap: 16px;
}

.grid.two {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.panel {
  border: 1px solid var(--grid);
  padding: 12px;
  background: rgba(4, 16, 8, 0.75);
}

.panel-title {
  font-size: 14px;
  color: var(--accent);
  margin-bottom: 10px;
  text-transform: uppercase;
}

.panel-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}

.table {
  display: grid;
  gap: 4px;
}

.table-row {
  display: grid;
  gap: 6px;
  padding: 6px;
  border-bottom: 1px dashed rgba(70, 180, 90, 0.2);
  font-size: 13px;
}

.table-6 .table-row {
  grid-template-columns: repeat(6, minmax(80px, 1fr));
}

.table-11 .table-row {
  grid-template-columns: repeat(11, minmax(80px, 1fr));
}

.table-7 .table-row {
  grid-template-columns: repeat(7, minmax(80px, 1fr));
}

.table-head {
  color: var(--accent);
  text-transform: uppercase;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.form-row input {
  min-width: 220px;
}

.form-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  text-transform: uppercase;
}

input,
select {
  background: #020a05;
  border: 1px solid var(--grid);
  color: var(--text);
  padding: 6px 8px;
  font-family: inherit;
}

button,
.btn {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: #02140a;
  padding: 6px 12px;
  text-transform: uppercase;
  font-family: "VT323", monospace;
  letter-spacing: 1px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-sm {
  padding: 4px 8px;
  font-size: 12px;
}

.chip {
  border: 1px solid var(--grid);
  padding: 2px 8px;
  text-decoration: none;
  color: var(--text);
  text-transform: uppercase;
}

.chip.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #02140a;
}

.tabs {
  display: flex;
  gap: 8px;
}

.tab {
  border: 1px solid var(--grid);
  color: var(--text);
  text-decoration: none;
  padding: 4px 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: "VT323", monospace;
}

.tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #02140a;
}

.table-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
  font-size: 12px;
  text-transform: uppercase;
}

button:hover,
.btn:hover,
.link:hover {
  filter: brightness(1.1);
}

.link {
  color: var(--accent);
  text-decoration: none;
}

.data-list {
  display: grid;
  gap: 6px;
  font-size: 12px;
}

.data-list div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.data-list span:first-child {
  color: var(--accent);
}

.hint {
  font-size: 13px;
  color: var(--warn);
}

.actions {
  display: flex;
  gap: 6px;
}

.inline-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.hidden {
  display: none;
}

.nav {
  display: flex;
  justify-content: flex-end;
}

.login-box {
  max-width: 420px;
  width: 100%;
}

@keyframes blink {
  0% {
    opacity: 0.1;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.1;
  }
}

@keyframes boot {
  0% {
    opacity: 0;
    transform: translateY(6px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .table-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    font-size: 11px;
  }

  .table-head {
    display: none;
  }

  .table-row > div {
    padding: 4px 0;
  }

  header.frame,
  footer.frame {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    align-items: flex-start;
  }
}
