* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Pretendard', 'Inter', sans-serif;
}

body {
  color: #fff;
  min-height: 100vh;
  background: radial-gradient(circle at 30% 30%, #5865F2, #0a0a0a 90%);
  position: relative;
  overflow-x: hidden;
}

#bg-gif {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: url("/logo/LLIMXLOGINWALLPAER2.png") center/cover no-repeat;
  filter: brightness(0.6) blur(2px);
}

.wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.top-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 24px;
  background: rgba(25, 25, 35, 0.8);
  box-shadow: 0 0 15px rgba(88, 101, 242, 0.4);
  z-index: 2;
  backdrop-filter: blur(8px);
}

.top-header .left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.top-header img {
  width: 30px;
  height: 30px;
}

.top-header .title {
  font-size: 1.2rem;
  font-weight: bold;
  color: #cfd4ff;
  text-shadow: 0 0 6px #5865F2;
}

.top-header .right button {
  background: linear-gradient(90deg, #5865F2, #00AFFF);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 8px 16px;
  cursor: pointer;
  font-weight: 600;
  transition: 0.3s;
}

.top-header .right button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 10px #00AFFF;
}

.main-content {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 0;
}

.login-card {
  width: 400px;
  padding: 40px;
  background: rgba(25, 25, 45, 0.8);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  text-align: center;
  z-index: 1;
  transition: all 0.3s ease;
}

.login-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 40px rgba(88, 101, 242, 0.4);
}

.login-card .logo img {
  width: 50px;
  height: 50px;
  margin-bottom: 10px;
}

.login-card h2 {
  font-size: 1.5rem;
  margin-bottom: 8px;
  color: #e2e7ff;
  text-shadow: 0 0 8px #5865F2;
}

.login-card p {
  font-size: 0.9rem;
  color: #b8c2ff;
  margin-bottom: 25px;
}

.input-field {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  border: 1px solid rgba(88, 101, 242, 0.4);
  border-radius: 10px;
  background: rgba(40, 45, 80, 0.6);
}

.input-field input {
  flex: 1;
  padding: 12px;
  border: none;
  outline: none;
  border-radius: 8px;
  font-size: 14px;
  color: #fff;
  background: transparent;
}

.input-field .icon {
  margin-left: 10px;
  font-size: 18px;
  color: #9da6ff;
}

.login-btn,
.social-btn {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  margin-bottom: 10px;
  color: #fff;
  text-shadow: 0 0 5px #c084fc;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  background: linear-gradient(90deg, #9d50bb, #6e48aa);
}

/* 버튼 뒤에 생기는 부드러운 glow 효과 */
.login-btn::before,
.social-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.15);
  transform: skewX(-20deg);
  transition: 0.4s;
}

/* hover 시 빛이 스쳐 지나가는 듯한 효과 */
.login-btn:hover::before,
.social-btn:hover::before {
  left: 200%;
}

/* hover 시 살짝 떠오르는 느낌 */
.login-btn:hover,
.social-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.6);
}

/* 클릭 시 살짝 눌리는 효과 */
.login-btn:active,
.social-btn:active {
  transform: scale(0.97);
  box-shadow: 0 0 10px rgba(192, 132, 252, 0.3);
}

.divider {
  position: relative;
  text-align: center;
  margin: 20px 0;
}

.divider span {
  background: rgba(25, 25, 45, 0.8);
  padding: 0 10px;
  font-size: 12px;
  color: #ddd;
}

.divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 1px;
  background: #555;
  transform: translateY(-50%);
}

footer {
  margin-top: auto;
  text-align: center;
  padding: 10px;
  font-size: 14px;
  color: #ccc;
  background: rgba(15, 15, 25, 0.8);
}

/* 모달 (약관) */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backdrop-filter: blur(4px);
  background: rgba(0, 0, 0, 0.7);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 5;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: rgba(25, 25, 45, 0.95);
  border-radius: 12px;
  padding: 25px;
  width: 500px;
  max-height: 80vh;
  overflow-y: auto;
  color: #e6e9ff;
  box-shadow: 0 0 25px rgba(88, 101, 242, 0.4);
}

/* ✅ 약관 텍스트 가독성 향상 */
.terms-text {
  max-height: 60vh;
  overflow-y: auto;
  margin-bottom: 20px;
  padding: 15px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  color: #f2f3ff;
  line-height: 1.6;
  font-size: 14px;
}

.terms-text h4 {
  color: #9da6ff;
  margin-top: 10px;
}

.terms-text::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40px;
  background: linear-gradient(transparent, rgba(25, 25, 45, 0.95));
  pointer-events: none;
}

/* 버튼들 */
#agreeButton,
#closeModal {
  padding: 10px 16px;
  border: none;
  border-radius: 8px;
  margin-right: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: 0.3s;
}

#agreeButton {
  background: linear-gradient(90deg, #5865F2, #00AFFF);
  color: #fff;
}

#agreeButton:disabled {
  background: rgba(255, 255, 255, 0.1);
  color: #aaa;
  cursor: not-allowed;
}

#agreeButton:hover:enabled {
  transform: scale(1.05);
  box-shadow: 0 0 12px #5865F2;
}

#closeModal {
  background: #2b2d31;
  color: #ccc;
}

#closeModal:hover {
  background: #3a3c40;
}

/* 반응형 */
@media (max-width: 768px) {
  .login-card {
    width: 90%;
    padding: 25px;
  }

  .modal-content {
    width: 90%;
  }
}