/* =========================================================
   HSL — PORTÃO DE ACESSO (gate de login/cadastro)
   Modal dividido: imagem + bolhas | formulário
   Paleta: grafite #0e0e0e / #141414 · lime #CAFF00 · cerise #DB2763 · bone #E0DDCC
   ========================================================= */

/* anti-flash: esconde a página até o gate estar montado */
html.hsl-esp body { opacity: 0; }

.hslG {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(10, 10, 10, .92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  animation: hslG-fade .4s var(--p2-out, ease) both;
  overflow: auto;
}
@keyframes hslG-fade { from { opacity: 0; } to { opacity: 1; } }

.hslG__modal {
  position: relative;
  width: 100%;
  max-width: 940px;
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  background: #141414;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 40px 120px rgba(0, 0, 0, .75);
  animation: hslG-sobe .5s cubic-bezier(.22, 1, .36, 1) both;
}
@keyframes hslG-sobe { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---------- lado A: imagem + bolhas ---------- */
.hslG__lado {
  position: relative;
  min-height: 240px;
  overflow: hidden;
  background: #0b0b0b;
}
.hslG__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.92) contrast(1.04);
}
.hslG__bolhas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .75; }
/* legenda sobre a arte (a sombra já vem assada na imagem) */
.hslG__marca {
  position: absolute;
  left: 30px;
  right: 30px;
  bottom: 26px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.hslG__marca b {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: #E0DDCC;
}
.hslG__marca i {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-style: normal;
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #CAFF00;
}

/* ---------- lado B: formulário ---------- */
.hslG__painel {
  padding: clamp(26px, 4vw, 44px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #141414;
}
.hslG__form { display: flex; flex-direction: column; gap: 14px; }
.hslG__form[hidden] { display: none; }

.hslG__abas { display: flex; gap: 22px; margin-bottom: 4px; }
.hslG__aba {
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 0 0 8px;
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #6a6a6a;
  cursor: pointer;
  transition: color .25s, border-color .25s;
}
.hslG__aba--ativo { color: #CAFF00; border-bottom-color: #CAFF00; }

.hslG__titulo {
  font-size: clamp(24px, 3vw, 30px);
  font-weight: 600;
  letter-spacing: -.02em;
  color: #fff;
  margin: 2px 0 0;
}
.hslG__sub { font-size: 13.5px; line-height: 1.5; color: #a3a3a3; margin-top: -6px; }

.hslG__campo { display: flex; flex-direction: column; gap: 7px; }
.hslG__campo[hidden] { display: none; }
.hslG__campo label {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #a3a3a3;
}
.hslG__campo input[type="text"],
.hslG__campo input[type="email"],
.hslG__campo input[type="password"] {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  background: #1b1b1b;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 8px;
  color: #fff;
  font-size: 15px;
  outline: none;
  transition: border-color .2s, background .2s;
}
.hslG__campo input::placeholder { color: #5f5f5f; }
.hslG__campo input:focus { border-color: #DB2763; background: #1f1f1f; }

.hslG__senha { position: relative; display: flex; }
.hslG__senha input { padding-right: 46px; }
.hslG__olho {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: none;
  border: 0;
  color: #6a6a6a;
  cursor: pointer;
  border-radius: 6px;
}
.hslG__olho:hover { color: #E0DDCC; background: rgba(255, 255, 255, .06); }
.hslG__olho svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 1.7; }

/* barra de força da senha (4 segmentos, estilo referência) */
.hslG__forca { display: flex; gap: 4px; }
.hslG__forca i {
  flex: 1;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, .1);
  transition: background .3s;
}
.hslG__forca[data-n="1"] i:nth-child(-n+1) { background: #DB2763; }
.hslG__forca[data-n="2"] i:nth-child(-n+2) { background: #DB2763; }
.hslG__forca[data-n="3"] i:nth-child(-n+3) { background: #F4F803; }
.hslG__forca[data-n="4"] i { background: #CAFF00; }

.hslG__check {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: #8f8f8f;
  cursor: pointer;
  user-select: none;
}
.hslG__check input { width: 15px; height: 15px; accent-color: #DB2763; }

.hslG__erro {
  min-height: 16px;
  font-size: 12.5px;
  line-height: 1.35;
  color: #DB2763;
  margin: -4px 0 0;
}

.hslG__bt {
  height: 52px;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: #CAFF00;
  color: #151519;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .2s var(--p2-out, ease), box-shadow .2s, filter .2s;
}
.hslG__bt:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(202, 255, 0, .18); filter: brightness(1.05); }
.hslG__bt:active { transform: none; }
.hslG__bt:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

.hslG__troca { text-align: center; font-size: 13px; color: #a3a3a3; }
.hslG__esqueci { text-align: center; font-size: 12px; margin: -4px 0 0; }
.hslG__esqueci[hidden] { display: none; }
.hslG__esqueci button {
  background: none;
  border: 0;
  padding: 0;
  font-size: 12px;
  color: #6a6a6a;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.hslG__esqueci button:hover { color: #DB2763; }
.hslG__esqueci button:disabled { opacity: .5; cursor: wait; }
.hslG__ok { color: #CAFF00; font-size: 12px; line-height: 1.45; }
.hslG__troca button {
  background: none;
  border: 0;
  padding: 0;
  color: #CAFF00;
  font-size: 13px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.hslG__troca button:hover { color: #E0DDCC; }

.hslG__nota { text-align: center; font-size: 11px; line-height: 1.5; color: #6a6a6a; }

/* ---------- chip "você está logado" ---------- */
.hslG__chip {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9000;
  display: none;
  align-items: center;
  gap: 10px;
  padding: 8px 8px 8px 14px;
  background: rgba(20, 20, 20, .92);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 999px;
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 11px;
  letter-spacing: .06em;
  color: #E0DDCC;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .5);
}
.hslG__chip b { color: #CAFF00; font-weight: 400; }
.hslG__chip button {
  background: rgba(255, 255, 255, .08);
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  font: inherit;
  color: #a3a3a3;
  cursor: pointer;
}
.hslG__chip button:hover { background: #DB2763; color: #fff; }
@media (min-width: 861px) { .hslG__chip--on { display: inline-flex; } }

/* ---------- chip: nome clicável (abre o perfil) ---------- */
.hslG__chip button.hslG__chipNome {
  background: none;
  border: 0;
  padding: 0;
  color: #E0DDCC;
  letter-spacing: .06em;
  border-bottom: 1px dashed rgba(224, 221, 204, .45);
  border-radius: 0;
}
.hslG__chip button.hslG__chipNome:hover { background: none; color: #CAFF00; border-bottom-color: #CAFF00; }

/* ---------- modal editar perfil (nome + info · sem foto) ---------- */
.hslP {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(10, 10, 10, .92);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.hslP[hidden] { display: none !important; }
.hslP__card {
  width: 100%;
  max-width: 430px;
  background: #141419;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 14px;
  padding: 24px 24px 22px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, .75);
  animation: hslG-sobe .35s cubic-bezier(.22, 1, .36, 1) both;
}
.hslP__cab { display: flex; align-items: center; justify-content: space-between; }
.hslP__cab span {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #CAFF00;
}
.hslP__x { background: none; border: 0; color: #6a6a6a; font-size: 26px; line-height: 1; cursor: pointer; }
.hslP__x:hover { color: #fff; }
.hslP__sub { font-size: 13px; color: #a3a3a3; line-height: 1.5; margin: 6px 0 18px; }
.hslP__campo { display: flex; flex-direction: column; gap: 7px; margin-bottom: 14px; }
.hslP__campo label {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #a3a3a3;
}
.hslP__campo label i { font-style: normal; color: #6a6a6a; text-transform: none; letter-spacing: .04em; }
.hslP__campo input {
  height: 46px;
  padding: 0 14px;
  background: #1b1b21;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 8px;
  color: #fff;
  font-size: 15px;
  outline: none;
  transition: border-color .2s, background .2s;
}
.hslP__campo input::placeholder { color: #5f5f5f; }
.hslP__campo input:focus { border-color: #DB2763; background: #1f1f26; }
.hslP__dica { font-size: 11.5px; color: #6a6a6a; line-height: 1.5; margin: 0 0 6px; }
.hslP__erro { min-height: 16px; font-size: 12.5px; line-height: 1.35; color: #DB2763; margin: 0 0 8px; }
.hslP__bt {
  width: 100%;
  height: 50px;
  border: 0;
  border-radius: 8px;
  background: #CAFF00;
  color: #151519;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .2s var(--p2-out, ease), box-shadow .2s;
}
.hslP__bt:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(202, 255, 0, .18); }
.hslP__bt:disabled { opacity: .55; cursor: not-allowed; transform: none; }

/* ---------- mobile: vira coluna ---------- */
@media (max-width: 860px) {
  .hslG { padding: 14px; align-items: center; }
  .hslG__modal { grid-template-columns: 1fr; min-height: 0; max-height: 94vh; overflow: auto; }
  .hslG__lado { min-height: 190px; height: 190px; }
  .hslG__img { object-position: center 24%; }
  .hslG__marca { left: 18px; right: 18px; bottom: 12px; gap: 6px; }
  .hslG__marca b { font-size: 11px; }
  .hslG__marca i { font-size: 9px; }
  .hslG__painel { padding: 24px 20px 26px; }
}

@media (prefers-reduced-motion: reduce) {
  .hslG, .hslG__modal { animation: none; }
}
