:root {
  color-scheme: dark;
  --bg: #111827;
  --card-bg: #1f2937;
  --card-border: #374151;
  --text: #f9fafb;
  --text-muted: #d1d5db;
  --text-faint: #9ca3af;
  --blue: #60a5fa;
  --blue-strong: #3b82f6;
  --purple: #a78bfa;
  --pink: #f472b6;
  --green: #4ade80;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.page {
  max-width: 48rem;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1rem;
}

.header__icon {
  width: 4rem;
  height: 4rem;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(96,165,250,.2), rgba(167,139,250,.2));
  border: 1px solid rgba(255,255,255,.1);
}

.camera-icon {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--blue);
}

.header__title {
  margin: .5rem 0 0;
  font-size: 1.875rem;
  font-weight: 700;
  background: linear-gradient(90deg, #93c5fd, #d8b4fe);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.header__subtitle {
  margin: 0;
  font-size: 1.125rem;
  color: var(--text-faint);
  letter-spacing: .05em;
}

.info-cards {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: .5rem;
}
@media (min-width: 768px) {
  .info-cards { grid-template-columns: 1fr 1fr; }
}

.info-card {
  border-radius: 1rem;
  padding: 1.5rem;
  background: rgba(31,41,55,.8);
  border: 1px solid rgba(255,255,255,.1);
  text-align: left;
}
.info-card--blue { box-shadow: inset 0 0 0 9999px rgba(59,130,246,.03); }
.info-card--purple { box-shadow: inset 0 0 0 9999px rgba(217,70,239,.03); }

.info-card__label {
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--blue);
}
.info-card--purple .info-card__label { color: var(--purple); }

.info-card__value {
  margin: .5rem 0 0;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text);
}

.examples {
  margin-top: 2rem;
}
.examples__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
  margin: 0 0 .75rem;
}
.examples__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: .75rem;
}
.examples__img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: .5rem;
  border: 1px solid var(--card-border);
}

.card {
  margin-top: 2rem;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: .75rem;
  box-shadow: 0 10px 25px rgba(0,0,0,.3);
  padding: 1.5rem;
}

.field { margin-bottom: 1.5rem; }
.field label {
  display: block;
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: .25rem;
}

.input {
  width: 100%;
  padding: .625rem .75rem;
  background: #111827;
  border: 1px solid var(--card-border);
  border-radius: .5rem;
  color: var(--text);
  font-size: 1rem;
}
.input:focus {
  outline: none;
  border-color: var(--blue-strong);
  box-shadow: 0 0 0 2px rgba(59,130,246,.35);
}

.dropzone {
  padding: 1.5rem;
  border: 2px dashed var(--card-border);
  border-radius: .5rem;
  cursor: pointer;
  text-align: center;
  transition: border-color .2s, background-color .2s;
}
.dropzone:hover, .dropzone--active {
  border-color: var(--blue-strong);
  background: rgba(59,130,246,.08);
}
.dropzone__text {
  margin: .5rem 0 0;
  font-size: .875rem;
  color: var(--text-muted);
}
.dropzone__hint {
  margin: .25rem 0 0;
  font-size: .75rem;
  color: var(--text-faint);
}

.previews {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}
@media (min-width: 640px) {
  .previews { grid-template-columns: 1fr 1fr; }
}

.preview-item {
  display: flex;
  align-items: center;
  padding: .75rem;
  background: rgba(31,41,55,.5);
  border: 1px solid var(--card-border);
  border-radius: .5rem;
}
.preview-item img {
  width: 4rem;
  height: 4rem;
  object-fit: cover;
  border-radius: .375rem;
  flex-shrink: 0;
}
.preview-item span {
  margin-left: .75rem;
  font-size: .875rem;
  color: var(--text-muted);
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.preview-item button {
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  padding: .25rem;
  border-radius: 9999px;
  font-size: 1rem;
  line-height: 1;
}
.preview-item button:hover { background: var(--card-border); }

.actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 1rem;
}

.button {
  padding: .625rem 1.5rem;
  background: var(--blue-strong);
  color: #fff;
  border: none;
  border-radius: .5rem;
  font-size: .95rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color .2s;
}
.button:hover { background: #2563eb; }
.button:disabled { opacity: .6; cursor: not-allowed; }

.success {
  text-align: center;
  padding: 2rem 0;
}
.success__icon {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
  border-radius: 9999px;
  background: rgba(74,222,128,.15);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}
.success h2 { margin: 0 0 .5rem; font-size: 1.25rem; color: var(--text); }
.success p { margin: 0; color: var(--text-muted); }

.toast-container {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: .5rem;
  z-index: 50;
}
.toast {
  padding: .75rem 1rem;
  background: #374151;
  color: #fff;
  border-radius: .5rem;
  font-size: .875rem;
  box-shadow: 0 4px 12px rgba(0,0,0,.3);
  animation: toast-in .15s ease-out;
}
.toast--error { background: #7f1d1d; }
.toast--success { background: #14532d; }

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
