/* AURORA registration: compact card on desktop, fully scrollable on phones. */
html, body { min-height:100%; }
body.registration-open {
  position:relative !important; inset:auto !important;
  width:100% !important; height:auto !important; min-height:100vh !important; min-height:100dvh !important;
  overflow-x:hidden !important; overflow-y:auto !important; overscroll-behavior-y:contain !important;
  touch-action:pan-y !important;
}
body.registration-open .topbar { position:relative !important; }
body.registration-open .shell {
  display:block !important; width:min(calc(100% - 24px), 480px) !important; max-width:480px !important;
  height:auto !important; min-height:0 !important; margin:22px auto 32px !important;
  padding:0 0 28px !important; overflow:visible !important;
}
body.registration-open #login-view,
body.registration-open .login-wrap {
  display:block !important; width:100% !important; height:auto !important; min-height:0 !important;
  max-height:none !important; margin:0 !important; padding:0 !important; overflow:visible !important;
}
body.registration-open #login-view .login-card {
  display:block !important; position:relative !important; width:100% !important; max-width:480px !important;
  min-width:0 !important; height:auto !important; min-height:0 !important; max-height:none !important;
  margin:0 auto !important; padding:clamp(18px, 4vw, 26px) !important; overflow:visible !important;
  border:1px solid rgba(177,202,255,.3) !important; border-radius:20px !important;
  box-shadow:0 18px 55px rgba(0,0,0,.28) !important;
}
body.registration-open .aurora-brand-lockup,
body.registration-open #login-form,
body.registration-open #password-reset-form,
body.registration-open #first-password-form,
body.registration-open #owner-register-entry,
body.registration-open #freelancer-register-entry { display:none !important; }
body.registration-open #register-form:not(.hidden),
body.registration-open #freelancer-register-form:not(.hidden) {
  display:grid !important; grid-template-columns:minmax(0,1fr) !important; gap:13px !important;
  width:100% !important; max-width:100% !important; min-width:0 !important;
  margin:0 !important; padding:0 !important; overflow:visible !important; align-content:start !important;
}
body.registration-open #register-form .eyebrow,
body.registration-open #freelancer-register-form .eyebrow { margin:0 0 2px !important; line-height:1.4; }
body.registration-open #owner-signup-fields,
body.registration-open #register-fields { display:grid; grid-template-columns:minmax(0,1fr); gap:12px; min-width:0; }
body.registration-open #register-form label,
body.registration-open #freelancer-register-form label {
  display:grid !important; grid-template-columns:minmax(0,1fr) !important; gap:6px !important;
  width:100% !important; min-width:0 !important; margin:0 !important; font-size:13px !important;
  line-height:1.4 !important; font-weight:650 !important; overflow-wrap:anywhere;
}
body.registration-open #register-form input:not([type=checkbox]),
body.registration-open #freelancer-register-form input:not([type=checkbox]) {
  display:block !important; box-sizing:border-box !important; width:100% !important; min-width:0 !important;
  min-height:46px !important; margin:0 !important; padding:10px 12px !important;
  border:1px solid #cbd5e1 !important; border-radius:10px !important; background:#fff !important;
  color:#172033 !important; font:inherit !important; font-size:16px !important;
}
body.registration-open #register-form input[type=file],
body.registration-open #freelancer-register-form input[type=file] {
  min-height:48px !important; padding:8px !important; font-size:13px !important;
  border:1px dashed #91a8c4 !important; background:#f8fbff !important;
}
body.registration-open #register-form input:focus,
body.registration-open #freelancer-register-form input:focus { outline:3px solid rgba(55,145,220,.2) !important; border-color:#2786c5 !important; }
body.registration-open #register-form input[type=checkbox],
body.registration-open #freelancer-register-form input[type=checkbox] { width:18px !important; height:18px !important; min-height:18px !important; }
body.registration-open #register-form label.aurora-policy-consent { display:flex !important; align-items:flex-start !important; gap:9px !important; font-size:12px !important; }
body.registration-open .aurora-policy-consent input { flex:0 0 18px; margin-top:2px !important; }
body.registration-open #register-form .btn,
body.registration-open #freelancer-register-form .btn { width:100% !important; min-height:48px !important; white-space:normal; }
body.registration-open .registration-sticky-footer {
  position:static !important; display:flex !important; flex-wrap:wrap !important; justify-content:center !important;
  align-items:center !important; gap:8px !important; width:100% !important; padding:14px 0 0 !important;
  background:transparent !important; border:0 !important;
}
body.registration-open .registration-back-button { min-height:40px; padding:8px 12px; }
body.registration-open #signup-otp-panel { display:grid; gap:10px; min-width:0; }
body.registration-open #signup-otp-panel.hidden,
body.registration-open .hidden,
body.registration-open [hidden] { display:none !important; }
body.registration-open #register-error,
body.registration-open #signup-otp-message,
body.registration-open #freelancer-register-message { overflow-wrap:anywhere; }
body.registration-open #aurora-policy-center { display:block !important; width:100% !important; max-width:480px !important; margin:14px auto 0 !important; }
@media (max-width:360px) {
  body.registration-open .shell { width:calc(100% - 16px) !important; margin-top:12px !important; }
  body.registration-open #login-view .login-card { padding:15px !important; border-radius:15px !important; }
}

