:root {
  color-scheme: light;
  --page: #f7f5ef;
  --paper: #fff;
  --ink: #292d2b;
  --muted: #747872;
  --line: #e6e2d8;
  --accent: #d87355;
  --accent-dark: #b9553d;
  --accent-soft: #fff0e8;
  --aqua: #5f9f98;
  --danger: #b64d55;
  --danger-soft: #fff0f1;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }

.login-shell {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr);
}

.welcome {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100%;
  padding: clamp(28px, 5vw, 68px);
  overflow: hidden;
  background: #fff4e8;
}

.welcome::after {
  content: "";
  position: absolute;
  right: clamp(-90px, -6vw, -40px);
  bottom: clamp(-100px, -8vw, -50px);
  width: clamp(260px, 34vw, 520px);
  aspect-ratio: 1;
  border: clamp(42px, 5vw, 76px) solid rgba(216, 115, 85, .08);
  border-radius: 50%;
  pointer-events: none;
}

.brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -.01em;
}

.brand-mark {
  position: relative;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: var(--accent);
  box-shadow: 0 7px 18px rgba(185, 85, 61, .18);
}

.brand-mark i {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fff;
}

.brand-mark i:nth-child(1) { transform: translate(-8px, -7px); }
.brand-mark i:nth-child(2) { transform: translate(0, -10px); }
.brand-mark i:nth-child(3) { transform: translate(8px, -7px); }
.brand-mark i:nth-child(4) { width: 15px; height: 12px; transform: translateY(6px); }

.welcome-copy {
  position: relative;
  z-index: 1;
  max-width: 560px;
  margin: clamp(48px, 10vh, 120px) 0;
}

.eyebrow {
  margin: 0 0 13px;
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.welcome h1 {
  margin: 0;
  max-width: 9ch;
  font-size: clamp(42px, 6vw, 82px);
  line-height: 1.06;
  letter-spacing: -.055em;
}

.welcome-copy > p:last-child {
  max-width: 38ch;
  margin: 24px 0 0;
  color: #656760;
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.8;
}

.pet-note {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  width: fit-content;
  max-width: 100%;
}

.pet-note > span:last-child { display: grid; gap: 4px; }
.pet-note strong { font-size: 14px; }
.pet-note small { color: var(--muted); font-size: 12px; }

.pet-face {
  position: relative;
  display: grid;
  place-items: center;
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  border: 4px solid rgba(255, 255, 255, .9);
  border-radius: 16px;
  background: #f4d9b4;
  box-shadow: 0 8px 22px rgba(91, 71, 45, .1);
}

.pet-face b { position: relative; z-index: 1; font-size: 18px; }
.ear { position: absolute; top: -7px; width: 18px; height: 22px; border-radius: 12px 12px 5px 5px; background: #cf956c; }
.ear.left { left: 2px; transform: rotate(-21deg); }
.ear.right { right: 2px; transform: rotate(21deg); }

.signin {
  display: grid;
  place-items: center;
  padding: clamp(28px, 6vw, 76px);
  background: var(--paper);
}

.signin-inner { width: min(100%, 410px); }

.signin h2 {
  margin: 0;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.12;
  letter-spacing: -.045em;
}

.intro { margin: 13px 0 34px; color: var(--muted); line-height: 1.7; }

form { display: grid; gap: 10px; }

label, .password-label label { font-size: 13px; font-weight: 750; }

.password-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.password-label button {
  min-height: 32px;
  padding: 0 2px;
  border: 0;
  background: transparent;
  color: var(--accent-dark);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: none;
  background: #fcfbf8;
  color: var(--ink);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

input:hover { border-color: #d4cbbc; }
input:focus { border-color: var(--accent); background: #fff; box-shadow: 0 0 0 4px rgba(216, 115, 85, .14); }

.form-message {
  min-height: 22px;
  margin: 2px 0 -2px;
  color: var(--danger);
  font-size: 13px;
  line-height: 1.55;
}

.submit {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  margin-top: 2px;
  padding: 0 18px;
  border: 0;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 10px 24px rgba(185, 85, 61, .2);
  cursor: pointer;
  font-weight: 800;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}

.submit:hover { transform: translateY(-1px); background: var(--accent-dark); box-shadow: 0 12px 28px rgba(185, 85, 61, .25); }
.submit:active { transform: translateY(0); }
.submit:disabled { cursor: wait; opacity: .68; transform: none; box-shadow: none; }

button:focus-visible { outline: 3px solid rgba(95, 159, 152, .45); outline-offset: 3px; }

.security-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 26px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.security-note span { width: 7px; height: 7px; border-radius: 50%; background: var(--aqua); box-shadow: 0 0 0 4px rgba(95, 159, 152, .12); }

@media (max-width: 760px) {
  .login-shell { grid-template-columns: 1fr; }
  .welcome { min-height: auto; padding: 24px 22px 28px; }
  .welcome-copy { margin: 42px 0 32px; }
  .welcome h1 { max-width: 10ch; font-size: clamp(38px, 13vw, 58px); }
  .welcome-copy > p:last-child { margin-top: 18px; font-size: 14px; }
  .signin { place-items: start stretch; padding: 34px 22px 42px; }
  .signin-inner { margin: 0 auto; }
}

@media (max-width: 380px) {
  .welcome { padding-inline: 18px; }
  .signin { padding-inline: 18px; }
  .pet-note small { max-width: 24ch; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
