body {
    margin: 0;
    background: black;
    font-family: sans-serif;
    color: white;
}

.quiz-mode {
    height: 100vh;
    overflow: hidden;
}

.stars {
    position: fixed;
    inset: 0;
    z-index: 0;
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    box-shadow: 0 0 6px white;
    animation: moveStar linear infinite, glow 2s ease-in-out infinite;
}

.hero-screen {
    position: relative;
    height: 100vh;
    width: 100%;
}

.hero-screen h1 {
    position: absolute;
    top: 39%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    overflow: hidden;
    white-space: nowrap;
    color: aliceblue;
    border-right: 3px solid aliceblue;
    font-size: 2rem;
    z-index: 1;
    animation: typing 2s steps(14) forwards, blink 0.5s infinite;
}

.pop-heading {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.5);
    color: aliceblue;
    font-size: 2rem;
    opacity: 0;
    width: auto;
    overflow: visible;
    white-space: normal;
    border-right: none;
    animation: popIn 0.8s ease-out forwards, glowPulse 2s infinite 1s;
}

@keyframes popIn {
    0% { transform: translate(-50%, -50%) scale(0.5); opacity: 0; }
    60% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

@keyframes glowPulse {
  0%,100% { text-shadow: 0 0 5px white; }
  50% { text-shadow: 0 0 20px white; }
}

@keyframes moveStar {
    from {
        transform: translate(-40vw, -20vw);
        opacity: 0;
    }
    10% { opacity: 1; }
    to {
        transform: translate(140vw, 40vw);
        opacity: 0;
    }
}

@keyframes glow {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

@keyframes typing {
    to { width: 15ch; }
}

@keyframes blink {
    50% { border-color: transparent; }
}

.learning-section {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
}

h2 {
    font-size: 2.5rem;
    color: aliceblue;
    margin: 50px 0;
    text-align: center;
}

.main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 80%;
    gap: 2rem;
}

.left {
    border: 1px solid black;
    height: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.right {
    border: 1px solid black;
    height: 300px;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
}

.action-btn {
    padding: 15px 30px;
    font-size: 1.2rem;
    background: transparent;
    color: aliceblue;
    border: 2px solid aliceblue;
    cursor: pointer;
    transition: 0.3s;
}

.action-btn:hover {
    background: aliceblue;
    color: black;
}

.left:hover {
   border-color: aliceblue;
}

.right:hover {
   border-color: aliceblue;
}

.notes-container {
    position: relative;
    z-index: 2; 
    margin-top: 100vh; 
    background-color: rgba(0, 0, 0, 0.8); 
    padding: 50px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.main-images {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr; 
    grid-template-rows: 1fr 1fr 1fr;
    gap: 2rem; 
    width: 80%; 
}

.room {
    border: 1px solid white;
    height: 200px;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    cursor: pointer;
    transition: 0.3s;
}

.room:hover {
    background: white;
    color: black;
}

.quiz-wrapper {
    position: relative;
    z-index: 10; 
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
}

.app-container {
    background: rgba(0, 0, 0, 0.9);
    border: 1px solid white;
    padding: 3rem;
    width: 90%;
    max-width: 600px;
    text-align: center;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.screen h1 {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    border: none;
    animation: none;
    width: auto;
    color: aliceblue;
    margin-bottom: 1rem;
}

.subtitle {
    color: #ccc;
    margin-bottom: 2rem;
}

.btn {
    padding: 15px 30px;
    font-size: 1.1rem;
    background: transparent;
    color: aliceblue;
    border: 1px solid aliceblue;
    cursor: pointer;
    transition: 0.3s;
    margin: 10px;
}

.btn:hover {
    background: aliceblue;
    color: black;
}

.options-grid {
    display: grid;
    grid-template-columns: 1fr; 
    gap: 1rem;
    margin-top: 2rem;
}

.option-btn {
    background: transparent;
    border: 1px solid #555;
    color: white;
    padding: 15px;
    text-align: left;
    cursor: pointer;
    transition: 0.2s;
}

.option-btn:hover {
    border-color: white;
    background: rgba(255,255,255, 0.1);
}

.hud {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    border-bottom: 1px solid #333;
    padding-bottom: 1rem;
}

.hud-item h3 {
    margin: 0;
    color: aliceblue;
}

.label {
    font-size: 0.8rem;
    color: #888;
}

.progress-container {
    height: 4px;
    background: #333;
    width: 100%;
    margin-bottom: 2rem;
}

#progress-bar {
    height: 100%;
    background: aliceblue;
    width: 0%;
    transition: width 0.3s;
}

.hidden {
    display: none;
}

.difficulty-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
    margin: 30px 0;
}

.diff-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid white;
    padding: 20px;
    color: white;
    cursor: pointer;
    transition: 0.3s;
}

.diff-btn:hover {
    transform: translateY(-5px);
    background: white;
    color: black;
}

.diff-btn.easy:hover { border-color: #00ff00; background: #00ff00; }
.diff-btn.medium:hover { border-color: #ffff00; background: #ffff00; }
.diff-btn.hard:hover { border-color: #ff0000; background: #ff0000; color: white; }

.stats-container {
    margin-top: 30px;
    border-top: 1px solid #333;
    padding-top: 20px;
}

#scoreChart {
    max-height: 200px; 
    margin-bottom: 15px;
}

.btn.small {
    font-size: 0.8rem;
    padding: 5px 10px;
    border: 1px solid #555;
    color: #888;
}

@media (max-width: 600px) {
    .difficulty-grid {
        grid-template-columns: 1fr;
    }
}

.nav-bar {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 9999;
}

nav {
  max-width: 1200px;
  margin: auto;
  padding: 12px 20px;
  display: flex;
  justify-content: flex-end;
}

.link {
  display: flex;
  gap: 25px;
}

nav .link a {
  color: white;
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 6px;
  transition: 0.3s ease;
  font-weight: 500;
}

nav .link a:hover {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid white;
}


nav .link a:hover {
  border-color: white;
}

.contact-section {
  padding: 80px 20px;
  background: transparent;
  position: relative;
  z-index: 10;
}

.contact-container {
  max-width: 600px;
  margin: auto;
  text-align: center;
}

.contact-container h2 {
  font-size: 2.2rem;
  margin-bottom: 10px;
}

.contact-subtext {
  font-size: 1rem;
  opacity: 0.85;
  margin-bottom: 40px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.contact-form input,
.contact-form textarea {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  border-radius: 6px;
  outline: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.contact-form button {
  padding: 12px;
  background: white;
  color: black;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: 0.3s ease;
}

.contact-form button:hover {
  background: transparent;
  color: white;
  border: 1px solid white;
}

.contact-info {
  margin-top: 30px;
  font-size: 0.95rem;
  opacity: 0.85;
}

.light-mode {
  background: #474e52;
  color: #1b1b1b;
}


.light-mode .learning-section,
.light-mode .notes-container,
.light-mode .app-container,
.light-mode .contact-section {
  background: rgba(88, 84, 84, 0.55);
  color: #1b1b1b;
  backdrop-filter: blur(6px);
}


.light-mode h1,
.light-mode h2,
.light-mode h3 {
  color: #111;
}


.light-mode .room,
.light-mode .left,
.light-mode .right {
  border: 1px solid #888;
  color: #111;
  background: rgba(255,255,255,0.5);
}

.light-mode .room:hover {
  background: #222;
  color: white;
}


.light-mode .btn,
.light-mode .action-btn,
.light-mode .theme-btn {
  border: 1px solid #222
}
@media (max-width: 768px) {

 
  .hero-screen h1,
  .pop-heading {
    font-size: 1.5rem;
    text-align: center;
    width: auto;
    white-space: normal;
  }

  .link {
    margin-left: 0;
    text-align: center;
  }


  .main {
    grid-template-columns: 1fr;
    width: 95%;
  }

  .left, .right {
    height: 200px;
  }

 
  .main-images {
    grid-template-columns: 1fr 1fr;
    width: 95%;
  }

  .room {
    height: 150px;
    font-size: 1.2rem;
  }

 
  .app-container {
    width: 95%;
    padding: 1.5rem;
  }

  .options-grid {
    grid-template-columns: 1fr;
  }

  
  .contact-container {
    width: 95%;
  }
}
@media (min-width: 769px) and (max-width: 1024px) {

  .main {
    grid-template-columns: 1fr;
    width: 90%;
  }

  .main-images {
    grid-template-columns: 1fr 1fr;
    width: 90%;
  }

  .app-container {
    width: 85%;
  }
}
@media (min-width: 1025px) and (max-width: 1280px) {

  .main {
    width: 85%;
  }

  .main-images {
    grid-template-columns: 1fr 1fr 1fr;
  }
}
@media (max-width: 768px) {
  nav {
    justify-content: center;
  }

  .link {
    gap: 15px;
    flex-wrap: wrap;
  }

  nav .link a {
    padding: 6px 10px;
    font-size: 0.9rem;
  }
}
body {
  padding-top: 70px;
}.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 2rem;
  color: white;         
  opacity: 0.7;
  cursor: pointer;
  text-decoration: none; 
  z-index: 10;
  
  animation: bounce 1.5s infinite;
}

.scroll-indicator:hover {
  opacity: 1;            
}


@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  40% {
    transform: translateX(-50%) translateY(-10px);
  }
  60% {
    transform: translateX(-50%) translateY(-5px);
  }
}