/* AURORA responsive registration hardening: use a real viewport-sized scroll
   container and prevent long labels, file names, and controls from widening it. */
html { -webkit-text-size-adjust:100%; text-size-adjust:100%; }
body.registration-open { min-height:100svh !important; min-height:100dvh !important; }
body.registration-open .shell,
body.registration-open #login-view,
body.registration-open .login-wrap,
body.registration-open .login-card,
body.registration-open #register-form,
body.registration-open #freelancer-register-form { box-sizing:border-box !important; }
body.registration-open .shell { width: min(calc(100% - 24px), 480px) !important; }
body.registration-open #register-form label,
body.registration-open #freelancer-register-form label { overflow-wrap:anywhere !important; }
body.registration-open input,
body.registration-open select,
body.registration-open textarea,
body.registration-open button { max-width:100% !important; }
body.registration-open input[type=file] { white-space:normal !important; overflow-wrap:anywhere !important; }
body.registration-open .registration-sticky-footer { padding-bottom: max(14px, env(safe-area-inset-bottom)) !important; }
@media (max-width: 380px) {
  body.registration-open .shell { width:calc(100% - 16px) !important; margin:8px auto 20px !important; }
  body.registration-open #login-view .login-card { padding:12px !important; }
  body.registration-open #register-form:not(.hidden),
  body.registration-open #freelancer-register-form:not(.hidden) { gap:10px !important; }
  body.registration-open #register-form input:not([type=checkbox]),
  body.registration-open #freelancer-register-form input:not([type=checkbox]) { min-height:48px !important; }
}
@media (min-width: 761px) {
  body.registration-open .shell { margin-top:24px !important; }
}
/* Freelancer landing page: never leave an empty owner dashboard on first login. */
body.freelancer-account-active #owner-dashboard-view > *:not(#freelancer-home) { display:none !important; }
#freelancer-home { width:100%; box-sizing:border-box; padding:clamp(14px,3vw,24px); }
#freelancer-home.hidden { display:none !important; }
.freelancer-home-card { max-width:760px; margin:0 auto; padding:clamp(18px,4vw,28px); border:1px solid #d7e7f5; border-radius:18px; background:linear-gradient(145deg,#fff 0%,#f2f8ff 100%); box-shadow:0 10px 28px rgba(20,70,110,.08); }
.freelancer-home-card h1 { margin:4px 0 8px; font-size:clamp(22px,4vw,30px); line-height:1.2; overflow-wrap:anywhere; }
.freelancer-home-card p { line-height:1.55; overflow-wrap:anywhere; }
.freelancer-home-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin-top:18px; }
.freelancer-home-actions button { min-width:0; min-height:50px; padding:12px; white-space:normal; }
.freelancer-home-summary { margin-top:16px; }
@media(max-width:420px) {
  .freelancer-home-actions { grid-template-columns:minmax(0,1fr); }
}
@media(prefers-reduced-motion:reduce) {
  .freelancer-home-card, .freelancer-home-card * { scroll-behavior:auto !important; animation:none !important; transition:none !important; }
}


