﻿@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@400;500;600;700;800&display=swap");

:root {
  --primary-glow: #1ABB9C;
  --secondary-glow: #00d2ff;
  --dark-bg: #070B12;
  --card-bg: rgba(13, 20, 36, 0.75);
  --card-border: rgba(255, 255, 255, 0.08);
  --input-bg: rgba(255, 255, 255, 0.035);
  --input-border: rgba(255, 255, 255, 0.09);
  --text-primary: #ffffff;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent-cyan: #00f2fe;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--dark-bg);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-font-smoothing: antialiased;
}

/* Canvas de Partículas Futuristas */
#cyber-particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  opacity: 0.85;
}

/* Background com Efeitos Futuristas de Luz e Grade */
.bg-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 38px 38px;
  pointer-events: none;
  z-index: 1;
}

.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(140px);
  pointer-events: none;
  opacity: 0.4;
  z-index: 1;
  animation: pulseGlow 12s infinite alternate ease-in-out;
}

.bg-glow-1 {
  width: 600px;
  height: 600px;
  top: -120px;
  left: -100px;
  background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
}

.bg-glow-2 {
  width: 700px;
  height: 700px;
  bottom: -180px;
  right: -120px;
  background: radial-gradient(circle, var(--secondary-glow) 0%, transparent 70%);
  animation-delay: -6s;
}

@keyframes pulseGlow {
  0% { transform: scale(1) translate(0, 0); opacity: 0.3; }
  100% { transform: scale(1.2) translate(50px, 40px); opacity: 0.55; }
}

/* Container Principal */
.container {
  position: relative;
  width: 100%;
  min-height: 100vh;
  background: transparent;
  overflow: hidden;
  z-index: 2;
  display: flex;
}

.forms-container {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.signin-signup {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  left: 75%;
  width: 50%;
  transition: 1s 0.7s cubic-bezier(0.77, 0, 0.175, 1);
  display: grid;
  grid-template-columns: 1fr;
  z-index: 5;
}

/* Formulários */
form {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 2rem 5rem;
  transition: all 0.2s 0.7s;
  overflow: hidden;
  grid-column: 1 / 2;
  grid-row: 1 / 2;
  max-width: 500px;
  margin: 0 auto;
  width: 100%;
}

form.sign-up-form {
  opacity: 0;
  z-index: 1;
}

form.sign-in-form {
  z-index: 2;
}

.form-header {
  text-align: center;
  margin-bottom: 22px;
}

.cyber-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(26, 187, 156, 0.1);
  border: 1px solid rgba(26, 187, 156, 0.3);
  color: var(--primary-glow);
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  box-shadow: 0 0 15px rgba(26, 187, 156, 0.15);
}

.title {
  font-family: "Space Grotesk", sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
  text-shadow: 0 0 25px rgba(255, 255, 255, 0.15);
}

.subtitle {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.45;
  font-weight: 400;
}

/* Efeito Shimmer Metálico no Logo */
@keyframes shimmerSweep {
  0% { background-position: -250% 0; }
  100% { background-position: 250% 0; }
}

