/* /account — registration, password recovery and account management on pandoraworld.net. Same tokens as
   site.css / silk.css (dark first, light variant); own sheet so the page does not depend on the hashed site sheet.
   Layout (owner 2026-11-02 UI/UX pass): desktop = brand panel (art, title, perks) + form card side by side; the logged-in
   panel = profile sidebar + tabbed settings; phone = one column, the brand panel shrinks to a title band. */
:root {
  --bg: #0c0a07; --surface: #17130d; --surface-2: #1f1a12; --line: #3a3122; --line-soft: #2a2318; --text: #ece5d3; --muted: #a89f8a;
  --gold: #d9b765; --gold-strong: #f1d68f; --gold-ink: #1a1305; --cta-top: #f0d27f; --cta-bottom: #b98d34;
  --ok: #9fe07a; --bad: #ff7a6a; --warn: #e8b84a; --focus: #f6dc93; --radius: 14px;
  --shadow: 0 18px 48px rgba(0, 0, 0, .45);
  --font-display: "Palatino Linotype", Palatino, "Book Antiqua", "Iowan Old Style", Georgia, serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f4f2ed; --surface: #fffdf8; --surface-2: #f1ece1; --line: #d6ccb6; --line-soft: #e6dfcf; --text: #1c170e; --muted: #5f5645;
    --gold: #85641b; --gold-strong: #5e4510; --ok: #2f7d1f; --bad: #b3261e; --warn: #8a5a00; --focus: #6b4e12; color-scheme: light;
    --shadow: 0 12px 32px rgba(60, 45, 15, .12);
  }
}
:root[data-theme="light"] {
  --bg: #f4f2ed; --surface: #fffdf8; --surface-2: #f1ece1; --line: #d6ccb6; --line-soft: #e6dfcf; --text: #1c170e; --muted: #5f5645;
  --gold: #85641b; --gold-strong: #5e4510; --ok: #2f7d1f; --bad: #b3261e; --warn: #8a5a00; --focus: #6b4e12; color-scheme: light;
  --shadow: 0 12px 32px rgba(60, 45, 15, .12);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--text); font: 1rem/1.55 var(--font-body); }
a { color: var(--gold); }
a:hover { color: var(--gold-strong); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
[hidden] { display: none !important; }

/* ── header / footer ── */
.acct-head { display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 12px clamp(16px, 4vw, 32px); border-bottom: 1px solid var(--line-soft); }
.acct-head img { height: 34px; width: auto; display: block; }
.acct-head nav { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; justify-content: flex-end; font-size: .9rem; }
.acct-head nav a { text-decoration: none; }
.acct-head select { width: auto; min-height: 34px; padding: 4px 8px; font-size: .85rem; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--text); }
footer { text-align: center; color: var(--muted); font-size: .85rem; padding: 20px 16px; border-top: 1px solid var(--line-soft); }
footer a { margin: 0 8px; }

/* ── page layout ── */
.auth { flex: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding: clamp(16px, 4vw, 40px) clamp(16px, 4vw, 32px) 48px;
  display: grid; gap: clamp(20px, 3vw, 40px); grid-template-columns: minmax(0, 1fr); align-items: start; }
.auth__brand { position: relative; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--line-soft); padding: 20px;
  background: linear-gradient(180deg, rgba(12, 10, 7, .35), rgba(12, 10, 7, .92)), url("/images/wharf-900.jpg") center / cover no-repeat; color: #f3ecda; }
