/* Sign in */

.auth-page { min-height: 100vh; }

.auth {
  display: grid;
  place-items: center;
  min-height: calc(100vh - var(--header));
  padding: clamp(1.5rem, 4vw, 3rem) 0;
}

.auth-card {
  width: min(1040px, 100%);
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  border-radius: 30px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.auth-card-single { width: min(520px, 100%); grid-template-columns: 1fr; }
.auth-card-single .pill { margin: 0; }
.auth-field small { color: var(--muted); font-weight: 500; }
.auth-field > small { font-size: 0.78rem; line-height: 1.45; }
.auth-field input.is-locked {
  cursor: not-allowed;
  opacity: 0.85;
  padding-right: 2.6rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239b6bff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3Cpath d='M8 11V7a4 4 0 0 1 8 0v4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.95rem center;
  background-size: 1.05rem;
}
.auth-field input.is-locked:focus { box-shadow: none; }

/* Side panel */

.auth-side {
  display: grid;
  align-content: start;
  gap: 1.1rem;
  padding: clamp(1.8rem, 4vw, 3rem);
  background: var(--cta-bg);
}

.auth-side .pill { margin: 0; }

.auth-side h1 {
  font-size: clamp(2rem, 3.6vw, 2.9rem);
  font-weight: 800;
}

.auth-side > p { color: var(--muted); max-width: 26rem; }

[data-theme="light"] .auth-side { color: #fff; }
[data-theme="light"] .auth-side > p { color: rgba(255, 255, 255, 0.86); }
[data-theme="light"] .auth-side .pill {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.status-mock {
  margin-top: 0.6rem;
  padding: 1.1rem;
  border-radius: 20px;
  background: #0c0c16;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e8e8f4;
  box-shadow: 0 20px 50px rgba(20, 10, 80, 0.35);
}

.status-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  font-size: 0.92rem;
}

.status-head span {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: rgba(46, 230, 197, 0.15);
  color: #2ee6c5;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}

.status-bar {
  height: 7px;
  margin: 0.9rem 0 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.status-bar i {
  display: block;
  width: var(--w);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8b7bff, #5b8cff, #2ee6c5);
}

.status-mock ul { display: grid; gap: 0.55rem; }

.status-mock li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: #8e8ea8;
  font-size: 0.85rem;
}

.status-mock li::before {
  content: "";
  width: 16px;
  height: 16px;
  flex: none;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
}

.status-mock li.is-done { color: #e8e8f4; }

.status-mock li.is-done::before {
  border-color: transparent;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m5 10.5 3.2 3.2L15 7' fill='none' stroke='%23052a24' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 11px no-repeat,
    #2ee6c5;
}

.status-mock li.is-active { color: #fff; font-weight: 600; }

.status-mock li.is-active::before {
  border-color: #9b8cff;
  box-shadow: inset 0 0 0 3px #0c0c16, inset 0 0 0 8px #9b8cff;
}

.auth-perks { display: grid; gap: 0.5rem; font-size: 0.92rem; }

.auth-perks li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.auth-perks li::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--cyan);
}

[data-theme="light"] .auth-perks li::before { background: #fff; }

/* Form */

.auth-main {
  display: grid;
  align-items: center;
  padding: clamp(1.8rem, 4vw, 3rem);
}

.auth-form { display: grid; gap: 1.1rem; }

.auth-form h2 { font-size: clamp(1.9rem, 3vw, 2.4rem); font-weight: 800; }

.auth-sub { margin-top: -0.6rem; color: var(--muted); }

.auth-field { display: grid; gap: 0.5rem; font-size: 0.92rem; font-weight: 600; }

.auth-label-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.auth-label-row a,
.auth-alt a {
  color: var(--violet);
  font-weight: 600;
  text-decoration: none;
}

.auth-label-row a:hover,
.auth-alt a:hover { text-decoration: underline; }

.auth-label-row a { font-size: 0.85rem; }

.auth-field input[aria-invalid="true"] {
  border-color: #ff6b8a;
  box-shadow: 0 0 0 4px rgba(255, 107, 138, 0.15);
}

.password-wrap { position: relative; display: block; }
.password-wrap input { padding-right: 3.2rem; }

.password-toggle {
  position: absolute;
  top: 50%;
  right: 0.4rem;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  transform: translateY(-50%);
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.password-toggle:hover,
.password-toggle[aria-pressed="true"] { color: var(--violet); background: var(--surface-2); }

.password-toggle:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }

.remember {
  position: relative;
  display: flex;
  width: fit-content;
  cursor: pointer;
  font-size: 0.9rem;
}

.remember input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  min-height: 0;
}

.remember span { display: flex; align-items: center; gap: 0.6rem; }

.remember span::before {
  content: "";
  width: 20px;
  height: 20px;
  flex: none;
  border-radius: 6px;
  border: 1.5px solid var(--line-strong);
  background: var(--input-bg);
}

.remember input:checked + span::before {
  border-color: transparent;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m5 10.5 3.2 3.2L15 7' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 13px no-repeat,
    var(--btn-bg);
}

.remember input:focus-visible + span::before { outline: 2px solid var(--cyan); outline-offset: 3px; }

.auth-message {
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  background: rgba(255, 107, 138, 0.12);
  color: #ff8aa3;
}

.auth-message.is-info { background: var(--pill-bg); color: var(--pill-text); }

[data-theme="light"] .auth-message:not(.is-info) { color: #c81e4a; background: rgba(200, 30, 74, 0.08); }

.auth-message[hidden] { display: none; }

.btn[disabled] { opacity: 0.75; cursor: progress; transform: none; }

.auth-alt {
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
}

@media (max-width: 860px) {
  .auth-card { grid-template-columns: 1fr; }
  .auth-main { order: -1; }
  .status-mock, .auth-perks { display: none; }
}

@media (max-width: 640px) {
  .header-end .btn span { display: none; }
  .header-end .btn { width: 44px; padding: 0; }
  .auth-card { border-radius: 22px; }
}
