/* stylelint-disable */
/* ============================================================
   REGISTRATION — aligned with Personal Dashboard / Article meta palette
   NoFakeBiz Platform
============================================================ */

/* Dashboard-aligned tokens (registration.css is only loaded here) */
:root {
  --nfb-reg-green: #1a7f4a;
  --nfb-reg-green-600: #156b3f;
  --nfb-reg-green-soft: #238a57;
  --nfb-reg-mint: #ecf8f1;
  --nfb-reg-mint-warm: #e8f4ee;
  --nfb-reg-line: rgba(26, 127, 74, 0.28);
  --nfb-reg-line-strong: rgba(26, 127, 74, 0.4);
  --nfb-reg-bg-page: #f1f7f4;
  --nfb-reg-ink: #0f2133;
  --nfb-reg-muted: #5c6d7a;
  --nfb-reg-text: #1a2d3a;
  --nfb-reg-slate: #475569;
  --nfb-reg-card-shadow: 0 14px 42px rgba(15, 33, 51, 0.06), 0 2px 10px rgba(26, 127, 74, 0.05);
  /* Fields: white fill, green-tinted border (reads as form, not flat white) */
  --nfb-reg-field-bg: #ffffff;
  --nfb-reg-field-bg-focus: #ffffff;
  --nfb-reg-field-border: rgba(26, 127, 74, 0.34);
  --nfb-reg-field-border-hover: rgba(26, 127, 74, 0.5);
  --nfb-reg-field-border-disabled: rgba(26, 127, 74, 0.2);
  --nfb-reg-field-disabled-bg: #f4f4f5;
  --nfb-reg-field-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

/* ============================================================
   GLOBAL RESET & BASE
============================================================ */
.registration-page *,
.registration-page *::before,
.registration-page *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--nfb-reg-bg-page);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  padding: 0;
  position: relative;
  overflow-x: hidden;
  color: var(--nfb-reg-text);
}

/* ============================================================
   REGISTRATION CARD
============================================================ */
.registration-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.registration-card {
  width: 100%;
  max-width: 800px;
  background: #fff;
  border-radius: 20px;
  border: 1px solid var(--nfb-reg-line);
  box-shadow: var(--nfb-reg-card-shadow);
  padding: 3rem;
  margin: 0 auto;
}

.registration-card h1 {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--nfb-reg-green);
  margin: 0 0 1rem 0;
  text-align: center;
  letter-spacing: -0.02em;
}

/* ============================================================
   BACK TO SITE LINK
============================================================ */
.back-to-site {
  display: inline-block;
  margin: 0 auto 1.5rem;
  font-size: 0.875rem;
  color: var(--nfb-reg-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  font-weight: 400;
  text-align: center;
  width: 100%;
}

.back-to-site i {
  transition: transform 0.15s ease;
  display: inline-block;
}

.back-to-site:hover {
  color: var(--nfb-reg-green);
  text-decoration: underline;
}

.back-to-site:hover i {
  transform: translateX(-3px);
}

.back-to-site:active {
  color: var(--nfb-reg-green-600);
}

/* ============================================================
   HELP LINK
============================================================ */
.help-link-wrapper {
  text-align: center;
  margin-bottom: 2rem;
}

.help-link-wrapper a {
  color: var(--nfb-reg-green);
  text-decoration: none;
  font-size: 0.9375rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.2s;
  font-weight: 500;
}

.help-link-wrapper a:hover {
  color: var(--nfb-reg-green-600);
  text-decoration: underline;
}

.help-link-wrapper a i {
  font-size: 1rem;
}

/* ============================================================
   FORM SECTIONS
============================================================ */
.form-section {
  border: none;
  margin: 0 0 2rem 0;
  padding: 0;
}

.form-section legend {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--nfb-reg-green);
  margin-bottom: 1rem;
  padding: 0;
}

.form-section label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--nfb-reg-slate);
  margin-bottom: 0.5rem;
}

.nfb-reg-phone-label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--nfb-reg-slate);
  margin: 0.5rem 0 0.5rem 0;
}

.nfb-reg-phone-hint-inline {
  font-weight: 400;
  color: var(--nfb-reg-muted);
  font-size: 0.8125rem;
}

