/* default login css */

/*intro css */
/* Animated background with color flashes */
@keyframes backgroundFlash {
  0% { background-color: rgba(41, 41, 41, 0.8); }
  25% { background-color: rgba(74, 35, 90, 0.8); }
  50% { background-color: rgba(35, 65, 90, 0.8); }
  75% { background-color: rgba(90, 60, 35, 0.8); }
  100% { background-color: rgba(41, 41, 41, 0.8); }
}

@keyframes colorCycle {
  0% { border-color: #ff6b6b; box-shadow: 0 0 20px rgba(255, 107, 107, 0.5); }
  25% { border-color: #4ecdc4; box-shadow: 0 0 20px rgba(78, 205, 196, 0.5); }
  50% { border-color: #45b7d1; box-shadow: 0 0 20px rgba(69, 183, 209, 0.5); }
  75% { border-color: #96ceb4; box-shadow: 0 0 20px rgba(150, 206, 180, 0.5); }
  100% { border-color: #ff6b6b; box-shadow: 0 0 20px rgba(255, 107, 107, 0.5); }
}

@keyframes pulseGlow {
  0% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.05); opacity: 1; }
  100% { transform: scale(1); opacity: 0.7; }
}

/* Enhanced square name with color flash effects */
@keyframes nameColorFlash {
  0% { 
    background: linear-gradient(45deg, rgba(255, 107, 107, 0.9), rgba(78, 205, 196, 0.9));
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
  }
  25% { 
    background: linear-gradient(45deg, rgba(78, 205, 196, 0.9), rgba(69, 183, 209, 0.9));
    color: #ffeb3b;
    text-shadow: 0 0 10px rgba(255, 235, 59, 0.8);
  }
  50% { 
    background: linear-gradient(45deg, rgba(69, 183, 209, 0.9), rgba(150, 206, 180, 0.9));
    color: #e91e63;
    text-shadow: 0 0 10px rgba(233, 30, 99, 0.8);
  }
  75% { 
    background: linear-gradient(45deg, rgba(150, 206, 180, 0.9), rgba(255, 107, 107, 0.9));
    color: #9c27b0;
    text-shadow: 0 0 10px rgba(156, 39, 176, 0.8);
  }
  100% { 
    background: linear-gradient(45deg, rgba(255, 107, 107, 0.9), rgba(78, 205, 196, 0.9));
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
  }
}

@keyframes namePulse {
  0% { 
    transform: translateY(0);
    box-shadow: 0 0 0 rgba(255, 255, 255, 0.3);
  }
  50% { 
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.4);
  }
  100% { 
    transform: translateY(0);
    box-shadow: 0 0 0 rgba(255, 255, 255, 0.3);
  }
}

@keyframes nameBorderGlow {
  0% { border-top: 2px solid #ff6b6b; }
  25% { border-top: 2px solid #4ecdc4; }
  50% { border-top: 2px solid #45b7d1; }
  75% { border-top: 2px solid #96ceb4; }
  100% { border-top: 2px solid #ff6b6b; }
}

/* Square name styling with enhanced effects */
.square_name { 
  position: absolute; 
  bottom: 0; 
  left: 0; 
  width: 100%; 
  font-size: 22px; 
  font-weight: 600;
  text-overflow: ellipsis; 
  overflow: hidden; 
  white-space: nowrap; 
  padding: 0px 0px; 
  border-radius: 0 0 25px 25px; 
  text-align: center; 
  background: linear-gradient(45deg, rgba(255, 107, 107, 0.9), rgba(78, 205, 196, 0.9));
  color: white;
  z-index: 2;
  animation: nameColorFlash 4s infinite, namePulse 3s ease-in-out infinite, nameBorderGlow 5s infinite;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  backdrop-filter: blur(5px);
  border-top: 10px solid transparent;
  letter-spacing: 0.5px;
}

/* Hover effects for square name */
.user_square_elem:hover .square_name {
  animation-duration: 1s, 1.5s, 2s;
  padding: 10px 4px;
  font-size: 21px;
  border-radius: 0 0 25px 25px;
  background: linear-gradient(45deg, rgba(255, 107, 107, 0.95), rgba(78, 205, 196, 0.95));
}

/* User square element - rounded with animations */
.user_square_elem {
  border-radius: 25px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  animation: colorCycle 3s infinite, pulseGlow 2s ease-in-out infinite;
  transition: all 0.3s ease;
  overflow: hidden;
  position: relative;
}

.user_square_elem::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
  border-radius: 27px;
  z-index: -1;
  animation: colorCycle 4s infinite;
  filter: blur(10px);
}

.user_square_elem:hover {
  transform: translateY(-5px);
  animation-duration: 1s, 1s;
}

/* Friend view - rounded with effects */
.view_friend {
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 2px solid transparent;
  animation: colorCycle 5s infinite;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
  overflow: hidden;
}

.view_friend::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}

.view_friend:hover::after {
  left: 100%;
}

/* Enhanced login elements */
#login_logo { 
  height: 70px;
  border-radius: 15px;
  animation: pulseGlow 3s ease-in-out infinite;
}

#intro_top { 
  width: 100%; 
  height: 100%; 
  z-index: 1; 
  position: relative; 
  background: #292929 url('images/background.jpg'); 
  background-repeat: no-repeat; 
  background-size: cover; 
  background-position: center center; 
  background-attachment: fixed;
  animation: backgroundFlash 10s ease-in-out infinite;
}

#login_wrap { 
  width: 100%; 
  height: 100%; 
}

#login_all { 
  width: 1100px; 
  max-width: 94%; 
  border-radius: 50px;
  display: block; 
  margin: 0 auto; 
  color: #fff;
  border: 2px solid transparent;
  animation: colorCycle 6s infinite;
  box-shadow: 0 25px 35px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

#login_all:hover {
  transform: translateY(-10px);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
}

.login_not_member { 
  text-align: center; 
  padding-top: 5px; 
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  margin: 10px;
  padding: 15px;
  animation: pulseGlow 4s ease-in-out infinite;
}

#intro_lang { 
  position: absolute; 
  top: 10px; 
  right: 20px; 
  width: 40px; 
  height: 40px; 
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  animation: colorCycle 3s infinite;
  cursor: pointer;
  transition: all 0.3s ease;
}

