* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #0a0a0a;
  color: #e0e0e0;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 2rem 1rem;
}

.container {
  max-width: 520px;
  width: 100%;
  background: #141414;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

h1 {
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  text-align: center;
}

.subtitle {
  text-align: center;
  color: #888;
  font-size: 0.85rem;
  margin-top: 0.25rem;
}

.status-bar {
  margin: 1.5rem 0;
  padding: 0.75rem 1rem;
  background: #1a1a2e;
  border: 1px solid #2a2a4a;
  border-radius: 8px;
  text-align: center;
  font-size: 0.9rem;
  color: #7eb8ff;
}

.actions {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.btn {
  padding: 0.6rem 1.2rem;
  border: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  background: #2a2a2a;
  color: #ccc;
}

.btn:hover:not(:disabled) {
  background: #3a3a3a;
}

.btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.btn.primary {
  background: #2563eb;
  color: #fff;
  flex: 1;
}

.btn.primary:hover:not(:disabled) {
  background: #3b82f6;
}

.btn.danger {
  background: #4a1a1a;
  color: #ff6b6b;
  flex: 1;
}

.btn.danger:hover:not(:disabled) {
  background: #6a2a2a;
}

.btn.toggle {
  flex: 1;
  background: #1a2a1a;
  color: #6bff6b;
}

.btn.toggle.active {
  background: #1a3a1a;
  color: #6bff6b;
}

.btn.toggle:not(.active) {
  background: #2a2a2a;
  color: #888;
}

.section {
  margin-bottom: 1.5rem;
}

.section h2 {
  font-size: 0.85rem;
  font-weight: 600;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
}

.file-upload {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.file-label {
  padding: 0.5rem 1rem;
  background: #2a2a2a;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: background 0.15s;
  white-space: nowrap;
}

.file-label:hover {
  background: #3a3a3a;
}

#fileInput {
  display: none;
}

#controls {
  opacity: 0.3;
  transition: opacity 0.3s;
}

.control-group {
  margin-bottom: 1rem;
}

.control-group label {
  display: block;
  font-size: 0.8rem;
  color: #888;
  margin-bottom: 0.4rem;
}

.slider-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.slider-row input[type="range"] {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  background: #2a2a2a;
  border-radius: 3px;
  outline: none;
}

.slider-row input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  transition: background 0.15s;
}

.slider-row input[type="range"]::-webkit-slider-thumb:hover {
  background: #3b82f6;
}

.slider-row span {
  min-width: 2.5rem;
  text-align: right;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  color: #aaa;
}

.toggle-row {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
}

.shortcuts {
  background: #1a1a1a;
  border-radius: 8px;
  padding: 1rem;
}

.shortcut-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: #888;
}

kbd {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 4px;
  font-family: monospace;
  font-size: 0.75rem;
  color: #ccc;
  margin-right: 0.25rem;
}
