  :root {
    --brand-blue: #2e3192;
    --brand-light: #eff6ff;
    --text-main: #0f172a;
    --text-muted: #475569;
    --border-color: #cbd5e1;
    --bg-page: #f8fafc;
    --bg-white: #ffffff;
    --bg-disabled: #f1f5f9;
    --input-focus: rgba(59, 130, 246, 0.3);
    --text-footer: #e6e6e6;
  }

  body {
    margin: 0;
    font-family: system-ui, -apple-system, sans-serif;
    background-color: var(--bg-page);
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
  }

  .login-wrapper {
    width: 100%;
    max-width: 550px;
    padding: 2rem;
    box-sizing: border-box;
  }

  .login-card {
    background-color: var(--bg-white);
    border-radius: 1rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--border-color);
    padding: 2rem 1.5rem;
  }

  .back-to-main {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    margin-bottom: 1rem;
    transition: all 0.2s;
    opacity: 0.7;
  }

  .back-to-main:hover {
    color: var(--brand-blue);
    opacity: 1;
  }

  .back-to-main svg {
    transition: transform 0.2s;
  }

  .back-to-main:hover svg {
    transform: translateX(-2px);
  }

  .form-heading {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 0.5rem 0;
    text-align: center;
  }

  .form-subtitle {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin: 0 0 1.5rem 0;
    text-align: center;
    line-height: 1.5;
  }

  .brand-header {
    text-align: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
  }

  .logo {
    max-width: 200px;
    height: auto;
  }

  .custom-select-wrapper {
    position: relative;
    user-select: none;
    margin-bottom: 1rem;
    z-index: 100;
  }

  .custom-select {
    position: relative;
    display: flex;
    flex-direction: column;
  }

  .custom-select__trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--brand-blue);
    background-color: var(--bg-white);
    border: 2px solid var(--brand-blue);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
  }

  .custom-select.open .custom-select__trigger {
    box-shadow: 0 0 0 4px var(--input-focus);
  }

  .arrow {
    width: 10px;
    height: 10px;
    border-bottom: 2.5px solid var(--brand-blue);
    border-right: 2.5px solid var(--brand-blue);
    transform: translateY(-25%) rotate(45deg);
    transition: transform 0.2s;
  }

  .custom-select.open .arrow {
    transform: translateY(25%) rotate(-135deg);
  }

  .custom-options {
    position: absolute;
    display: block;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--bg-white); 
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.2);
    margin-top: 0.5rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.2s;
    max-height: 220px;
    overflow-y: auto;
  }

  .custom-select.open .custom-options {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
    transform: translateY(0);
  }

  .custom-option {
    display: block; 
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
    color: var(--text-main);
    cursor: pointer;
    border-bottom: 1px solid var(--bg-disabled);
    transition: background-color 0.2s;
  }

  .custom-option:last-child {
    border-bottom: none;
  }

  .custom-option:hover {
    background-color: var(--brand-light);
    color: var(--brand-blue);
  }

  .custom-option.selected {
    background-color: var(--brand-blue);
    color: var(--bg-white);
  }

  .branch-prompt {
    background-color: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fca5a5;
    padding: 1rem;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(185, 28, 28, 0.1);
  }

  .branch-prompt.hidden {
    display: none;
  }

  .alert-info {
    background-color: #eff6ff;
    color: #1e40af;
    border: 1px solid #93c5fd;
    padding: 1rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .alert-info svg {
    flex-shrink: 0;
    margin-top: 0.125rem;
  }

  .form-group {
    margin-bottom: 1.25rem;
  }

  .form-label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: var(--text-main);
  }

  .form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    color: var(--text-main);
    box-sizing: border-box;
    transition: all 0.2s;
  }

  .form-input:focus:not(:disabled) {
    outline: none;
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 3px var(--input-focus);
  }

  .form-input:disabled {
    background-color: var(--bg-disabled);
    color: #94a3b8;
    cursor: not-allowed;
    border-color: #e2e8f0;
  }

  .form-input.error {
    border-color: #f87171;
  }

  .error-text {
    color: #dc2626;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    font-weight: 500;
  }

  .btn-primary {
    width: 100%;
    padding: 0.875rem;
    background-color: var(--brand-blue);
    color: var(--bg-white);
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(46, 49, 146, 0.2);
  }

  .btn-primary:hover:not(:disabled) {
    background-color: #23256e;
    transform: translateY(-1px);
    box-shadow: 0 6px 8px -1px rgba(46, 49, 146, 0.3);
  }

  .btn-primary:disabled {
    background-color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
  }

  .error-container {
    color: #dc2626;
    font-size: 0.875rem;
    min-height: 1.25rem;
    margin-bottom: 1rem;
    text-align: center;
    font-weight: 500;
  }

  .custom-options a{
    text-decoration: none;
    color: inherit;
  }

  .success-message{
    color: #16a34a;
    font-size: 0.875rem;
    min-height: 1.25rem;
    margin-bottom: 1rem;
    text-align: center;
    font-weight: 500;
  }

  .form-footer {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
  }

  .form-link {
    color: var(--brand-blue);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
    padding: 0.25rem;
  }

  .form-link:hover {
    color: #23256e;
    text-decoration: underline;
  }

  .form-link-forgot {
    display: block;
    color: var(--brand-blue);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: right;
    margin-bottom: 1rem;
    transition: all 0.2s;
  }

  .form-link-forgot:hover {
    color: #23256e;
    text-decoration: underline;
  }

  .form-info {
    color: var(--text-muted);
    font-size: 0.85rem;
    text-align: center;
    line-height: 1.5;
    margin-top: 0.5rem;
  }

  footer {
    text-align: center;
    color: var(--text-footer);
    font-size: 0.75rem;
    padding: 1rem;
    opacity: 0.7;
    width: 100%;
    margin: 0;
    box-sizing: border-box;
  }

  footer a {
    color: var(--text-footer);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
  }

  body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #1e293b 0%, #334155 25%, var(--brand-blue) 60%, #4f46e5 100%);
  }

  /* Mobile responsive styles */
  @media (max-width: 768px) {
    .login-wrapper {
      padding: 10px;
    }
  }
