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

body {
  font-family: 'Poppins', sans-serif;
  background-color: #f5f7ff;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
}

.container {
  display: flex;
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  width: 90%;
  max-width: 1000px;
}

.left {
  width: 50%;
  background-color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.left img {
  width: 100%;
  margin-left: 50px;
}

.right {
  width: 50%;
  padding: 60px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background-color: #ffffff;
}

.right h2 {
  font-size: 26px;
  margin-bottom: 20px;
  color: #222;
  text-align: center;
}

/* ===== FORM GROUP ===== */
.form-group {
  position: relative;
  margin-bottom: 25px;
}

.form-group i {
  position: absolute;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  color: #888;
  font-size: 16px;
}

.form-group input {
  width: 100%;
  padding: 16px 16px 16px 42px;
  border: 1px solid #ccc;
  border-radius: 10px;
  font-size: 14px;
  background-color: #fff;
  outline: none;
}

.form-group label {
  position: absolute;
  top: 50%;
  left: 42px;
  transform: translateY(-50%);
  background-color: white;
  padding: 0 6px;
  color: #888;
  font-size: 14px;
  pointer-events: none;
  transition: 0.2s ease all;
}

.form-group input:focus + label,
.form-group input:not(:placeholder-shown) + label {
  top: 6px;
  left: 38px;
  font-size: 12px;
  color: #4a6cf7;
  font-weight: 500;
}

/* === LUPA PASSWORD LINK === */
.forgot-link {
  text-align: right;
  margin-bottom: 20px;
}

.forgot-link a {
  color: #4a6cf7;
  font-size: 14px;
  text-decoration: none;
}

.forgot-link a:hover {
  text-decoration: underline;
}

/* === BUTTON FORM LOGIN === */
form button {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(to right, #4a6cf7, #6b8dfd);
  color: white;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
  transition: 0.3s;
}

form button:hover {
  background: linear-gradient(to right, #3c59d1, #5577f0);
}

/* === MODAL === */
.modal {
  display: none;
  position: fixed;
  z-index: 99;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
}

.modal-box {
  background: linear-gradient(to bottom right, #ffffff, #f4f7ff);
  border-radius: 20px;
  padding: 40px 30px;
  width: 90%;
  max-width: 400px;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
  animation: fadeIn 0.3s ease;
  position: relative;
  transition: all 0.3s ease-in-out;
}

.modal-box img {
  width: 72px;
  margin-bottom: 16px;
  animation: pulse 1.2s infinite ease-in-out alternate;
}

.modal-box h3 {
  font-size: 22px;
  margin-bottom: 20px;
  color: #333;
  font-weight: 600;
}

/* Gunakan .form-group dalam modal agar konsisten */
.modal-box .form-group {
  margin-bottom: 24px;
}

/* === MODAL BUTTONS === */
.modal-buttons {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.modal-buttons button {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-box button.send {
  background: linear-gradient(to right, #4a6cf7, #6b8dfd);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 600;
  box-shadow: 0 4px 8px rgba(74, 108, 247, 0.3);
  transition: background 0.3s ease, transform 0.2s ease;
}

.modal-box button.send:hover {
  background: linear-gradient(to right, #3c59d1, #567bf9);
  transform: translateY(-1px);
}

.modal-box button.close {
  background-color: #f0f0f0;
  color: #333;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 500;
  transition: background 0.3s ease, transform 0.2s ease;
}

.modal-box button.close:hover {
  background-color: #e0e0e0;
  transform: translateY(-1px);
}

/* === ANIMATIONS === */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulse {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.08);
  }
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .container {
    flex-direction: column;
  }

  .left,
  .right {
    width: 100%;
  }

  .right {
    padding: 40px 30px;
  }
}
