/* LEMLIN look for Rakazo's sign-in, sign-up and password pages, in the style of video.lemlin.com:
   a white card on a light grey page, the brand top left, a big bold headline, soft grey fields,
   an ink-black button, and a live panel on the right. Only applies when skin.js has marked the
   page (html.lemlin-auth), so the rest of Rakazo is untouched. */
html.lemlin-auth {
  --lemlin-page: #f7f7f8;
  --lemlin-card: #ffffff;
  --lemlin-ink: #09090b;
  --lemlin-ink-2: #27272a;
  --lemlin-muted: #71717a;
  --lemlin-line: #e4e4e7;
  --lemlin-field: #fafafa;
  color-scheme: light;
}

html.lemlin-auth body,
html.lemlin-auth #root {
  background: var(--lemlin-page) !important;
}

html.lemlin-auth .lemlin-auth-page {
  background: var(--lemlin-page) !important;
  color: var(--lemlin-ink) !important;
  min-height: 100vh;
  padding: 32px max(16px, env(safe-area-inset-left, 0px)) !important;
  font-family: -apple-system, system-ui, "SF Pro Text", Inter, "Segoe UI", Roboto, sans-serif;
}

html.lemlin-auth .lemlin-auth-form {
  position: relative;
  width: min(1000px, 100%) !important;
  min-height: 600px;
  align-items: stretch !important;
  justify-content: center;
  background: var(--lemlin-card);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 28px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 24px 64px -16px rgba(9, 9, 11, 0.18), 0 48px 120px -48px rgba(9, 9, 11, 0.22);
  padding: 120px calc(46% + 40px) 56px 56px;
  color: var(--lemlin-ink);
}

/* Brand lockup, top left. */
html.lemlin-auth .lemlin-auth-form::before {
  content: "";
  position: absolute;
  top: 44px;
  left: 56px;
  width: 260px;
  height: 40px;
  background: url("/skin/brand.svg") no-repeat left center / contain;
}

/* Live panel, right half. */
html.lemlin-auth .lemlin-auth-form::after {
  content: "";
  position: absolute;
  top: 16px;
  right: 16px;
  bottom: 16px;
  width: 44%;
  border-radius: 20px;
  background: #0f1726 url("/skin/panel.svg") no-repeat center / cover;
}

/* Rakazo's round logo is replaced by the brand lockup. */
html.lemlin-auth .lemlin-auth-form > div:first-child:has(> span) {
  display: none !important;
}

html.lemlin-auth .lemlin-auth-form h1 {
  margin: 0 0 28px !important;
  font-size: 36px !important;
  line-height: 1.1 !important;
  font-weight: 700 !important;
  letter-spacing: -0.03em !important;
  text-align: left !important;
  color: var(--lemlin-ink) !important;
  text-wrap: balance;
}

html.lemlin-auth .lemlin-auth-form h1::after {
  content: "Bots with their own computer, memory and routines. Sign in to see what they are doing.";
  display: block;
  margin-top: 12px;
  font-size: 15px;
  line-height: 1.5;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--lemlin-muted);
}

html.lemlin-auth[data-lemlin-mode="signup"] .lemlin-auth-form h1::after {
  content: "Your own AI team, each bot with its own computer, memory and routines.";
}

html.lemlin-auth[data-lemlin-mode="forgotpassword"] .lemlin-auth-form h1::after,
html.lemlin-auth[data-lemlin-mode="resetpassword"] .lemlin-auth-form h1::after {
  content: "";
  margin: 0;
}

html.lemlin-auth .lemlin-auth-form label {
  color: var(--lemlin-ink-2) !important;
  font-size: 13px !important;
  font-weight: 600 !important;
}

html.lemlin-auth .lemlin-auth-form input:not([type="checkbox"]):not([type="radio"]) {
  background: var(--lemlin-field) !important;
  border: 1px solid var(--lemlin-line) !important;
  border-radius: 12px !important;
  color: var(--lemlin-ink) !important;
  font-size: 15px !important;
  min-height: 48px;
  box-shadow: none !important;
}

html.lemlin-auth .lemlin-auth-form input:focus-visible {
  outline: 2px solid var(--lemlin-ink) !important;
  outline-offset: 1px;
}

html.lemlin-auth .lemlin-auth-form button[type="submit"] {
  background: var(--lemlin-ink) !important;
  color: #ffffff !important;
  border-radius: 12px !important;
  min-height: 48px;
  font-size: 15px !important;
  font-weight: 600 !important;
  border: 0 !important;
}

html.lemlin-auth .lemlin-auth-form button:not([type="submit"]) {
  border-radius: 12px !important;
}

html.lemlin-auth .lemlin-auth-form a {
  color: var(--lemlin-ink-2) !important;
}

@media (max-width: 860px) {
  html.lemlin-auth .lemlin-auth-form {
    padding: 104px 24px 32px;
    min-height: 0;
  }
  html.lemlin-auth .lemlin-auth-form::before {
    left: 24px;
    top: 32px;
  }
  html.lemlin-auth .lemlin-auth-form::after {
    display: none;
  }
  html.lemlin-auth .lemlin-auth-form h1 {
    font-size: 30px !important;
  }
}
