:root {
  --bg-color: #f0f0f3;
  --primary-color: #1abc9c; /* Lux green as requested */
  --primary-color-hover: #16a085; /* Slightly darker shade for hover */
  --hero-overlay: rgba(0, 0, 0, 0.35);
  --input-bg: #ecf0f1; /* Refined light blue-gray tone for inputs */
  --light-shadow: #ffffff;
  --dark-shadow: rgba(163, 177, 198, 0.6);
  --font-color: #2c3e50;
}

/* Global Reset and Base Styling */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body, html {
  height: 100%;
  font-family: 'Poppins', sans-serif;
  background: var(--bg-color);
  font-size: 16px;
  color: var(--font-color);
}

/* Container splits the screen into hero & login sections */
.container {
  display: flex;
  height: 100vh;
}

/* Login Section Styling */
.login-container {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.login-box {
  background: var(--bg-color);
  padding: 40px 50px;
  border-radius: 20px;
  width: 100%;
  max-width: 400px;
  box-shadow: 8px 8px 16px var(--dark-shadow), -8px -8px 16px var(--light-shadow);
}

/* Hover lift removed to avoid animated movement */

h2 {
  text-align: center;
  margin-bottom: 25px;
  font-size: 2rem;
  font-weight: 700;
  color: var(--font-color);
}

/* Input Fields with a Light Blue-Gray Tone and Neumorphic Effect */
/* Neumorphic inputs: text, tel, OTP */
input[type="text"],
input[type="tel"],
.otp-input {
  width: 100%;
  padding: 14px;
  margin-bottom: 25px;
  border: none;
  background: var(--input-bg);
  border-radius: 10px;
  box-shadow: inset 4px 4px 8px var(--dark-shadow), inset -4px -4px 8px var(--light-shadow);
  font-size: 1.1rem;
  transition: box-shadow 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
  background-clip: padding-box;
}

input[type="text"]::placeholder,
input[type="tel"]::placeholder {
  color: #7b8a97;
  opacity: 0.95;
}

input[type="text"]:focus,
input[type="tel"]:focus,
.otp-input:focus {
  outline: none;
  box-shadow: inset 2px 2px 4px var(--dark-shadow), inset -2px -2px 4px var(--light-shadow);
}

/* Embossed 3D Button Styling with Lux Green Color */
button {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--primary-color), var(--primary-color-hover));
  color: #fff;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 7px 7px 14px var(--dark-shadow), -7px -7px 14px var(--light-shadow);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  background: linear-gradient(145deg, var(--primary-color-hover), var(--primary-color));
  box-shadow: 5px 5px 10px var(--dark-shadow), -5px -5px 10px var(--light-shadow);
}

button:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* OTP Form Styling */
.otp-message {
  text-align: center;
  margin-bottom: 25px;
  font-size: 1.1rem;
}

.otp-container {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 25px;
}

.otp-container .otp-input {
  width: 60px;
  margin-bottom: 0;
  text-align: center;
  font-size: 1.3rem;
}

.resend-link {
  display: block;
  text-align: center;
  margin-bottom: 25px;
  color: var(--primary-color);
  text-decoration: underline;
  cursor: pointer;
  font-size: 1.1rem;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
  .container {
    flex-direction: column;
  }
  .hero, .login-container {
    flex: none;
    width: 100%;
  }
  .hero {
    height: 40vh;
  }
}

/* Reduce hero height further on mobile so form moves up */
@media (max-width: 576px) {
  /* Preserve full-viewport container so hero stays visible */
  .container {
    height: 100vh !important;
    flex-direction: column !important;
  }

  .hero {
    /* Fix flex so it doesn’t collapse, and set an explicit mobile height */
    flex: none !important;
    height: 45vh !important;      /* adjust this percentage as needed */
    min-height: 150px !important; /* ensures it never disappears */
    background-size: cover !important;
    background-position: top center !important;
  }

  .login-container {
    /* Pull the login box up into the freed space */
    position: relative;
    top: 5vh;                   /* tweak this to control vertical shift */
  }
}

/* Center the loader GIF */
#otp-loader img {
  display: inline-block;
  vertical-align: middle;
}

/* Respect user motion preference */
@media (prefers-reduced-motion: reduce) {
  .login-box,
  button {
    transition: none;
  }
  .login-box:hover,
  button:hover {
    transform: none;
  }
}



/* Password field (neumorphic, matches text inputs) */

.login-box input[type="password"] {
  display: block;
  width: 100%;
  padding: 14px;
  margin-bottom: 25px;
  border: 0;
  border-radius: 10px;
  background: var(--input-bg);
  font-size: 1.1rem;
  -webkit-appearance: none;
  appearance: none;
  background-clip: padding-box;
  box-shadow: inset 4px 4px 8px var(--dark-shadow), inset -4px -4px 8px var(--light-shadow);
  transition: box-shadow 0.2s ease;
}

.login-box input[type="password"]:focus {
  outline: 0;
  box-shadow: inset 2px 2px 4px var(--dark-shadow), inset -2px -2px 4px var(--light-shadow);
}

.login-box input[type="password"]::placeholder {
  color: #7b8a97;
  opacity: 0.95;
}

/* Keep neumorphic look when browser autofills */
.login-box input[type="password"]:-webkit-autofill {
  -webkit-text-fill-color: var(--font-color);
  -webkit-box-shadow: 0 0 0 1000px var(--input-bg) inset, inset 4px 4px 8px var(--dark-shadow), inset -4px -4px 8px var(--light-shadow);
}

.reset-link {
  display: block;
  margin-top: 10px;
  text-align: center;
  color: var(--primary-color);
  text-decoration: underline;
  cursor: pointer;
  font-size: 0.95rem;
}
