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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #0f0f0f 0%, #1a1a1a 50%, #0f0f0f 100%);
  color: #ffffff;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Tela Inicial */
.screen {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
  transition: all 0.6s ease-in-out;
}

.welcome-container {
  background: linear-gradient(145deg, #2a2a2a, #1f1f1f);
  padding: 50px 40px;
  border-radius: 25px;
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  text-align: center;
  max-width: 450px;
  width: 100%;
  border: 1px solid rgba(0, 255, 204, 0.3);
  position: relative;
  overflow: hidden;
  animation: fadeInUp 0.8s ease-out;
}

.welcome-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #00ffcc, #ff6b6b, #4ecdc4, #45b7d1);
  background-size: 400% 400%;
  animation: gradientShift 3s ease infinite;
}

.profile-image {
  margin-bottom: 30px;
  position: relative;
}

.profile-image img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 3px solid #00ffcc;
  object-fit: cover;
  transition: transform 0.2s ease;
}

.welcome-message h1 {
  color: #00ffcc;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 15px;
  text-shadow: 0 0 15px rgba(0, 255, 204, 0.4);
}

.welcome-message p {
  color: #e0e0e0;
  font-size: 1.3em;
  margin-bottom: 35px;
  line-height: 1.6;
  opacity: 0.9;
}

#continue-btn {
  background: linear-gradient(135deg, #00ffcc, #00e6b8);
  color: #1a1a1a;
  padding: 18px 40px;
  border: none;
  border-radius: 15px;
  font-size: 1.3em;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 255, 204, 0.3);
}

#continue-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s;
}

#continue-btn:hover::before {
  left: 100%;
}

#continue-btn:hover {
  background: linear-gradient(135deg, #ff6b6b, #ff5252);
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(255, 107, 107, 0.4);
}

#continue-btn:active {
  transform: translateY(-1px);
}

/* Modal/Pop-up */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  animation: fadeIn 0.5s ease-out;
}

.modal-content {
  background: linear-gradient(145deg, #2a2a2a, #1f1f1f);
  border-radius: 20px;
  padding: 40px 30px;
  max-width: 500px;
  width: 100%;
  border: 2px solid #ff6b6b;
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.8),
    0 0 30px rgba(255, 107, 107, 0.3);
  text-align: center;
  position: relative;
  animation: modalSlideIn 0.6s ease-out;
}

/* Posicionamento específico para mobile */
@media (max-width: 768px) {
  .modal-overlay {
    justify-content: flex-end;
    align-items: flex-start;
    padding: 20px 20px 20px 20px;
  }
  
  .modal-content {
    max-width: 320px;
    width: 100%;
    margin-top: 60px;
    margin-right: 0;
    animation: modalSlideInMobile 0.6s ease-out;
  }
}

.modal-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ff6b6b, #ff5252, #ff6b6b);
  background-size: 200% 200%;
  animation: gradientShift 2s ease infinite;
}

.modal-header h2 {
  color: #ff6b6b;
  font-size: 2em;
  font-weight: 700;
  margin-bottom: 25px;
  text-shadow: 0 0 15px rgba(255, 107, 107, 0.4);
}

.modal-body p {
  color: #e0e0e0;
  font-size: 1.2em;
  line-height: 1.6;
  margin-bottom: 25px;
}

#try-again-btn {
  background: linear-gradient(135deg, #00ffcc, #00e6b8);
  color: #1a1a1a;
  padding: 16px 35px;
  border: none;
  border-radius: 12px;
  font-size: 1.2em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 6px 20px rgba(0, 255, 204, 0.3);
}

#try-again-btn:hover {
  background: linear-gradient(135deg, #ff6b6b, #ff5252);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
}

