/* ==========================================================================
   Starcard · Tela de login v2 (Funcionário / Parceiro)
   HTML/CSS/JS puro — sem build, sem framework.
   Usado por: /login.html e /parceiro/login.html (mesma marcação)
   ========================================================================== */

:root {
  --lg-p: #7C3AED;
  --lg-p-dark: #6B21A8;
  --lg-p-soft: #EDE9FE;
  --lg-p-softer: #F5F3FF;
  --lg-ink: #111827;
  --lg-ink-2: #374151;
  --lg-muted: #6B7280;
  --lg-faint: #9CA3AF;
  --lg-line: #E5E7EB;
  --lg-bg: #FAF9FC;
  --lg-err: #DC2626;
  --lg-ok: #16A34A;
  --lg-grad: linear-gradient(150deg, #7C3AED 0%, #6D28D9 45%, #4C1D95 100%);
  --lg-btn-grad: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 50%, #6B21A8 100%);
}

@property --lg-ang { syntax: '<angle>'; initial-value: 0deg; inherits: false; }

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--lg-ink);
  background: var(--lg-bg);
  -webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }
a { color: var(--lg-p); text-decoration: none; }
a:hover { color: var(--lg-p-dark); }
button { font-family: inherit; }

/* Conteúdo por aba: html[data-tab] decide o que aparece */
html[data-tab="func"] [data-for="par"],
html[data-tab="par"] [data-for="func"] { display: none !important; }

/* ------------------------------------------------------------------ layout */
.lg-shell { display: flex; height: 100dvh; min-height: 100dvh; overflow: hidden; }

.lg-panel {
  position: relative; flex: 1 1 0; min-width: 0; overflow: hidden;
  display: flex; flex-direction: column;
  padding: clamp(24px, 6vh, 56px) clamp(28px, 4.5vw, 64px) clamp(20px, 4vh, 40px);
  color: #fff; background: var(--lg-grad);
}
.lg-side {
  flex: 0 0 clamp(460px, 52vw, 720px); min-width: 0; min-height: 0;
  display: flex; align-items: center; justify-content: center;
  padding: clamp(14px, 3.5vh, 48px) clamp(16px, 2.5vw, 28px);
  overflow: hidden; background: var(--lg-bg);
}
/* --k é calculado no JS para o formulário caber na altura da janela (desktop) */
.lg-fit { width: 100%; max-width: 560px; flex: none; transform: scale(var(--k, 1)); transform-origin: center center; }

