body {
  margin: 0;
  font-family: Arial, sans-serif;
  min-height: 100vh;
}

.login-page {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;

  background-image: url("photos/index_background.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.home-page {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(to bottom, #fff1f5, #ffe4ec);
}

.login-container,
.home-container {
  text-align: center;
  padding: 40px 24px;
}

h1 {
  margin-bottom: 10px;
  font-size: 2.2rem;
  color: rgb(9, 9, 9);
}

.subtitle {
  margin-bottom: 30px;
  color: rgb(15, 14, 14);
}

.login-box {
  background: rgba(255, 255, 255, 0.85);
  padding: 30px;
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  width: 320px;
  max-width: 90vw;
}

.login-box label {
  display: block;
  margin-bottom: 12px;
  font-weight: bold;
}

.login-box input {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 12px;
  margin-bottom: 16px;
  box-sizing: border-box;
  font-size: 1rem;
}

.login-box button {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 12px;
  background: #ff6fa1;
  color: white;
  font-size: 1rem;
  cursor: pointer;
}

.login-box button:hover {
  opacity: 0.9;
}

#message {
  margin-top: 14px;
  color: #d6336c;
  min-height: 20px;
}
.memory-card {
  width: 320px;
  height: 440px;
  margin: 30px auto 0;
  perspective: 1200px;
  cursor: pointer;
}

.memory-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s ease;
  transform-style: preserve-3d;
  animation: swing 3s ease-in-out infinite;
}

.memory-card.flipped .memory-card-inner {
  transform: rotateY(180deg);
  animation: none;
}

.memory-card-front,
.memory-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  overflow: hidden;
  backface-visibility: hidden;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.15);
  background: white;
}

.memory-card-front {
  position: relative;
}

.memory-card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-tip {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.88);
  color: #d6336c;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: bold;
}

.memory-card-back {
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px 24px;
  box-sizing: border-box;
  background: linear-gradient(to bottom, #fff7fa, #ffe4ec);
}

.memory-card-back h2 {
  margin-bottom: 16px;
  color: #d6336c;
  font-size: 1.6rem;
}

.memory-card-back p {
  color: #444;
  line-height: 1.8;
  font-size: 1rem;
}

@keyframes swing {
  0% {
    transform: rotate(-4deg);
  }
  50% {
    transform: rotate(4deg);
  }
  100% {
    transform: rotate(-4deg);
  }
}