/* Tela de Redirecionamento */
.redirect-container {
  background: linear-gradient(145deg, #2a2a2a, #1f1f1f);
  padding: 60px 40px;
  border-radius: 25px;
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  text-align: center;
  max-width: 450px;
  width: 100%;
  border: 1px solid rgba(0, 255, 204, 0.3);
  position: relative;
  overflow: hidden;
  animation: fadeInUp 0.8s ease-out;
}

.redirect-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #00ffcc, #4ecdc4, #45b7d1);
  background-size: 400% 400%;
  animation: gradientShift 3s ease infinite;
}

.success-icon {
  margin-bottom: 30px;
}

.checkmark {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, #00ffcc, #4ecdc4);
  color: #1a1a1a;
  font-size: 3em;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  box-shadow: 
    0 0 30px rgba(0, 255, 204, 0.5),
    0 10px 25px rgba(0, 0, 0, 0.3);
}

.redirect-container h2 {
  color: #00ffcc;
  font-size: 2.2em;
  font-weight: 700;
  margin-bottom: 30px;
  text-shadow: 0 0 15px rgba(0, 255, 204, 0.4);
}

.loading-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 20px;
}

.loading-progress {
  height: 100%;
  background: linear-gradient(90deg, #00ffcc, #4ecdc4, #45b7d1);
  border-radius: 3px;
  animation: loadingProgress 2s ease-in-out;
}

/* Animações */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes modalSlideInMobile {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes gradientShift {
  0%, 100% { 
    background-position: 0% 50%; 
  }
  50% { 
    background-position: 100% 50%; 
  }
}

@keyframes loadingProgress {
  from {
    width: 0%;
  }
  to {
    width: 100%;
  }
}

/* Classes de transição */
.fade-out {
  animation: fadeOut 0.6s ease-in-out forwards;
}

.fade-in {
  animation: fadeIn 0.6s ease-in-out forwards;
}

/* Responsividade */
@media (max-width: 768px) {
  .welcome-container,
  .redirect-container {
    padding: 40px 30px;
    margin: 10px;
  }

  .modal-content {
    padding: 30px 25px;
    margin: 10px;
  }

  .welcome-message h1 {
    font-size: 2.2em;
  }

  .profile-image img {
    width: 100px;
    height: 100px;
  }

  .modal-header h2 {
    font-size: 1.8em;
  }

  .redirect-container h2 {
    font-size: 2em;
  }
}

@media (max-width: 480px) {
  .screen {
    padding: 15px;
  }

  .welcome-container,
  .redirect-container {
    padding: 30px 20px;
    border-radius: 20px;
  }

  .modal-content {
    padding: 25px 20px;
    border-radius: 15px;
  }

  .welcome-message h1 {
    font-size: 2em;
    margin-bottom: 12px;
  }

  .welcome-message p {
    font-size: 1.1em;
    margin-bottom: 30px;
  }

  .profile-image img {
    width: 90px;
    height: 90px;
  }

  #continue-btn,
  #try-again-btn {
    padding: 16px 30px;
    font-size: 1.1em;
  }

  .modal-header h2 {
    font-size: 1.6em;
    margin-bottom: 20px;
  }

  .modal-body p {
    font-size: 1.1em;
  }

  .redirect-container h2 {
    font-size: 1.8em;
  }

  .checkmark {
    width: 70px;
    height: 70px;
    font-size: 2.5em;
  }
}

@media (max-width: 360px) {
  .welcome-container,
  .redirect-container {
    padding: 25px 15px;
  }

  .modal-content {
    padding: 20px 15px;
  }

  .welcome-message h1 {
    font-size: 1.8em;
  }

  .profile-image img {
    width: 80px;
    height: 80px;
  }

  #continue-btn,
  #try-again-btn {
    padding: 14px 25px;
    font-size: 1em;
  }

  .modal-header h2 {
    font-size: 1.4em;
  }

  .redirect-container h2 {
    font-size: 1.6em;
  }

  .checkmark {
    width: 60px;
    height: 60px;
    font-size: 2em;
  }
}

