:root {
  --k-blue: #002979;
  --k-yellow: #E89C24;
  --bg-light: #f4f6fb;
  --ink: #0f172a;
  --muted: #64748b;

  /* iOS safe-area (Dynamic Island / notch / home indicator) */
  --safe-top: env(safe-area-inset-top);
  --safe-bottom: env(safe-area-inset-bottom);
  --safe-left: env(safe-area-inset-left);
  --safe-right: env(safe-area-inset-right);
}

html{
  background: #001844; /* fundo atrás do status bar */
}

body{
  background: #001844; /* garante que não fica branco */
}

@media (max-width: 900px){
  body{
    background:
      radial-gradient(900px 520px at 15% 0%, rgba(232,156,36,.28), transparent 60%),
      radial-gradient(900px 520px at 85% 10%, rgba(255,255,255,.10), transparent 60%),
      linear-gradient(180deg, #002979 0%, #001844 100%);
  }
}


/* RESET */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent; /* sensação mais "app" no mobile */
}

html, body {
  height: 100%;
}

body {
  font-family: "Segoe UI", system-ui, sans-serif;
  color: var(--ink);

  /* altura correta no mobile moderno */
  min-height: 100svh;
  min-height: 100dvh;

  /* fundo base (no desktop fica claro; no mobile vamos sobrepor) */
  background: var(--bg-light);

  overscroll-behavior: none;
}

/* IMPORTANT: evita zoom no iOS ao focar */
input, select, textarea, button {
  font-size: 16px;
}

/* LAYOUT */
.login-layout {
  height: 100dvh;
  height: 100svh;
  min-height: 0;

  display: grid;
  grid-template-columns: 1fr 1fr;

  /* respeita Dynamic Island / notch / bordas */
  padding-top: var(--safe-top);
  padding-bottom: var(--safe-bottom);
  padding-left: var(--safe-left);
  padding-right: var(--safe-right);

  background: var(--bg-light);
}

/* LOGIN */
.login-area {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
}

.login-card {
  width: 100%;
  max-width: 420px;

  /* mais “cara de portal” */
  background: rgba(255, 255, 255, 0.96);
  border-radius: 18px;
  padding: 36px 32px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12);
  border: 1px solid rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(10px);
}

.login-logo {
  max-width: 160px;
  margin: 0 auto 18px;
  display: block;
}

.login-title {
  text-align: center;
  font-size: 22px;
  font-weight: 800;
}

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

/* FORM */
.field-group {
  margin-bottom: 20px;
}

.field-group label {
  font-size: 13px;
  font-weight: 800;
}

.field-group label span {
  color: var(--k-yellow);
}

.field-input {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;

  background: rgba(255,255,255,0.98);
  border: 1px solid #dbe0ea;
  border-radius: 12px;
  padding: 12px 14px;

  box-shadow: 0 8px 16px rgba(15,23,42,.05);
}

.field-input i {
  color: var(--k-blue);
}

.field-input input {
  border: none;
  outline: none;
  flex: 1;

  /* 16px evita zoom no iOS */
  font-size: 16px;
  background: transparent;
  color: var(--ink);
}

.toggle-password {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--k-blue);
  padding: 6px;
  border-radius: 10px;
}

.toggle-password:active {
  transform: translateY(1px);
}

.field-help {
  font-size: 12px;
  color: var(--muted);
  margin-top: 4px;
}

/* BOTÃO */
.btn-login {
  width: 100%;
  margin-top: 12px;

  background: var(--k-yellow);
  color: #000;
  border: none;
  border-radius: 14px;
  padding: 14px;

  font-size: 15px; /* ok pois o botão não causa zoom */
  font-weight: 900;
  cursor: pointer;

  display: flex;
  justify-content: center;
  gap: 10px;

  box-shadow: 0 14px 30px rgba(232, 156, 36, 0.28);
  transition: transform .12s ease, opacity .12s ease;
}

.btn-login:hover {
  opacity: .96;
}

.btn-login:active {
  transform: translateY(1px);
}

.login-help {
  margin-top: 18px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
}

/* INFO DESKTOP */
.info-area {
  background: var(--k-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
}

.info-card {
  max-width: 420px;
  color: #fff;
}

.info-card h2 {
  font-size: 24px;
  margin-bottom: 8px;
}

.info-card p {
  opacity: .85;
  margin-bottom: 24px;
}

.info-list {
  list-style: none;
}

.info-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  margin-bottom: 12px;
}

.info-list i {
  font-size: 18px;
  color: var(--k-yellow);
}

.info-list strong {
  display: block;
}

.info-card footer {
  margin-top: 28px;
  font-size: 13px;
  opacity: .7;
}

/* MOBILE */
@media (max-width: 900px) {
  .login-layout {
    grid-template-columns: 1fr;

    /* fundo “bonito” e que preenche a tela toda */
    background:
      radial-gradient(900px 520px at 15% 0%, rgba(232,156,36,.28), transparent 60%),
      radial-gradient(900px 520px at 85% 10%, rgba(255,255,255,.10), transparent 60%),
      linear-gradient(180deg, #002979 0%, #001844 100%);
  }

  .info-area {
    display: none;
  }

  .login-area {
    padding: 24px; /* NÃO soma safe-area aqui */
  }

  .login-card {
    padding: 32px 24px;
  }
}

.field-input input{ font-size: 16px; }

button, a, .btn-login, .toggle-password{
  touch-action: manipulation;
}