#intro_lang:hover {
  transform: rotate(15deg) scale(1.1);
}

/* Enhanced section styles */
.section { 
  width: 100%; 
  height: auto; 
  margin: 0 auto; 
}

.section_content { 
  width: 100%; 
  max-width: 1100px; 
  margin: 0 auto;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border: 1px solid transparent;
  animation: colorCycle 8s infinite;
}

.section_inside { 
  margin: 0 auto;
  border-radius: 15px;
  padding: 20px;
  background: rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

.section_inside:hover {
  background: rgba(0, 0, 0, 0.3);
  transform: scale(1.02);
}

/* Flash animation for special effects */
@keyframes quickFlash {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.flash-element {
  animation: quickFlash 0.5s ease-in-out;
}

.user_square_elem img { 
  width: 100%; 
  display: block; 
  height: auto; 
  min-height: 200px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

/* Make user squares bigger */
.user_square_elem {
  border-radius: 25px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  animation: colorCycle 3s infinite, pulseGlow 2s ease-in-out infinite;
  transition: all 0.3s ease;
  overflow: hidden;
  position: relative;
  width: 160px;
  height: 180px;
  margin: 15px;
}

.user_square_elem:hover img {
  transform: scale(1.1);
}

/* Mobile adjustments */
@media screen and (max-width: 768px){
  .user_square_elem {
    width: 90vw;
    max-width: 180px;
    height: 200px;
    margin: 10px auto;
  }
  
  .square_name {
    font-size: 22px;
    padding: 1px 1px;
    animation-duration: 5s, 4s, 6s; /* Slower animations on mobile */
  }
  
  .user_square_elem::before,
  .view_friend::after {
    display: none;
  }
  
  #login_all {
    animation-duration: 8s;
  }
}

@media screen and (max-width: 1120px){
  .section_inside { 
    width: 96%; 
    border-radius: 12px;
  }
  
  #login_all {
    border-radius: 20px;
  }
  
  .user_square_elem,
  .view_friend {
    border-radius: 15px;
  }
  
  .square_name {
    border-radius: 0 0 15px 15px;
  }
}