/* Quicka client portal: sign-in page. The Quicka website's design, plain CSS. */

:root {
  --navy-900: #062b4e;
  --blue-600: #015aaa;
  --surface: #ffffff;
  --text: #062b4e;
  --text-muted: #59594f;
  --border: #e0e0da;
  --accent: #015aaa;
  --error: #9b1c1c;
  --radius-md: 8px;
  --radius-pill: 999px;
  /* Google Fonts first; if they are blocked, the system's own sans-serif. */
  --font-display: 'Archivo', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial,
    sans-serif;
  --font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial,
    sans-serif;
  --gutter: clamp(1rem, 3vw, 1.75rem);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
}
body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.5;
  color: var(--text);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

/* One column on phones and tablets; brand panel beside the form from 900px. */
.login {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-height: 100vh;
  min-height: 100dvh;
}
@media (min-width: 900px) {
  .login {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  }
}

/* Brand panel */
.login__brand {
  position: relative;
  display: flex;
  align-items: flex-end;
  /* The top padding leaves room for "Back to site", so the logo never runs under it. */
  padding: calc(var(--gutter) + 2.75rem + 1.5rem) clamp(1.5rem, 5vw, 4rem) clamp(1.5rem, 5vw, 4rem);
  background: var(--navy-900);
  color: #fff;
  overflow: hidden;
}
.login__brand::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(98, 171, 66, 0.22), transparent 60%),
    linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.35));
  pointer-events: none;
}
.login__brand-inner {
  position: relative;
  z-index: 1;
  min-width: 0;
}
.login__logo {
  display: block;
  width: auto;
  height: clamp(4rem, 12vw, 7rem);
  max-width: 100%;
}
.login__brand-line {
  margin: 0.5rem 0 0;
  color: rgba(255, 255, 255, 0.8);
  max-width: 24ch;
}

/* "Back to site": a link, top left, above the brand wash. 44px target. */
.login__back {
  position: absolute;
  top: var(--gutter);
  left: var(--gutter);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-pill);
  background: rgba(0, 0, 0, 0.22);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
}
.login__back:hover {
  background: rgba(0, 0, 0, 0.38);
  border-color: rgba(255, 255, 255, 0.55);
}
.login__back-arrow {
  flex: none;
  display: block;
}

/* Form side */
.login__form-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 5vw, 4rem) clamp(1rem, 5vw, 4rem);
}
.login__form-wrap {
  width: 100%;
  max-width: 24rem;
}
.login__eyebrow {
  margin: 0;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
  font-weight: 600;
}
.login__title {
  margin: 0.5rem 0 0;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.1;
}
.login__sub {
  margin: 0.5rem 0 0;
  color: var(--text-muted);
}
.login__error {
  margin: 1.5rem 0 0;
  padding: 0.75rem 1rem;
  border-left: 4px solid var(--error);
  border-radius: var(--radius-md);
  background: rgba(155, 28, 28, 0.08);
  color: var(--error);
  font-size: 0.875rem;
  font-weight: 600;
}
.login__form {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.login__field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.login__field label {
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}
.login__field input {
  width: 100%;
  min-height: 3rem;
  padding: 0 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  font: inherit;
}
.login__submit {
  width: 100%;
  min-height: 3rem;
  padding: 0 1.25rem;
  border: none;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: var(--surface);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.login__row {
  margin: 1rem 0 0;
  font-size: 0.875rem;
}
.login__link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}
.login__link:hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
.login__foot {
  width: 100%;
  max-width: 24rem;
  margin: 2.5rem 0 0;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.25rem;
  font-size: 0.8125rem;
}
.login__foot a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--text-muted);
  text-decoration: none;
}
.login__foot a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* Keyboard focus, visible on both backgrounds. */
.login__field input:focus-visible,
.login__submit:focus-visible,
.login__link:focus-visible,
.login__foot a:focus-visible {
  outline: 3px solid var(--blue-600);
  outline-offset: 2px;
}
.login__back:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 2px;
}
