/* 로그인 페이지 — Figma log-in / Content Area (674:1373) */

body {
  background: #f0f0f0;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.login-wrapper {
  width: 100%;
  display: flex;
  justify-content: center;
}

.login-phone {
  width: 360px;
  min-height: 780px;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background-color: #ffffff;
  background-image: linear-gradient(180deg, rgba(255, 238, 245, 0) 40%, rgba(255, 238, 245, 0.2) 100%);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.12);
}

/* ── App Bar (Figma 360×56, logo 73×16, padding 16px) ── */
.login-app-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  width: 100%;
  height: 56px;
  padding-left: 16px;
  box-sizing: border-box;
  background: transparent;
}

.login-header-logo {
  display: block;
  height: 16px;
  width: auto;
  max-width: 100%;
}

/* ── login-main (Content Area) ── */
.login-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 40px 16px 0;
  min-height: 0;
}

.login-content {
  width: 328px;
  margin: 0 auto;
}

.login-title {
  margin: 0 0 24px;
  font-family: 'Pretendard', sans-serif;
  font-size: 24px;
  font-weight: 600;
  line-height: 36px;
  text-align: center;
  color: #171a1c;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.login-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Input Field_Form — instance 328×48, inner Text Field */
.login-field {
  position: relative;
  width: 100%;
  height: 48px;
}

.login-field__text-field {
  display: flex;
  align-items: center;
  width: 100%;
  height: 48px;
  padding: 0 12px;
  box-sizing: border-box;
  background: #eef0f2;
  border-radius: 4px;
  border: 1px solid transparent;
  outline: none;
}

.login-field__text-field:focus-within {
  outline: none;
  box-shadow: none;
}

.login-input {
  flex: 1;
  min-width: 0;
  width: 100%;
  height: 100%;
  border: none;
  outline: none;
  box-shadow: none;
  background: transparent;
  font-family: 'Pretendard', sans-serif;
  font-size: 15px;
  font-weight: 400;
  line-height: 22.5px;
  color: #171a1c;
}

.login-input:focus {
  outline: none;
  box-shadow: none;
}

.login-input::placeholder {
  color: #929da5;
}

/* 아이디 — Figma 674:1377(빈) / 674:1477(입력+지우기, Vector 8×8 #929da5) */
.login-field--id .login-field__text-field {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: 0 0 0 12px;
}

.login-field--id .login-input {
  flex: 1;
  min-width: 0;
}

.login-input--id:not(:placeholder-shown) {
  font-weight: 500;
}

.login-field__btn-area--clear,
.login-field__btn-area--password {
  position: static;
  flex-shrink: 0;
}

/* 비밀번호 — closed_eye / open_eye, 24×24 in 48×48 */
.login-field--password .login-field__text-field {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: 0 0 0 12px;
}

.login-field--password .login-input {
  flex: 1;
  min-width: 0;
}

/* 비밀번호 입력값은 브라우저의 기본 password 마스킹으로 표시한다. */
.login-input--password:not(:placeholder-shown) {
  font-weight: 500;
}

.login-field__btn-area {
  position: absolute;
  top: 0;
  right: 0;
  width: 48px;
  height: 48px;
}

.password-toggle,
.login-input-clear {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

/* Figma close_btn.png — 24×24 (클릭 48×48) */
.login-input-clear__icon {
  display: block;
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.password-toggle .icon-eye {
  display: block;
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.password-toggle .icon-eye[hidden] {
  display: none;
}

.remember-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  margin: 0 0 12px;
  cursor: pointer;
}

.remember-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* Checkmark — 미체크(668:1548): Icon fill #ffffff, stroke #cad0d4 / 체크(668:1547): fill #32383d */
.remember-box {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 4px;
  border: 1px solid #cad0d4;
  background-color: #ffffff;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.remember-row input:checked + .remember-box {
  border-color: #32383d;
  background-color: #32383d;
}

.remember-row input:checked + .remember-box::after {
  content: "";
  width: 9px;
  height: 5px;
  border-left: 2px solid #ffffff;
  border-bottom: 2px solid #ffffff;
  transform: rotate(-45deg) translate(1px, -1px);
}

.remember-label {
  font-family: 'Pretendard', sans-serif;
  font-size: 13px;
  font-weight: 500;
  line-height: 19.5px;
  color: #929da5;
}

.remember-row input:checked ~ .remember-label {
  color: #525d65;
}

.form-msg {
  margin: 0;
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  line-height: 1.5;
}

.form-msg.hidden {
  display: none;
}

.form-msg.error {
  display: block;
  font-size: 14px;
  font-weight: 500;
  line-height: 21px;
  color: #f7312b;
}

.form-msg.success {
  color: #32383d;
}

.btn-login {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 4px;
  background: #cad0d4;
  color: #ffffff;
  font-family: 'Pretendard', sans-serif;
  font-size: 15px;
  font-weight: 500;
  line-height: 22.5px;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-login.active {
  background: #32383d;
}

.btn-login.active:hover {
  background: #3a4147;
}

/* Body/03/Medium — 아이디 찾기, 비밀번호 재설정 (Figma 674:1382, 674:1384) */
.login-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  font-family: 'Pretendard', sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 21px;
  color: #8d99a2;
}

.login-links button {
  border: none;
  background: transparent;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
}

.login-links-divider {
  color: #cad0d4;
  font-weight: 400;
  user-select: none;
}

.login-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 16px 70px;
  font-family: 'Pretendard', sans-serif;
  font-size: 14px;
  line-height: 21px;
}

.login-footer-text {
  font-weight: 500;
  color: #171a1c;
}

/* Body/03/Semibold — 계정 만들기 (Figma 674:1387) */
.login-footer-link {
  border: none;
  background: transparent;
  padding: 0;
  font-family: 'Pretendard', sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 21px;
  color: #8d99a2;
  cursor: pointer;
}

.login-footer-link:disabled {
  color: #8d99a2;
  cursor: pointer;
  opacity: 1;
}

.login-safe-area {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 34px;
  pointer-events: none;
}

/* 모바일 로그인 화면은 기기 viewport 전체 너비로 표시 */
@media (max-width: 767px) {
  body {
    background: #ffffff;
  }

  .login-phone {
    width: 100%;
    box-shadow: none;
  }
}
