/* Premium Aesthetic Design — index.css */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

:root {
  --primary: #6366f1;
  --success: #22c55e;
  --danger: #ef4444;
  --bg1: #eef2ff;
  --bg2: #c7d2fe;
  --glass: rgba(255, 255, 255, 0.2);
  --text: #111827;
  --radius: 18px;
  --shadow: 0 8px 32px rgba(0,0,0,0.15);
}

body {
  font-family: "Poppins", sans-serif;
  background: linear-gradient(135deg, var(--bg1), var(--bg2));
  margin: 0;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text);
}

.wrapper {
  width: 100%;
  max-width: 420px;
  padding: 20px;
}

.glass-card {
  background: var(--glass);
  backdrop-filter: blur(14px);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.3);
  animation: fadeIn 0.8s ease;
  text-align: center;
}

.title {
  font-size: 1.8rem;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 6px;
}

.subtitle {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 20px;
}

.status {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 500;
  margin-bottom: 20px;
  transition: all 0.3s ease;
}

.camera-frame {
  border: 2px dashed rgba(99,102,241,0.2);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(0,0,0,0.1);
  position: relative;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}

video, canvas {
  width: 100%;
  display: block;
}

.button-group {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.btn {
  border: none;
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  color: #fff;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, opacity 0.2s ease;
  font-size: 15px;
}

.btn:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.primary { background: var(--primary); }
.success { background: var(--success); }
.danger { background: var(--danger); }

.result {
  background: rgba(255,255,255,0.3);
  border-radius: var(--radius);
  padding: 16px;
  text-align: left;
  color: #111;
  box-shadow: var(--shadow);
  min-height: 50px;
  font-size: 0.95rem;
}

.result.success {
  background: linear-gradient(135deg, #dcfce7, #bbf7d0);
  color: #166534;
  border-left: 6px solid var(--success);
  animation: pop 0.3s ease;
}

.result.error {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  color: #7f1d1d;
  border-left: 6px solid var(--danger);
  animation: pop 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pop {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@media (max-width: 480px) {
  .glass-card { padding: 22px; }
  .title { font-size: 1.5rem; }
  .btn { font-size: 14px; padding: 10px 14px; }
}
