/* CRO Hub login — intentionally small, dependency-free and mobile-first. */
:root {
  --crohub-brand: #843015;
  --crohub-brand-hover: #6f2811;
  --crohub-ink: #292421;
  --crohub-copy: #49423e;
  --crohub-line: #ded6d0;
  --crohub-surface-soft: #f8f5f2;
  --crohub-focus: #005fcc;
}

body.login {
  min-height: 100%;
  color: var(--crohub-copy);
  background:
    radial-gradient(circle at 15% 10%, rgba(169, 59, 29, 0.12), transparent 34rem),
    var(--crohub-surface-soft);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.login #login {
  width: min(400px, calc(100% - 32px));
  padding: clamp(48px, 10vh, 96px) 0 32px;
}

body.login h1 {
  margin-bottom: 22px;
}

body.login h1 a {
  width: auto;
  height: auto;
  margin: 0;
  color: var(--crohub-ink);
  background: none;
  font-size: 0;
  font-weight: 800;
  line-height: 1.1;
  text-indent: 0;
}

body.login h1 a::before {
  content: "CRO Hub";
  font-size: clamp(2rem, 8vw, 2.75rem);
  letter-spacing: -0.035em;
}

body.login form {
  padding: 28px;
  border: 1px solid var(--crohub-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 12px 40px rgba(40, 30, 20, 0.1);
}

body.login label {
  color: var(--crohub-ink);
  font-weight: 650;
}

body.login form .input,
body.login input[type="text"],
body.login input[type="password"] {
  min-height: 48px;
  border: 1px solid #b7aca5;
  border-radius: 9px;
  color: var(--crohub-ink);
  background: #fff;
  box-shadow: none;
  font-size: 1rem;
}

body.login :where(a, button, input, [tabindex]):focus-visible {
  outline: 3px solid var(--crohub-focus) !important;
  outline-offset: 3px !important;
  box-shadow: none !important;
}

body.login .button.wp-hide-pw {
  min-width: 44px;
  min-height: 44px;
  color: var(--crohub-brand);
}

body.login .button-primary {
  min-height: 44px;
  padding: 0 18px;
  border-color: var(--crohub-brand);
  border-radius: 9px;
  color: #fff;
  background: var(--crohub-brand);
  font-weight: 700;
  text-shadow: none;
  box-shadow: none;
}

body.login .button-primary:hover,
body.login .button-primary:focus {
  border-color: var(--crohub-brand-hover);
  background: var(--crohub-brand-hover);
}

body.login #nav,
body.login #backtoblog,
body.login .privacy-policy-page-link {
  padding: 0 4px;
  color: var(--crohub-copy);
}

body.login :where(#nav, #backtoblog, .privacy-policy-page-link) a {
  color: var(--crohub-brand-hover);
  text-underline-offset: 0.16em;
}

body.login .message,
body.login .notice,
body.login #login_error {
  border-radius: 0 10px 10px 0;
  box-shadow: none;
}

/* Replace the large in-card support treatment with the same compact action
   used throughout CRO Hub. Account creation remains in the card. */
body.login .abtb-login-prompt .abtb-support {
  display: none !important;
}

body.login .abtb-support-fab {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 100000;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--crohub-brand);
  border-radius: 999px;
  color: var(--crohub-brand);
  background: #ffffff;
  box-shadow: 0 7px 22px rgba(42, 35, 32, 0.14);
  font: 700 0.8125rem/1.1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-decoration: none;
}

body.login .abtb-support-fab:hover {
  color: #ffffff;
  background: var(--crohub-brand);
}

body.login .abtb-support-fab svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

@media (max-width: 480px) {
  body.login #login {
    padding-top: 32px;
  }

  body.login form {
    padding: 22px 20px;
  }

  body.login .abtb-support-fab {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(12px, env(safe-area-inset-bottom));
    padding: 9px 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.login *,
  body.login *::before,
  body.login *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

@media (forced-colors: active) {
  body.login :where(a, button, input, [tabindex]):focus-visible {
    outline-color: Highlight !important;
  }
}
