/* ===== FONT POPPINS ===== */
@font-face {
  font-family: 'Poppins';
  src: url('fonts/Poppins-Regular.woff2') format('woff2');
  font-weight: 400;
}
@font-face {
  font-family: 'Poppins';
  src: url('fonts/Poppins-Bold.woff2') format('woff2');
  font-weight: 700;
}
@font-face {
  font-family: 'Poppins';
  src: url('fonts/Poppins-Black.woff2') format('woff2');
  font-weight: 900;
}

/* ===== RESET ===== */
* {
  box-sizing: border-box;
}

/* ===== BODY BACKGROUND ===== */
body {
  margin: 0;
  min-height: 100vh;
  font-family: Poppins, sans-serif;

  background:
    repeating-linear-gradient(
      to right,
      rgba(255,255,255,0.3) 0px,
      rgba(255,255,255,0.3) 1px,
      transparent 1px,
      transparent 150px
    ),
    repeating-linear-gradient(
      to bottom,
      rgba(255,255,255,0.3) 0px,
      rgba(255,255,255,0.3) 1px,
      transparent 1px,
      transparent 150px
    ),
    linear-gradient(135deg, #32cd32, #8a2be2);
}

/* ===== LAYOUT ===== */
main {
  height: 100vh;
  display: flex;
  align-items: center;
}

.left {
  background: white;
  width: 40%;
  height: 90vh;
  margin-left: 50px;
  border-radius: 30px;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* ===== TEXT ===== */
.logo {
  height: 100px;
  transform: rotate(180deg);
  margin-bottom: 10px;
}

.titlw {
  margin: 0;
  font-weight: 900;
  font-size: 28px;
}

.textInd {
  font-size: 14px;
  margin: 0 0 30px;
  color: #444;
}

/* ===== FORM ===== */
form {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

/* ===== INPUT WRAPPER ===== */
.input-wrapper {
  width: 80%;
  position: relative;
}

/* ===== INPUT ===== */
.input-wrapper input {
  width: 100%;
  padding: 15px 70px 15px 40px; /* spazio icone sx e dx */
  border-radius: 8px;
  border: 2px solid transparent;
  background: #ada9a33d;
  font-size: 14px;
  transition: border 0.3s, box-shadow 0.3s;
}

.input-wrapper input:focus {
  border-color: #540655;
  box-shadow: 0 0 6px rgba(50, 205, 50, 0.7);
  outline: none;
}

.input-wrapper input::placeholder {
  color: #313131;
}

/* ===== ICONA SINISTRA (se la userai) ===== */
.icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  display: none;
}

/* ===== CHECK ICON ===== */
.check-icon {
  position: absolute;
  right: 40px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  display: none;
}

/* ===== EYE ICON ===== */
.eye-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s, transform 0.2s;
}

.eye-icon:hover {
  opacity: 1;
  transform: translateY(-50%) scale(1.1);
}

/* ===== BUTTON ===== */
button {
  width: 73%;
  margin-top: 20px;
  padding: 12px;
  background: #9b3ad8;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  font-size: 15px;
  transition: background 0.3s, transform 0.2s;
}

button:hover {
  background: #842ec0;
  transform: translateY(-1px);
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* ===== EXTRA ===== */
#formError {
  margin-top: 12px;
  font-size: 14px;
  min-height: 18px;
}

.forgot {
  margin-top: 10px;
  font-size: 13px;
}

.forgot a,
.textInfo a {
  color: #540655;
  text-decoration: underline;
}
@keyframes shake {
  0% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
  100% { transform: translateX(0); }
}

.shake {
  animation: shake 0.35s ease;
}

.input-error {
  border-color: #ed5353 !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .left {
    width: 90%;
    margin: auto;
  }
}
