/* ── Sign in / sign up / reset (split layout) ─────────────────── */
.auth { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; padding-top: 64px; font-family: Manrope, ui-sans-serif, system-ui, sans-serif; color: #e5e7eb; background: #0c0c0d; }
.auth *, .auth *::before, .auth *::after { box-sizing: border-box; }
.auth [hidden] { display: none !important; }

.auth__art { position: relative; overflow: hidden; background: #080808; }
.auth__art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.auth__art::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(8,8,8,.25) 0%, rgba(8,8,8,.35) 45%, rgba(8,8,8,.92) 100%),
    linear-gradient(90deg, rgba(8,8,8,0) 70%, rgba(12,12,13,.85) 100%);
}
.auth__tip { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; padding: 0 12% 56px 27%; }
.auth__tip-label {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 12px;
  color: #C0C0C0; font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
}
.auth__tip-label svg { width: 14px; height: 14px; }
.auth__tip p { margin: 0; max-width: 430px; color: #fff; font-size: 16px; line-height: 1.6; }

.auth__panel { display: flex; align-items: center; justify-content: center; padding: 56px 32px; }
.auth__box { width: 100%; max-width: 440px; display: flex; flex-direction: column; }
.auth__box > div { display: flex; flex-direction: column; }

.auth__title { margin: 0 0 8px; color: #fff; font-size: 34px; font-weight: 700; letter-spacing: -.02em; line-height: 1.15; }
.auth__sub { margin: 0 0 32px; color: #9ca3af; font-size: 15px; line-height: 1.6; }
.auth__sub a { color: #fff; font-weight: 600; text-decoration: none; }
.auth__sub a:hover { text-decoration: underline; }
.auth__sub strong { color: #fff; }
.auth__small { font-size: 13px; margin: 12px 0 0; }

.auth__alert { margin: -12px 0 20px; padding: 10px 12px; border-radius: 8px; border: 1px solid rgba(248,113,113,.3); color: #fca5a5; font-size: 13px; }

.auth__social {
  display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 50px;
  background: #18181a; border: 1px solid rgba(255,255,255,.1); border-radius: 8px;
  color: #fff; font: inherit; font-size: 15px; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .2s, border-color .2s;
}
.auth__social:hover { background: #1f1f22; border-color: rgba(255,255,255,.18); }
.auth__social:disabled { opacity: .5; cursor: default; }
.auth__social svg { width: 20px; height: 20px; flex-shrink: 0; }

.auth__or { display: flex; align-items: center; gap: 16px; margin: 40px 0 28px; color: #6b7280; font-size: 10.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.auth__or::before, .auth__or::after { content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.08); }

.auth__form { display: flex; flex-direction: column; gap: 22px; }
.auth__field { display: flex; flex-direction: column; gap: 10px; }
.auth__field label, .auth__label-row label { color: #fff; font-size: 14px; font-weight: 600; }
.auth__label-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.auth__mini { color: #9ca3af; font-size: 10.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; text-decoration: none; white-space: nowrap; }
.auth__mini:hover { color: #fff; }
.auth__input {
  width: 100%; height: 48px; padding: 0 16px; background: #0a0a0b; border: 1px solid rgba(255,255,255,.1); border-radius: 8px;
  color: #fff; font: inherit; font-size: 14.5px; outline: none; transition: border-color .2s, box-shadow .2s;
}
.auth__input::placeholder { color: #6b7280; }
.auth__input:focus { border-color: rgba(192,192,192,.6); box-shadow: 0 0 0 3px rgba(192,192,192,.12); }
.auth__hint { color: #6b7280; font-size: 12px; }

.auth__check { display: flex; align-items: flex-start; gap: 14px; cursor: pointer; user-select: none; }
.auth__check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.auth__check-box {
  width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; border-radius: 5px; display: grid; place-items: center;
  border: 1px solid rgba(255,255,255,.2); background: #0a0a0b; color: transparent; transition: background .15s, border-color .15s;
}
.auth__check-box svg { width: 13px; height: 13px; }
.auth__check input:checked + .auth__check-box { background: #C0C0C0; border-color: #C0C0C0; color: #0a0a0a; }
.auth__check input:focus-visible + .auth__check-box { box-shadow: 0 0 0 3px rgba(192,192,192,.25); }
.auth__check-text { display: flex; flex-direction: column; gap: 4px; }
.auth__check-text strong { color: #fff; font-size: 14px; font-weight: 600; }
.auth__check-text small { color: #6b7280; font-size: 12px; }

.auth__error { margin: -8px 0 0; color: #f87171; font-size: 13px; }
.auth__error:empty { display: none; }

.auth__submit {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 50px; margin-top: 18px;
  border: none; border-radius: 8px; background: linear-gradient(180deg, #e4e4e4 0%, #bdbdbd 100%);
  color: #0a0a0a; font: inherit; font-size: 15px; font-weight: 700; text-decoration: none; cursor: pointer;
  box-shadow: 0 0 28px rgba(192,192,192,.28); transition: box-shadow .2s, opacity .2s;
}
.auth__submit:hover { box-shadow: 0 0 36px rgba(192,192,192,.42); }
.auth__submit:disabled { opacity: .55; cursor: default; }

.auth__fine { margin: 0; color: #6b7280; font-size: 12px; line-height: 1.6; text-align: center; }
.auth__fine a { color: #C0C0C0; text-decoration: none; }
.auth__back { align-self: center; margin-top: 24px; color: #C0C0C0; font-size: 13px; text-decoration: none; }
.auth__back:hover { color: #fff; }

@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth__art { display: none; }
  .auth__panel { align-items: flex-start; padding: 48px 20px 64px; }
  .auth__title { font-size: 28px; }
}

/* ── Account dashboard ─────────────────────────────────────────── */
.acc-wrap { min-height: calc(100vh - 64px); padding: 120px 20px 80px; display: flex; justify-content: center; align-items: flex-start; font-family: Manrope, ui-sans-serif, system-ui, sans-serif; color: #e5e7eb; }
.acc-wrap *, .acc-wrap *::before, .acc-wrap *::after { box-sizing: border-box; }
.acc-wrap [hidden] { display: none !important; }

.acc-tabs { position: relative; display: flex; border-bottom: 1px solid rgba(255,255,255,.07); }
.acc-tabs button { flex: 1; padding: 15px 8px 13px; border: none; background: none; color: rgba(255,255,255,.55); font: inherit; font-size: 14px; font-weight: 800; letter-spacing: -.01em; cursor: pointer; transition: color .2s; }
.acc-tabs button:hover { color: rgba(255,255,255,.82); }
.acc-tabs button.active { color: #fff; }
.acc-tabs--left button { flex: 0 0 auto; padding-left: 4px; padding-right: 4px; margin-right: 24px; }
.acc-ink { position: absolute; bottom: -1px; left: 0; height: 2px; width: 0; background: #fff; border-radius: 2px; transition: transform .3s cubic-bezier(.4,0,.2,1), width .3s cubic-bezier(.4,0,.2,1); }

.acc-input {
  width: 100%; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12); border-radius: 12px;
  padding: 10px 12px; color: #fff; font: inherit; font-size: 14px; outline: none; transition: border-color .2s;
}
.acc-input:focus { border-color: rgba(255,255,255,.3); }
.acc-input::placeholder { color: rgba(255,255,255,.28); }

.acc-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 11px 16px;
  border: 1px solid #C0C0C0; border-radius: 12px; background: #C0C0C0; color: #0a0a0a; font: inherit; font-size: 14px; font-weight: 600;
  cursor: pointer; text-decoration: none; transition: opacity .2s, background .2s;
}
.acc-btn:hover { opacity: .9; }
.acc-btn:disabled { opacity: .5; cursor: default; }
.acc-btn--outline { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.14); color: #fff; }
.acc-btn--outline:hover { background: rgba(255,255,255,.08); opacity: 1; }
.acc-btn--danger { background: transparent; border-color: rgba(248,113,113,.5); color: #f87171; }
.acc-btn--sm { width: auto; padding: 8px 14px; font-size: 13px; }
.acc-inline { width: auto; align-self: flex-start; }

.acc-link { color: #C0C0C0; font-size: 12.5px; text-decoration: none; }
.acc-link:hover { color: #fff; }
.acc-error { margin: 0; color: #f87171; font-size: 12.5px; }
.acc-error:empty { display: none; }
.acc-notice { margin: 0 0 20px; padding: 10px 12px; border-radius: 10px; border: 1px solid rgba(34,197,94,.3); color: #86efac; font-size: 13px; }
.acc-muted { color: #9ca3af; margin: 0; }
.acc-small { font-size: 12.5px; }
.acc-strong { color: #fff; font-weight: 500; text-decoration: none; }
a.acc-strong:hover { text-decoration: underline; }

.acc-page { width: 100%; max-width: 720px; }
.acc-head { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.acc-head__text { flex: 1; min-width: 0; }
.acc-name { margin: 0; color: #fff; font-size: 20px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acc-avatar {
  position: relative; width: 52px; height: 52px; padding: 0; border-radius: 50%; flex-shrink: 0; overflow: hidden;
  display: grid; place-items: center; cursor: pointer;
  background: #1f1f1f; border: 1px solid rgba(255,255,255,.12); color: #fff; font-size: 20px; font-weight: 600;
}
.acc-avatar img { width: 100%; height: 100%; object-fit: cover; }
.acc-avatar__edit {
  position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55);
  color: #fff; opacity: 0; transition: opacity .15s;
}
.acc-avatar__edit svg { width: 18px; height: 18px; }
.acc-avatar:hover .acc-avatar__edit, .acc-avatar:focus-visible .acc-avatar__edit, .acc-avatar.busy .acc-avatar__edit { opacity: 1; }
.acc-avatar.busy { cursor: progress; }

/* affiliate tab */
.aff { display: flex; flex-direction: column; }
.aff-stats { display: flex; gap: 12px; margin-top: 18px; flex-wrap: wrap; }
.aff-stat { flex: 1; min-width: 120px; padding: 16px; border: 1px solid rgba(255,255,255,.08); border-radius: 12px; background: rgba(255,255,255,.02); display: flex; flex-direction: column; gap: 4px; }
.aff-stat__v { color: #fff; font-size: 22px; font-weight: 700; }
.aff-stat__l { color: #9ca3af; font-size: 12.5px; }
.aff-set { display: flex; flex-direction: column; gap: 8px; max-width: 340px; }

/* --- balance tab --- */
.bal { display: flex; flex-direction: column; }
.bal-card {
  display: flex; flex-direction: column; gap: 6px;
  padding: 22px; border: 1px solid rgba(255,255,255,.08); border-radius: 14px;
  background: linear-gradient(135deg, rgba(192,192,192,.08), rgba(255,255,255,.02));
}
.bal-card__label { color: #9ca3af; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.bal-card__amount { color: #fff; font-size: 38px; font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.bal-card__note { color: #9ca3af; font-size: 12.5px; margin-top: 2px; }

.bal-topup { display: flex; flex-direction: column; gap: 10px; max-width: 420px; margin-top: 24px; }
.bal-topup__label { color: #fff; font-size: 15px; font-weight: 600; }
.bal-presets { display: flex; gap: 8px; flex-wrap: wrap; }
.bal-preset {
  padding: 7px 14px; border: 1px solid rgba(255,255,255,.14); border-radius: 10px;
  background: rgba(255,255,255,.03); color: #e5e5e5; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.bal-preset:hover { background: rgba(255,255,255,.07); }
.bal-preset.active { border-color: #C0C0C0; background: rgba(192,192,192,.14); color: #fff; }
.bal-amount { max-width: 220px; }

.bal-history { margin-top: 4px; }
.bal-history li { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.bal-amt { font-weight: 700; font-size: 14px; margin-left: auto; }
.bal-amt.is-pos { color: #4ade80; }
.bal-amt.is-neg { color: #f87171; }

.acc-page section { padding-top: 8px; }
.acc-list { list-style: none; margin: 0; padding: 0; }
.acc-list li { display: flex; align-items: center; gap: 16px; padding: 14px 2px; border-bottom: 1px solid rgba(255,255,255,.06); }
.acc-list li > div { flex: 1; min-width: 0; }
.acc-list__review { flex-direction: column; align-items: flex-start !important; gap: 6px !important; }
.acc-stars { color: #00b67a; letter-spacing: 1px; margin-left: 6px; }
.acc-review-body { margin: 0; color: #d1d5db; font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; }
.acc-empty { color: #9ca3af; font-size: 14px; line-height: 1.6; padding: 24px 2px; margin: 0; }

.acc-section { display: flex; flex-direction: column; gap: 10px; padding: 20px 2px; border-bottom: 1px solid rgba(255,255,255,.06); }
.acc-h2 { margin: 0; color: #fff; font-size: 15px; font-weight: 600; }
.acc-row { display: flex; gap: 10px; }
.acc-row .acc-input { flex: 1; }

@media (max-width: 520px) {
  .acc-wrap { padding: 96px 16px 60px; }
  .acc-head { flex-wrap: wrap; }
  .acc-tabs--left button { margin-right: 16px; }
  .acc-list li { flex-wrap: wrap; gap: 6px 12px; }
}