.auth__brand h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.6rem, 1.2rem + 2vw, 2.4rem); line-height: 1.15; margin: 0 0 6px; }
.auth__brand .lede { color: #d6cdb6; margin: 0; }
.perks { display: none; list-style: none; padding: 0; margin: 22px 0 0; gap: 12px; }
.perks li { position: relative; padding-inline-start: 30px; color: #e9e1cb; }
.perks li::before { content: ""; position: absolute; inset-inline-start: 0; top: .2em; width: 20px; height: 20px; border-radius: 50%;
  background: linear-gradient(var(--cta-top), var(--cta-bottom)); }
.perks li::after { content: ""; position: absolute; inset-inline-start: 7px; top: calc(.2em + 4px); width: 5px; height: 9px; border: solid #1a1305; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.auth__panel { min-width: 0; }
@media (min-width: 880px) {
  .auth { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: stretch; }
  .auth__brand { padding: 36px; min-height: 520px; display: flex; flex-direction: column; justify-content: flex-end;
    background-image: linear-gradient(180deg, rgba(12, 10, 7, .1) 0%, rgba(12, 10, 7, .55) 45%, rgba(12, 10, 7, .95) 100%), url("/images/wharf-1600.jpg"); }
  .perks { display: grid; }
}
/* Logged-in panel: the brand panel becomes a title band above a wide dashboard. */
body.is-dashboard .auth { grid-template-columns: minmax(0, 1fr); }
body.is-dashboard .auth__brand { min-height: 0; padding: 22px 24px; background-image: linear-gradient(90deg, rgba(12, 10, 7, .92), rgba(12, 10, 7, .55)), url("/images/wharf-1600.jpg"); }
body.is-dashboard .perks, body.is-dashboard .auth__brand .lede { display: none; }

/* ── cards and forms ── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(18px, 3vw, 28px); box-shadow: var(--shadow); }
.card + .card, .card + .links, .banner + .card { margin-top: 16px; }
.card h2 { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; margin: 0 0 4px; }
.card__sub { color: var(--muted); margin: 0 0 6px; font-size: .92rem; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset + fieldset { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line-soft); }
legend { padding: 0; margin: 0 0 4px; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.grid-2 { display: grid; gap: 0 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .grid-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.field { display: grid; gap: 6px; margin: 14px 0 0; align-content: start; }
.field__top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.field label { font-size: .88rem; font-weight: 600; color: var(--text); }
.field__top a { font-size: .85rem; }
.hint { font-size: .8rem; color: var(--muted); margin: 0; }
.hint--strong { color: var(--gold-strong); }
.field__error { font-size: .82rem; color: var(--bad); margin: 0; }
.field__error:empty { display: none; }
input[type="text"], input[type="password"], input[type="email"], select {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text);
  font: inherit; font-size: 16px; transition: border-color .15s, box-shadow .15s; }
input:hover, select:hover { border-color: color-mix(in srgb, var(--gold) 45%, var(--line)); }
input:focus, select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px color-mix(in srgb, var(--gold) 25%, transparent); }
input[aria-invalid="true"], select[aria-invalid="true"] { border-color: var(--bad); box-shadow: 0 0 0 3px color-mix(in srgb, var(--bad) 18%, transparent); }
.pw { position: relative; }
.pw input { padding-inline-end: 84px; }
.pw__toggle { position: absolute; inset-inline-end: 6px; top: 50%; transform: translateY(-50%); min-height: 34px; padding: 4px 12px; border-radius: 8px;
  border: 0; background: var(--surface-2); color: var(--muted); font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer; }
.pw__toggle:hover { color: var(--text); }
.meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: 2px; }
.meter span { height: 4px; border-radius: 4px; background: var(--line-soft); transition: background .2s; }
.meter[data-score="1"] span:nth-child(-n+1) { background: var(--bad); }
.meter[data-score="2"] span:nth-child(-n+2) { background: var(--warn); }
.meter[data-score="3"] span:nth-child(-n+3) { background: var(--gold); }
.meter[data-score="4"] span { background: var(--ok); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 20px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
.btn:hover { border-color: var(--gold); color: var(--text); }
.btn--cta { background: linear-gradient(var(--cta-top), var(--cta-bottom)); color: var(--gold-ink); border-color: transparent; }
.btn--cta:hover { color: var(--gold-ink); filter: brightness(1.06); }
.btn--block { width: 100%; }
.btn--ghost { background: transparent; }
.btn[disabled] { opacity: .6; cursor: default; filter: none; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 20px; }
.actions { margin-top: 22px; }
.links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; font-size: .92rem; text-align: center; }
.alert { margin: 16px 0 0; padding: 10px 14px; border-radius: 10px; font-size: .9rem; border: 1px solid; }
.alert:empty { display: none; }
.alert--bad { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, transparent); background: color-mix(in srgb, var(--bad) 8%, transparent); }
.alert--ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 40%, transparent); background: color-mix(in srgb, var(--ok) 8%, transparent); font-weight: 600; }
.banner { padding: 12px 16px; border-radius: 10px; border: 1px solid var(--gold); background: color-mix(in srgb, var(--gold) 10%, transparent); color: var(--gold-strong); font-size: .92rem; }
.captcha { margin: 16px 0 0; }
.captcha .row { margin-top: 10px; }
.success { text-align: center; }
.success__icon { width: 56px; height: 56px; margin: 4px auto 12px; border-radius: 50%; background: linear-gradient(var(--cta-top), var(--cta-bottom)); position: relative; }
.success__icon::after { content: ""; position: absolute; left: 21px; top: 13px; width: 12px; height: 22px; border: solid var(--gold-ink); border-width: 0 3px 3px 0; transform: rotate(45deg); }
.success .row { justify-content: center; }
.idline { display: inline-flex; gap: 8px; align-items: baseline; padding: 8px 14px; border-radius: 10px; background: var(--surface-2); margin: 10px 0 4px; }
.idline b { font-size: 1.05rem; }

/* ── recover stepper ── */
.steps { display: flex; gap: 8px; list-style: none; padding: 0; margin: 0 0 18px; counter-reset: step; }
.steps li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: .82rem; color: var(--muted); min-width: 0; }
.steps li::before { counter-increment: step; content: counter(step); flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line); font-weight: 700; font-size: .8rem; }
.steps li[aria-current="step"] { color: var(--text); font-weight: 600; }
.steps li[aria-current="step"]::before, .steps li.done::before { background: linear-gradient(var(--cta-top), var(--cta-bottom)); color: var(--gold-ink); border-color: transparent; }
.question { margin: 4px 0 0; padding: 12px 14px; border-radius: 10px; background: var(--surface-2); font-family: var(--font-display); font-size: 1.1rem; }

/* ── dashboard ── */
.dash { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 880px) { .dash { grid-template-columns: 300px minmax(0, 1fr); } }
.profile { text-align: center; }
.avatar { width: 72px; height: 72px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display);
  font-size: 2rem; font-weight: 700; color: var(--gold-ink); background: linear-gradient(var(--cta-top), var(--cta-bottom)); }
.profile__name { font-size: 1.2rem; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.who { display: grid; gap: 2px; margin: 16px 0 0; text-align: start; }
.who div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-soft); }
.who dt { color: var(--muted); font-size: .88rem; }
.who dd { margin: 0; font-weight: 600; font-size: .92rem; overflow-wrap: anywhere; text-align: end; }
.profile .hint { margin-top: 12px; text-align: start; }
.profile .btn { margin-top: 16px; }
.tabs { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-2); overflow-x: auto; scrollbar-width: none; margin: 0 0 18px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: 1 0 auto; min-height: 40px; padding: 8px 14px; border: 0; border-radius: 9px; background: transparent; color: var(--muted);
  font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer; white-space: nowrap; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0, 0, 0, .3); }
.spin { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(26, 19, 5, .3); border-top-color: currentColor; border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } input, select, .meter span { transition: none; } }
