@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
:root {
  color-scheme: light;
  font-family: Inter, "Segoe UI", system-ui, sans-serif;
  --night: #101126;
  --ink: #17182e;
  --muted: #565a73;
  --orange: #ff9c47;
  --line: #e0e0ed;
  --soft: #f5f4fa;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--soft); color: var(--ink); }
h1, h2, p, dl, dd { margin: 0; }
a { color: inherit; }
button, input { font: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #b45400; outline-offset: 4px; }
.shell { width: min(100% - 64px, 1120px); margin-inline: auto; }
.skip { position: absolute; top: 12px; left: 12px; z-index: 2; padding: 12px; background: #fff; transform: translateY(-150%); }
.skip:focus { transform: none; }
.topbar { background: var(--night); color: #faf9ff; border-bottom: 1px solid #ffffff22; }
.topbar-inner, .topbar-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.topbar-inner { min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; font-size: .9rem; letter-spacing: .035em; font-weight: 800; white-space: nowrap; }
.brand img { flex: none; border-radius: 23%; }
.return-site { text-decoration: none; font-size: .86rem; font-weight: 650; color: #e5e2f5; }
.return-site:hover { text-decoration: underline; text-underline-offset: 4px; }
.login, .dashboard-hero {
  background: radial-gradient(ellipse at 18% 75%, #393866 0%, #222346 41%, transparent 75%), var(--night);
  color: #faf9ff;
}
.login { min-height: calc(100svh - 72px); display: grid; align-items: center; padding-block: clamp(40px, 6vw, 84px); }
.login-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 450px); align-items: center; gap: clamp(36px, 8vw, 106px); }
.login-intro h1, .dashboard-hero h1 { font-size: clamp(2.6rem, 6.3vw, 5.6rem); line-height: 1; letter-spacing: -.068em; font-weight: 780; }
h1 em { color: var(--orange); font-style: normal; }
.login-intro h1 em { display: block; }
.login-intro p, .dashboard-hero p { color: #deddf0; margin-top: 20px; max-width: 380px; font-size: clamp(1rem, 1.8vw, 1.2rem); line-height: 1.6; }
.login-art {
  width: min(72%, 370px);
  aspect-ratio: 1;
  margin: 4px 0 -20px 7%;
  background: url("hero-640.webp") center / contain no-repeat;
}
.login-panel, .panel { border: 1px solid var(--line); border-radius: 26px; background: #fff; color: var(--ink); }
.login-panel { padding: clamp(21px, 4vw, 37px); box-shadow: 0 18px 60px #0d0d2b55; }
h2 { font-size: clamp(1.35rem, 2.75vw, 1.8rem); font-weight: 770; letter-spacing: -.04em; }
.muted { color: var(--muted); margin: 10px 0 19px; font-size: .94rem; line-height: 1.55; }
.stack { display: grid; gap: 10px; min-width: 0; }
label { display: block; font-size: .86rem; font-weight: 700; }
input:not([type="hidden"]) { min-height: 48px; min-width: 0; width: 100%; padding: 10px 13px; border: 1px solid #c5c6d9; background: #fff; border-radius: 12px; color: var(--ink); font-size: 1rem; }
input::placeholder { color: #626781; }
.input-row { display: flex; gap: 8px; margin-top: 8px; }
.input-row input { font-family: ui-monospace, monospace; }
.input-row .btn { flex: none; }
.email-address, .profile dd, .max-details p { overflow-wrap: anywhere; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 47px; border: 1px solid transparent; border-radius: 12px; padding: 8px 13px; font-size: .9rem; font-weight: 730; text-decoration: none; cursor: pointer; }
.btn:disabled { opacity: .6; cursor: default; }
.btn img { flex: none; }
.btn.primary { background: var(--orange); color: #25192d; }
.btn.primary:hover { background: #ffb777; }
.btn.max-button { width: 100%; background: #292746; color: #fff; }
.btn.max-button:hover { background: #3d3a60; }
.btn.soft { border-color: var(--line); background: #f5f4fb; color: #2c2e51; }
.btn.soft:hover { background: #e9e6f6; }
.btn.inverse { min-height: 42px; border-color: #9897b7; color: #fff; background: transparent; }
.btn.inverse:hover { background: #ffffff1b; }
.divider { display: flex; align-items: center; gap: 12px; margin-block: 16px; color: var(--muted); font-size: .84rem; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.reset { display: flex; justify-content: flex-start; margin-top: 12px; }
.link { min-height: 44px; padding: 0; border: 0; background: none; color: #393763; font-size: .88rem; font-weight: 650; text-align: left; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.secondary-form { margin-top: 8px; }
.notice { margin-bottom: 14px; padding: 10px 13px; border-radius: 10px; background: #f0eff9; color: #33355c; line-height: 1.45; }
.notice.error { background: #fff0ec; color: #8a2c1d; }
.max-details { margin-top: 16px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; }
.max-details summary { color: #33355c; font-size: .88rem; font-weight: 700; cursor: pointer; }
.max-details p { margin-bottom: 9px; }
.max-details .copy-status { margin: 0; color: var(--muted); font-size: .83rem; }
.max-details .copy-status:not(:empty) { margin-top: 8px; }
.wait { display: flex; align-items: center; gap: 8px; min-height: 36px; margin-block: 9px; color: var(--muted); font-size: .87rem; line-height: 1.35; }
.wait-indicator { width: 15px; height: 15px; flex: none; border: 2px solid #eee2d6; border-top-color: #b45400; border-radius: 50%; animation: rotate .9s linear infinite; }
@keyframes rotate { to { transform: rotate(360deg); } }
.dashboard-hero { padding: 44px 0 68px; }
.dashboard-hero h1 { font-size: clamp(2.4rem, 5.3vw, 4.65rem); }
.dashboard-hero p { margin-top: 12px; overflow-wrap: anywhere; }
.dashboard { position: relative; margin: -28px auto 50px; display: grid; grid-template-columns: 2fr 1fr; align-items: start; gap: 18px; }
.panel { min-width: 0; padding: clamp(18px, 3vw, 27px); }
.orders-panel { grid-column: 1 / -1; }
.empty { border: 1px dashed #c8c6df; border-radius: 12px; margin-top: 16px; padding: 18px; color: var(--muted); line-height: 1.45; }
.profile { display: grid; gap: 14px; margin-top: 16px; }
.profile dt { color: var(--muted); font-size: .81rem; }
.profile dd { margin-top: 4px; font-weight: 680; }
.card-grid {
  display: grid; grid-template-columns: minmax(0, 20rem);
  grid-template-columns: repeat(auto-fill, min(100%, 20rem)); gap: 14px;
  margin: 16px 0 0; padding: 0; list-style: none;
}
.wallet-card { min-width: 0; }
.card {
  position: relative; isolation: isolate; overflow: hidden; min-width: 0; aspect-ratio: 8 / 5;
  container-type: inline-size; display: flex;
  color: #fff; border-radius: 15px; background: radial-gradient(ellipse at 105% -20%, #725591, transparent 63%), #24254b;
}
.card:has(.card-cover)::after {
  position: absolute; z-index: -1; inset: 0; content: "";
  background: linear-gradient(180deg, #101126ef, #1011263d 46%, #101126dc 77%, #101126fa);
}
.card-cover { position: absolute; z-index: -2; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-info {
  display: flex; flex-direction: column; justify-content: space-between; gap: 8px;
  min-width: 0; width: 100%; padding: 12px; padding: clamp(9px, 5cqi, 16px);
}
.card-heading, .card-balance { display: grid; justify-items: start; gap: 3px; min-width: 0; }
.card-title, .card-number { max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.card-title { font-size: .94rem; font-size: clamp(.88rem, 5.5cqi, 1.1rem); line-height: 1.2; }
.card-number, .card-balance span, .card-balance time {
  color: #f3f1ff; font-size: .72rem; font-size: clamp(.67rem, 4cqi, .8rem); line-height: 1.2;
}
.card-balance-value { font-size: 1.35rem; font-size: clamp(1.2rem, 8.5cqi, 1.75rem); line-height: 1.07; font-variant-numeric: tabular-nums; }
.card-blocked { color: #ffd3ac; font-size: .7rem; font-size: clamp(.65rem, 3.8cqi, .75rem); font-weight: 700; }
.card-actions, .card-settings-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.card-actions { margin-top: 8px; }
.card-actions .btn { min-height: 44px; }
.btn.card-remove-link { color: #8a2c1d; }
.btn.card-remove-link:hover { background: #fff0ec; }
.btn.danger { background: #a62e25; color: #fff; }
.btn.danger:hover { background: #84221b; }
.card-settings { max-width: 680px; padding-block: 24px 48px; }
.card-back { display: inline-flex; align-items: center; }
.card-settings-panel { margin-top: 4px; }
.card-settings-heading { margin-bottom: 20px; }
.card-settings-panel h1 { margin-bottom: 8px; font-size: clamp(1.5rem, 4vw, 2.15rem); line-height: 1.17; }
.card-settings-panel p { color: var(--muted); line-height: 1.5; overflow-wrap: anywhere; }
.card-settings-panel .notice.error { color: #8a2c1d; }
.card-settings-form { display: grid; gap: 20px; }
.card-settings-panel > .card-settings-actions { margin-top: 20px; }
.card-cover-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.card-cover-field legend { margin-bottom: 10px; padding: 0; font-size: .86rem; font-weight: 700; }
.cover-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 112px), 1fr)); gap: 10px; }
.cover-option { position: relative; cursor: pointer; }
.cover-option input[type="radio"] { position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; opacity: 0; }
.cover-choice {
  display: grid; place-items: center; aspect-ratio: 8 / 5; overflow: hidden; padding: 4px;
  border: 2px solid var(--line); border-radius: 12px; background: var(--soft); color: var(--ink); text-align: center;
}
.cover-choice img { width: 100%; height: 100%; min-height: 0; object-fit: cover; border-radius: 6px; }
.cover-option input:checked + .cover-choice { border-color: #b45400; background: #fff1de; }
.cover-option input:focus-visible + .cover-choice { outline: 3px solid #b45400; outline-offset: 3px; }
.order-table { margin-top: 14px; overflow-x: auto; }
table { border-collapse: collapse; text-align: left; width: 100%; font-size: .9rem; }
th, td { border-bottom: 1px solid var(--line); padding: 12px 10px; vertical-align: top; min-width: 100px; }
th { color: var(--muted); font-size: .8rem; font-weight: 700; }
tbody tr:last-child td { border-bottom: 0; }
.amount { white-space: nowrap; font-weight: 750; }
.payment-status { display: inline-block; border-radius: 12px; padding: 4px 8px; background: #f2f0fa; color: #3c3e63; font-size: .78rem; font-weight: 700; }
.payment-status.success { color: #126747; background: #e0f4eb; }
@media (max-width: 760px) {
  .shell { width: calc(100% - 32px); }
  .topbar-inner, .topbar-actions { gap: 10px; }
  .brand { font-size: .78rem; gap: 7px; }
  .brand img { width: 33px; height: 33px; }
  .return-site { font-size: .78rem; }
  .login { align-items: start; padding-block: 29px 36px; }
  .login-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; max-width: 510px; }
  .login-intro h1 em { display: inline; }
  .login-intro p { margin-top: 11px; }
  .login-art { display: none; }
  .dashboard { grid-template-columns: minmax(0, 1fr); gap: 13px; }
  .dashboard-hero { padding-block: 30px 56px; }
}
@media (max-width: 420px) {
  .topbar-actions:has(form) .return-site { display: none; }
  .input-row { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .wait-indicator { animation: none; }
}
