* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Arial, sans-serif;
  font-size: 10px;
  background: #151515;
  color: #eee;
}

.site-header {
  background: #3a3a3a;
  border: 2px solid #111;
  margin: 10px;
  padding: 16px;
  text-align: center;
}

.site-header h1 {
  margin: 0;
  font-size: 20px;
  color: red;
  font-weight: bold;
}

.site-subheader {
  margin: 4px 0 0 0;
  font-size: 10px;
  font-weight: bold;
}

.sidebar h2,
.add-item-panel h2,
.items-panel h2 {
  font-size: 14px;
  font-weight: bold;
}

.hl-trade,
.hl-tip {
  color: red;
  font-weight: bold;
}

.hl-rare {
  color: #397bb1;
}

.hl-supreme {
  color: #03e0df;
}

.hl-fantastic {
  color: #ba05b7;
}

.layout {
  display: flex;
  gap: 10px;
  margin: 0 10px 10px 10px;
  align-items: flex-start;
}

.sidebar {
  background: #3a3a3a;
  border: 2px solid #111;
  padding: 16px;
  width: 340px;
  flex-shrink: 0;
}

.sidebar h2 {
  white-space: nowrap;
  text-align: center;
}

.sidebar ul {
  text-align: left;
}

.sidebar h2 {
  margin-top: 0;
  font-size: 1.1rem;
}

.sidebar ul {
  padding-left: 18px;
  font-size: 0.9rem;
  line-height: 1.5;
}

.main-content {
  background: #3a3a3a;
  border: 2px solid #111;
  padding: 16px;
  flex: 1;
  min-width: 0;
}

.add-item-panel {
  border-bottom: 1px solid #555;
  padding-bottom: 16px;
  margin-bottom: 16px;
}

.add-item-panel h2, .items-panel h2 {
  margin-top: 0;
}

#item-form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.field {
  display: flex;
  flex-direction: column;
  font-size: 0.85rem;
}

.field input, .field select {
  padding: 6px;
  border-radius: 4px;
  border: 1px solid #666;
  background: #222;
  color: #eee;
  min-width: 140px;
}

#item-form button {
  align-self: flex-end;
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  background: #4a7d4a;
  color: #fff;
  cursor: pointer;
  height: fit-content;
}

#item-form button:hover {
  background: #5a955a;
}

.items-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

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

.filters select, .filters input {
  padding: 6px;
  border-radius: 4px;
  border: 1px solid #666;
  background: #222;
  color: #eee;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  font-size: 0.9rem;
}

th, td {
  border: 1px solid #555;
  padding: 8px;
  text-align: left;
}

th {
  cursor: pointer;
  background: #333;
  user-select: none;
}

th:hover {
  background: #444;
}

tbody tr:nth-child(even) {
  background: #333;
}

.delete-btn {
  background: #8a3a3a;
  border: none;
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  cursor: pointer;
}

.delete-btn:hover {
  background: #a94a4a;
}

#empty-msg {
  text-align: center;
  color: #999;
  margin-top: 20px;
}
