*,
*::before,
*::after {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

body,
input {
  font-family: "Poppins", sans-serif;
}

body {
  overflow-x: hidden;
}
/* Popup Styles */
.popup {
  display: none; /* Hidden by default */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.popup-content {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  max-width: 400px;
  width: 90%;
}

.popup-content h3 {
  margin: 0 0 10px;
  color: #333;
}

.popup-content p {
  margin: 0 0 20px;
  color: #666;
}

.popup-btn {
  background: #3d5999; /* Green for success */
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
}

.popup-btn:hover {
  background: #3d5888;
}

main {
  width: 100%;
  min-height: 100vh;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  background-image: url("../images/web/background/bgggg.jpg");
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

footer {
  width: 100%;
  position: fixed;
  bottom: 0;
  left: 0;
  padding: 0.5rem 1rem;
  text-align: center;
  color: #151111;
  font-family: "Poppins", sans-serif;
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(5px);
  z-index: 10;
}

footer .footer-content {
  max-width: 1020px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

footer .footer-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

footer .footer-links a {
  color: #151111;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.8rem;
  transition: color 0.3s;
}

footer .footer-links a:hover {
  color: #3a599c;
}

footer p {
  margin: 0.3rem 0 0;
  color: #666;
}

.box {
  position: relative;
  width: 100%;
  max-width: 1020px;
  height: 640px;
  border-radius: 3.3rem;
  background: rgba(255, 255, 255);
  box-shadow: 0 60px 40px -30px rgba(0, 0, 0, 0.27);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  border: 1.5px solid rgba(255, 255, 255, 0.35);
}

.inner-box {
  position: absolute;
  width: calc(100% - 4.1rem);
  height: calc(100% - 4.1rem);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.forms-wrap {
  position: absolute;
  height: 100%;
  width: 45%;
  top: 0;
  left: 0;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  transition: 0.8s ease-in-out;
}

form {
  max-width: 260px;
  width: 100%;
  margin: 0 auto;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  grid-column: 1 / 2;
  grid-row: 1 / 2;
  transition: opacity 0.02s 0.4s;
}

form.sign-up-form {
  opacity: 0;
  pointer-events: none;
}

.logo-section {
  width: 100%;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex-direction: column;
  margin-bottom: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-direction: column;
}

.logo img {
  width: 150px;
  height: auto;
  margin: 0;
}

.logo h4 {
  font-size: 1.1rem;
  margin-top: -9px;
  letter-spacing: -0.5px;
  color: #151111;
}

.heading {
  margin-bottom: 1.5rem;
  text-align: center;
}

.heading h2 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #151111;
}

.heading h6 {
  color: #bababa;
  font-weight: 400;
  font-size: 0.75rem;
  display: inline;
}

.toggle,
.toggle1 {
  color: #151111;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  transition: 0.3s;
  display: block;
  width: 100%;
  text-align: center;
  margin-bottom: 0.5rem;
}

.toggle:hover {
  color: #3a599c;
}

.sign-size {
  color: #151111;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  transition: 0.3s;
}

.input-wrap {
  position: relative;
  height: 35px;
  margin-bottom: 1.5rem;
  width: 100%;
  max-width: 260px;
}

.input-field {
  position: absolute;
  width: 100%;
  height: 100%;
  background: none;
  border: none;
  outline: none;
  border-bottom: 1px solid #bbb;
  padding: 0 5px;
  font-size: 0.95rem;
  color: #151111;
  transition: 0.4s;
}

label {
  position: absolute;
  left: 5px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.95rem;
  color: #bbb;
  pointer-events: none;
  transition: 0.4s;
}

.input-field.active {
  border-bottom-color: #151111;
}

.input-field.active + label {
  font-size: 0.75rem;
  top: -2px;
  left: 0;
}

.sign-btn {
  display: inline-block;
  width: 100%;
  max-width: 260px;
  height: 43px;
  background-color: #151111;
  color: #fff;
  border: none;
  cursor: pointer;
  border-radius: 0.8rem;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 1rem;
  transition: 0.3s;
}

.sign-btn:hover {
  background-color: #3a599c;
}

.social-login {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  margin-top: 1.5rem;
}

.social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 260px;
  height: 43px;
  background-color: #ffffff;
  border-radius: 0.8rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  text-decoration: none;
  font-size: 0.8rem;
  color: #151111;
  transition: background-color 0.3s;
  padding: 0 1rem;
}

.social-btn:hover {
  background-color: #f0f0f0;
}

.social-btn img {
  width: 20px;
  height: 20px;
  margin-right: 0.5rem;
  object-fit: contain;
}

.form-options {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  margin-top: 1.5rem;
  width: 100%;
  max-width: 260px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: #bbb;
  font-family: "Poppins", sans-serif;
  cursor: pointer;
  transition: color 0.3s;
}

.forgot-password {
  color: #151111;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  font-family: "Poppins", sans-serif;
  transition: color 0.3s;
  display: block;
  position: relative;
  left: 100%;
  margin-top: 40px;
  transform: translateX(-100%);
}

.forgot-password:hover {
  color: #8371fd;
}

.text {
  color: #bbb;
  font-size: 0.9rem;
  text-align: center;
}

.text a {
  color: #bbb;
  transition: 0.3s;
}

.text a:hover {
  color: #3a599c;
}

main.sign-up-mode form.sign-in-form {
  opacity: 0;
  pointer-events: none;
}

main.sign-up-mode form.sign-up-form {
  opacity: 1;
  pointer-events: all;
}

main.sign-up-mode .forms-wrap {
  left: 55%;
}

main.sign-up-mode .carousel {
  left: 0%;
}

.carousel {
  position: absolute;
  top: 0;
  left: 45%;
  width: 55%;
  height: 100%;
  backdrop-filter: blur(18px) saturate(180%);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  border: 1.5px solid rgba(255, 255, 255, 0.35);
  border-radius: 2rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.5rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  transition: all 0.8s ease-in-out;
}

.images-wrapper {
  position: relative;
  width: 100%;
  height: 200px;
  border-radius: 1rem;
  overflow: hidden;
}

.image {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.image.show {
  opacity: 1;
  transform: scale(1);
  z-index: 2;
}

.caption-text {
  font-size: 0.9rem;
  color: #180f0f;
  text-align: center;
  font-weight: 500;
  height: 30px;
  margin: 0.5rem 0;
}

.text-slider {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0;
}

.text-wrap {
  max-height: 2.2rem;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.text-group {
  display: flex;
  flex-direction: column;
  transform: translateY(0);
  transition: transform 0.5s ease-in-out;
}

.text-group h2 {
  line-height: 1.4;
  font-size: 1.4rem;
  font-weight: 600;
  color: #070303;
  margin-bottom: 0.5rem;
}

.text-description {
  color: #130d0d;
  font-size: 0.95rem;
  min-height: 3rem;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}

.bullets {
  display: flex;
  justify-content: center;
  gap: 0.3rem;
}

.bullets span {
  width: 0.6rem;
  height: 0.6rem;
  background: #ffffff66;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease-in-out;
}

.bullets span.active {
  width: 1.2rem;
  background: #fff;
  border-radius: 1rem;
}


/* Fix browser autofill background color for input fields */
.input-field:-webkit-autofill,
.input-field:-webkit-autofill:hover,
.input-field:-webkit-autofill:focus,
.input-field:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px transparent inset !important;
  -webkit-text-fill-color: #151111 !important;
  background-color: transparent !important;
  background: transparent !important;
  transition: background-color 5000s ease-in-out 0s !important;
}

/* Firefox autofill */
.input-field:-moz-autofill {
  background-color: transparent !important;
  background: transparent !important;
}

/* Additional safety for all input states */
.input-field:focus {
  background: none !important;
  background-color: transparent !important;
}


/* Large Tablet (769px–1024px) */
@media (max-width: 1024px) and (min-width: 769px) {
  .box {
    max-width: 700px;
    height: 580px;
  }

  .inner-box {
    width: calc(100% - 3rem);
    height: calc(100% - 3rem);
  }

  .carousel {
    padding: 1rem;
  }

  .images-wrapper {
    height: 180px;
  }
}

/* Tablet (481px–768px) */
@media (max-width: 768px) and (min-width: 481px) {
  main {
    padding: 1.5rem;
  }

  .box {
    max-width: 550px;
    height: auto;
    min-height: 700px;
    border-radius: 2rem;
  }

  .inner-box {
    position: static;
    transform: none;
    width: 100%;
    height: auto;
    padding: 2rem;
  }

  .forms-wrap {
    position: static;
    width: 100%;
    height: auto;
    margin-bottom: 2rem;
  }

  form {
    max-width: 400px;
    padding: 1rem;
  }

  .input-wrap {
    max-width: 100%;
  }

  .carousel {
    position: static;
    width: 100%;
    height: 300px;
    margin-top: 1.5rem;
  }

  .images-wrapper {
    height: 180px;
  }

  .text-group h2 {
    font-size: 1.3rem;
  }

  .text-description {
    font-size: 0.9rem;
  }

  .sign-btn,
  .social-btn {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .box {
    max-width: 350px;
    min-height: 550px;
    border-radius: 2rem;
  }

  .forms-wrap {
    width: 100%;
    left: 0;
  }

  form {
    max-width: 260px;
    padding: 0.5rem;
  }

  .carousel {
    display: none; /* Hide carousel on very small screens */
  }

  main.sign-up-mode .forms-wrap {
    left: 0;
  }

  .logo img {
    width: 110px;
  }

  .heading h2 {
    font-size: 1.2rem;
  }

  footer {
    width: calc(100% - 2rem);
    font-size: 0.7rem;
  }
}
@media (max-width: 480px) and (min-width: 230px) {
  footer {
    width: 100%;
    padding: 0.5rem;

    max-width: 100%; /* Limits width on small screens */
  }

  footer .footer-links {
    gap: 0.8rem;
  }

  footer .footer-links a {
    font-size: 0.7rem;
  }

  footer p {
    font-size: 0.7rem;
  }
}
@media (max-width: 230px) {
  footer {
    width: 100%;
    border-radius: 0;
    max-width: 100%;
  }

  footer .footer-links {
    flex-direction: column;
    gap: 0.5rem;
  }
}