.shimmer-brand {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 800;
  font-size: 2.1rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 8px;
  background: linear-gradient(90deg, #ffffff 0%, #ffffff 30%, var(--accent-cyan) 50%, var(--primary-glow) 70%, #ffffff 100%);
  background-size: 250% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmerSweep 5s ease-in-out infinite;
  display: inline-block;
}

.shimmer-brand span {
  font-weight: 300;
  color: var(--primary-glow);
  -webkit-text-fill-color: var(--primary-glow);
}

/* Campos de Input Futuristas */
.input-field {
  max-width: 380px;
  width: 100%;
  background: var(--input-bg);
  backdrop-filter: blur(10px);
  margin: 9px 0;
  height: 54px;
  border-radius: 12px;
  display: grid;
  grid-template-columns: 15% 85%;
  padding: 0 0.8rem;
  position: relative;
  border: 1px solid var(--input-border);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.input-field:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

.input-field:focus-within {
  border-color: var(--primary-glow);
  background: rgba(26, 187, 156, 0.06);
  box-shadow: 0 0 25px rgba(26, 187, 156, 0.3), inset 0 0 8px rgba(26, 187, 156, 0.05);
}

.input-field i {
  text-align: center;
  line-height: 52px;
  color: var(--text-muted);
  transition: color 0.3s ease;
  font-size: 1.1rem;
}

.input-field:focus-within i {
  color: var(--primary-glow);
  text-shadow: 0 0 10px rgba(26, 187, 156, 0.7);
}

.input-field input {
  background: none;
  outline: none;
  border: none;
  line-height: 1;
  font-weight: 500;
  font-size: 0.95rem;
  color: #ffffff;
  width: 100%;
}

.input-field input::placeholder {
  color: #64748b;
  font-weight: 400;
}

.input-field .toggle-password {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.95rem;
  padding: 6px;
  transition: color 0.2s ease;
  z-index: 2;
}

.input-field .toggle-password:hover {
  color: var(--accent-cyan);
}

/* Botões Modernos e Tecnológicos */
.btn {
  width: 100%;
  max-width: 380px;
  background: linear-gradient(135deg, #1ABB9C 0%, #0fb992 50%, #00c6ff 100%);
  border: none;
  outline: none;
  height: 52px;
  border-radius: 12px;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
  margin: 16px 0 12px 0;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.165, 0.84, 0.44, 1);
  box-shadow: 0 8px 25px rgba(26, 187, 156, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
}

.btn:hover {
  background: linear-gradient(135deg, #18a78b 0%, #00c6ff 100%);
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(0, 198, 255, 0.5);
}

.btn:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(26, 187, 156, 0.3);
}

.btn-icon {
  font-size: 0.9rem;
  transition: transform 0.25s ease;
}

.btn:hover .btn-icon {
  transform: translateX(4px);
}

.link-btn {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.88rem;
  margin-top: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-radius: 8px;
}

.link-btn:hover {
  color: var(--accent-cyan);
  background: rgba(0, 242, 254, 0.08);
}

/* Painéis Laterais com Animação */
.panels-container {
  position: absolute;
  height: 100%;
  width: 100%;
  top: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}

/* Curva / Halo Futurista */
.container:before {
  content: "";
  position: absolute;
  height: 2200px;
  width: 2200px;
  top: -10%;
  right: 48%;
  transform: translateY(-50%);
  background: radial-gradient(circle at 60% 40%, rgba(26, 187, 156, 0.18) 0%, rgba(13, 20, 36, 0.96) 45%, #070B12 80%);
  border: 1px solid rgba(26, 187, 156, 0.25);
  box-shadow: 0 0 120px rgba(26, 187, 156, 0.15), inset 0 0 80px rgba(0, 0, 0, 0.8);
  transition: 1.8s cubic-bezier(0.77, 0, 0.175, 1);
  border-radius: 50%;
  z-index: 6;
}

.panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 6;
}

.left-panel {
  pointer-events: all;
  padding: 3rem 16% 2rem 10%;
}

.right-panel {
  pointer-events: none;
  padding: 3rem 10% 2rem 16%;
}

.panel .content {
  color: #ffffff;
  transition: transform 0.9s ease-in-out;
  transition-delay: 0.6s;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 440px;
}

/* Ícone Holográfico Futurista 3D CSS */
.cyber-core {
  position: relative;
  width: 100px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
}

.cyber-circle-outer {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px dashed rgba(26, 187, 156, 0.5);
  animation: rotateOuter 16s linear infinite;
}

.cyber-circle-inner {
  position: absolute;
  width: 76%;
  height: 76%;
  border-radius: 50%;
  border: 2px solid rgba(0, 242, 254, 0.4);
  border-top-color: transparent;
  animation: rotateInner 8s linear infinite reverse;
}

.cyber-icon {
  font-size: 2.2rem;
  color: var(--accent-cyan);
  text-shadow: 0 0 20px rgba(0, 242, 254, 0.8);
  animation: pulseIcon 3s ease-in-out infinite alternate;
}

@keyframes rotateOuter {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes rotateInner {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes pulseIcon {
  0% { transform: scale(0.95); opacity: 0.85; }
  100% { transform: scale(1.1); opacity: 1; }
}

.panel-desc {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 20px;
  font-weight: 400;
}

/* Feature Pills Tecnológicos */
.feature-pills {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  justify-content: center;
}

.pill {
  font-size: 0.78rem;
  font-weight: 600;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 6px 12px;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  backdrop-filter: blur(8px);
}

.pill i {
  color: var(--primary-glow);
}

/* Detalhes de Sistema Enterprise */
.enterprise-status {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(13, 20, 36, 0.65);
  border: 1px solid rgba(26, 187, 156, 0.25);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  color: #94a3b8;
  margin-top: 15px;
  backdrop-filter: blur(8px);
}

.status-dot {
  width: 7px;
  height: 7px;
  background-color: var(--primary-glow);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--primary-glow);
  animation: dotPulse 2s infinite ease-in-out;
}

@keyframes dotPulse {
  0% { transform: scale(0.9); opacity: 0.6; }
  50% { transform: scale(1.2); opacity: 1; box-shadow: 0 0 14px var(--primary-glow); }
  100% { transform: scale(0.9); opacity: 0.6; }
}

.encryption-tag {
  font-size: 0.7rem;
  color: #64748b;
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
}

.encryption-tag i {
  color: var(--primary-glow);
}

.panel-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.action-question {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.btn.transparent {
  background: rgba(255, 255, 255, 0.04);
  border: 1.5px solid rgba(26, 187, 156, 0.6);
  color: #ffffff;
  width: 170px;
  height: 46px;
  font-weight: 600;
  font-size: 0.88rem;
  border-radius: 12px;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.btn.transparent:hover {
  background: var(--primary-glow);
  border-color: var(--primary-glow);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(26, 187, 156, 0.5);
}

.right-panel .content {
  transform: translateX(800px);
}

/* Transição do modo cadastro / login */
.container.sign-up-mode:before {
  transform: translate(100%, -50%);
  right: 52%;
}

.container.sign-up-mode .left-panel .content {
  transform: translateX(-800px);
}

.container.sign-up-mode .signin-signup {
  left: 25%;
}

.container.sign-up-mode form.sign-up-form {
  opacity: 1;
  z-index: 2;
}

.container.sign-up-mode form.sign-in-form {
  opacity: 0;
  z-index: 1;
}

.container.sign-up-mode .right-panel .content {
  transform: translateX(0%);
}

.container.sign-up-mode .left-panel {
  pointer-events: none;
}

.container.sign-up-mode .right-panel {
  pointer-events: all;
}

.d-none {
  display: none !important;
}

/* Spinner de Carregamento */
.lds-dual-ring,
.lds-dual-ring:after {
  box-sizing: border-box;
}
.lds-dual-ring {
  display: inline-block;
  width: 16px;
  height: 16px;
  vertical-align: middle;
}
.lds-dual-ring:after {
  content: " ";
  display: block;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid #fff;
  border-color: #fff transparent #fff transparent;
  animation: lds-dual-ring 1s linear infinite;
}
@keyframes lds-dual-ring {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsividade Mobile e Tablet */
@media (max-width: 870px) {
  .container {
    min-height: 800px;
    height: 100vh;
  }
  .signin-signup {
    width: 100%;
    top: 95%;
    transform: translate(-50%, -100%);
    transition: 1s 0.8s ease-in-out;
  }

  .signin-signup,
  .container.sign-up-mode .signin-signup {
    left: 50%;
  }

  .panels-container {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr 2fr 1fr;
  }

  .panel {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 8%;
    grid-column: 1 / 2;
  }

  .right-panel {
    grid-row: 3 / 4;
  }

  .left-panel {
    grid-row: 1 / 2;
  }

  .panel .content {
    padding-right: 0;
  }

  .shimmer-brand {
    font-size: 1.6rem;
  }

  .panel-desc,
  .feature-pills,
  .enterprise-status {
    display: none;
  }

  .cyber-core {
    width: 65px;
    height: 65px;
    margin-bottom: 12px;
  }

  .cyber-icon {
    font-size: 1.5rem;
  }

  .container:before {
    width: 1500px;
    height: 1500px;
    transform: translateX(-50%);
    left: 30%;
    bottom: 68%;
    right: initial;
    top: initial;
    transition: 2s ease-in-out;
  }

  .container.sign-up-mode:before {
    transform: translate(-50%, 100%);
    bottom: 32%;
    right: initial;
  }

  .container.sign-up-mode .left-panel .content {
    transform: translateY(-300px);
  }

  .container.sign-up-mode .right-panel .content {
    transform: translateY(0px);
  }

  .right-panel .content {
    transform: translateY(300px);
  }

  .container.sign-up-mode .signin-signup {
    top: 5%;
    transform: translate(-50%, 0);
  }
}

@media (max-width: 570px) {
  form {
    padding: 0 1.2rem;
  }
  .container {
    padding: 1rem;
  }
  .title {
    font-size: 1.8rem;
  }
  .container:before {
    bottom: 74%;
    left: 50%;
  }
  .container.sign-up-mode:before {
    bottom: 26%;
    left: 50%;
  }
}