.nfb-reg-phone-row {
  display: flex;
  align-items: stretch;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.nfb-reg-phone-prefix {
  flex: 0 0 auto;
  min-width: 3.5rem;
  padding: 0.9375rem 0.75rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--nfb-reg-green-600);
  background: var(--nfb-reg-mint);
  border: 1px solid var(--nfb-reg-field-border);
  border-radius: 10px;
  box-shadow: var(--nfb-reg-field-shadow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.nfb-reg-phone-field {
  flex: 1;
  min-width: 0;
}

.nfb-reg-phone-field .placeholder-wrapper {
  margin-bottom: 0;
}

.nfb-reg-phone-field input[type="tel"] {
  margin-bottom: 0;
}

/* ============================================================
   INPUTS & SELECTS
============================================================ */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
select {
  width: 100%;
  padding: 0.9375rem 1.25rem;
  border: 1px solid var(--nfb-reg-field-border);
  border-radius: 10px;
  font-size: 0.9375rem;
  font-family: inherit;
  color: var(--nfb-reg-ink);
  background: var(--nfb-reg-field-bg);
  box-shadow: var(--nfb-reg-field-shadow);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  margin-bottom: 1rem;
}

/* Phone: comfortable padding; grouping is XXX XXX XXXX via JS, not letter-spacing */
input[type="tel"] {
  padding-left: 1.35rem;
  padding-right: 1.35rem;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}

input[type="text"]:hover:not(:disabled):not(:focus),
input[type="email"]:hover:not(:disabled):not(:focus),
input[type="tel"]:hover:not(:disabled):not(:focus),
input[type="password"]:hover:not(:disabled):not(:focus),
select:hover:not(:disabled):not(:focus) {
  border-color: var(--nfb-reg-field-border-hover);
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="password"]:focus,
select:focus {
  outline: none;
  border-color: var(--nfb-reg-green-soft);
  background: var(--nfb-reg-field-bg-focus);
  box-shadow: 0 0 0 3px rgba(26, 127, 74, 0.14), var(--nfb-reg-field-shadow);
}

input[type="text"]:disabled,
input[type="email"]:disabled,
input[type="tel"]:disabled,
input[type="password"]:disabled,
select:disabled {
  background: var(--nfb-reg-field-disabled-bg);
  color: var(--nfb-reg-muted);
  cursor: not-allowed;
  border-color: var(--nfb-reg-field-border-disabled);
  box-shadow: none;
}

input.error,
select.error {
  border-color: #dc2626;
  background: #fef2f2;
}

/* ============================================================
   PLACEHOLDER WRAPPER & OVERLAY
============================================================ */
.placeholder-wrapper {
  position: relative;
  width: 100%;
  margin-bottom: 1rem;
}

.placeholder-overlay {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 0.9375rem;
  color: var(--nfb-reg-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  z-index: 1;
  display: flex;
  align-items: center;
  padding: 0 1.25rem;
  box-sizing: border-box;
}

.placeholder-overlay .main-text {
  color: var(--nfb-reg-muted);
  font-weight: 400;
  margin-right: auto;
}

.placeholder-overlay .required-text {
  color: #b91c1c;
  font-weight: 400;
  font-size: 0.875rem;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.placeholder-overlay .optional-text {
  color: var(--nfb-reg-green-600);
  font-weight: 500;
  font-size: 0.875rem;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

input:focus + .placeholder-overlay,
select:focus + .placeholder-overlay,
input:not(:placeholder-shown) + .placeholder-overlay,
select:not([value=""]) + .placeholder-overlay {
  display: none;
}

/* ============================================================
   RADIO BUTTONS
============================================================ */
.radio-row {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.radio-row label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-weight: 400;
  margin-bottom: 0;
}

.radio-row input[type="radio"] {
  width: auto;
  margin: 0;
  cursor: pointer;
  accent-color: var(--nfb-reg-green);
}

/* ============================================================
   CHECKBOX
============================================================ */
.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
  margin-bottom: 1rem;
}

.checkbox-row input[type="checkbox"] {
  width: auto;
  margin: 0;
  margin-top: 0.25rem;
  cursor: pointer;
  flex-shrink: 0;
  accent-color: var(--nfb-reg-green);
}

.checkbox-row span {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--nfb-reg-slate);
}

.checkbox-row a {
  color: var(--nfb-reg-green);
  text-decoration: none;
  font-weight: 500;
}

.checkbox-row a:hover {
  text-decoration: underline;
  color: var(--nfb-reg-green-600);
}

/* ============================================================
   EMAIL & PASSWORD FEEDBACK
============================================================ */
.email-feedback,
.password-feedback {
  font-size: 0.875rem;
  margin-top: -0.5rem;
  margin-bottom: 1rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  min-height: 2.5rem;
  display: flex;
  align-items: center;
}

.email-feedback.success,
.password-feedback.success {
  background: var(--nfb-reg-mint);
  border-color: var(--nfb-reg-line);
  color: var(--nfb-reg-green-600);
}

.email-feedback.error,
.password-feedback.error {
  background: #fef2f2;
  border-color: #fecaca;
  color: #991b1b;
}

/* ============================================================
   PASSWORD RULES
============================================================ */
.password-rules {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 1rem 0;
  font-size: 0.875rem;
  color: var(--nfb-reg-muted);
}

.password-rules li {
  padding: 0.25rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.password-rules-example {
  color: var(--nfb-reg-muted);
  font-weight: 500;
  white-space: nowrap;
}

.nfb-info-tip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid var(--nfb-reg-line);
  color: var(--nfb-reg-green-600);
  font-size: 12px;
  line-height: 1;
  cursor: help;
  margin-left: 0.25rem;
  user-select: none;
  position: relative;
}

.nfb-info-tip:focus {
  outline: 2px solid rgba(14, 165, 233, 0.55);
  outline-offset: 2px;
}

.nfb-info-tip:hover::after,
.nfb-info-tip:focus::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  transform: translateX(-50%);
  width: max-content;
  max-width: 280px;
  padding: 10px 12px;
  background: #0f172a;
  color: #fff;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.45;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.28);
  z-index: 20;
  white-space: normal;
}

.nfb-info-tip:hover::before,
.nfb-info-tip:focus::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 4px);
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid #0f172a;
  z-index: 21;
}

