/* =========================================================
   FitnessPRO — telas de acesso do personal (login etc.)
   Mesmo visual do app do aluno (fitness-pro-mobile/css/app.css):
   Manrope, ícones Phosphor, azul #3B63E0, campos com ícone.
   ========================================================= */
:root {
  --bg: #f4f5f7;
  --surface-1: #ffffff;
  --surface-2: #f1f2f5;
  --line: #e1e4ea;
  --text: #14171f;
  --text-2: #5a6170;
  --text-3: #959ba8;
  --accent: #3b63e0;
  --accent-ink: #ffffff;
  --accent-soft: rgba(59, 99, 224, 0.09);
  --ok: #16a34a;
  --ok-soft: rgba(22, 163, 74, 0.1);
  --danger: #dc2626;
  --danger-bg: #fef1f1;
  --danger-line: #f8cdcd;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: light;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; background: var(--bg); }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", system-ui, sans-serif;
  font-size: 16px;
  line-height: 24px;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
button, a, label { touch-action: manipulation; }
input { font: inherit; font-size: 16px; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Layout: coluna centralizada; no desktop vira um cartão */
.auth {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(24px + env(safe-area-inset-top, 0px)) 24px calc(48px + env(safe-area-inset-bottom, 0px));
  max-width: 420px;
  margin: 0 auto;
}
@media (min-width: 768px) {
  body { display: grid; place-items: center; min-height: 100dvh; }
  .auth {
    min-height: 0;
    width: 420px;
    padding: 40px;
    background: var(--surface-1);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: 0 1px 2px rgba(20, 23, 31, 0.05), 0 12px 40px rgba(20, 23, 31, 0.06);
  }
}

.brand { display: flex; align-items: center; gap: 12px; }
.logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent);
  color: var(--accent-ink);
  display: grid;
  place-items: center;
  font-size: 28px;
  flex: none;
}
.brand-name { font-weight: 700; font-size: 18px; letter-spacing: -0.01em; }
.brand-name small { display: block; font-size: 13px; line-height: 16px; font-weight: 500; color: var(--text-2); }

.title-lg { font-size: 24px; line-height: 32px; font-weight: 700; letter-spacing: -0.02em; text-wrap: balance; }
.muted { color: var(--text-2); font-size: 14px; line-height: 20px; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.center { text-align: center; }

/* Perfil: personal x aluno */
.segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background: var(--surface-2);
  border-radius: 12px;
}
.segment a, .segment span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-2);
}
.segment span[aria-current] { background: var(--surface-1); color: var(--text); box-shadow: 0 1px 2px rgba(20, 23, 31, 0.08); }
.segment a:active { opacity: 0.7; }
.segment i { font-size: 18px; }

/* Avisos */
.banner { display: flex; gap: 12px; align-items: center; border-radius: 12px; padding: 12px; font-size: 14px; line-height: 20px; }
.banner > i { font-size: 20px; flex: none; }
.banner.error { background: var(--danger-bg); border: 1px solid var(--danger-line); }
.banner.error > i { color: var(--danger); }
.banner.ok { background: var(--ok-soft); border: 1px solid rgba(22, 163, 74, 0.25); }
.banner.ok > i { color: var(--ok); }
.banner .close { margin-left: auto; color: var(--text-3); font-size: 18px; display: grid; place-items: center; width: 28px; height: 28px; }

/* Formulário */
.field { display: block; margin-top: 16px; }
.field > span { font-size: 14px; line-height: 20px; font-weight: 500; color: var(--text-2); }
.input {
  margin-top: 4px;
  display: flex;
  align-items: center;
  min-height: 48px;
  background: var(--surface-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 4px 0 12px;
  gap: 8px;
  transition: border-color 300ms var(--ease);
}
.input input { flex: 1; background: none; border: 0; color: var(--text); font-size: 16px; outline: none; min-width: 0; height: 46px; }
.input:focus-within { border-color: var(--accent); }
.input > i { color: var(--text-3); font-size: 20px; }
.input:has(input.error) { border-color: var(--danger); }
.icon-btn { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; color: var(--text-3); }
.icon-btn i { font-size: 20px; }
/* Mensagens do jquery.validate */
label.error { display: block; margin-top: 6px; font-size: 13px; line-height: 18px; color: var(--danger); font-weight: 500; }

.check { display: flex; align-items: center; gap: 10px; margin-top: 16px; font-size: 14px; color: var(--text-2); cursor: pointer; min-height: 40px; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); }

.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  min-height: 48px; padding: 0 16px; border-radius: 12px; font-size: 16px; font-weight: 600;
  background: var(--accent); color: var(--accent-ink);
  transition: transform 300ms var(--ease), opacity 300ms var(--ease);
}
.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.5; pointer-events: none; }
.link { color: var(--accent); font-size: 14px; font-weight: 600; }
.links { display: flex; justify-content: space-between; gap: 16px; }
.foot { font-size: 12px; color: var(--text-3); }
.foot a { text-decoration: underline; }

@keyframes spin { to { transform: rotate(360deg); } }
.spin { animation: spin 0.8s linear infinite; }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } .btn, .input { transition: none; } }
