html {
  overflow-y: scroll;
}

body {
  margin: 0;
  background: #402352;
  font-family: "Poppins", sans-serif;
  color:white;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}
.container {
  width: 90%;
  max-width: 1000px;
  margin: auto;
}

#top-banner {
  background: rgba(0,0,0,0.2);
  border-bottom: 4px solid #ffd43b;
  padding: 30px 0;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-title {
  margin: 0;
  color: white;
  font-size: 1.8rem;
}

.nav {
  display: flex;
  gap: 15px;
}

.nav .nav-link {
  padding: 8px 14px;
  background: #ffd43b;
  color: #000000;
  text-decoration: none;
  border-radius: 8px;
  transition: 0.3s;
}

.nav .nav-link:hover {
  background: #9c67ba;
  color:white;
}
.page-intro {
  color:#ffffff;
  text-align: center;
  padding: 30px 20px;
}

.card-row {
  display: flex;
  gap: 20px;
  margin: 40px auto;
}

.card {
  flex: 1;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.3s, box-shadow 0.3s;
}

.card img {
  width: 100%;
  aspect-ratio: 3/4; 
  object-fit: cover;
  border-radius: 8px;
  border: 3px solid #2c1c00;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.3);
}

button.btn,
.movie-search button {
  background: #8b6cae;
  color: #000000;
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
}

button.btn:hover,
.movie-search button:hover{
  background: #402352;
  color: #ffffff;
  transform: scale(1.05);
}

.gallery-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
  width: 90%;
  max-width: 1000px;
  margin: 40px auto;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 1/1; 
  object-fit: cover;
  border: 3px solid #fdd835;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  display: block;
  transition: transform 0.3s;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.6);
  color: white;
  text-align: center;
  padding: 8px;
  opacity: 0;
  transition: opacity 0.3s;
}

.gallery-item:hover .caption {
  opacity: 1;
}

.site-footer {
  background: rgba(0,0,0,0.2);
  border-top:  4px solid #ffd43b;
  padding: 15px 0;
  text-align: center;
  color: #fff4d9;
}

.interactive-section {
  display: flex;
  justify-content: space-around;
  align-items: center;
  margin: 40px auto;
  padding: 20px;
  background: rgba(255,255,255,0.15);
  border-radius: 12px;
  text-align: center;
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

#colorBtn {
  background-color: #8b6cae;
  color: rgb(0, 0, 0);
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.2s;
}

#colorBtn:hover {
  background-color: #402352;
  color:white;
  transform: scale(1.05);
}

#dateTime {
  color: #f5e6ff;
  font-size: 1rem;
  background: rgba(0,0,0,0.3);
  padding: 10px 15px;
  border-radius: 8px;
  display: inline-block;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.faq-section {
  margin: 40px auto;
  padding: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: #ffffff;
}

.faq-item {
  cursor: pointer;
  border-radius: 8px;
  overflow: hidden;
  transition:0.4s ease;
}

.faq-question {
  background: #8b6cae;
  color:#000;
  padding: 10px;
  border-radius: 8px;
  margin: 0;
  transition:0.4s ease;
}

.faq-question:hover {
  background: #402352;
  color: #fff4d9;
}

.faq-answer {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  margin-top: 8px;
  transition: 0.3s ease;
}

.faq-item.active .faq-answer {
  max-height: 300px; 
  opacity: 1;
  padding: 12px;
}

.popup {
  display: none;
  position: fixed;
  z-index: 10;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
}

.popup-content {
  background-color: #fff4d9;
  margin: 8% auto;
  padding: 30px;
  border-radius: 12px;
  width: 90%;
  max-width: 400px;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
  color: #2c1c00;
  position: relative;
}

.popup-content h2 {
  text-align: center;
  margin-bottom: 15px;
  color: #402352;
}

.popup-content label {
  display: block;
  margin-top: 10px;
}

.popup-content input {
  width: 100%;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid #ccc;
  margin-top: 5px;
}

.popup-content .btn {
  width: 100%;
  margin-top: 15px;
  background-color: #8b6cae;
  color: white;
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  cursor: pointer;
  color: #2c1c00;
}