/* ------------------------------------------------------------------ painel */
.lg-glow {
  position: absolute; right: -80px; top: 80px; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(circle, rgba(192,132,252,.35), rgba(192,132,252,0) 70%);
  animation: lgFloat 12s ease-in-out infinite; pointer-events: none;
}
.lg-grain {
  position: absolute; inset: 0; pointer-events: none; opacity: .22; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1.4 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.lg-decor { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.lg-star {
  position: absolute; height: 2px; border-radius: 2px; pointer-events: none; opacity: 0;
  background: linear-gradient(90deg, rgba(255,255,255,0), rgba(255,255,255,.9));
  box-shadow: 0 0 8px rgba(233,213,255,.8); transform-origin: right center;
}
.lg-star-1 { left: 8%; top: 6%; width: 150px; animation: lgShoot 9s 2s linear infinite; }
.lg-star-2 { left: 38%; top: -2%; width: 110px; height: 1.5px; animation: lgShoot 12s 6.5s linear infinite; }
.lg-halo {
  position: absolute; left: 0; top: 0; width: 560px; height: 560px; border-radius: 50%;
  pointer-events: none; mix-blend-mode: screen; opacity: 0; transition: opacity .5s ease; will-change: transform;
  background: radial-gradient(circle, rgba(233,213,255,.32) 0%, rgba(196,160,255,.14) 35%, rgba(196,160,255,0) 65%);
}
.lg-logo { position: relative; align-self: flex-start; width: clamp(140px, min(18vw, 24vh), 240px); }
.lg-logo img { display: block; width: 100%; height: auto; animation: lgLogoGlow 1.6s .5s ease-in-out both; }
.lg-logo-shine {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, rgba(196,181,253,0) 40%, rgba(167,139,250,.95) 50%, rgba(196,181,253,0) 60%);
  background-size: 250% 100%; background-repeat: no-repeat;
  -webkit-mask: url(/assets/logo-starcard-branco.webp) center / 100% 100% no-repeat;
          mask: url(/assets/logo-starcard-branco.webp) center / 100% 100% no-repeat;
  animation: lgLogoShine 1.6s .5s ease-in-out both;
}
.lg-head { position: relative; margin-top: clamp(20px, 7vh, 72px); max-width: 560px; }
.lg-head-item { display: flex; flex-direction: column; gap: 18px; }
.lg-head.lg-anim .lg-head-item { animation: lgFadeUp .5s ease both; }
.lg-h1 {
  margin: 0; display: flex; flex-wrap: wrap; column-gap: .26em;
  font-size: clamp(30px, min(4.2vw, 6.4vh), 48px); line-height: 1.05; font-weight: 800; letter-spacing: -.02em;
}
.lg-h1 span { display: inline-block; }
.lg-head.lg-anim .lg-h1 span { animation: lgWordIn .7s cubic-bezier(.2,.7,.2,1) both; }
.lg-head.lg-anim .lg-h1 span:nth-child(2) { animation-delay: .1s; }
.lg-head.lg-anim .lg-h1 span:nth-child(3) { animation-delay: .2s; }
.lg-head.lg-anim .lg-h1 span:nth-child(4) { animation-delay: .3s; }
.lg-head.lg-anim .lg-h1 span:nth-child(5) { animation-delay: .4s; }
.lg-lede { margin: 0; font-size: clamp(15px, 2.2vh, 18px); line-height: 1.6; color: rgba(255,255,255,.88); text-wrap: pretty; }
.lg-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.lg-chip { padding: 8px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.1); font-size: 14px; font-weight: 600; }
.lg-copy { position: relative; margin-top: auto; padding-top: clamp(16px, 4vh, 48px); font-size: 13px; color: rgba(255,255,255,.7); }

/* ------------------------------------------------------------------ cartão */
.lg-card {
  display: flex; flex-direction: column; width: 100%;
  padding: clamp(20px, 4vw, 32px); border-radius: 20px; background: #fff; border: 1px solid #F0ECF8;
  box-shadow: 0 24px 60px -28px rgba(76,29,149,.22), 0 1px 2px rgba(17,24,39,.04);
  transition: box-shadow .25s ease-out;
}
.lg-card.lg-shake { animation: lgShake .5s cubic-bezier(.36,.07,.19,.97) both; }

/* abas (pílula elástica) */
.lg-tabs { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 12px; background: #F3F4F6; animation: lgFadeUp .45s ease both; }
.lg-pill {
  position: absolute; top: 4px; bottom: 4px; left: 4px; right: 50%; border-radius: 9px; background: #fff;
  box-shadow: 0 1px 2px rgba(17,24,39,.06), 0 4px 12px -2px rgba(17,24,39,.1);
  transition: left .3s cubic-bezier(.4,0,.2,1), right .3s cubic-bezier(.4,0,.2,1);
}
html[data-tab="par"] .lg-pill { left: 50%; right: 4px; }
.lg-tabs.dir-r .lg-pill { transition: right .28s cubic-bezier(.4,0,.2,1), left .34s .1s cubic-bezier(.3,1.3,.5,1); }
.lg-tabs.dir-l .lg-pill { transition: left .28s cubic-bezier(.4,0,.2,1), right .34s .1s cubic-bezier(.3,1.3,.5,1); }
.lg-tab {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 0;
  font-size: 15px; font-weight: 600; color: var(--lg-muted); transition: color .25s; border-radius: 9px;
}
.lg-tab:hover { color: var(--lg-ink-2); }
.lg-tab:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 2px; }
html[data-tab="func"] [data-tab-btn="func"],
html[data-tab="par"] [data-tab-btn="par"] { color: var(--lg-p); }
.lg-tab svg.pop { animation: lgTabPop .5s cubic-bezier(.2,.8,.2,1); }

