:root {
  --brand: #162ac4;
  --brand-dark: #1412a8;
  --bg: #f0f4ff;
  --text-dark: #111827;
  --text-muted: #6b7280;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0; padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

/* AUTH PAGE */
body.auth-page {
  width: 100%; height: 100%;
  min-height: 100vh;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.auth-header {
  background: linear-gradient(155deg, #0f35b8 0%, #1a56f0 60%, #2563eb 100%);
  padding: 48px 20px 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom-left-radius: 36px;
  border-bottom-right-radius: 36px;
  flex-shrink: 0;
}

.auth-header-logo {
  padding: 32px 20px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.auth-header-logo img {
  max-width: 160px;
  height: auto;
}

.auth-brand-text {
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 2px;
  text-align: center;
}

.auth-container {
  background: #fff;
  border-radius: 24px;
  padding: 28px 22px 32px;
  margin: -36px 20px 24px;
  box-shadow: 0 8px 32px rgba(19,67,198,0.12);
  position: relative;
  z-index: 10;
}

.auth-title {
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.auth-subtitle {
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

.auth-container input {
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 14px;
  border-radius: 14px;
  border: 1.5px solid #e2e8f0;
  font-size: 16px;
  font-family: inherit;
  color: var(--text-dark);
  background: #f8fafc;
  outline: none;
  transition: border-color 0.2s;
  display: block;
}
.auth-container input:focus {
  border-color: var(--brand);
  background: #fff;
}

.btn-primary {
  width: 100%;
  background: var(--brand);
  color: #fff;
  border: none;
  padding: 15px;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  margin-top: 10px;
  margin-bottom: 6px;
  cursor: pointer;
  min-height: 52px;
  font-family: inherit;
  transition: background 0.2s, transform 0.1s;
  letter-spacing: 0.3px;
}
.btn-primary:active {
  background: var(--brand-dark);
  transform: scale(0.98);
}

.switch-text {
  text-align: center;
  font-size: 14px;
  margin-top: 18px;
  color: var(--text-muted);
}
.switch-text a {
  color: var(--brand);
  font-weight: 700;
  text-decoration: none;
}

.resend-btn {
  background: none;
  border: none;
  color: var(--brand);
  text-decoration: underline;
  cursor: pointer;
  font-size: 14px;
  padding: 6px;
  font-family: inherit;
}
.resend-btn:disabled {
  color: #cbd5e1;
  cursor: not-allowed;
}

.otp-timer {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  text-align: center;
}

.resend-otp-container {
  margin-top: 10px;
  text-align: center;
}

@media (max-width: 360px) {
  .auth-container {
    margin-left: 14px;
    margin-right: 14px;
    padding: 22px 16px 26px;
  }
  .auth-brand-text { font-size: 24px; }
}
