/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

body {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(135deg, #667eea, #764ba2);
}

/* Container */
.container {
  width: 420px;
  padding: 30px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0px 8px 25px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
}

/* Headings */
h2 {
  text-align: center;
  margin-bottom: 15px;
  font-size: 22px;
  font-weight: 600;
  color: #333;
}
h3 {
  margin-bottom: 15px;
  color: #444;
  font-size: 18px;
  font-weight: 600;
}

/* Form Wrapper */
#loginWrapper, 
#registerWrapper {
  width: 100%;
  animation: fadeSlide 0.6s ease;
}

.anim-in { animation: fadeSlide 0.6s ease; }


.form-card {
  background: #f9f9f9;
  padding: 20px;
  border-radius: 14px;
  box-shadow: 0 5px 12px rgba(0,0,0,0.08);
  transition: transform 0.3s ease;
}
.form-card:hover {
  transform: translateY(-5px);
}

/* Inputs */
input[type="text"],
input[type="password"],
input[type="date"] {
  width: 100%;
  padding: 12px 15px;
  margin: 12px 0;
  border: 2px solid #ddd;
  border-radius: 10px;
  outline: none;
  font-size: 15px;
  transition: all 0.3s ease;
}

input:focus {
  border-color: #667eea;
  box-shadow: 0px 0px 8px rgba(102, 126, 234, 0.4);
}

.password-field {
  position: relative;
  margin: 12px 0;
}

.password-field input[type="password"],
.password-field input[type="text"] {
  margin: 0;
  padding-right: 46px;
}

/* Radio buttons inline */
label input[type="radio"] {
  margin-right: 5px;
}
label {
  font-size: 14px;
  font-weight: 500;
  display: block;
  margin-top: 10px;
}

/* Buttons */
button {
  width: 100%;
  padding: 12px;
  margin-top: 15px;
  background: #667eea;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
}
button:hover {
  background: #764ba2;
  transform: scale(1.05);
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #6372a8;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease;
}

.password-toggle:hover {
  background: rgba(102, 126, 234, 0.14);
  color: #4658ad;
  transform: translateY(-50%);
}

.password-toggle:focus-visible {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  background: rgba(102, 126, 234, 0.18);
}

.password-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.password-toggle .icon-eye-off {
  display: none;
}

.password-toggle.is-visible .icon-eye {
  display: none;
}

.password-toggle.is-visible .icon-eye-off {
  display: block;
}

/* Toggle links */
p {
  text-align: center;
  font-size: 14px;
  margin-top: 15px;
}
p a {
  color: #667eea;
  text-decoration: none;
  font-weight: 600;
}
p a:hover {
  color: #764ba2;
  text-decoration: underline;
}

/* Alerts */
.alert {
  padding: 12px;
  border-radius: 8px;
  margin: 15px 0;
  font-weight: 600;
  text-align: center;
  display: none;
  animation: fadeSlide 0.5s ease;
}
.alert-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}
.alert-error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Animations */
@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(-15px); }
  to { opacity: 1; transform: translateY(0); }
}
