  * { box-sizing: border-box; margin: 0; padding: 0; }

  :root {
    --ns-motion-fast: 0.2s ease-in-out;
    --ns-motion-medium: 0.34s cubic-bezier(0.22, 1, 0.36, 1);
    --ns-motion-slow: 0.48s cubic-bezier(0.22, 1, 0.36, 1);
    --ns-shadow-soft: 0 10px 24px rgba(15, 61, 46, 0.1);
    --ns-shadow-lift: 0 18px 42px rgba(15, 61, 46, 0.18);
  }

  body.auth-page-body {
    min-height: 100vh;
    font-family: "Nunito", sans-serif;
    background:
      radial-gradient(circle at 13% 15%, rgba(20, 92, 63, 0.18) 0 76px, transparent 78px),
      radial-gradient(circle at 90% 23%, rgba(49, 147, 90, 0.18) 0 64px, transparent 66px),
      radial-gradient(circle at 8% 66%, rgba(15, 61, 46, 0.15) 0 88px, transparent 90px),
      radial-gradient(circle at 90% 68%, rgba(20, 92, 63, 0.16) 0 78px, transparent 80px),
      #ffffff;
    color: #09251b;
    position: relative;
  }

  body.auth-page-body::before,
  body.auth-page-body::after {
    content: "";
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    border: 2px solid rgba(20, 92, 63, 0.12);
    background: rgba(234, 247, 241, 0.55);
    box-shadow: 0 18px 50px rgba(15, 61, 46, 0.1);
  }

  body.auth-page-body::before {
    width: 150px;
    height: 150px;
    left: 6%;
    top: 10%;
  }

  body.auth-page-body::after {
    width: 132px;
    height: 132px;
    right: 7%;
    top: 18%;
  }

  .auth-page {
    min-height: 82vh;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    background: transparent;
    border-radius: 0 0 10px 10px;
    animation: nsPageFadeIn var(--ns-motion-slow) both;
  }

  .auth-footer {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
    padding: 0 20px 24px;
    color: #145c3f;
    font-size: 0.78rem;
    font-weight: 800;
  }

  .auth-footer a {
    color: inherit;
    text-decoration: none;
  }

  .auth-page::before,
  .auth-page::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
  }

  .auth-page::before {
    width: 128px;
    height: 128px;
    left: 7%;
    top: 11%;
    border: 2px solid rgba(20, 92, 63, 0.16);
    background: rgba(234, 247, 241, 0.36);
    box-shadow: 0 18px 46px rgba(15, 61, 46, 0.08);
  }

  .auth-page::after {
    width: 112px;
    height: 112px;
    right: 8%;
    bottom: 20%;
    border: 2px solid rgba(49, 147, 90, 0.14);
    background: rgba(234, 247, 241, 0.42);
    box-shadow: 0 18px 46px rgba(15, 61, 46, 0.08);
  }

  .fade-in { animation: nsPageFadeIn var(--ns-motion-slow) both; }
  .slide-in-left { animation: nsSidebarSlideIn var(--ns-motion-medium) both; }
  .hover-lift { transition: transform var(--ns-motion-fast), box-shadow var(--ns-motion-fast); }
  .hover-lift:hover { transform: translateY(-4px); box-shadow: var(--ns-shadow-lift); }
  .btn-animate { cursor: pointer; transition: transform var(--ns-motion-fast), box-shadow var(--ns-motion-fast), background-color var(--ns-motion-fast), border-color var(--ns-motion-fast), color var(--ns-motion-fast), opacity var(--ns-motion-fast); }
  .btn-animate:hover:not(:disabled) { transform: translateY(-1px) scale(1.035); box-shadow: var(--ns-shadow-soft); }
  .btn-animate:active:not(:disabled) { transform: translateY(0) scale(0.98); }
  .card-reveal { animation: nsCardReveal var(--ns-motion-slow) both; }

  .auth-card {
    position: relative;
    z-index: 1;
    width: min(700px, 100%);
    height: 500px;
    border-radius: 20px;
    background: #ffffff;
    overflow: hidden;
    box-shadow: 0 28px 80px rgba(15, 61, 46, 0.16);
    animation: authFadeIn 0.36s ease both;
    transition: all var(--ns-motion-fast);
  }

  .auth-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--ns-shadow-lift);
  }

  @keyframes authFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }

  @keyframes nsPageFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  @keyframes nsSidebarSlideIn {
    from { opacity: 0; transform: translateX(-22px); }
    to { opacity: 1; transform: translateX(0); }
  }

  @keyframes nsCardReveal {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .form-side {
    position: absolute;
    top: 0;
    width: 58%;
    height: 100%;
    padding: 44px 32px;
    display: flex;
    align-items: center;
    transition: opacity 0.28s ease, transform 0.45s ease;
  }

  .login-side { right: 0; opacity: 1; pointer-events: auto; }
  .signup-side { left: 0; opacity: 0; pointer-events: none; transform: translateX(-14px); padding-top: 34px; padding-bottom: 34px; }

  .auth-card.show-register .login-side {
    opacity: 0;
    pointer-events: none;
    transform: translateX(14px);
  }

  .auth-card.show-register .signup-side {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
  }

  form { width: 100%; }

  form h2 {
    font-size: 1.55rem;
    color: #08251a;
    line-height: 1;
    margin-bottom: 8px;
    font-weight: 800;
  }

  .form-subtitle {
    font-size: 0.84rem;
    color: #7a8790;
    margin-bottom: 24px;
  }

  .name-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .input-box {
    position: relative;
    margin-bottom: 14px;
  }

  .input-box input,
  .input-box select {
    width: 100%;
    height: 40px;
    border: 1px solid #d6e2d9;
    border-radius: 8px;
    background: #f9fcfa;
    color: #09251b;
    padding: 0 40px 0 14px;
    font-family: inherit;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  }

  .input-box input::placeholder { color: #a0b2a8; }

  .input-box select {
    appearance: none;
    color: #09251b;
    cursor: pointer;
  }

  .input-box input:focus,
  .input-box select:focus {
    background: #ffffff;
    border-color: #1b7a52;
    box-shadow: 0 0 0 3px rgba(20, 92, 63, 0.10);
  }

  .field-icon {
    position: absolute;
    right: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #9aa9a0;
    font-size: 0.86rem;
    pointer-events: none;
  }

  .field-icon.leading {
    display: none;
  }

  .input-box.password-box input {
    padding-right: 82px;
  }

  .input-box.password-box .field-icon {
    right: 52px;
  }

  .password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: #145c3f;
    font-family: inherit;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
    padding: 5px;
    z-index: 3;
  }

  .forgot {
    text-align: right;
    margin: -6px 0 12px;
  }

  .forgot a {
    color: #145c3f;
    font-size: 0.78rem;
    text-decoration: none;
    font-weight: 700;
  }

  .resend-verification {
    display: none;
    border: 0;
    background: transparent;
    color: #145c3f;
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 800;
    margin: -4px 0 12px auto;
    padding: 0;
  }

  button[type="submit"] {
    width: 100%;
    height: 40px;
    border: 0;
    border-radius: 8px;
    background: #31935a;
    color: #ffffff;
    font-family: inherit;
    font-weight: 800;
    cursor: pointer;
    box-shadow: none;
    transition: background 0.2s ease, transform 0.2s ease;
  }

  button[type="submit"]:hover {
    background: #1b7a52;
    transform: translateY(-1px) scale(1.035);
    box-shadow: var(--ns-shadow-soft);
  }

  button,
  [role="button"],
  .toggle-btn,
  .mobile-auth-tab,
  .modal-btn,
  .modal-close,
  .loc-retry-btn,
  .loc-back-btn {
    cursor: pointer;
    transition: all var(--ns-motion-fast);
  }

  button:hover:not(:disabled),
  [role="button"]:hover,
  .toggle-btn:hover,
  .mobile-auth-tab:hover,
  .modal-btn:hover,
  .modal-close:hover,
  .loc-retry-btn:hover,
  .loc-back-btn:hover {
    transform: translateY(-1px) scale(1.035);
    box-shadow: var(--ns-shadow-soft);
  }

  button:active:not(:disabled),
  [role="button"]:active,
  .toggle-btn:active,
  .mobile-auth-tab:active,
  .modal-btn:active,
  .modal-close:active,
  .loc-retry-btn:active,
  .loc-back-btn:active {
    transform: translateY(0) scale(0.98);
  }

  .password-toggle:hover:not(:disabled),
  .password-toggle:active:not(:disabled) {
    transform: translateY(-50%);
    box-shadow: none;
  }

  @media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      scroll-behavior: auto !important;
      transition-duration: 0.01ms !important;
    }
  }

  .social-divider {
    display: flex;
    align-items: center;
    gap: 14px;
    color: #9aa7a0;
    font-size: 0.76rem;
    margin: 18px 0 12px;
  }

  .social-divider::before,
  .social-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #dce6df;
  }

  .social-row {
    display: flex;
    justify-content: center;
  }

  .social-row button {
    width: 100%;
    min-height: 38px;
    border: 1px solid #d6e2d9;
    border-radius: 8px;
    background: #ffffff;
    color: #0f3d2e;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: inherit;
    font-size: 0.84rem;
    font-weight: 800;
  }

  .social-row button::before {
    content: "G";
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    border: 1px solid rgba(20, 92, 63, 0.16);
    color: #145c3f;
    font-size: 0.76rem;
    font-weight: 900;
  }

  .toggle-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 42%;
    height: 100%;
    padding: 44px 34px;
    border-radius: 20px;
    background: linear-gradient(145deg, #2b7c45 0%, #145c3f 58%, #0f3d2e 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: left 0.45s cubic-bezier(.22,.75,.23,1), border-radius 0.45s ease;
    z-index: 4;
  }

  .auth-card.show-register .toggle-panel {
    left: 58%;
  }

  .panel-content {
    max-width: 230px;
  }

  .toggle-panel .nearserve-logo-img {
    width: 48px;
    height: 48px;
    padding: 5px;
    margin-bottom: 18px;
    background: rgba(255,255,255,0.16);
    box-shadow: none;
  }

  .brand-name {
    font-family: "Playfair Display", serif;
    font-size: 1.4rem;
    line-height: 1;
    margin-bottom: 7px;
    text-shadow: none;
  }

  .brand-name span { color: inherit; }

  .brand-kicker {
    font-size: 0.68rem;
    letter-spacing: 0.055em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.74);
    margin-bottom: 28px;
    white-space: nowrap;
  }

  .brand-divider {
    display: none;
  }

  .brand-features {
    display: none;
  }

  .brand-feature {
    width: 100px;
    color: #ffffff;
    font-size: 1.05rem;
    line-height: 1.2;
    font-weight: 700;
  }

  .brand-feature-icon {
    width: 68px;
    height: 68px;
    margin: 0 auto 12px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(35,151,92,0.76);
    border: 1px solid rgba(255,255,255,0.12);
    font-size: 1.55rem;
  }

  .panel-copy { display: none; }
  .auth-card:not(.show-register) .login-copy { display: block; }
  .auth-card.show-register .register-copy { display: block; }

  .panel-dots { display: flex; }

  .panel-copy h3 {
    font-size: 1.45rem;
    margin-bottom: 12px;
  }

  .panel-copy p {
    font-size: 0.9rem;
    line-height: 1.45;
    color: rgba(255,255,255,0.82);
    margin-bottom: 26px;
  }

  .toggle-btn {
    min-width: 110px;
    height: 38px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.78);
    background: transparent;
    color: #ffffff;
    font-weight: 800;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
  }

  .toggle-btn:hover {
    background: #ffffff;
    color: #145c3f;
  }

  .auth-switch {
    display: none;
  }

  .auth-switch button {
    border: 0;
    background: transparent;
    color: #00833f;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
  }

  .panel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
  }

  .panel-dots span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.38);
  }

  .auth-card:not(.show-register) .panel-dots span:first-child,
  .auth-card.show-register .panel-dots span:nth-child(2) {
    background: #ffffff;
  }

  .modal-overlay,
  #locationOverlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15,23,42,0.58);
    backdrop-filter: blur(8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
  }

  #locationOverlay { display: none; opacity: 1; pointer-events: auto; }
  .modal-overlay.active { opacity: 1; pointer-events: auto; }

  .modal,
  .loc-card {
    width: min(100%, 390px);
    padding: 30px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 28px 70px rgba(15,23,42,0.25);
    position: relative;
    text-align: center;
  }

  .modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: rgba(20,92,63,0.10);
    color: #145c3f;
    cursor: pointer;
  }

  .modal-icon,
  .loc-icon-wrap,
  .success-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 16px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    background: rgba(20,92,63,0.12);
    color: #145c3f;
    font-size: 1.5rem;
  }

  .modal h3,
  .loc-title,
  .modal-success h4 {
    color: #0f3d2e;
    margin-bottom: 8px;
    font-weight: 800;
  }

  .modal p,
  #locStatus,
  #locDeniedSub {
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 18px;
  }

  .modal .input-box input { padding-right: 14px; }
  .modal .input-box select {
    width: 100%;
    height: 40px;
    border: 1px solid #d6e2d9;
    border-radius: 8px;
    background: #f9fcfa;
    color: #09251b;
    padding: 0 14px;
    font-family: inherit;
    font-size: 0.9rem;
    outline: none;
  }

  .oauth-email-note {
    margin: -8px 0 14px;
    color: #64748b;
    font-size: 0.78rem;
    line-height: 1.35;
  }

  .modal-btn,
  .loc-retry-btn {
    width: 100%;
    height: 42px;
    border: 0;
    border-radius: 10px;
    background: #31935a;
    color: #ffffff;
    font-weight: 800;
    cursor: pointer;
  }

  .modal-success { display: none; }
  .loc-dots { display: inline-flex; gap: 5px; margin: 10px 0; }
  .loc-dots span { width: 8px; height: 8px; border-radius: 50%; background: #145c3f; opacity: 0.35; }
  #locDeniedMsg { display: none; }
  #locDeniedRegion, .karnataka-badge { display: inline-flex; margin-bottom: 12px; color: #145c3f; font-weight: 800; }
  .loc-back-btn { width: 100%; min-height: 42px; border: 1px solid rgba(20,92,63,0.2); border-radius: 10px; background: #fff; color: #145c3f; font-weight: 800; cursor: pointer; margin-top: 8px; }

  @media (min-width: 769px) {
    html,
    body {
      height: 100%;
    }

    body {
      min-height: 100vh;
      overflow-x: hidden;
    }

    .auth-page,
    .login-bg,
    .background,
    .main-container {
      min-height: 100vh;
      height: 100%;
    }    .auth-card {
      z-index: 1;
    }
  }

  @media (max-width: 768px) {
    html,
    body {
      width: 100%;
      overflow-x: hidden;
      background:
        radial-gradient(circle at 12% 12%, rgba(20, 92, 63, 0.11) 0 44px, transparent 46px),
        radial-gradient(circle at 90% 16%, rgba(49, 147, 90, 0.10) 0 38px, transparent 40px),
        radial-gradient(circle at 8% 82%, rgba(15, 61, 46, 0.08) 0 56px, transparent 58px),
        #f3f7f1;
    }

    .auth-page {
      min-height: calc(100vh - 52px);
      padding: 0;
      display: block;
      background: transparent;
    }

    .auth-page::before,
    .auth-page::after {
      display: none;
    }

    body.auth-page-body::before,
    body.auth-page-body::after {
      display: none;
    }

    .auth-card {
      height: auto;
      min-height: 100vh;
      width: 100%;
      max-width: 100vw;
      border-radius: 0;
      background: transparent;
      box-shadow: none;
      overflow: visible;
      display: flex;
      flex-direction: column;
    }

    .toggle-panel,
    .form-side {
      position: relative;
      left: auto !important;
      right: auto;
      top: auto;
      width: 100%;
      height: auto;
    }

    .toggle-panel {
      order: 1;
      min-height: 236px;
      padding: 34px 24px 60px;
      border-radius: 0;
      background: linear-gradient(135deg, #0f3d2e 0%, #145c3f 64%, #1b7a52 100%);
      box-shadow: none;
    }

    .panel-content {
      max-width: 310px;
      margin: 0 auto;
    }

    .toggle-panel .nearserve-logo-img {
      width: 64px;
      height: 64px;
      padding: 6px;
      margin-bottom: 12px;
      background: #ffffff;
      box-shadow: 0 10px 28px rgba(0,0,0,0.14);
    }

    .brand-name {
      font-family: "Nunito", sans-serif;
      font-size: 1.9rem;
      font-weight: 900;
      margin-bottom: 4px;
    }

    .brand-name span {
      color: inherit;
    }

    .brand-kicker {
      display: none;
    }

    .mobile-brand-tagline {
      display: block !important;
      color: rgba(255,255,255,0.82);
      font-size: 0.88rem;
      font-weight: 700;
      line-height: 1.35;
    }

    .panel-copy,
    .panel-dots,
    .brand-divider,
    .brand-features {
      display: none !important;
    }

    .mobile-auth-tabs {
      order: 2;
      display: flex !important;
      width: calc(100% - 32px);
      max-width: 440px;
      margin: -38px auto 0;
      padding: 28px 22px 12px;
      gap: 7px;
      border-radius: 32px 32px 0 0;
      background: #ffffff;
      box-shadow: 0 -8px 28px rgba(15,61,46,0.08);
      position: relative;
      z-index: 5;
    }

    .mobile-auth-tab {
      flex: 1;
      min-height: 40px;
      border: 0;
      border-radius: 999px;
      background: transparent;
      color: #526159;
      font: inherit;
      font-weight: 900;
      cursor: pointer;
    }

    .mobile-auth-tab.active {
      background: #145c3f;
      color: #ffffff;
      box-shadow: 0 8px 18px rgba(20,92,63,0.26);
    }

    .form-side {
      order: 3;
      width: calc(100% - 32px);
      max-width: 440px;
      margin: 0 auto 24px;
      padding: 14px 22px 34px;
      display: none;
      opacity: 1;
      transform: none !important;
      pointer-events: auto;
      background: rgba(255,255,255,0.97);
      border-radius: 0 0 32px 32px;
      box-shadow: 0 22px 42px rgba(15,61,46,0.12);
    }

    .auth-card:not(.show-register) .login-side,
    .auth-card.show-register .signup-side {
      display: flex;
    }

    form h2 {
      display: none;
    }

    .form-subtitle {
      display: none;
    }

    .input-box {
      margin-bottom: 14px;
    }

    .input-box input,
    .input-box select {
      height: 46px;
      border-radius: 15px;
      border: 1px solid rgba(20,92,63,0.10);
      background: #ffffff;
      box-shadow: 0 8px 18px rgba(15,61,46,0.05);
      font-size: 0.94rem;
    }

    .mobile-confirm {
      display: block !important;
    }

    button[type="submit"] {
      height: 50px;
      margin-top: 4px;
      border-radius: 15px;
      background: linear-gradient(135deg, #0f3d2e, #145c3f, #1b7a52);
      box-shadow: 0 12px 24px rgba(20,92,63,0.22);
      font-size: 0.96rem;
    }

    .forgot {
      margin: -4px 0 12px;
    }

    .login-side .social-divider,
    .signup-side .social-divider {
      display: flex;
      margin: 20px 0 14px;
      color: #8c9a93;
    }

    .login-side .social-row,
    .signup-side .social-row {
      display: flex;
      margin-bottom: 14px;
    }

    .social-row button {
      width: 100%;
      min-height: 46px;
      border-radius: 12px;
      background: #ffffff;
      box-shadow: 0 8px 18px rgba(15,61,46,0.08);
    }

    .auth-switch {
      display: none;
    }

    .auth-footer { padding: 0 16px 18px; gap: 12px; font-size: 0.7rem; }

    .name-row { grid-template-columns: 1fr; gap: 0; }
  }
