/* Tela de login do Briefing — sóbria: dois painéis, tipografia e espaço.
   Esquerda (navy): a marca entra uma única vez — "mse" sobe, "briefing" assenta fechando o
   espaçamento entre letras, o ponto ciano surge, um fio tricolor se desenha. Mosaico quase imperceptível.
   Direita (branco): o acesso. Movimento curto, sem loops chamativos. */

.login {
  position: fixed; inset: 0; z-index: 40; display: grid; grid-template-columns: 1.15fr 1fr;
  background: #fff; color: var(--ink); animation: lg-in .4s ease both;
}
.login[hidden] { display: none; }
@keyframes lg-in { from { opacity: 0; } }
.login.saindo { animation: lg-out .5s var(--suave) forwards; }
@keyframes lg-out { to { opacity: 0; visibility: hidden; } }

/* ---------- Painel da marca ---------- */
.lp-marca {
  position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between;
  padding: 44px 56px; background: linear-gradient(160deg, #003779 0%, var(--navy) 48%, #00224f 100%); color: #fff;
}
.lp-marca::before {
  content: ''; position: absolute; left: 50%; top: 50%; width: 170vmax; height: 170vmax; margin: -85vmax 0 0 -85vmax;
  background: url('img/mosaico.png') 0 0 / 340px 170px repeat; opacity: .22; transform: rotate(-8deg);
  animation: mosaico 160s linear infinite; pointer-events: none;
}
.lp-marca::after { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: linear-gradient(90deg, #fff 0 58%, var(--cyan) 58% 76%, var(--teal) 76% 100%); }
.lp-marca > * { position: relative; }
.lp-topo, .lp-rodape { font-size: 10px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: rgba(255, 255, 255, .55); opacity: 0; animation: lp-surge .8s ease 1.6s forwards; }
.lp-rodape { display: flex; justify-content: space-between; gap: 16px; }

.lp-centro { max-width: 520px; }
.la { --t: clamp(22px, 3vw, 40px); display: flex; align-items: baseline; gap: calc(var(--t) * .5); line-height: 1; }
.la-mse { height: var(--t); width: auto; display: block; opacity: 0; transform: translateY(10px); animation: lp-sobe .9s var(--suave) .2s forwards; }
.la-palavra { font-size: calc(var(--t) * 1.84); font-weight: 300; letter-spacing: .14em; opacity: 0; animation: la-assenta 1.4s cubic-bezier(.16, 1, .3, 1) .45s forwards; }
@keyframes la-assenta { from { opacity: 0; letter-spacing: .14em; } 40% { opacity: 1; } to { opacity: 1; letter-spacing: -.035em; } }
.la-ponto { align-self: baseline; width: calc(var(--t) * .35); height: calc(var(--t) * .35); margin-left: calc(var(--t) * .06); border-radius: 50%; background: var(--cyan); opacity: 0; transform: scale(.2); animation: la-ponto .6s cubic-bezier(.34, 1.4, .64, 1) 1.45s forwards; }
@keyframes la-ponto { to { opacity: 1; transform: none; } }
.la-fio { width: 64px; height: 2px; margin: 30px 0 22px; background: linear-gradient(90deg, #fff 0 58%, var(--cyan) 58% 76%, var(--teal) 76% 100%); transform: scaleX(0); transform-origin: left; animation: la-fio .9s cubic-bezier(.7, 0, .2, 1) 1.7s forwards; }
@keyframes la-fio { to { transform: scaleX(1); } }
.lp-frase { margin: 0; max-width: 30ch; font-size: clamp(15px, 1.5vw, 19px); font-weight: 300; line-height: 1.5; color: rgba(255, 255, 255, .82); opacity: 0; animation: lp-sobe .9s var(--suave) 1.95s forwards; }

@keyframes lp-sobe { to { opacity: 1; transform: none; } }
@keyframes lp-surge { to { opacity: 1; } }

/* ---------- Painel do acesso ---------- */
.lp-acesso { display: flex; align-items: center; justify-content: center; padding: 44px 32px; background: #fff; }
.lp-form { width: min(340px, 100%); }
.lp-form > * { opacity: 0; transform: translateY(8px); animation: lp-sobe .7s var(--suave) forwards; }
.lp-form > :nth-child(1) { animation-delay: .5s; }
.lp-form > :nth-child(2) { animation-delay: .6s; }
.lp-form > :nth-child(3) { animation-delay: .7s; }
.lp-form > :nth-child(4) { animation-delay: .8s; }
.lp-form > :nth-child(5) { animation-delay: .9s; }
.lp-form > :nth-child(6) { animation-delay: 1s; }
.lp-kicker { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 10px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--ink2); }
.lp-kicker::before { content: ''; width: 24px; height: 1.5px; background: var(--navy); }
.lp-form h1 { margin: 14px 0 0; font-size: 28px; font-weight: 300; letter-spacing: -.025em; line-height: 1.15; color: var(--navy); }
.lp-texto { margin: 10px 0 0; font-size: 13px; line-height: 1.6; color: var(--ink2); }
#google-login { display: flex; min-height: 44px; margin: 28px 0 0; }
/* Botão "Continuar com o Google" (modo Firebase), no padrão visual do Google */
.g-botao { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 44px; padding: 0 16px; border: 1px solid #dadce0; border-radius: 4px; background: #fff; color: #3c4043; font: 500 14px 'Open Sans', Roboto, sans-serif; letter-spacing: .01em; cursor: pointer; transition: background .2s, box-shadow .2s, border-color .2s; }
.g-botao svg { width: 18px; height: 18px; flex: none; }
.g-botao:hover { background: #f8faff; border-color: #c6dafc; box-shadow: 0 1px 3px rgba(60, 64, 67, .2); }
.g-botao:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.g-botao:disabled { opacity: .6; cursor: progress; }
.login-erro { min-height: 18px; margin: 10px 0 0; font-size: 12px; color: var(--red); }
.lp-nota { display: flex; align-items: center; gap: 8px; margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--grid); font-size: 11px; color: var(--muted); }
.lp-nota svg { flex: none; width: 13px; height: 13px; }

@media (max-width: 860px) {
  .login { grid-template-columns: 1fr; grid-template-rows: auto 1fr; overflow-y: auto; }
  .lp-marca { padding: 28px 22px 26px; min-height: 0; gap: 24px; }
  .lp-rodape { display: none; }
  .la-fio { margin: 20px 0 14px; }
  .lp-acesso { align-items: flex-start; padding: 32px 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .lp-marca::before { animation: none; }
  .lp-topo, .lp-rodape, .la-mse, .la-palavra, .la-ponto, .lp-frase, .lp-form > * { animation: none; opacity: 1; transform: none; }
  .la-palavra { letter-spacing: -.035em; }
  .la-fio { animation: none; transform: none; }
}
