body {
  margin: 0;
  font-family: Inter, Arial, sans-serif;
  background: #0f172a;
  color: #e2e8f0;
}

* {
  box-sizing: border-box;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 32px 20px 72px;
}

.card {
  background: #111827;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  margin-bottom: 16px;
}

h1, h2, p {
  margin-top: 0;
}

.app-header-title h2 {
  margin-bottom: 0;
}

.muted {
  color: #94a3b8;
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.row {
  display: flex;
}

.space-between {
  justify-content: space-between;
}

.align-center {
  align-items: center;
}

.gap {
  gap: 12px;
}

.wrap-mobile {
  flex-wrap: wrap;
}

label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
}

input[type="text"],
input[type="password"] {
  width: 100%;
  border-radius: 12px;
  border: 1px solid #334155;
  background: #0f172a;
  color: #e2e8f0;
  padding: 12px 14px;
}

button,
.button-link {
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  background: #2563eb;
  color: white;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

button.secondary {
  background: #334155;
}

button.danger,
.button-link.danger {
  background: #dc2626;
}

button:hover,
.button-link:hover {
  opacity: 0.95;
}

.label {
  display: block;
  font-size: 13px;
  color: #94a3b8;
  margin-bottom: 6px;
}

.upload-box,
.file-list-section {
  padding: 18px;
  border: 1px dashed #475569;
  border-radius: 14px;
}

.file-list-section {
  margin-top: 20px;
}

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

.file-picker {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 220px;
  border: 1.5px dashed #64748b;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.08), rgba(15, 23, 42, 0.55));
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.file-picker:hover,
.file-picker.drag-over {
  border-color: #60a5fa;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.16), rgba(15, 23, 42, 0.72));
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.16);
}

.file-picker input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-picker-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.18);
  color: #bfdbfe;
  font-size: 28px;
  font-weight: 700;
}

.file-picker-title {
  font-size: 20px;
  font-weight: 700;
  color: #f8fafc;
}

.file-picker-hint {
  font-size: 14px;
  color: #cbd5e1;
}

.file-picker-meta {
  font-size: 13px;
  color: #93c5fd;
}

.progress {
  margin-top: 20px;
}

.progress-bar {
  width: 100%;
  height: 14px;
  background: #1e293b;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 8px;
}

.progress-bar > div {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #22c55e, #2563eb);
  transition: width 0.2s ease;
}

.small-text {
  font-size: 13px;
  color: #cbd5e1;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.file-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.file-table th,
.file-table td {
  text-align: left;
  padding: 14px 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  vertical-align: middle;
}

.file-table th:last-child,
.file-table td:last-child {
  text-align: right;
}

.file-table th {
  color: #cbd5e1;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.file-name-cell {
  font-weight: 600;
  word-break: break-word;
}

.file-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.empty-row,
.file-table td.empty-row {
  text-align: center;
  color: #94a3b8;
}

.section-header {
  margin-bottom: 14px;
}

.hidden {
  display: none;
}

.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 9999;
  pointer-events: none;
}

.toast {
  min-width: 280px;
  max-width: 420px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.96);
  color: #e2e8f0;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  pointer-events: auto;
}

.toast.success {
  border-color: rgba(34, 197, 94, 0.5);
  color: #bbf7d0;
}

.toast.error {
  border-color: rgba(239, 68, 68, 0.5);
  color: #fecaca;
}

.toast.info {
  border-color: rgba(59, 130, 246, 0.5);
  color: #bfdbfe;
}

@media (max-width: 640px) {
  .row.space-between {
    flex-direction: column;
    align-items: stretch;
  }

  button,
  .button-link {
    width: 100%;
  }

  .file-picker {
    min-height: 190px;
    padding: 22px 16px;
  }

  .toast-container {
    left: 16px;
    right: 16px;
    top: 16px;
  }

  .toast {
    min-width: 0;
    max-width: none;
  }
}
