/**
 * @file public/css/styles.css
 * @description Estilos globais e tokens Dark Glassmorphism (Padrão whatsweb-app / MedScheduler).
 */

:root {
  --background: #09090B;
  --foreground: #FAFAFA;

  --bg-base: #09090B;
  --bg-surface: #18181B;
  --bg-card: rgba(24, 24, 27, 0.7);
  --bg-elevated: #27272A;
  --bg-hover: #3F3F46;

  --primary: #0EA5E9;
  --primary-light: #60A5FA;
  --primary-dark: #2563EB;
  --secondary: #0EA5E9;
  --accent: #0EA5E9;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;

  --text-primary: #FAFAFA;
  --text-secondary: #A1A1AA;
  --text-muted: #71717A;

  --border: rgba(255, 255, 255, 0.1);
  --border-hover: rgba(255, 255, 255, 0.2);
  --glass: rgba(24, 24, 27, 0.6);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  --shadow-glow: 0 0 40px rgba(59, 130, 246, 0.15);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
}

* {
  -webkit-tap-highlight-color: transparent;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}

*::-webkit-scrollbar {
  display: none !important;
}

html, body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Override browser autofill styles for dark theme (whatsweb-app standard) */
.auth-dark-page input:-webkit-autofill,
.auth-dark-page input:-webkit-autofill:hover,
.auth-dark-page input:-webkit-autofill:focus,
.auth-dark-page input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 30px #18181B inset !important;
  -webkit-text-fill-color: #FAFAFA !important;
  transition: background-color 5000s ease-in-out 0s;
}

/* Efeito .blurred-data sobre os caracteres X/* */
.blurred-data {
  filter: blur(2.6px);
  user-select: none;
  display: inline-block;
  letter-spacing: 0.04em;
  color: #475569;
  background: rgba(148, 163, 184, 0.16);
  padding: 0 3px;
  border-radius: 4px;
}

.unlocked-highlight {
  background: rgba(16, 185, 129, 0.14);
  color: #065f46;
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 600;
}

.no-scrollbar::-webkit-scrollbar {
  display: none;
}

.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* ─── Glassmorphism Components (whatsweb-app LoginPage standard) ─────────── */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.glass-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card), var(--shadow-glow);
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 0px;
}

.input-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.input {
  width: 100%;
  padding: 10px 12px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

.input::placeholder {
  color: var(--text-muted);
}

.input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  outline: none;
  white-space: nowrap;
  user-select: none;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(59, 130, 246, 0.5);
}

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  background: var(--bg-hover);
}

.btn-sm {
  padding: 6px 14px;
  font-size: 13px;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
}

.btn-full {
  width: 100%;
}

.fade-in {
  animation: fadeIn 0.3s ease;
}

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

.spinner {
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.3);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
