@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary-color: #4f46e5;
  --primary-hover: #4338ca;
  --bg-gradient-start: #e0e7ff;
  --bg-gradient-end: #c7d2fe;
  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(255, 255, 255, 0.5);
  --text-main: #1f2937;
  --text-muted: #6b7280;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 20px;
  box-sizing: border-box;
}

.login-container, .capture-container {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
  width: 100%;
  max-width: 400px;
  text-align: center;
  animation: slideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.capture-container {
  max-width: 600px;
  padding: 30px;
}

.brand-logo {
  height: 60px;
  margin-bottom: 20px;
  object-fit: contain;
}

.login-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 10px;
}

.login-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 30px;
}

.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
  background: rgba(255, 255, 255, 0.9);
  font-size: 16px;
  font-family: inherit;
  color: var(--text-main);
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
  background: #ffffff;
}

.btn-primary {
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-radius: 12px;
  background-color: var(--primary-color);
  color: white;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
  margin-top: 10px;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.2);
}

.btn-danger {
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-radius: 12px;
  background-color: #ef4444;
  color: white;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
  margin-top: 10px;
}

.btn-danger:hover {
  background-color: #dc2626;
  transform: translateY(-1px);
  box-shadow: 0 10px 15px -3px rgba(220, 38, 38, 0.2);
}

.btn-primary:disabled, .btn-danger:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.alert-danger {
  background-color: #fee2e2;
  color: #991b1b;
  padding: 12px;
  border-radius: 8px;
  font-size: 14px;
  margin-bottom: 20px;
  border: 1px solid #fecaca;
}

/* Webcam Container */
.webcam-container {
  width: 100%;
  margin-bottom: 20px;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  position: relative;
}

.webcam-container video {
  width: 100%;
  height: auto;
  display: block;
}

.buttons-row {
  display: flex;
  gap: 16px;
}

footer {
  margin-top: 40px;
  color: #4b5563;
  font-size: 14px;
  font-weight: 500;
  text-align: center;
}

footer a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

footer a:hover {
  color: var(--primary-hover);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 480px) {
  .login-container, .capture-container {
    padding: 24px;
  }
}