.password-rules li::before {
  content: '•';
  color: var(--nfb-reg-green);
  font-weight: bold;
  margin-right: 0.25rem;
}

/* ============================================================
   CAPTCHA SECTION
============================================================ */
.captcha-section {
  background: #ffffff;
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--nfb-reg-line);
  box-shadow: var(--nfb-reg-field-shadow);
}

.captcha-section legend {
  margin-bottom: 1rem;
}

.captcha-prompt {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--nfb-reg-ink);
  margin-bottom: 0.75rem;
  cursor: default;
}

.captcha-required {
  color: #b91c1c;
  font-weight: 600;
}

#captcha-question {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--nfb-reg-green);
}

.captcha-input-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.captcha-input-wrapper input {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}

.captcha-refresh {
  background: var(--nfb-reg-green);
  color: #fff;
  border: 1px solid var(--nfb-reg-green-600);
  padding: 0.625rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  transition: background 0.2s, border-color 0.2s;
}

.captcha-refresh:hover {
  background: var(--nfb-reg-green-600);
}

/* ============================================================
   SUBMIT BUTTON
============================================================ */
.submit-btn {
  width: 100%;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, var(--nfb-reg-green) 0%, var(--nfb-reg-green-600) 100%);
  color: #fff;
  border: 1px solid var(--nfb-reg-green-600);
  border-radius: 12px;
  font-size: 1.0625rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 14px rgba(26, 127, 74, 0.25);
  margin-top: 1.5rem;
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(26, 127, 74, 0.3);
}

.submit-btn:active:not(:disabled) {
  transform: translateY(0);
}

.submit-btn:disabled {
  background: #94a3b8;
  border-color: #64748b;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* ============================================================
   ERROR MESSAGES
============================================================ */
.form-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  padding: 1rem;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
}

#clientErrorBox {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  padding: 1rem;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  font-size: 0.9375rem;
  display: none;
}

#clientErrorBox div {
  margin: 0.25rem 0;
}

/* Local network — county grounding (registration) */
.nfb-reg-local-network-callout {
  margin: 0 0 1.15rem 0;
  padding: 0.9rem 1.05rem;
  background: linear-gradient(135deg, var(--nfb-reg-mint) 0%, var(--nfb-reg-mint-warm) 100%);
  border: 1px solid var(--nfb-reg-line);
  border-left: 4px solid var(--nfb-reg-green);
  border-radius: 0 12px 12px 0;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--nfb-reg-ink);
}

.nfb-reg-local-network-callout strong {
  color: var(--nfb-reg-green-600);
}

/* ============================================================
   RESPONSIVE DESIGN
============================================================ */
@media (max-width: 768px) {
  .registration-card {
    padding: 2rem 1.5rem;
    border-radius: 16px;
  }

  .registration-card h1 {
    font-size: 1.875rem;
  }

  .radio-row {
    flex-direction: column;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .registration-card {
    padding: 1.5rem 1rem;
  }

  .registration-card h1 {
    font-size: 1.5rem;
  }
}
