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

/* Body styles for centering and clean layout */
body {
  background-color: #ffffff; /* white background */
  font-family: 'Segoe UI', sans-serif;
  color: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 2rem;
}

/* Container that holds the whole app */
.app {
  text-align: center;
  max-width: 550px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

/* Title styling */
.title {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  color: #e60073;
}

/* Container provides 3D perspective for flip */
.flashcard-container {
  perspective: 1000px;
  width: 100%;
}

/* Main flashcard setup (flip animation happens here) */
.flashcard {
  width: 100%;
  height: 250px;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.8s ease;
  border: 2px solid #e60073;
  border-radius: 20px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  background-color: transparent;
}

/* Both front and back sides of the card */
.flashcard .front,
.flashcard .back {
  position: absolute;
  width: 100%;
  height: 100%;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: 600;
  border-radius: 20px;
  backface-visibility: hidden;
  text-align: center;
  box-sizing: border-box;
}

/* Front of the card: soft pink background with dark text */
.flashcard .front {
  background-color: #ffe6f0;
  color: #1a1a1a;
  z-index: 2;
}

/* Back of the card: deeper pink with white text */
.flashcard .back {
  background-color: #cc0066;
  color: #fff;
  transform: rotateY(180deg);
}

/* Flip the card when .flipped is added */
.flashcard.flipped {
  transform: rotateY(180deg);
}

/* Button section styling */
.controls {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
}

/*  Button styling */
button {
  padding: 0.7rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background-color: #e60073;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
  box-shadow: 0 4px 10px rgba(230, 0, 115, 0.4);
}

button:hover {
  background-color: #cc0066;
  transform: scale(1.05);
}

/*Progress bar*/
.progress-indicator {
  margin-top: 0.5rem;
  font-size: 1rem;
  color: #000000
}


/* Mobile adjustments for smaller screens */
@media (max-width: 480px) {
  body {
    padding: 1rem;
  }

  .title {
    font-size: 1.5rem;
  }

  .flashcard {
    height: 200px;
  }

  button {
    flex: 1;
    font-size: 0.95rem;
    padding: 0.6rem;
  }

  .app {
    gap: 1rem;
  }
}
