
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(160deg, #f7f2dc 0%, #f7f2dc 45%, #eaf3df 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 1rem;
}

.login-card {
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  border: 1px solid #d7d2b5;
  text-align: center;
  max-width: 350px;
  width: 100%;
  min-width: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.auth-top {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  margin-bottom: 0.2rem;
}

.icon-btn {
  background: none;
  border: none;
  font-size: 20px;
  color: #005b35;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease;
}

.icon-btn:hover {
  background: rgba(0, 91, 53, .12);
}

.lang-icon-btn {
  border: 1px solid #d7d2b5;
  background: #fff;
}

.logo {
  font-size: 2rem;
  color: #004225;
  font-weight: bold;
  margin-bottom: 1rem;
}

h2 {
  margin-bottom: 1.5rem;
  color: #333;
}

.form-container {
  width: 100%;
  max-width: 300px;
  min-width: 0;
}

form {
  width: 100%;
}

form input {
  width: 100%;
  min-width: 0;
  padding: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 1rem;
}

form input:focus {
  outline: none;
  border-color: #ddd;
  box-shadow: none;
}

.password-wrap {
  position: relative;
  margin-bottom: 1rem;
  width: 100%;
  min-width: 0;
}

.password-wrap input {
  margin-bottom: 0;
  padding-right: 3.1rem;
}

.pw-toggle {
  position: absolute;
  right: 1px;
  top: 1px;
  height: calc(100% - 2px);
  width: 2.65rem;
  border: none;
  border-left: 1px solid #d9d9d9;
  background: #fff;
  border-radius: 0 5px 5px 0;
  padding: 0;
  font-size: 1rem;
  line-height: 1;
  color: #444;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pw-toggle:hover {
  background: rgba(0, 0, 0, 0.03);
}

.pw-toggle i {
  display: block;
  line-height: 1;
  pointer-events: none;
}

.field-hint {
  margin: -0.55rem 0 0.8rem;
  text-align: left;
  color: #666;
  font-size: 0.82rem;
}

.form-error {
  background: #edf5e6;
  border: 1px solid #b9cba8;
  color: #004225;
  border-radius: 6px;
  font-size: 0.9rem;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.9rem;
  text-align: left;
}

.form-success {
  background: #eff8f0;
  border: 1px solid #b6d6bc;
  color: #005b35;
  border-radius: 6px;
  font-size: 0.9rem;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.9rem;
  text-align: left;
}

form button:not(.pw-toggle) {
  width: 100%;
  padding: 0.75rem;
  background: #005b35;
  color: white;
  font-size: 1rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s ease;
}

form button:hover {
  background: #005b35;
}

.signup {
  margin-top: 1rem;
  font-size: 0.9rem;
}

.signup a {
  color: #005b35;
  text-decoration: none;
  font-weight: 700;
}

.signup a:hover {
  text-decoration: underline;
}

.terms-link {
  margin-top: 0.4rem;
  font-size: 0.85rem;
}

.terms-link a {
  color: #666;
  text-decoration: none;
}

.terms-link a:hover {
  text-decoration: underline;
}

.logo {
width: 75%;
height: 75%;
max-width: 240px;
}

.logo img {
width: 100%;
height: 100%;
object-fit: contain;
}

@media (max-width: 480px) {
  .container {
    align-items: flex-start;
    padding: 1rem 0.75rem;
  }

  .login-card {
    padding: 1.35rem 1rem;
    border-radius: 10px;
  }

  .form-container {
    max-width: none;
  }

  h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
  }
}
