/* =========================================================
   DV Investment Advisors — auth pages (login / signup / account)
   ========================================================= */

.auth {
  min-height: calc(100vh - 74px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 24px;
  background:
    radial-gradient(1100px 520px at 50% -10%, rgba(200,164,92,.10), transparent 60%),
    linear-gradient(180deg, var(--bg-soft), var(--bg-softer));
}

.auth__card {
  width: 100%;
  max-width: 440px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 40px 36px;
}

.auth__card .eyebrow { margin-bottom: .6rem; }
.auth__title { font-size: clamp(1.7rem, 4vw, 2.1rem); margin-bottom: .35rem; }
.auth__sub { color: var(--muted); font-size: .98rem; margin-bottom: 1.6rem; }

/* Google button */
.btn--google {
  width: 100%;
  justify-content: center;
  background: #fff;
  border-color: var(--line);
  color: var(--ink);
  font-weight: 600;
}
.btn--google:hover { border-color: #c9d3e2; background: #fafbfd; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.btn--google svg { width: 18px; height: 18px; }

/* Divider */
.auth__divider {
  display: flex; align-items: center; gap: .9rem;
  color: var(--muted); font-size: .82rem;
  margin: 1.3rem 0;
}
.auth__divider::before, .auth__divider::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}

/* Message banner */
.auth__msg {
  padding: .75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  margin-bottom: 1.1rem;
  line-height: 1.45;
}
.auth__msg--error   { background: #fdecec; color: #a12626; border: 1px solid #f5c2c2; }
.auth__msg--success { background: #eaf7ee; color: #1e6b39; border: 1px solid #bfe3cb; }

.auth__submit { width: 100%; justify-content: center; margin-top: .4rem; }

.auth__row { display: flex; justify-content: flex-end; margin: -.4rem 0 1rem; }
.auth__row a { font-size: .85rem; }

.auth__switch { text-align: center; margin: 1.5rem 0 0; color: var(--muted); font-size: .93rem; }
.auth__switch a { font-weight: 600; color: var(--navy-600); }
.auth__switch a:hover { color: var(--gold-500); }

.auth__legal { text-align: center; margin: 1rem 0 0; font-size: .78rem; color: var(--muted); line-height: 1.5; }

/* Account / dashboard */
.account { padding: 72px 0 90px; min-height: calc(100vh - 74px); background: var(--bg-soft); }
.account__head { display: flex; align-items: center; gap: 1.1rem; margin-bottom: 2rem; flex-wrap: wrap; }
.account__avatar {
  width: 60px; height: 60px; border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(150deg, var(--navy-800), var(--navy-600));
  color: var(--gold-400); font-family: var(--font-head); font-size: 1.5rem; font-weight: 600;
  overflow: hidden; flex: none;
}
.account__avatar img { width: 100%; height: 100%; object-fit: cover; }
.account__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; margin-top: 1.6rem; }
.account__row { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.account__row:last-child { border-bottom: 0; }
.account__row span:first-child { color: var(--muted); font-size: .92rem; }
.account__row span:last-child { font-weight: 600; color: var(--navy-900); word-break: break-word; text-align: right; }

.auth-loading { display: grid; place-items: center; min-height: 60vh; color: var(--muted); }

@media (max-width: 520px) {
  .auth__card { padding: 32px 24px; }
}

/* =========================================================
   Nav auth chip / account state
   ========================================================= */
.nav__account { display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; color: var(--navy-800); }
.nav__account:hover { color: var(--gold-500); }
.nav__avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(150deg, var(--navy-800), var(--navy-600));
  color: var(--gold-400); font-family: var(--font-head); font-weight: 600; font-size: .9rem;
}
.nav__avatar img { width: 100%; height: 100%; object-fit: cover; }
.nav__accname { line-height: 1; }

/* =========================================================
   Toast notifications
   ========================================================= */
.toast-host {
  position: fixed; z-index: 200; left: 50%; bottom: 24px; transform: translateX(-50%);
  display: flex; flex-direction: column; gap: .6rem; width: min(92vw, 420px);
}
.toast {
  padding: .85rem 1.1rem; border-radius: var(--radius-sm); font-size: .95rem; font-weight: 500;
  box-shadow: var(--shadow-md); opacity: 0; transform: translateY(12px);
  transition: opacity .28s ease, transform .28s ease; color: #fff;
}
.toast.in { opacity: 1; transform: none; }
.toast--success { background: #1e7d47; }
.toast--error { background: #b8342b; }

/* =========================================================
   Danger zone + danger button
   ========================================================= */
.btn--danger { background: #b8342b; color: #fff; border-color: #b8342b; }
.btn--danger:hover { background: #9c2a22; color: #fff; transform: translateY(-2px); box-shadow: 0 8px 22px rgba(184,52,43,.3); }
.danger-zone { border-color: #f0c9c6; }
.danger-zone h3 { color: #b8342b; }
.danger-row {
  display: flex; align-items: center; justify-content: space-between; gap: 1.2rem;
  padding: 1rem 0; border-top: 1px solid var(--line); flex-wrap: wrap;
}
.danger-row:first-of-type { border-top: 0; }
.danger-row strong { color: var(--navy-900); }
.danger-row .form-note { margin: .2rem 0 0; }
.danger-row .btn { flex: none; }

/* =========================================================
   Modal (delete confirmation)
   ========================================================= */
.modal { position: fixed; inset: 0; z-index: 300; display: grid; place-items: center; padding: 24px; }
.modal[hidden] { display: none; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(10,26,51,.55); backdrop-filter: blur(2px); }
.modal__card {
  position: relative; z-index: 1; width: 100%; max-width: 460px;
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-md); padding: 30px 28px;
}
.modal__card h3 { color: #b8342b; margin-bottom: .5rem; }
.modal__card p { font-size: .96rem; color: var(--muted); }
.modal__actions { display: flex; justify-content: flex-end; gap: .7rem; flex-wrap: wrap; }
.modal__actions .btn { justify-content: center; }

[dir="rtl"] .danger-row { text-align: right; }