/* Research-backed signup refresh: calm, focused, single-column registration.
   Preserve every existing field and ID; this layer changes presentation only. */
body.registration-open {
  background:#f3f7fc !important;
  color:#172033 !important;
}
body.registration-open .topbar {
  background:#ffffff !important;
  border-bottom:1px solid #e4ebf4 !important;
  box-shadow:0 2px 12px rgba(24,50,84,.04);
}
body.registration-open .brand { color:#17345c !important; }
body.registration-open .shell {
  width:min(calc(100% - 28px),520px) !important;
  max-width:520px !important;
  margin:clamp(16px,4vh,36px) auto 36px !important;
}
body.registration-open #login-view .login-card {
  width:100% !important;
  max-width:520px !important;
  padding:clamp(20px,4vw,32px) !important;
  overflow:hidden !important;
  background:#fff !important;
  color:#172033 !important;
  border:1px solid #e1e9f2 !important;
  border-radius:22px !important;
  box-shadow:0 18px 55px rgba(27,55,91,.10) !important;
}
body.registration-open #login-view .login-card::before {
  content:"";
  display:block;
  height:5px;
  margin:calc(clamp(20px,4vw,32px) * -1) calc(clamp(20px,4vw,32px) * -1) 22px;
  background:linear-gradient(90deg,#2563eb 0%,#38bdf8 55%,#14b8a6 100%);
}
body.registration-open #register-form .eyebrow,
body.registration-open #freelancer-register-form .eyebrow {
  color:#2563eb !important;
  font-size:11px !important;
  letter-spacing:.12em !important;
  font-weight:800 !important;
  margin:0 0 3px !important;
}
body.registration-open #register-form > .muted.small,
body.registration-open #freelancer-register-form > .muted.small {
  color:#64748b !important;
  font-size:13px !important;
  line-height:1.55 !important;
  margin:0 0 4px !important;
}
body.registration-open #owner-signup-fields,
body.registration-open #register-fields {
  display:grid !important;
  grid-template-columns:minmax(0,1fr) !important;
  gap:14px !important;
  min-width:0 !important;
  padding:16px !important;
  border:1px solid #e7edf5 !important;
  border-radius:15px !important;
  background:#f8fafd !important;
}
body.registration-open #owner-signup-fields::before,
body.registration-open #register-fields::before {
  display:block;
  color:#1e3a5f;
  font-size:13px;
  line-height:1.3;
  font-weight:800;
  letter-spacing:.01em;
  margin:0 0 1px;
}
body.registration-open #owner-signup-fields::before { content:"Business information"; }
body.registration-open #register-fields::before { content:"Personal details and account security"; }
body.registration-open #register-form label,
body.registration-open #freelancer-register-form label {
  color:#334155 !important;
  font-size:13px !important;
  line-height:1.45 !important;
  font-weight:700 !important;
  gap:7px !important;
}
body.registration-open #register-form input:not([type=checkbox]),
body.registration-open #freelancer-register-form input:not([type=checkbox]) {
  min-height:50px !important;
  padding:12px 14px !important;
  border:1px solid #cbd5e1 !important;
  border-radius:11px !important;
  background:#fff !important;
  color:#172033 !important;
  box-shadow:0 1px 2px rgba(15,23,42,.025) !important;
  font-size:16px !important;
}
body.registration-open #register-form input::placeholder,
body.registration-open #freelancer-register-form input::placeholder { color:#94a3b8 !important; }
body.registration-open #register-form input:focus,
body.registration-open #freelancer-register-form input:focus {
  border-color:#3b82f6 !important;
  box-shadow:0 0 0 4px rgba(59,130,246,.13) !important;
  outline:0 !important;
}
body.registration-open #register-form input[type=file],
body.registration-open #freelancer-register-form input[type=file] {
  min-height:54px !important;
  padding:9px !important;
  border:1px dashed #9bb3d0 !important;
  border-radius:11px !important;
  background:#f5f9ff !important;
  color:#475569 !important;
  font-size:13px !important;
}
body.registration-open #register-form label.aurora-policy-consent,
body.registration-open #freelancer-register-form label.aurora-policy-consent {
  display:flex !important;
  align-items:flex-start !important;
  gap:10px !important;
  padding:12px 13px !important;
  border:1px solid #e7edf5 !important;
  border-radius:12px !important;
  background:#fbfdff !important;
  color:#475569 !important;
  font-size:12px !important;
  line-height:1.5 !important;
}
body.registration-open .aurora-policy-consent a { color:#1d4ed8 !important; font-weight:750; }
body.registration-open #register-form .btn,
body.registration-open #freelancer-register-form .btn {
  min-height:54px !important;
  border-radius:12px !important;
  background:#2563eb !important;
  box-shadow:0 7px 16px rgba(37,99,235,.18) !important;
  color:#fff !important;
  font-size:14px !important;
  font-weight:800 !important;
  letter-spacing:.01em;
}
body.registration-open #register-form .btn:disabled,
body.registration-open #freelancer-register-form .btn:disabled {
  opacity:.65 !important;
  box-shadow:none !important;
}
body.registration-open #register-error,
body.registration-open #signup-otp-message,
body.registration-open #freelancer-register-message {
  padding:0 2px;
  font-size:13px !important;
  line-height:1.5 !important;
}
body.registration-open #signup-otp-panel {
  padding:16px !important;
  border:1px solid #dbeafe !important;
  border-radius:15px !important;
  background:#f5f9ff !important;
}
body.registration-open #signup-otp-panel > p {
  color:#475569 !important;
  line-height:1.55 !important;
}
body.registration-open #signup-otp-panel label { color:#334155 !important; }
body.registration-open #signup-otp-panel #resend-signup-otp {
  background:#eaf1fb !important;
  color:#1e40af !important;
  border:1px solid #d7e5fa !important;
  box-shadow:none !important;
}
body.registration-open .registration-sticky-footer {
  border-top:1px solid #edf1f6 !important;
  margin-top:2px !important;
  padding-top:16px !important;
  color:#64748b !important;
  font-size:13px !important;
}
body.registration-open .registration-back-button {
  color:#1d4ed8 !important;
  font-weight:800 !important;
}
body.registration-open #signup-back-btn {
  background:#eff4fa !important;
  color:#334155 !important;
  border:1px solid #e2e8f0 !important;
}
body.registration-open #aurora-policy-center {
  color:#334155 !important;
}
body.registration-open #aurora-policy-center details {
  border:1px solid #e1e9f2 !important;
  border-radius:13px !important;
  background:#fff !important;
  padding:12px 14px !important;
}
body.registration-open #aurora-policy-center summary {
  color:#334155 !important;
  cursor:pointer;
}
@media(max-width:520px) {
  body.registration-open .shell {
    width:calc(100% - 20px) !important;
    margin:12px auto 28px !important;
  }
  body.registration-open #login-view .login-card {
    padding:18px !important;
    border-radius:17px !important;
  }
  body.registration-open #login-view .login-card::before {
    margin:-18px -18px 18px;
  }
  body.registration-open #owner-signup-fields,
  body.registration-open #register-fields { padding:13px !important; gap:12px !important; }
}
@media(prefers-reduced-motion:reduce) {
  body.registration-open *, body.registration-open *::before,
  body.registration-open *::after { scroll-behavior:auto !important; transition:none !important; animation:none !important; }
}


/* Keep the existing account-type and OTP visibility logic authoritative. */
body.registration-open #owner-signup-fields.hidden,
body.registration-open #register-fields.hidden,
body.registration-open #signup-otp-panel.hidden { display:none !important; }
