/* Account pages (WEB_SHOP_V1): /account, /account/success.
   Tokens match the landing page. Rendered by web/routes/account.js. */
:root {
  --ao-ink: #17123B;
  --ao-ink-2: #1E1849;
  --ao-ink-3: #2A2263;
  --ao-violet: #7C6AEF;
  --ao-violet-deep: #5B47C4;
  --ao-saffron: #FFB454;
  --ao-mist: #F4F2FC;
  --ao-line: #E7E4F4;
  --ao-line-2: #F0EEF8;
  --ao-lilac: #C9C3EC;
  --ao-text-2: #4A4470;
  --ao-telegram: #2AABEE;
  --ao-discord: #5865F2;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { font-family: 'Instrument Sans', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
body.acct-dark { background: var(--ao-ink); color: #FFFFFF; }
body.acct-light { background: var(--ao-mist); color: var(--ao-ink); }
body.acct-dark a { color: var(--ao-lilac); }
body.acct-dark a:hover { color: #FFFFFF; }
body.acct-light a { color: var(--ao-violet-deep); }
body.acct-light a:hover { color: var(--ao-ink); }
h1, h2, h3 { font-family: 'Bricolage Grotesque', sans-serif; margin: 0; }
.acct-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.acct-stack { display: flex; flex-direction: column; gap: 10px; }
.acct-stack-sm { display: flex; flex-direction: column; gap: 6px; }
.acct-stack-md { display: flex; flex-direction: column; gap: 16px; }

/* Brand */
.acct-brand { display: inline-flex; align-items: center; gap: 10px; color: #FFFFFF !important; text-decoration: none; font-family: 'Bricolage Grotesque', sans-serif; font-weight: 700; font-size: 20px; }

/* Buttons */
.acct-btn { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; width: 100%; border: 0; border-radius: 12px; font: inherit; font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; }
.acct-btn:focus-visible, .acct-logout:focus-visible { outline: 3px solid var(--ao-saffron); outline-offset: 2px; }
.acct-btn-telegram { min-height: 52px; border-radius: 14px; background: var(--ao-telegram); color: #FFFFFF; font-size: 17px; }
.acct-btn-telegram:hover { filter: brightness(1.05); }
/* DISCORD_WEB_LOGIN_V1: same size and shape as the Telegram button, Discord blurple. */
.acct-btn-discord { min-height: 52px; border-radius: 14px; background: var(--ao-discord); color: #FFFFFF !important; font-size: 17px; }
.acct-btn-discord:hover { filter: brightness(1.08); color: #FFFFFF !important; }
.acct-btn-ghost-dark { min-height: 52px; border-radius: 14px; background: transparent; border: 1px solid var(--ao-lilac); color: #FFFFFF !important; font-weight: 600; }
.acct-btn-ghost-dark:hover { background: var(--ao-ink-3); }
.acct-login-buttons { display: flex; flex-direction: column; gap: 12px; }
.acct-steps { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; text-align: left; font-size: 15px; line-height: 1.45; color: #E2DEF7; }
.acct-btn-buy { background: var(--ao-violet-deep); color: #FFFFFF !important; }
.acct-btn-buy:hover { background: #4E3BB0; }
.acct-btn-ghost { background: transparent; border: 1px solid var(--ao-lilac); color: var(--ao-ink) !important; font-weight: 600; }
.acct-notice { margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--ao-ink-3); color: #FFFFFF; font-size: 15px; text-align: left; }
.acct-notice-light { background: #FFF4E3; color: var(--ao-ink); border: 1px solid #F5D9A8; }

/* Login */
.acct-login { min-height: 100vh; display: flex; flex-direction: column; }
.acct-login-header { max-width: 1120px; width: 100%; margin: 0 auto; padding: 18px 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.acct-back { font-size: 15px; padding: 12px 4px; }
.acct-login-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 32px 16px 64px; }
.acct-login-card { width: 100%; max-width: 460px; background: var(--ao-ink-2); border: 1px solid var(--ao-ink-3); border-radius: 24px; padding: 40px 32px; display: flex; flex-direction: column; gap: 22px; text-align: center; }
.acct-login-card h1 { font-size: 34px; font-weight: 800; letter-spacing: -0.4px; }
.acct-lede { margin: 0; font-size: 16px; line-height: 1.5; color: var(--ao-lilac); }
.acct-checks { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; text-align: left; font-size: 15px; color: #E2DEF7; }
.acct-checks li { display: flex; gap: 10px; align-items: flex-start; }
.acct-checks svg { flex: none; margin-top: 1px; }
.acct-small { margin: 0; font-size: 14px; color: var(--ao-lilac); }
.acct-login-footer { text-align: center; padding: 0 16px 28px; font-size: 13px; color: #A8A1D6; }

/* Account header */
.acct-header { background: var(--ao-ink); color: #FFFFFF; }
.acct-header-inner { max-width: 1120px; margin: 0 auto; padding: 18px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.acct-who { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.acct-who form { margin: 0; }
.acct-id { display: flex; align-items: center; gap: 10px; }
.acct-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--ao-ink-3); display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ao-saffron); }
.acct-id-text { display: flex; flex-direction: column; line-height: 1.2; }
.acct-id-name { font-weight: 600; font-size: 15px; }
.acct-id-user { font-size: 13px; color: var(--ao-lilac); font-family: 'Spline Sans Mono', monospace; }
.acct-logout { background: none; border: 0; color: var(--ao-lilac); font: inherit; font-size: 14px; padding: 12px 8px; text-decoration: underline; cursor: pointer; }
.acct-logout:hover { color: #FFFFFF; }

/* Account main */
.acct-main { max-width: 1120px; margin: 0 auto; padding: 40px 24px 64px; display: flex; flex-direction: column; gap: 28px; }
.acct-h1 { font-size: 40px; font-weight: 800; letter-spacing: -0.5px; }
.acct-sub { margin: 0; font-size: 17px; color: var(--ao-text-2); }
.acct-h2 { font-size: 28px; font-weight: 800; }
.acct-h3 { font-size: 22px; font-weight: 800; }
.acct-grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.acct-grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.acct-card { background: #FFFFFF; border: 1px solid var(--ao-line); border-radius: 18px; padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.acct-card-ink { background: var(--ao-ink); border-color: var(--ao-ink); color: #FFFFFF; }
.acct-label { font-size: 13px; font-weight: 600; letter-spacing: 0.6px; text-transform: uppercase; color: var(--ao-violet-deep); }
.acct-label-saffron { color: var(--ao-saffron); }
.acct-big { font-family: 'Bricolage Grotesque', sans-serif; font-size: 52px; font-weight: 800; line-height: 1; }
.acct-plan { font-family: 'Bricolage Grotesque', sans-serif; font-size: 32px; font-weight: 800; line-height: 1.1; }
.acct-plan-link { font-size: 15px; font-weight: 600; margin-top: auto; padding-top: 6px; }
.acct-detail { font-size: 14px; color: var(--ao-text-2); margin: 0; }
.acct-detail-ink { color: var(--ao-lilac); }
.acct-code { font-family: 'Spline Sans Mono', monospace; font-size: 17px; background: var(--ao-ink-3); border-radius: 10px; padding: 12px 14px; overflow-wrap: anywhere; }
.acct-row { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; }
.acct-pack { background: #FFFFFF; border: 1px solid var(--ao-line); border-radius: 18px; padding: 26px; display: flex; flex-direction: column; gap: 14px; }
.acct-pack-best { border: 2px solid var(--ao-violet); }
.acct-pack form { margin: 6px 0 0; }
.acct-pack-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.acct-pack-name { font-family: 'Bricolage Grotesque', sans-serif; font-size: 26px; font-weight: 800; }
.acct-badge { background: var(--ao-saffron); color: var(--ao-ink); font-size: 12px; font-weight: 700; border-radius: 999px; padding: 5px 10px; white-space: nowrap; }
.acct-pack-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.acct-price { font-family: 'Bricolage Grotesque', sans-serif; font-size: 44px; font-weight: 800; line-height: 1; }
.acct-per { font-size: 15px; color: var(--ao-text-2); }
.acct-pack-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 15px; color: #2C2650; }
.acct-history { gap: 12px; }
.acct-table-wrap { overflow-x: auto; }
.acct-table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 460px; }
.acct-table th { text-align: left; color: var(--ao-text-2); font-size: 13px; font-weight: 600; padding: 10px 8px; border-bottom: 1px solid var(--ao-line); }
.acct-table td { padding: 12px 8px; border-bottom: 1px solid var(--ao-line-2); }
.acct-num { text-align: right !important; }
.acct-muted { color: var(--ao-text-2); }
.acct-c-date, .acct-c-amt { white-space: nowrap; }
.acct-status { font-size: 13px; font-weight: 600; color: var(--ao-ink); white-space: nowrap; }
.acct-status-on { color: var(--ao-violet-deep); }
.acct-status-off { color: var(--ao-text-2); font-weight: 500; }
.acct-plan-when { font-family: 'Instrument Sans', system-ui, sans-serif; font-size: 17px; font-weight: 600; color: var(--ao-text-2); white-space: nowrap; }
.acct-footer { display: flex; flex-wrap: wrap; gap: 18px; font-size: 14px; color: var(--ao-text-2); }

/* Success */
.acct-success-wrap { min-height: 100vh; display: flex; flex-direction: column; }
.acct-success-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 40px 16px 64px; }
.acct-success-card { width: 100%; max-width: 520px; background: #FFFFFF; border: 1px solid var(--ao-line); border-radius: 24px; padding: 40px 32px; display: flex; flex-direction: column; gap: 20px; text-align: center; align-items: center; }
.acct-h1-sm { font-size: 34px; font-weight: 800; }
.acct-lede-dark { margin: 0; font-size: 16px; line-height: 1.5; color: var(--ao-text-2); }
.acct-lede-dark strong { color: var(--ao-ink); }
.acct-try { width: 100%; background: var(--ao-ink); color: #FFFFFF; border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 6px; text-align: left; }
.acct-mono { font-family: 'Spline Sans Mono', monospace; font-size: 16px; overflow-wrap: anywhere; }
.acct-actions { width: 100%; display: flex; flex-wrap: wrap; gap: 12px; }
.acct-actions .acct-btn { flex: 1 1 200px; width: auto; }
.acct-small-dark { margin: 0; font-size: 13px; color: var(--ao-text-2); }

@media (max-width: 520px) {
  .acct-login-card, .acct-success-card { padding: 32px 20px; }
  .acct-login-header, .acct-header-inner { padding: 14px 16px; }
  .acct-main { padding: 28px 16px 48px; }
  .acct-h1 { font-size: 32px; }
  .acct-login-card h1, .acct-h1-sm { font-size: 28px; }
  .acct-big { font-size: 44px; }
  .acct-price { font-size: 38px; }
  /* Purchases: each row stacks into two lines (item + amount, then date ·
     paid with · status) so the table never needs a sideways scroll. */
  .acct-table { min-width: 0; }
  .acct-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .acct-table, .acct-table tbody { display: block; }
  .acct-table tr { display: grid; grid-template-columns: auto auto 1fr auto; gap: 4px 6px; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--ao-line-2); }
  .acct-table td { padding: 0; border: 0; }
  .acct-c-item { grid-column: 1 / 4; grid-row: 1; font-weight: 600; min-width: 0; }
  .acct-c-amt { grid-column: 4; grid-row: 1; }
  .acct-c-date, .acct-c-via { grid-row: 2; font-size: 13px; color: var(--ao-text-2); }
  .acct-c-date { grid-column: 1; }
  .acct-c-via { grid-column: 2; }
  .acct-c-via::before { content: "· "; }
  .acct-c-status { grid-column: 4; grid-row: 2; text-align: right; }
  .acct-c-empty { grid-column: 1 / -1; }
}