.error {
  color: red;
  font-size: 0.85rem;
}

.rating-section {
  text-align: center;
  background: rgba(255,255,255,0.1);
  padding: 20px;
  border-radius: 12px;
  color: #ffffff;
  margin: 40px auto;
  box-shadow: 0 0 15px rgba(0,0,0,0.3);
}

.star-rating {
  display: flex;
  justify-content: center;
  gap: 8px;
  font-size: 2rem;
  margin-top: 10px;
}

.star {
  cursor: pointer;
  color: #d3c3ff;
  transition: transform 0.3s, color 0.3s;
}

.star:hover {
  transform: scale(1.2);
  color: #ffcf61;
}

.star.selected {
  color: #ffcf61;
}

.rating-result {
  margin-top: 15px;
  font-weight: bold;
  color: #fff4d9;
}

.dynamic-message #wonkaMessage {
  font-size: 1rem;
  padding: 10px;
  border-radius: 8px;
  color: #2c1c00;;
}

.time-display-section {
  text-align: center;
  color:white;
  margin: 30px auto;
  padding: 20px;
  background: rgba(255,255,255,0.15);
  border-radius: 12px;
  width: 90%;
  max-width: 500px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

#timeDisplay {
  margin-top: 10px;
  color: #fff4d9;
  font-size: 1.2rem;
  background: rgba(0,0,0,0.3);
  padding: 7px;
  border-radius: 8px;
  display: inline-block;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.nav-item:focus {
  outline: none;
  box-shadow: 0 0 8px 2px #a36fffaa;
  background: linear-gradient(135deg, #b47cff, #7b42f6);
  color: white !important;
  transform: scale(1.03);
  transition: all 0.2s;
}

.multi-step-form {
  background: rgba(255,255,255,0.15);
  padding: 25px;
  margin: 50px auto;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  color: #ffffff;
  text-align: center;
}

.multi-step-form h2 {
  color: #ffffff;
  margin-bottom: 15px;
}

.form-step {
  display: none;
  flex-direction: column;
  align-items: center;
}

.form-step.active {
  display: flex;
}

.form-step input,
.form-step textarea {
  width: 80%;
  margin: 10px 0;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid #ccc;
}

.btn-group {
  display: flex;
  gap: 10px;
}

.nextBtn, .backBtn {
  background: #8b6cae;
  color: rgb(0, 0, 0);
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s;
}

.nextBtn:hover, .backBtn:hover {
  background: #402352;
  color:white;
}


.greeting-message {
  font-size: 1.4rem;
  font-weight: 500;
  color: #ffffff;
  margin-top: 10px;
  transition: color 0.3s ease, opacity 0.5s ease;
}

.gallery-search {
  text-align: center;
  margin-bottom: 20px;
}

#gallerySearch {
  width: 60%;
  padding: 10px 15px;
  border-radius: 25px;
  border: 2px solid #fdd835;
  background-color: #2e1a47;
  color: #fff;
  font-size: 16px;
  transition: all 0.3s ease;
}

#gallerySearch::placeholder {
  color: #ccc;
}

#gallerySearch:focus {
  outline: none;
  border-color: #ffb347;
  box-shadow: 0 0 10px #ffb347;
}


.faq-search {
  position: relative;
  width: 300px;
  margin: 20px 0;
}

#faqSearch {
  width: 100%;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid #ccc;
}

#suggestions {
  position: absolute;
  background: white;
  color:#000;
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
  border: 1px solid #ccc;
  border-top: none;
  z-index: 1000;
  max-height: 150px;
  overflow-y: auto;
}

#suggestions li {
  padding: 8px;
  cursor: pointer;
}

#suggestions li:hover {
  background-color: #f0f0f0;
}


.highlight {
  background-color: #ffffff;
  color:#8b6cae;
}


#scrollBar {
  position: fixed;
  top: 0;
  left: 0;
  height: 8px;
  width: 0%;
  background: linear-gradient(90deg, #ff8c00, #ff4d4d, #ff66cc, #cc66ff, #66ccff);
  background-size: 400% 100%;
  animation: gradientMove 4s infinite linear;
  border-radius: 0 10px 10px 0;
  z-index: 9999;
  transition: width 0.2s ease;
}


