
  :root {
    --u-black:   #000000;
    --u-white:   #ffffff;
    --u-gray100: #F6F6F6;
    --u-gray200: #EEEEEE;
    --u-gray400: #AAAAAA;
    --u-gray600: #545454;
    --u-border:  #D9D9D9;
    --u-error:   #C8372D;
  }

  * { box-sizing: border-box; margin: 0; padding: 0; }

  body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--u-white);
    color: var(--u-black);
    font-size: 15px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
  }

  /* ── NAV ────────────────────────────────────────────────── */
  .top-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .top-nav .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--u-black);
    text-decoration: none;
    letter-spacing: -0.5px;
  }
  .top-nav .nav-links a {
    color: var(--u-black);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-left: 24px;
    transition: opacity .15s;
  }
  .top-nav .nav-links a:hover { opacity: 0.6; }

  /* ── LAYOUT ─────────────────────────────────────────────── */
  .auth-layout {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Form panel */
  .form-panel {
    width: 100%;
    max-width: 440px;
    padding: 40px 32px 60px;
  }

  /* ── STEPS ──────────────────────────────────────────────── */
  .step { display: none; }
  .step.active { display: block; }


  /* ── TITLE ──────────────────────────────────────────────── */
  .form-title {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 8px;
    letter-spacing: -0.3px;
  }
  .form-subtitle {
    font-size: 14px;
    color: var(--u-gray600);
    margin-bottom: 32px;
  }

  /* ── INPUTS ─────────────────────────────────────────────── */
  .field {
    margin-bottom: 16px;
  }
  .field label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: var(--u-gray600);
    display: block;
    margin-bottom: 6px;
  }
  .field input,
  .field select {
    width: 100%;
    padding: 14px 16px;
    border: 1.5px solid var(--u-border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    color: var(--u-black);
    background: var(--u-white);
    outline: none;
    transition: border-color .15s;
    appearance: none;
  }
  .field input:focus,
  .field select:focus {
    border-color: var(--u-black);
  }
  .field input.error {
    border-color: var(--u-error);
  }
  .field .err-msg {
    font-size: 12px;
    color: var(--u-error);
    margin-top: 5px;
    display: none;
  }
  .field input.error + .err-msg,
  .field .err-msg.show { display: block; }
  .server-errors {
    background: #fff0f0;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 10px 16px;
    margin-bottom: 14px;
    color: #721c24;
    font-size: 14px;
  }
  .server-errors p { margin: 3px 0; }

  /* Phone with flag prefix */
  .phone-wrap {
    display: flex;
    border: 1.5px solid var(--u-border);
    border-radius: 8px;
    overflow: hidden;
    transition: border-color .15s;
  }
  .phone-wrap:focus-within { border-color: var(--u-black); }
  .phone-prefix {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 14px;
    background: var(--u-gray100);
    border-right: 1.5px solid var(--u-border);
    white-space: nowrap;
    font-size: 15px;
    cursor: pointer;
    user-select: none;
  }
  .phone-prefix .flag { font-size: 18px; }
  .phone-wrap input {
    border: none;
    border-radius: 0;
    flex: 1;
  }
  .phone-wrap input:focus { border-color: transparent; }

  /* Password strength */
  .pwd-wrap { position: relative; }
  .pwd-wrap input { padding-right: 48px; }
  .pwd-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--u-gray600);
    font-size: 18px;
    padding: 0;
  }
  .strength-bar {
    display: flex;
    gap: 4px;
    margin-top: 8px;
  }
  .strength-bar span {
    flex: 1;
    height: 3px;
    border-radius: 2px;
    background: var(--u-gray200);
    transition: background .25s;
  }
  .strength-bar.s1 span:nth-child(1) { background: #C8372D; }
  .strength-bar.s2 span:nth-child(1),
  .strength-bar.s2 span:nth-child(2) { background: #E87B3A; }
  .strength-bar.s3 span:nth-child(-n+3) { background: #3AA76D; }
  .strength-bar.s4 span { background: #2B8A55; }
  .strength-label {
    font-size: 11px;
    color: var(--u-gray600);
    margin-top: 4px;
  }

  /* ── FORGOT LINK ──────────────────────────────────────────── */
  .forgot-link {
    font-size: 13px;
    color: var(--u-black);
    font-weight: 600;
    text-decoration: underline;
    display: block;
    text-align: right;
    margin-top: -8px;
    margin-bottom: 12px;
  }
  .forgot-link:hover { opacity: .7; }

  /* ── BUTTONS ─────────────────────────────────────────────── */
  .btn-primary-u {
    width: 100%;
    padding: 15px;
    background: var(--u-black);
    color: var(--u-white);
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
    margin-top: 8px;
  }
  .btn-primary-u:hover { background: #222; }
  .btn-primary-u:disabled {
    background: var(--u-gray200);
    color: var(--u-gray400);
    cursor: not-allowed;
  }

  .btn-outline-u {
    width: 100%;
    padding: 13px;
    background: var(--u-white);
    color: var(--u-black);
    border: 1.5px solid var(--u-border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: border-color .15s, background .15s;
    margin-top: 12px;
    text-decoration: none;
  }
  .btn-outline-u:hover {
    border-color: var(--u-black);
    background: var(--u-gray100);
  }
  .btn-outline-u img { width: 20px; height: 20px; }

  /* Back button */
  .btn-back {
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    color: var(--u-gray600);
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0;
    margin-bottom: 28px;
    transition: color .15s;
  }
  .btn-back:hover { color: var(--u-black); }

  /* ── DIVIDER ─────────────────────────────────────────────── */
  .divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: var(--u-gray400);
    font-size: 13px;
  }
  .divider::before,
  .divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--u-border);
  }

  /* ── LEGAL TEXT ──────────────────────────────────────────── */
  .legal {
    font-size: 12px;
    color: var(--u-gray600);
    line-height: 1.6;
    margin-top: 20px;
  }
  .legal a {
    color: var(--u-black);
    font-weight: 600;
    text-decoration: underline;
  }

  .signin-link {
    font-size: 14px;
    color: var(--u-gray600);
    margin-top: 28px;
  }
  .signin-link a {
    color: var(--u-black);
    font-weight: 700;
    text-decoration: underline;
  }

  /* ── SUCCESS ─────────────────────────────────────────────── */
  .success-box {
    text-align: center;
    padding: 20px 0;
  }
  .success-icon {
    width: 64px;
    height: 64px;
    background: var(--u-black);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    color: #fff;
    font-size: 28px;
  }

  /* ── RESPONSIVE ──────────────────────────────────────────── */
  @media (max-width: 991px) {
    .form-panel {
      padding: 32px 24px 48px;
    }
  }
  @media (max-width: 480px) {
    .form-title { font-size: 1.4rem; }
  }

