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

  body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #111111;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
  }

  .topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2.5rem;
    height: 60px;
    background: #000;
    border-bottom: 3px solid #CC1F1F;
    flex-shrink: 0;
  }
  .logo {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.5px;
    text-transform: uppercase;
    text-decoration: none;
  }
  .logo span { color: #CC1F1F; }
  .topbar-right {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(255,255,255,0.65);
  }
  .topbar-right i { font-size: 14px; }

  .page {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
  }

  .card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border-radius: 8px;
    padding: 2.5rem 2.5rem 2rem;
  }

  .card-header { margin-bottom: 1.75rem; }
  .card-tag {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #fff;
    background: #CC1F1F;
    padding: 3px 8px;
    border-radius: 3px;
    margin-bottom: 0.75rem;
  }
  .card-title {
    font-size: 24px;
    font-weight: 700;
    color: #111;
    margin-bottom: 6px;
    letter-spacing: -0.5px;
  }
  .card-sub {
    font-size: 13px;
    color: #777;
    line-height: 1.5;
  }

  .divider-line {
    height: 1px;
    background: #E8E8E8;
    margin: 1.5rem 0;
  }

  .form-group { margin-bottom: 14px; }
  .form-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #444;
    margin-bottom: 6px;
  }
  .input-wrap { position: relative; }
  .input-wrap i {
    position: absolute;
    left: 11px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    color: #AAA;
    pointer-events: none;
  }
  .form-input {
    width: 100%;
    padding: 10px 11px 10px 36px;
    font-size: 14px;
    border: 1.5px solid #E0E0E0;
    border-radius: 6px;
    background: #FAFAFA;
    color: #111;
    outline: none;
    transition: border-color 0.15s, background 0.15s;
  }
  .form-input:focus {
    border-color: #CC1F1F;
    background: #fff;
  }
  .form-input::placeholder { color: #C0C0C0; }

  .btn-primary {
    width: 100%;
    background: #CC1F1F;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 13px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
  }
  .btn-primary:hover { background: #A81818; }
  .btn-primary i { font-size: 16px; }

  .btn-primary .spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
  }
  .btn-primary.loading .spinner { display: block; }
  .btn-primary.loading .btn-text,
  .btn-primary.loading .btn-icon { display: none; }

  @keyframes spin { to { transform: rotate(360deg); } }

  .error-message {
    display: none;
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    color: #991B1B;
    align-items: center;
    gap: 8px;
  }
  .error-message.visible { display: flex; }
  .error-message i { font-size: 16px; flex-shrink: 0; }

  .success-message {
    display: none;
    background: #F0FDF4;
    border: 1px solid #BBF7D0;
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    color: #166534;
    align-items: center;
    gap: 8px;
  }
  .success-message.visible { display: flex; }
  .success-message i { font-size: 16px; flex-shrink: 0; }

  .back-link {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 1.5rem;
    font-size: 13px;
    color: #CC1F1F;
    text-decoration: none;
    justify-content: center;
  }
  .back-link:hover { text-decoration: underline; }
  .back-link i { font-size: 16px; }

  .bottombar {
    background: #000;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 12px 2.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
  }
  .bottombar-left { font-size: 11px; color: rgba(255,255,255,0.6); }
  .bottombar-right { display: flex; gap: 20px; }
  .bottombar-right a { font-size: 11px; color: rgba(255,255,255,0.6); text-decoration: none; cursor: pointer; }
  .bottombar-right a:hover { color: rgba(255,255,255,0.6); }

  @media (max-width: 480px) {
    .topbar { padding: 0 1.25rem; }
    .page { padding: 1.5rem 1.25rem; }
    .card { padding: 2rem 1.5rem 1.5rem; }
    .bottombar { padding: 12px 1.25rem; flex-direction: column; gap: 8px; text-align: center; }
  }
  .nav-icon-btn, .theme-btn {
    border: none;
    background: transparent;
    color: inherit;
    cursor: pointer;
    padding: 0.45rem;
    border-radius: 999px;
    transition: background 0.2s, color 0.2s, opacity 0.2s;
  }
  .nav-icon-btn:hover, .theme-btn:hover {
    opacity: 0.8;
    background: rgba(255,255,255,0.08);
  }
  body.light {
    background: #F5F7FA;
    color: #111;
  }
  body.light .topbar, body.light .topnav {
    background: #fff;
    border-color: #E5E7EB;
    color: #111;
  }
  body.light .topbar-right, body.light .topnav-right {
    color: rgba(0,0,0,0.65);
  }
  body.light .logo {
    color: #111;
  }
  body.light .logo span {
    color: #CC1F1F;
  }
  body.light a, body.light .nav-link {
    color: #111;
  }
  body.light .bottombar { background: #fff; border-top-color: #E8E8E8; }
  body.light .bottombar-left { color: rgba(0,0,0,0.4); }
  body.light .bottombar-right a { color: rgba(0,0,0,0.4); }
  body.light .bottombar-right a:hover { color: #111; }
  body.light .nav-icon-btn, body.light .theme-btn { color: rgba(0,0,0,0.4); }
  body.light .nav-icon-btn:hover, body.light .theme-btn:hover { color: #111; background: rgba(0,0,0,0.04); }