@keyframes gradientMove {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}


@media (max-width: 992px) {

  .container {
    flex-direction: column;
  }

 
  .nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }
}


@media (max-width: 600px) {

  .nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
    gap: 10px;
  }

  .card {
    width: 100%;
    margin-bottom: 15px;
  }

  .time-box {
    width: 100%;
  }
}

.gallery-container {
  display: grid;
  gap: 15px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}


@media (max-width: 992px) {
  .gallery-container {
    grid-template-columns: repeat(3, 1fr);
  }
}


@media (max-width: 600px) {
  .gallery-container {
    grid-template-columns: repeat(1, 1fr);
  }
}


body.light-mode {
  background: #EAD7DC;
  color: #450d0d;
}

body.light-mode #top-banner,
body.light-mode .site-footer {
  background: #C794A2;
  color: #000000;
}

body.light-mode .site-title{
  color:#450d0d;
}

body.light-mode .card {
  background: #f2dbe2;
  color: #000000;
}

body.light-mode .faq-section,
body.light-mode .multi-step-form,
body.light-mode .rating-section,
body.light-mode .interactive-section,
body.light-mode .time-display-section {
  background: rgba(255,255,255,0.1);
  color: #000000;
}

body.light-mode .btn {
  background-color: #C794A2;
  color: #000000;
}

body.light-mode .btn:hover {
  background-color: #B26C7F;
  color: #000000;
}

body.light-mode #colorBtn ,
body.light-mode .nextBtn,
body.light-mode .backBtn{
  background-color: #C794A2;
  color: #000000;
}

body.light-mode #colorBtn:hover,
body.light-mode .nextBtn:hover,
body.light-mode .backBtn:hover {
  background-color: #B26C7F;
  color: #000000;
}

body.light-mode #gallerySearch,
body.light-mode .faq-question{
  background: #C794A2;
}

body.light-mode #gallerySearch::placeholder{
  color:#000;
}

body.light-mode .popup-content h2,
body.light-mode .popup-content {
  background-color: #ffffff;
  color: rgb(0, 0, 0);
}

body.light-mode .page-intro,
body.light-mode .text-form,
body.light-mode .dynamic-message #wonkaMessage,
body.light-mode .page-intro .greeting-message,
body.light-mode .rating-result {
  color: #450d0d;
}

.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.7);
}
.modal-content {
  background-color: #8b79a8;
  color: #000;
  margin: 10% auto;
  padding: 20px;
  width: 80%;
  max-width: 500px;
  border-radius: 10px;
  text-align: center;
}
.modal .close {
  float: right;
  font-size: 24px;
  cursor: pointer;
}
body.light-mode .modal-content {
  background: #2e2e3f;
  color: #fff;
}


.theme-toggle {
  position: fixed;
  top: 400px;
  right: 0px; 
  z-index: 1000;
}

.toggle-label {
  display: inline-block;
  width: 60px;
  height: 30px;
  background-color: #222;
  border-radius: 30px;
  position: relative;
  cursor: pointer;
  transition: background-color 0.3s;
}

.toggle-label::before {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  left: 2px;
  top: 2px;
  background-color: #fff;
  border-radius: 50%;
  transition: transform 0.4s;
}

#themeToggle {
  display: none;
}

#themeToggle:checked + .toggle-label {
  background-color: #f1c40f;
}

#themeToggle:checked + .toggle-label::before {
  transform: translateX(30px);
}
.movie-search {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 20px;
}

.movie-search input {
  padding: 8px 12px;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  width: 61%;
}

.movie-results {
  display: grid;
  max-width: 1050px; 
  margin: 40px auto;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 15px;
  padding: 20px;
}

.movie-card {
  background: rgba(255, 255, 255, 0.1);
  color:white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  text-align: center;
  padding: 10px;
}

.movie-card img {
  width: 100%;
  height: 270px;
  object-fit: cover;
  border-radius: 10px;
}

input.invalid, textarea.invalid {
  border: 2px solid red;
}