* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Arial,
    sans-serif;
  background: #ffffff;
  color: #111111;
}

.container {
  max-width: 920px;
  margin: 0 auto;
  padding: 24px 16px 64px;
}

h1 {
  margin: 0 0 16px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 16px;
  margin: 12px 0;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 720px) {
  .grid {
    grid-template-columns: 1fr;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 10px 0;
}

.field span {
  font-size: 13px;
  opacity: 0.85;
}

input {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  color: #111111;
  outline: none;
}

input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}

.actions {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 10px;
}

button,
.button {
  appearance: none;
  border: 0;
  border-radius: 10px;
  padding: 10px 12px;
  background: #2d6bff;
  color: #ffffff;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.button.secondary {
  background: #f3f4f6;
  color: #111111;
}

.message {
  margin-top: 12px;
  font-size: 13px;
  opacity: 0.95;
  min-height: 18px;
}

.summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 6px;
}

@media (max-width: 720px) {
  .summary {
    grid-template-columns: 1fr;
  }
}

.summaryItem {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 10px 12px;
}

.summaryLabel {
  font-size: 12px;
  opacity: 0.75;
}

.summaryValue {
  font-size: 18px;
  margin-top: 6px;
  font-weight: 700;
}

.actions.end {
  justify-content: flex-end;
}

.tableWrap {
  margin-top: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  overflow: auto;
  max-height: 520px;
  background: #ffffff;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.table th,
.table td {
  border: 1px solid #e5e7eb;
  padding: 6px 8px;
  vertical-align: top;
  white-space: pre-wrap;
}

.table th {
  background: #f9fafb;
  position: sticky;
  top: 0;
  z-index: 1;
}

.autocomplete {
  position: absolute;
  background: #ffffff;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.18);
  max-height: 260px;
  overflow: auto;
  z-index: 9999;
}

.autocompleteItem {
  padding: 10px 12px;
  cursor: pointer;
  color: #111111;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.autocompleteItem:hover {
  background: #f3f4f6;
}