/* cascata de entrada */
.lg-body { display: flex; flex-direction: column; }
.lg-body.lg-anim .lg-c1 { animation: lgFadeUp .45s .05s ease both; }
.lg-body.lg-anim .lg-c2 { animation: lgFadeUp .45s .10s ease both; }
.lg-body.lg-anim .lg-c3 { animation: lgFadeUp .45s .15s ease both; }
.lg-body.lg-anim .lg-c4 { animation: lgFadeUp .45s .20s ease both; }
.lg-body.lg-anim .lg-c5 { animation: lgFadeUp .45s .25s ease both; }
.lg-body.lg-anim .lg-c6 { animation: lgFadeUp .45s .30s ease both; }
.lg-body.lg-anim .lg-c7 { animation: lgFadeUp .45s .35s ease both; }
.lg-body.lg-anim .lg-c8 { animation: lgFadeUp .45s .40s ease both; }

/* título */
.lg-title-block { margin-top: 32px; display: flex; flex-direction: column; gap: 6px; }
.lg-greet { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--lg-p); }
.lg-title-wrap { position: relative; height: 38px; overflow: hidden; }
.lg-title-wrap h2 { margin: 0; font-size: 30px; line-height: 38px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }
.lg-title-old { position: absolute; left: 0; top: 0; opacity: 0; }
.lg-title-wrap.swap .lg-title-old { animation: lgTitleOut .45s cubic-bezier(.6,0,.3,1) both; }
.lg-title-wrap.swap .lg-title { animation: lgTitleIn .5s .05s cubic-bezier(.2,.8,.2,1) both; }
.lg-sub { margin: 0; font-size: 15px; line-height: 1.55; color: var(--lg-muted); text-wrap: pretty; }
.lg-sub strong {
  font-weight: 600; color: var(--lg-ink-2); padding: 0 1px;
  background: linear-gradient(transparent 62%, rgba(196,181,253,.6) 62%, rgba(196,181,253,.6) 92%, transparent 92%);
}

/* ------------------------------------------------------------------ campos */
.lg-fields { margin-top: 28px; display: flex; flex-direction: column; gap: 16px; }
.lg-group { display: flex; flex-direction: column; gap: 6px; }

