:root {
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #0e1116;
  color: #e7ecf3;
}

.app {
  max-width: 760px;
  margin: 0 auto;
  padding: 14px;
}

.header h1 {
  margin: 0 0 4px;
  font-size: 1.35rem;
}

.header p {
  margin: 0 0 12px;
  color: #b5bfcc;
}

.card {
  background: #171c25;
  border: 1px solid #2a3140;
  border-radius: 12px;
  padding: 10px;
  margin-bottom: 10px;
}

.upload-label {
  display: inline-block;
  margin-bottom: 8px;
  font-size: 0.95rem;
}

input[type="file"] {
  width: 100%;
}

.hint {
  margin: 8px 0 0;
  color: #9eacbe;
  font-size: 0.85rem;
}

.status {
  min-height: 1.2em;
  margin-bottom: 8px;
  color: #b7c1cf;
}

.row {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 6px 0;
  border-top: 1px solid #263041;
}

.row:first-child {
  border-top: 0;
}

.thumb {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #33405a;
}

.name {
  font-size: 0.86rem;
  color: #d3dbe8;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.controls {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

button,
a#downloadBtn {
  background: #2d7ef7;
  color: #ffffff;
  border: 0;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 0.85rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
}

button.small {
  background: #33405a;
  min-width: 34px;
  padding: 8px;
}

button:disabled {
  opacity: 0.55;
}

.actions {
  display: grid;
  gap: 8px;
}

.danger {
  background: #d15454;
}