.lg-frame { padding: 1px; border-radius: 13px; background: var(--lg-line); transition: box-shadow .2s; }
.lg-frame.is-hover { background: var(--lg-faint); }
.lg-frame.is-hover .lg-field { box-shadow: inset 0 1px 3px rgba(17,24,39,.08); }
.lg-frame.is-focus {
  padding: 1.5px; box-shadow: 0 0 0 4px rgba(124,58,237,.12);
  background: conic-gradient(from var(--lg-ang), #7C3AED, #C084FC, #E9D5FF, #A855F7, #7C3AED);
  animation: lgRot 3s linear infinite;
}
.lg-frame.is-focus .lg-field { box-shadow: none; }
.lg-frame.is-error, .lg-frame.is-error.is-focus { padding: 1px; background: var(--lg-err); box-shadow: 0 0 0 4px rgba(220,38,38,.1); animation: none; }

.lg-field {
  position: relative; display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 12px 0 10px;
  border-radius: 12px; background: #fff; cursor: text; transition: background .45s ease;
}
.lg-frame.is-focus .lg-field { height: 55px; }
.lg-field.is-pasted { background: var(--lg-p-softer); }
.lg-ico {
  flex: none; width: 36px; height: 36px; border-radius: 9px; display: flex; align-items: center; justify-content: center;
  background: #F3F4F6; color: var(--lg-muted); transition: background .2s, color .2s;
}
.lg-frame.is-focus .lg-ico { background: var(--lg-p-soft); color: var(--lg-p); }
.lg-frame.is-error .lg-ico { background: #FEE2E2; color: var(--lg-err); }
.lg-ico.tickA { animation: lgTickA .18s ease; }
.lg-ico.tickB { animation: lgTickB .18s ease; }
.lg-ico .ico-open { display: none; }
.lg-frame.is-open .lg-ico .ico-open { display: block; animation: lgPopIn .35s ease both; }
.lg-frame.is-open .lg-ico .ico-closed { display: none; }
.lg-shackle { transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.lg-frame.is-filled .lg-shackle { transform: translateY(-3px); }

.lg-label {
  position: absolute; left: 58px; top: 19px; font-size: 15px; font-weight: 500; color: var(--lg-muted);
  pointer-events: none; transition: all .18s ease;
}
.lg-frame.is-focus .lg-label, .lg-frame.is-filled .lg-label { top: 9px; font-size: 11.5px; }
.lg-frame.is-focus .lg-label { color: var(--lg-p); }
.lg-frame.is-error .lg-label { color: var(--lg-err); }

.lg-input-wrap { flex: 1; min-width: 0; position: relative; align-self: stretch; display: flex; align-items: center; }
.lg-input-wrap input {
  position: relative; width: 100%; border: 0; outline: 0; font: inherit; font-size: 15px; color: var(--lg-ink);
  background: transparent; padding: 16px 0 0; transition: color .45s ease, opacity .2s ease, transform .2s ease;
}
.lg-input-wrap input::placeholder { color: transparent; }
.lg-frame.is-focus .lg-input-wrap input::placeholder { color: var(--lg-faint); }
.lg-field.is-pasted input { color: var(--lg-p); }
.lg-input-wrap input.is-clearing { opacity: 0; transform: translateX(-12px); }
.lg-input-wrap input::-ms-reveal, .lg-input-wrap input::-ms-clear { display: none; }

#email::selection { background: var(--lg-p); color: #fff; }
#senha::selection { background: var(--lg-p); color: #fff; }
#senha.is-masked { color: transparent; caret-color: transparent; }
#senha.is-masked::selection { background: transparent; color: transparent; }

/* sugestão de domínio */
.lg-ghost {
  position: absolute; inset: 0; display: flex; align-items: center; padding-top: 16px; font-size: 15px;
  white-space: pre; overflow: hidden; pointer-events: none;
}
.lg-ghost-typed { color: transparent; }
.lg-ghost-rest { color: #C4C4CC; }
.lg-ghost kbd {
  margin-left: 8px; padding: 1px 6px; border-radius: 5px; border: 1px solid var(--lg-line);
  font: 600 11px/1.4 inherit; color: var(--lg-faint); background: #fff;
}

/* pontos da senha */
.lg-dots { position: absolute; inset: 0; display: flex; align-items: center; padding-top: 16px; overflow: hidden; pointer-events: none; }
.lg-dot { flex: none; display: flex; align-items: center; justify-content: center; width: 14px; height: 20px; transition: background .12s; }
.lg-dot i { width: 8px; height: 8px; border-radius: 50%; background: var(--lg-p); animation: lgDotDrop .32s cubic-bezier(.3,1.5,.5,1) both; transition: background .12s; }
.lg-dot.sel { background: var(--lg-p); }
.lg-dot.sel i { background: #fff; }
.lg-dot.sel-first { border-radius: 5px 0 0 5px; }
.lg-dot.sel-last { border-radius: 0 5px 5px 0; }
.lg-dot.sel-first.sel-last { border-radius: 5px; }
.lg-letter { flex: none; font-size: 15px; color: var(--lg-ink); white-space: pre; animation: lgLetterIn .2s ease both; }
.lg-caret { flex: none; width: 1.5px; height: 18px; background: var(--lg-p); animation: lgCaret 1s steps(1) infinite; }

/* direita do campo de e-mail */
.lg-trail { flex: none; display: flex; align-items: center; gap: 8px; }
.lg-valid { animation: lgPopIn .3s ease both; }
.lg-valid path { stroke-dasharray: 14; animation: lgDrawCheck .45s .12s ease both; }
.lg-clear {
  width: 22px; height: 22px; border-radius: 50%; border: 0; padding: 0; background: var(--lg-line); color: #4B5563;
  display: flex; align-items: center; justify-content: center; cursor: pointer; animation: lgPopIn .25s ease both;
}
.lg-clear:hover { background: #D1D5DB; }

/* chip "Continuar como" */
.lg-chip-acc {
  display: flex; align-items: center; gap: 12px; height: 58px; padding: 0 12px 0 10px; border-radius: 13px;
  background: linear-gradient(135deg, var(--lg-p-softer), #fff 70%); border: 1px solid #E9D5FF;
}
.lg-avatar {
  flex: none; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #8B5CF6, #6B21A8); color: #fff; font-size: 13px; font-weight: 700; letter-spacing: .02em;
  box-shadow: 0 4px 10px -4px rgba(124,58,237,.6);
}
.lg-chip-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lg-chip-txt small { font-size: 11.5px; font-weight: 500; color: var(--lg-p); }
.lg-chip-txt b { font-size: 15px; font-weight: 600; color: var(--lg-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lg-chip-x {
  flex: none; width: 26px; height: 26px; border-radius: 50%; border: 0; padding: 0; background: var(--lg-p-soft); color: var(--lg-p-dark);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.lg-chip-x:hover { background: #DDD6FE; }

/* olho */
.lg-eye {
  border: 0; background: none; padding: 5px; cursor: pointer; display: flex; border-radius: 8px;
  color: var(--lg-muted); transition: color .2s; touch-action: none; -webkit-user-select: none; user-select: none;
}
.lg-eye:hover { background: #F3F4F6; }
.lg-eye:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 1px; }
.lg-eye[data-eye="open"], .lg-eye[data-eye="half"] { color: var(--lg-p); }
.lg-eye svg { overflow: visible; }
.lg-eye .lid { transition: d .34s cubic-bezier(.4,0,.2,1); }
.lg-eye .eye-g { transform-origin: 12px 12px; }
.lg-eye .eye-g.shake { animation: lgEyeShake .3s .13s ease; }
.lg-eye .eye-g.drowsy { animation: lgDrowsy 1.6s ease-in-out infinite; }
.lg-eye .lashes { opacity: 1; transform: none; transition: opacity .22s ease .16s, transform .3s cubic-bezier(.3,1.4,.5,1) .16s; }
.lg-eye:not([data-eye="closed"]) .lashes { opacity: 0; transform: translateY(-2.5px); transition-delay: 0s; }
.lg-eye .pupil-follow { transition: transform .12s ease-out; }
.lg-eye .iris { transform-origin: 12px 12px; transform: scale(.2); opacity: 0; transition: transform .34s cubic-bezier(.3,1.5,.5,1), opacity .2s; }
.lg-eye[data-eye="open"] .iris { transform: scale(1); opacity: 1; }
.lg-eye[data-eye="half"] .iris { transform: scale(.78); opacity: 1; }
.lg-eye .slash { stroke-dasharray: 23; stroke-dashoffset: 0; }
.lg-eye .slash.in { animation: lgSlashIn .16s cubic-bezier(.7,0,.3,1) both; }
.lg-eye .slash.out { animation: lgSlashOut .24s ease both; }

/* mensagens */
.lg-msg { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; }
.lg-msg svg { flex: none; transform-origin: 50% 50%; }
.lg-msg.lg-in { animation: lgErrIn .32s cubic-bezier(.2,.8,.2,1) both; }
.lg-msg.lg-in.lg-err svg { animation: lgWiggle .55s .12s ease both; }
.lg-err { color: var(--lg-err); }
.lg-warn { color: #B45309; }

/* linha lembrar / esqueci */
.lg-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; column-gap: 12px; row-gap: 10px; margin-top: 16px; }
.lg-switch {
  display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 0; cursor: pointer;
  font-size: 14px; font-weight: 500; color: #4B5563; white-space: nowrap; border-radius: 6px;
}
.lg-switch:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 3px; }
.lg-track { position: relative; flex: none; width: 34px; height: 20px; border-radius: 999px; background: #D1D5DB; transition: background .25s; }
.lg-knob {
  position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(17,24,39,.25); transition: transform .28s cubic-bezier(.3,1.4,.5,1);
}
.lg-switch[aria-checked="true"] .lg-track { background: var(--lg-p); }
.lg-switch[aria-checked="true"] .lg-knob { transform: translateX(14px); }
.lg-link-btn {
  border: 0; background: none; padding: 0; cursor: pointer; font-size: 14px; font-weight: 600; color: var(--lg-p); white-space: nowrap; border-radius: 4px;
}
.lg-link-btn:hover { color: var(--lg-p-dark); }
.lg-link-btn:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 3px; }

/* cartões que abrem (esqueci / ajuda) */
.lg-collapse { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .35s cubic-bezier(.4,0,.2,1); }
.lg-collapse.is-open { grid-template-rows: 1fr; }
.lg-collapse > div { overflow: hidden; min-height: 0; }
.lg-collapse-in { opacity: 0; transform: translateY(-6px); transition: opacity .3s ease, transform .35s ease; }
.lg-collapse.is-open .lg-collapse-in { opacity: 1; transform: none; }
.lg-note {
  margin-top: 12px; display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px;
  background: var(--lg-p-softer); border: 1px solid #E9D5FF;
}
.lg-note-ico { flex: none; width: 30px; height: 30px; border-radius: 8px; background: var(--lg-p-soft); color: var(--lg-p); display: flex; align-items: center; justify-content: center; }
.lg-note p { margin: 0; font-size: 13.5px; line-height: 1.5; color: #4C1D95; text-wrap: pretty; }

/* ------------------------------------------------------------------ botão */
.lg-submit-wrap { position: relative; display: flex; justify-content: center; margin-top: 26px; }
.lg-btn {
  position: relative; overflow: hidden; width: 100%; height: 54px; border: 0; border-radius: 12px;
  font-size: 16px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--lg-line); color: var(--lg-faint); cursor: not-allowed;
  transition: width .45s cubic-bezier(.4,0,.2,1), border-radius .45s, box-shadow .3s, transform .15s;
}
.lg-btn:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 3px; }
.lg-btn[data-state="ready"], .lg-btn[data-state="loading"] { background: var(--lg-btn-grad); color: #fff; }
.lg-btn[data-state="ready"] { cursor: pointer; box-shadow: 0 10px 24px -10px rgba(124,58,237,.6); }
.lg-btn[data-state="ready"]:hover { box-shadow: 0 14px 30px -8px rgba(124,58,237,.7); }
.lg-btn[data-state="ready"]:active { transform: scale(.985); }
.lg-btn[data-state="ready"].breathe { animation: lgBreathe 1.5s .15s ease-out 1; }
.lg-btn[data-state="success"] { width: 54px; border-radius: 27px; background: var(--lg-ok); color: #fff; box-shadow: 0 10px 24px -10px rgba(22,163,74,.6); cursor: default; }
.lg-btn[data-state="locked"] { background: var(--lg-p-soft); color: var(--lg-p-dark); }

.lg-btn .b-part { display: none; }
.lg-btn[data-state="success"] .b-check,
.lg-btn[data-state="loading"] .b-spin,
.lg-btn[data-state="locked"] .b-clock { display: block; }
.lg-btn[data-state="loading"] .b-loadbar,
.lg-btn[data-state="locked"] .b-lockbar { display: block; }
.lg-btn[data-state="ready"] .b-enter { display: flex; }
.lg-btn[data-state="idle"] .b-arrow, .lg-btn[data-state="ready"] .b-arrow { display: flex; }

.b-label { position: relative; font-variant-numeric: tabular-nums; }
.b-label.lg-in { animation: lgFadeUp .25s ease both; }
.lg-btn[data-state="success"] .b-label { display: none; }
.b-check { animation: lgPopIn .45s cubic-bezier(.2,.8,.2,1) both; }
.b-spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: lgSpin .7s linear infinite; }
.b-shine {
  position: absolute; top: 0; bottom: 0; left: 0; width: 45%; pointer-events: none;
  background: linear-gradient(105deg, rgba(255,255,255,0), rgba(255,255,255,.35), rgba(255,255,255,0));
  transform: translateX(-120%) skewX(-18deg);
}
.lg-btn[data-state="ready"]:hover .b-shine { transform: translateX(320%) skewX(-18deg); transition: transform .8s ease; }
.b-arrow { position: relative; width: 18px; height: 18px; }
.b-arrow svg { position: absolute; inset: 0; }
.b-arrow .a-main { position: relative; transition: transform .3s cubic-bezier(.4,0,.2,1); }
.b-arrow .a-t1 { opacity: 0; transition: opacity .25s ease, transform .35s cubic-bezier(.4,0,.2,1); }
.b-arrow .a-t2 { opacity: 0; transition: opacity .3s ease, transform .4s cubic-bezier(.4,0,.2,1); }
.lg-btn[data-state="ready"]:hover .a-main { transform: translateX(6px); }
.lg-btn[data-state="ready"]:hover .a-t1 { opacity: .4; transform: translateX(-1px); }
.lg-btn[data-state="ready"]:hover .a-t2 { opacity: .18; transform: translateX(-8px); }
.b-enter {
  position: absolute; right: 14px; top: 50%; margin-top: -11px; height: 22px; align-items: center; padding: 0 7px;
  border-radius: 6px; border: 1px solid currentColor; opacity: .6; font-size: 11px; font-weight: 600; letter-spacing: .02em;
  animation: lgFadeUp .3s ease both;
}
.b-loadbar { position: absolute; left: 0; bottom: 0; height: 2.5px; width: 38%; border-radius: 2px; background: rgba(255,255,255,.8); animation: lgLoadBar 1.1s ease-in-out infinite; }
.b-lockbar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--lg-p); transition: width 1s linear; }
.lg-ripple { position: absolute; width: 20px; height: 20px; margin: -10px 0 0 -10px; border-radius: 50%; background: rgba(255,255,255,.45); pointer-events: none; animation: lgRipple .65s ease-out forwards; }

.lg-confetti { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; }
.lg-confetti span { position: absolute; transition: transform .85s cubic-bezier(.15,.8,.3,1), opacity .45s .5s ease; }

/* ------------------------------------------------------------------ rodapé do cartão */
.lg-secure { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 14px; font-size: 12px; color: var(--lg-faint); }
.lg-sep { height: 1px; margin-top: 26px; background: linear-gradient(90deg, rgba(229,231,235,0), #E5E7EB 30%, #E5E7EB 70%, rgba(229,231,235,0)); }
.lg-foot { margin: 20px 0 0; text-align: center; font-size: 14px; color: var(--lg-muted); }
.lg-foot a { font-weight: 600; }
.lg-help-row { display: flex; justify-content: center; margin-top: 12px; }
.lg-help-btn {
  display: flex; align-items: center; gap: 6px; border: 0; background: none; padding: 0; cursor: pointer;
  font-size: 13px; font-weight: 500; color: var(--lg-muted); border-radius: 4px;
}
.lg-help-btn:hover { color: var(--lg-p); }
.lg-help-btn:focus-visible { outline: 2px solid var(--lg-p); outline-offset: 3px; }
.lg-help-card {
  margin-top: 12px; display: grid; gap: 8px; padding: 10px; border-radius: 14px; background: #fff;
  border: 1px solid var(--lg-p-soft); box-shadow: 0 10px 24px -16px rgba(76,29,149,.3);
}
.lg-help-link { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; text-decoration: none; }
.lg-help-link span:last-child { display: flex; flex-direction: column; gap: 1px; }
.lg-help-link b { font-size: 14px; font-weight: 600; }
.lg-help-link small { font-size: 13px; }
.lg-help-ico { flex: none; width: 32px; height: 32px; border-radius: 9px; color: #fff; display: flex; align-items: center; justify-content: center; }
.lg-help-wa { background: #F0FDF4; color: #166534; }
.lg-help-wa:hover { background: #DCFCE7; color: #166534; }
.lg-help-wa .lg-help-ico { background: var(--lg-ok); }
.lg-help-wa small { color: #15803D; }
.lg-help-mail { background: var(--lg-p-softer); color: #4C1D95; }
.lg-help-mail:hover { background: var(--lg-p-soft); color: #4C1D95; }
.lg-help-mail .lg-help-ico { background: var(--lg-p); }
.lg-help-mail small { color: var(--lg-p-dark); }

/* ------------------------------------------------------------------ overlay de sucesso */
.lg-overlay {
  position: fixed; inset: 0; z-index: 50; background: var(--lg-grad);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  transition: clip-path .75s cubic-bezier(.7,0,.2,1);
}
.lg-overlay img { width: 220px; height: auto; opacity: 0; transform: scale(.9); transition: opacity .45s .5s, transform .6s .5s cubic-bezier(.2,.8,.2,1); }
.lg-overlay .b-spin { width: 22px; height: 22px; border-color: rgba(255,255,255,.3); border-top-color: #fff; animation-duration: .8s; opacity: 0; transition: opacity .4s .7s; }
.lg-overlay.is-open img { opacity: 1; transform: none; }
.lg-overlay.is-open .b-spin { opacity: 1; }

/* ------------------------------------------------------------------ responsivo */
@media (max-width: 879px) {
  .lg-shell { flex-direction: column; height: auto; overflow: visible; }
  .lg-panel { flex: none; padding: 28px 24px 32px; }
  .lg-logo { width: 150px; }
  .lg-head { margin-top: 28px; }
  .lg-h1 { font-size: clamp(28px, 8vw, 40px); }
  .lg-copy { display: none; }
  .lg-side { flex: none; align-items: flex-start; padding: 20px 14px 32px; overflow: visible; }
  .lg-fit { transform: none !important; }
  /* 16px evita o zoom automático do iOS ao focar o campo */
  .lg-input-wrap input, .lg-ghost, .lg-letter { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .lg-star, .lg-halo, .lg-glow { display: none !important; }
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important;
    transition-duration: .12s !important; transition-delay: 0s !important;
  }
}

/* ------------------------------------------------------------------ keyframes */
@keyframes lgFadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes lgFloat { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-24px, 18px); } }
@keyframes lgSpin { to { transform: rotate(360deg); } }
@keyframes lgShake { 10%, 90% { transform: translateX(-2px); } 20%, 80% { transform: translateX(4px); } 30%, 50%, 70% { transform: translateX(-7px); } 40%, 60% { transform: translateX(7px); } }
@keyframes lgWordIn { from { opacity: 0; filter: blur(10px); transform: translateY(14px); } to { opacity: 1; filter: blur(0); transform: none; } }
@keyframes lgShoot { 0% { opacity: 0; transform: translate(0, 0) rotate(20deg); } 1.5% { opacity: 1; } 9% { opacity: 0; transform: translate(520px, 190px) rotate(20deg); } 100% { opacity: 0; transform: translate(520px, 190px) rotate(20deg); } }
@keyframes lgLogoShine { from { background-position: 180% 0; } to { background-position: -80% 0; } }
@keyframes lgLogoGlow { 0%, 100% { filter: drop-shadow(0 0 0 rgba(255,255,255,0)); } 50% { filter: drop-shadow(0 0 14px rgba(233,213,255,.85)); } }
@keyframes lgPopIn { 0% { opacity: 0; transform: scale(.4); } 60% { opacity: 1; transform: scale(1.15); } 100% { transform: scale(1); } }
@keyframes lgRot { to { --lg-ang: 360deg; } }
@keyframes lgDotDrop { 0% { opacity: 0; transform: translateY(-12px) scale(.4); } 100% { opacity: 1; transform: none; } }
@keyframes lgCaret { 50% { opacity: 0; } }
@keyframes lgRipple { to { transform: scale(28); opacity: 0; } }
@keyframes lgTabPop { 0% { transform: rotate(-14deg) scale(.7); } 60% { transform: rotate(8deg) scale(1.15); } 100% { transform: none; } }
@keyframes lgDrawCheck { from { stroke-dashoffset: 14; } to { stroke-dashoffset: 0; } }
@keyframes lgErrIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@keyframes lgWiggle { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-18deg); } 40% { transform: rotate(14deg); } 60% { transform: rotate(-8deg); } 80% { transform: rotate(4deg); } }
@keyframes lgTickA { 50% { transform: scale(1.05); } }
@keyframes lgTickB { 50% { transform: scale(1.05); } }
@keyframes lgBreathe { 0% { box-shadow: 0 0 0 0 rgba(124,58,237,.55), 0 10px 24px -10px rgba(124,58,237,.6); } 70% { box-shadow: 0 0 0 14px rgba(124,58,237,0), 0 10px 24px -10px rgba(124,58,237,.6); } 100% { box-shadow: 0 0 0 0 rgba(124,58,237,0), 0 10px 24px -10px rgba(124,58,237,.6); } }
@keyframes lgLoadBar { 0% { transform: translateX(-100%); } 100% { transform: translateX(270%); } }
@keyframes lgTitleOut { from { opacity: 1; transform: none; } to { transform: translateY(-110%); opacity: 0; } }
@keyframes lgTitleIn { from { transform: translateY(110%); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes lgLetterIn { from { opacity: 0; transform: translateY(-6px); filter: blur(3px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes lgSlashIn { from { stroke-dashoffset: 23; } to { stroke-dashoffset: 0; } }
@keyframes lgSlashOut { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -23; } }
@keyframes lgEyeShake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-1.4px); } 50% { transform: translateX(1.4px); } 75% { transform: translateX(-.7px); } }
@keyframes lgDrowsy { 0%, 100% { transform: scaleY(1); } 45% { transform: scaleY(.2); } 62% { transform: scaleY(.85); } }
