:root {
  --bg: #f4f4f4;
  --surface: #fff;
  --soft: #f2f2f2;
  --soft-hover: #e9e9e9;
  --text: #171717;
  --muted: #8b8b8b;
  --border: #e5e5e5;
  --accent: #ffdd2d;
  --accent-hover: #f4d21f;
  --green: #18a957;
  --green-soft: #e8f7ed;
  --danger: #db4b5e;
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

/* UX completion pass: clearer cards, filtered events, safer topups. */
.screen-home .cards-section .section-heading > div {
  display: grid;
  gap: 2px;
}

.cards-meta {
  display: block !important;
  color: #8c9199 !important;
  font-size: 10px !important;
  font-weight: 750 !important;
}

.screen-home .cards-section .cards-summary .card-summary-row .wallet-card-copy strong,
.screen-home .cards-section .cards-summary .card-summary-row .wallet-card-copy small {
  grid-column: 1 !important;
  grid-row: auto !important;
}

.screen-home .cards-list {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

.cards-showcase {
  grid-template-columns: 160px minmax(0, 1fr) !important;
  gap: 12px !important;
  min-height: 164px !important;
  align-items: center !important;
}

.cards-visual-stack {
  min-height: 152px !important;
}

.stacked-card {
  width: 158px !important;
  height: 100px !important;
  border-radius: 19px !important;
}

.cards-summary {
  border-radius: 22px !important;
  box-shadow: 0 14px 34px rgba(20, 24, 32, .055) !important;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 54px !important;
  grid-template-columns: minmax(0, 1fr) 12px !important;
  gap: 7px !important;
  padding: 0 10px 0 12px !important;
}

.card-summary-row .wallet-card-copy {
  display: grid !important;
  grid-column: 1 !important;
  min-width: 0 !important;
  gap: 2px !important;
}

.card-summary-row .wallet-card-copy strong {
  grid-column: 1 !important;
  grid-row: auto !important;
  color: #111 !important;
  font-size: 12px !important;
  font-weight: 850 !important;
}

.card-summary-row .wallet-card-copy small {
  display: block !important;
  grid-column: 1 !important;
  grid-row: auto !important;
  color: #8f939b !important;
  font-size: 9px !important;
  font-weight: 700 !important;
}

.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row[data-status="reissuing"] .card-status {
  background: #fff5df !important;
  color: #b47700 !important;
}

.card-summary-row[data-status="expired"] .card-status {
  background: #f1f2f4 !important;
  color: #8f939b !important;
}

.card-summary-row .row-chevron {
  grid-column: 2 !important;
}

.screen-topup .topup-target {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  gap: 11px;
  margin: 14px 0 12px;
  padding: 12px;
  border: 1px solid #eeeeef;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(20, 24, 32, .04);
}

.topup-target-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 15px;
  background: #fff0f1;
  color: var(--accent);
  font-size: 22px;
  font-weight: 650;
}

.topup-target div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.topup-target small {
  color: #9297a0;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.topup-target strong {
  overflow: hidden;
  color: #111;
  font-size: 14px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topup-target span:last-child {
  color: #7e8490;
  font-size: 11px;
  font-weight: 650;
}

.quick-amounts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 0 0 14px;
}

.quick-amounts button {
  min-height: 42px;
  border: 1px solid #eeeeef;
  border-radius: 15px;
  background: #fff;
  color: #111;
  font-size: 12px;
  font-weight: 850;
  box-shadow: 0 8px 20px rgba(20, 24, 32, .035);
}

.quick-amounts button:hover,
.quick-amounts button:focus-visible {
  border-color: rgba(255, 79, 94, .24);
  background: #fff8f8;
  outline: none;
}

.notification-filters {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  margin: 0 0 14px;
  padding: 2px 0 10px;
}

.notification-filters::-webkit-scrollbar { display: none; }

.notification-filters button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 34px;
  padding: 0 13px;
  border: 0;
  border-radius: 20px;
  background: #f3f4f6;
  color: #8f949d;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.notification-filters button.active {
  background: #111;
  color: #fff;
  box-shadow: 0 4px 12px rgba(20, 24, 32, .14);
}

.notification-filters .filter-icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.notification-filters .filter-count {
  display: none;
  align-items: center;
  justify-content: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .1);
  font-size: 9px;
  font-weight: 900;
  line-height: 1;
}

.notification-filters button.active .filter-count {
  background: rgba(255, 255, 255, .22);
}

.notification-item.unread {
  background: linear-gradient(90deg, #fff8f8, #fff);
}

.notification-item.unread strong::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--accent);
  vertical-align: 1px;
}

.topup-confirm-panel {
  border-radius: 26px;
}

.topup-confirm-panel h2 {
  margin-bottom: 8px;
  color: #111;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -.65px;
}

.topup-confirm-panel p {
  color: #737985;
  font-size: 13px;
  line-height: 1.45;
}

.topup-confirm {
  background: var(--accent) !important;
  color: #fff !important;
  box-shadow: 0 14px 30px rgba(255, 79, 94, .2) !important;
}

.topup-confirm:hover,
.topup-confirm:focus-visible {
  background: var(--accent-hover) !important;
  color: #fff !important;
  outline: none;
}

@media (max-width: 360px) {
  .cards-showcase {
    grid-template-columns: 136px minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .stacked-card {
    width: 136px !important;
    height: 86px !important;
  }

  .screen-home .card-row.card-summary-row,
  .screen-home .card-row.card-summary-row:nth-child(n) {
    min-height: 50px !important;
    padding-left: 10px !important;
  }

  .card-summary-row .wallet-card-copy strong {
    font-size: 10px !important;
  }

  .card-summary-row .wallet-card-copy small,
  .card-summary-row .card-status {
    font-size: 8px !important;
  }

  .quick-amounts,
  .notification-filters {
    gap: 5px;
  }
}

/* Stable mobile layout for top-up and YooMoney admin surfaces. */
.screen-topup .topup-hero {
  position: relative !important;
  top: auto !important;
}

.screen-topup .topup-form {
  margin-top: 12px !important;
}

.screen-topup .topup-form .topup-submit,
.topup-sbp-session .topup-submit,
.topup-sbp-session .ui-button {
  margin-top: 0 !important;
}

.topup-sbp-session .topup-submit {
  margin-top: 0 !important;
}

.topup-method-switch button {
  line-height: 1.25;
  white-space: normal;
  overflow-wrap: anywhere;
}

.topup-sbp-note,
.topup-note {
  overflow-wrap: anywhere;
}

.topup-fee-breakdown {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid #ececef;
  border-radius: 8px;
  background: #fff;
}

.topup-fee-breakdown > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  color: #7e8490;
  font-size: 12px;
}

.topup-fee-breakdown strong {
  flex: 0 0 auto;
  color: #17191d;
  font-size: 12px;
}

.topup-fee-breakdown .topup-fee-total {
  margin-top: 2px;
  padding-top: 9px;
  border-top: 1px solid #ececef;
  color: #17191d;
  font-weight: 800;
}

.screen-yoomoney .modal-overlay {
  padding: max(16px, env(safe-area-inset-top)) 14px max(16px, env(safe-area-inset-bottom));
  box-sizing: border-box;
}

.screen-yoomoney .modal-card {
  width: min(100%, 360px) !important;
  max-width: 100% !important;
  max-height: calc(100dvh - 32px) !important;
  overflow-y: auto !important;
  border-radius: 8px;
  box-sizing: border-box;
}

.screen-yoomoney .ym-account-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.screen-yoomoney .ym-account-text {
  min-width: 0;
}

.screen-yoomoney .ym-account-actions {
  margin-left: auto;
}

@media (max-width: 430px) {
  .screen-yoomoney .ym-account-row {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  .screen-yoomoney .ym-account-actions {
    display: grid;
    width: 100%;
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 6px;
    margin-left: 0;
  }

  .screen-yoomoney .ym-account-actions button {
    min-width: 0;
    padding-inline: 2px;
    font-size: 9px;
  }

  .screen-yoomoney .ym-del-btn {
    width: auto;
  }
}

/* Final service rail polish: compact decorative ducks and wheel-friendly horizontal cards. */
.screen-home .quick-actions {
  display: flex !important;
  gap: 12px !important;
  margin: 3px -20px 0 !important;
  padding: 0 20px 12px !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}

.screen-home .quick-actions::-webkit-scrollbar {
  display: none;
}

.screen-home .quick-actions .shelf-heading {
  display: none !important;
}

.screen-home .quick-actions button,
.screen-home .quick-actions button:first-of-type {
  position: relative !important;
  flex: 0 0 172px !important;
  width: 172px !important;
  min-height: 92px !important;
  grid-template-columns: 44px minmax(0, 1fr) !important;
  gap: 12px !important;
  padding: 16px !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 14px 38px rgba(25, 30, 38, .07) !important;
  scroll-snap-align: start;
}

.screen-home .quick-actions button + button {
  border-left: 1px solid #eeeeef !important;
}

.screen-home .quick-actions .promo-duck {
  position: absolute !important;
  top: 10px !important;
  right: 10px !important;
  z-index: 1 !important;
  display: grid !important;
  width: 30px !important;
  height: 30px !important;
  place-items: center !important;
  overflow: hidden !important;
  padding: 2px !important;
  border: 1px solid rgba(255, 79, 94, .1) !important;
  border-radius: 12px !important;
  background: rgba(255, 240, 241, .86) !important;
  color: inherit !important;
  opacity: .95 !important;
  pointer-events: none !important;
}

.screen-home .quick-actions .promo-duck img,
.screen-home .quick-actions .promo-duck svg {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
}

.screen-home .quick-actions button > span:not(.promo-duck),
.screen-home .quick-actions .promo-duck + span,
.screen-home .quick-actions button:first-of-type .promo-duck + span {
  display: grid !important;
  width: 44px !important;
  height: 44px !important;
  place-items: center !important;
  border: 1px solid #cde9ff !important;
  border-radius: 15px !important;
  background: #e8f5ff !important;
  color: var(--blue) !important;
}

.screen-home .quick-actions #mailQuickBtn > span {
  border-color: #c9f2df !important;
  background: #edfff5 !important;
  color: #15b76b !important;
}

.screen-home .quick-actions #ymQuickBtn > span {
  border-color: #d5f0e3 !important;
  background: #effdf5 !important;
  color: #19b971 !important;
}

.screen-home .quick-actions strong {
  position: relative !important;
  z-index: 2 !important;
  min-width: 0 !important;
  padding-right: 18px !important;
  color: #151515 !important;
  font-size: 12px !important;
  font-weight: 850 !important;
  white-space: normal !important;
}

.screen-home .quick-actions strong small {
  display: block !important;
  overflow: hidden !important;
  max-width: 88px !important;
  color: #989ba1 !important;
  font-size: 9px !important;
  font-weight: 650 !important;
  line-height: 1.25 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.screen-home .quick-actions button:hover,
.screen-home .quick-actions button:focus-visible {
  background: #fffafa !important;
  transform: translateY(-1px);
}

@media (max-width: 360px) {
  .screen-home .quick-actions {
    margin-right: -16px !important;
    margin-left: -16px !important;
    padding-right: 16px !important;
    padding-left: 16px !important;
  }

  .screen-home .quick-actions button,
  .screen-home .quick-actions button:first-of-type {
    flex-basis: 164px !important;
    width: 164px !important;
    padding: 14px !important;
  }
}

/* Mail service and horizontal service rail, aligned with the light wallet home. */
.screen-home .quick-actions {
  display: flex !important;
  gap: 12px !important;
  margin: 3px -20px 0 !important;
  padding: 0 20px 12px !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

.screen-home .quick-actions::-webkit-scrollbar {
  display: none;
}

.screen-home .quick-actions .shelf-heading {
  display: none !important;
}

.screen-home .quick-actions .duck-sticker,
.screen-home .quick-actions .promo-duck {
  display: none !important;
}

.screen-home .quick-actions button,
.screen-home .quick-actions button:first-of-type {
  flex: 0 0 176px !important;
  width: 176px !important;
  min-height: 96px !important;
  grid-template-columns: 44px minmax(0, 1fr) !important;
  gap: 12px !important;
  padding: 16px !important;
  border: 1px solid #eeeeef !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 14px 38px rgba(25, 30, 38, .07) !important;
  scroll-snap-align: start;
}

.screen-home .quick-actions button + button {
  border-left: 1px solid #eeeeef !important;
}

.screen-home .quick-actions button:hover,
.screen-home .quick-actions button:first-of-type:hover {
  background: #fffafa !important;
  transform: translateY(-1px);
}

.screen-home .quick-actions button > span,
.screen-home .quick-actions .promo-duck + span,
.screen-home .quick-actions button:first-of-type .promo-duck + span {
  display: grid !important;
  width: 44px !important;
  height: 44px !important;
  place-items: center !important;
  border: 1px solid #cde9ff !important;
  border-radius: 15px !important;
  background: #e8f5ff !important;
  color: var(--blue) !important;
}

.screen-home .quick-actions #mailQuickBtn > span {
  border-color: #c9f2df !important;
  background: #edfff5 !important;
  color: #15b76b !important;
}

.screen-home .quick-actions #ymQuickBtn > span {
  border-color: #d5f0e3 !important;
  background: #effdf5 !important;
  color: #19b971 !important;
}

.screen-home .quick-actions strong {
  min-width: 0 !important;
  color: #151515 !important;
  font-size: 12px !important;
  font-weight: 850 !important;
  white-space: normal !important;
}

.screen-home .quick-actions strong small {
  overflow: hidden;
  max-width: 96px;
  color: #989ba1 !important;
  font-size: 9px !important;
  font-weight: 650 !important;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.screen-mailboxes {
  min-height: calc(100dvh - 64px) !important;
  padding: 18px 20px 42px !important;
  background: #fff !important;
  color: #111 !important;
}

.tg-chrome[data-view="mailboxes"] {
  background: #fff !important;
}

.tg-chrome[data-view="mailboxes"] .back-action,
.tg-chrome[data-view="mailboxes"] .chrome-title strong {
  color: #111 !important;
}

.mail-panel {
  display: block;
}

.mail-overview {
  padding: 0 0 12px !important;
  border: 0 !important;
  border-bottom: 1px solid #eeeeef !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.mail-overview h1 {
  color: #111 !important;
  font-size: 24px !important;
  font-weight: 900 !important;
  letter-spacing: -1.2px !important;
  margin: 0 !important;
}

.mail-summary {
  display: grid !important;
  grid-template-columns: 1fr !important;
  margin-top: 14px !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 10px 28px rgba(25, 30, 38, .05) !important;
}

.mail-summary span {
  min-height: 52px !important;
  padding: 0 14px !important;
  border-bottom: 1px solid #eeeeef !important;
}

.mail-summary small {
  color: #9297a0 !important;
  font-size: 9px !important;
  font-weight: 850 !important;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.mail-summary strong {
  color: #111 !important;
  font-size: 15px !important;
  font-weight: 900 !important;
}

.mail-form {
  margin-top: 14px !important;
}

.screen-mailboxes .topup-field {
  height: 52px !important;
  padding: 6px 12px !important;
  border: 1px solid #eeeeef !important;
  border-radius: 16px !important;
  background: #fff !important;
  box-shadow: 0 8px 20px rgba(20, 24, 32, .03) !important;
}

.screen-mailboxes .topup-field span {
  color: #9297a0 !important;
  font-size: 9px !important;
  font-weight: 850 !important;
}

.screen-mailboxes .topup-field input {
  color: #111 !important;
  font-size: 16px !important;
  font-weight: 850 !important;
}

.screen-mailboxes .topup-submit {
  min-height: 52px !important;
  margin-top: 0 !important;
  border-radius: 16px !important;
  background: var(--accent) !important;
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 850 !important;
  box-shadow: 0 10px 24px rgba(255, 79, 94, .18) !important;
}

.screen-mailboxes .topup-submit:disabled {
  border: 0 !important;
  background: #eff1f4 !important;
  color: #a6abb3 !important;
  box-shadow: none !important;
  opacity: 1 !important;
}

.mail-list-section {
  margin-top: 24px !important;
}

.screen-mailboxes .section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px !important;
}

.mailboxes-list {
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 10px 28px rgba(25, 30, 38, .05) !important;
}

.mailbox-row {
  min-height: 56px !important;
  padding: 0 14px !important;
  border-bottom: 1px solid #eeeeef !important;
  background: #fff !important;
  color: #111 !important;
}

.mailbox-row:hover {
  background: #fafbfc !important;
}

.screen-mailboxes .cards-empty {
  min-height: 126px !important;
  padding: 26px !important;
  border: 1px dashed #d8dbe0 !important;
  border-radius: 18px !important;
  background: #fff !important;
  color: #111 !important;
  box-shadow: none !important;
}

.screen-mailboxes .cards-empty strong {
  color: #111 !important;
  font-size: 16px !important;
  font-weight: 900 !important;
}

.screen-mailboxes .cards-empty span {
  color: #8f949d !important;
  font-size: 12px !important;
}

@media (max-width: 360px) {
  .screen-home .quick-actions {
    margin-right: -16px !important;
    margin-left: -16px !important;
    padding-right: 16px !important;
    padding-left: 16px !important;
  }

  .screen-home .quick-actions button,
  .screen-home .quick-actions button:first-of-type {
    flex-basis: 164px !important;
    width: 164px !important;
    padding: 14px !important;
  }

  .screen-mailboxes {
    padding-right: 16px !important;
    padding-left: 16px !important;
  }
}

/* Proxy status in the main balance hero. */
.screen-home .proxy-status-card {
  position: relative;
  z-index: 2;
  display: grid;
  width: min(210px, 58%);
  min-height: 54px;
  grid-template-columns: 10px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  margin-top: 14px;
  padding: 10px 12px;
  border: 1px solid rgba(238, 238, 239, .95);
  border-radius: 18px;
  background: rgba(255, 255, 255, .86);
  color: #111;
  text-align: left;
  box-shadow: 0 14px 34px rgba(20, 24, 32, .07);
  backdrop-filter: blur(14px);
  transform: none !important;
}

.screen-home .proxy-status-card:hover,
.screen-home .proxy-status-card:focus-visible,
.screen-home .proxy-status-card:active {
  border-color: rgba(255, 79, 94, .22);
  background: rgba(255, 255, 255, .94);
  outline: none;
  transform: none !important;
}

.proxy-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #b8bdc7;
  box-shadow: 0 0 0 5px rgba(184, 189, 199, .14);
}

.proxy-status-dot[data-state="alive"] {
  background: #21c76a;
  box-shadow: 0 0 0 5px rgba(33, 199, 106, .16), 0 0 18px rgba(33, 199, 106, .34);
}

.proxy-status-dot[data-state="partial"],
.proxy-status-dot[data-state="checking"] {
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(255, 79, 94, .13), 0 0 18px rgba(255, 79, 94, .28);
}

.proxy-status-dot[data-state="dead"] {
  background: #c7cbd3;
  box-shadow: 0 0 0 5px rgba(199, 203, 211, .18);
}

.proxy-status-card span:nth-child(2) {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.proxy-status-card small {
  overflow: hidden;
  color: #8d939d;
  font-size: 9px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.proxy-status-card strong {
  overflow: hidden;
  color: #111;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: -.25px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.proxy-status-card b {
  padding: 5px 8px;
  border-radius: 999px;
  background: #fff0f1;
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
  white-space: nowrap;
}

@media (max-width: 360px) {
  .screen-home .proxy-status-card {
    width: min(196px, 61%);
    min-height: 50px;
    margin-top: 12px;
    padding: 9px 10px;
  }

  .proxy-status-card strong {
    font-size: 11px;
  }

  .proxy-status-card b {
    padding-inline: 7px;
    font-size: 9px;
  }
}

/* Absolute final card block layout. Keep this after all legacy card overrides. */
.screen-home .cards-list {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

.cards-showcase {
  display: block !important;
  min-height: 0 !important;
  padding: 0 !important;
}

.cards-showcase-top {
  display: grid !important;
  grid-template-columns: 150px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 14px !important;
  min-height: 158px !important;
  margin-bottom: 10px !important;
}

.cards-visual-stack {
  position: relative !important;
  min-height: 150px !important;
  margin: 0 !important;
  overflow: visible !important;
}

.stacked-card {
  width: 148px !important;
  height: 94px !important;
  border-radius: 20px !important;
  box-shadow: 0 18px 36px rgba(21, 24, 32, .16) !important;
}

.stacked-card[data-stack-index="0"] {
  top: 52px !important;
  left: 0 !important;
  transform: rotate(0deg) !important;
}

.stacked-card[data-stack-index="1"] {
  top: 29px !important;
  left: 13px !important;
  transform: rotate(-4deg) !important;
}

.stacked-card[data-stack-index="2"] {
  top: 7px !important;
  left: 0 !important;
  transform: rotate(-8deg) !important;
}

.cards-focus-card {
  display: grid !important;
  width: 100% !important;
  min-height: 118px !important;
  align-content: center !important;
  gap: 5px !important;
  padding: 16px !important;
  border: 1px solid #eeeeef !important;
  border-radius: 24px !important;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 79, 94, .11), transparent 52%),
    #fff !important;
  text-align: left !important;
  box-shadow: 0 14px 34px rgba(20, 24, 32, .055) !important;
}

.cards-focus-card span {
  color: #9297a0 !important;
  font-size: 9px !important;
  font-weight: 850 !important;
  text-transform: uppercase !important;
  letter-spacing: .05em !important;
}

.cards-focus-card strong {
  color: #111 !important;
  font-size: 17px !important;
  font-weight: 900 !important;
  letter-spacing: -.55px !important;
}

.cards-focus-card small {
  color: #747b87 !important;
  font-size: 11px !important;
  font-weight: 750 !important;
}

.cards-focus-card b {
  width: max-content !important;
  margin-top: 7px !important;
  padding: 6px 10px !important;
  border-radius: 999px !important;
  background: #fff0f1 !important;
  color: var(--accent) !important;
  font-size: 10px !important;
  font-weight: 900 !important;
}

.cards-summary {
  display: block !important;
  width: 100% !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 12px 30px rgba(20, 24, 32, .045) !important;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 54px !important;
  grid-template-columns: minmax(0, 1fr) 12px !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 0 14px !important;
  border-bottom: 1px solid #f0f1f3 !important;
}

.screen-home .card-row.card-summary-row:last-child {
  border-bottom: 0 !important;
}

.card-summary-row .wallet-card-copy {
  display: grid !important;
  grid-column: 1 !important;
  min-width: 0 !important;
  gap: 3px !important;
}

.card-summary-row .wallet-card-copy strong {
  overflow: hidden !important;
  color: #111 !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  letter-spacing: -.35px !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.card-summary-row .wallet-card-copy small {
  display: block !important;
  overflow: hidden !important;
  color: #8b9099 !important;
  font-size: 10px !important;
  font-weight: 750 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.card-summary-row .card-state,
.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row .row-chevron {
  display: block !important;
  grid-column: 2 !important;
}

@media (max-width: 360px) {
  .cards-showcase-top {
    grid-template-columns: 130px minmax(0, 1fr) !important;
    gap: 10px !important;
    min-height: 140px !important;
  }

  .cards-visual-stack {
    min-height: 132px !important;
  }

  .stacked-card {
    width: 128px !important;
    height: 82px !important;
    border-radius: 18px !important;
  }

  .stacked-card[data-stack-index="0"] { top: 46px !important; }
  .stacked-card[data-stack-index="1"] { top: 25px !important; left: 10px !important; }
  .stacked-card[data-stack-index="2"] { top: 6px !important; }

  .cards-focus-card {
    min-height: 108px !important;
    padding: 14px !important;
    border-radius: 22px !important;
  }

  .cards-focus-card strong {
    font-size: 15px !important;
  }
}

/* Notifications should not jump on hover/press. */
.screen-notifications .notification-item,
.screen-notifications .notification-item:hover,
.screen-notifications .notification-item:focus-visible,
.screen-notifications .notification-filters button,
.screen-notifications .notification-filters button:hover,
.screen-notifications .notification-filters button:focus-visible,
.screen-notifications .notification-filters button:active,
.screen-notifications .list-pagination button,
.screen-notifications .list-pagination button:hover,
.screen-notifications .list-pagination button:focus-visible,
.screen-notifications .list-pagination button:active {
  transform: none !important;
}

.screen-notifications .notification-filters button:hover,
.screen-notifications .notification-filters button:focus-visible {
  background: #e8e9ec;
  outline: none;
}

.screen-notifications .notification-filters button.active:hover,
.screen-notifications .notification-filters button.active:focus-visible {
  background: #2a2a2a;
}

.screen-notifications .list-pagination button:hover,
.screen-notifications .list-pagination button:focus-visible {
  box-shadow: 0 6px 16px rgba(20, 24, 32, .06);
  outline: none;
}

/* Card section recomposition: visual overview first, readable list below. */
.screen-home .cards-list {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

.cards-showcase {
  display: block !important;
  min-height: 0 !important;
  padding: 0 !important;
}

.cards-showcase-top {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 158px;
  margin-bottom: 10px;
}

.cards-visual-stack {
  position: relative !important;
  min-height: 150px !important;
  margin: 0 !important;
  overflow: visible !important;
}

.stacked-card {
  width: 148px !important;
  height: 94px !important;
  border-radius: 20px !important;
  box-shadow: 0 18px 36px rgba(21, 24, 32, .16) !important;
}

.stacked-card[data-stack-index="0"] {
  top: 52px !important;
  left: 0 !important;
  transform: rotate(0deg) !important;
}

.stacked-card[data-stack-index="1"] {
  top: 29px !important;
  left: 13px !important;
  transform: rotate(-4deg) !important;
}

.stacked-card[data-stack-index="2"] {
  top: 7px !important;
  left: 0 !important;
  transform: rotate(-8deg) !important;
}

.cards-focus-card {
  display: grid;
  min-height: 118px;
  align-content: center;
  gap: 5px;
  padding: 16px;
  border: 1px solid #eeeeef;
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 79, 94, .11), transparent 52%),
    #fff;
  text-align: left;
  box-shadow: 0 14px 34px rgba(20, 24, 32, .055);
}

.cards-focus-card span {
  color: #9297a0;
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.cards-focus-card strong {
  color: #111;
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -.55px;
}

.cards-focus-card small {
  color: #747b87;
  font-size: 11px;
  font-weight: 750;
}

.cards-focus-card b {
  width: max-content;
  margin-top: 7px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff0f1;
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
}

.cards-summary {
  display: block !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 12px 30px rgba(20, 24, 32, .045) !important;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 54px !important;
  grid-template-columns: minmax(0, 1fr) 12px !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 0 14px !important;
  border-bottom: 1px solid #f0f1f3 !important;
}

.screen-home .card-row.card-summary-row:last-child {
  border-bottom: 0 !important;
}

.card-summary-row .wallet-card-copy {
  display: grid !important;
  grid-column: 1 !important;
  min-width: 0 !important;
  gap: 3px !important;
}

.card-summary-row .wallet-card-copy strong {
  overflow: hidden !important;
  color: #111 !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  letter-spacing: -.35px !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.card-summary-row .wallet-card-copy small {
  display: block !important;
  overflow: hidden !important;
  color: #8b9099 !important;
  font-size: 10px !important;
  font-weight: 750 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.card-summary-row .card-state,
.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row .row-chevron {
  display: block !important;
  grid-column: 2 !important;
}

@media (max-width: 360px) {
  .cards-showcase-top {
    grid-template-columns: 130px minmax(0, 1fr);
    gap: 10px;
    min-height: 140px;
  }

  .cards-visual-stack {
    min-height: 132px !important;
  }

  .stacked-card {
    width: 128px !important;
    height: 82px !important;
    border-radius: 18px !important;
  }

  .stacked-card[data-stack-index="0"] { top: 46px !important; }
  .stacked-card[data-stack-index="1"] { top: 25px !important; left: 10px !important; }
  .stacked-card[data-stack-index="2"] { top: 6px !important; }

  .cards-focus-card {
    min-height: 108px;
    padding: 14px;
    border-radius: 22px;
  }

  .cards-focus-card strong {
    font-size: 15px;
  }
}

/* Final readability override for compact card rows. */
.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  grid-template-columns: minmax(0, 1fr) 12px !important;
}

.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row .row-chevron {
  grid-column: 2 !important;
}

html, body { background: #dedede; color: var(--text); }
button, input, select { color: var(--text); }
button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid rgba(255, 221, 45, .65);
  outline-offset: 2px;
  box-shadow: none;
}

.app-shell { width: min(100vw, 430px); background: var(--bg); }
.screen { background: var(--bg); }

.tg-chrome {
  height: 66px;
  grid-template-columns: 86px 1fr 86px;
  align-items: center;
  padding: 7px 14px 0;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.tg-chrome[data-view="home"] {
  grid-template-columns: 1fr auto;
  height: 86px;
  padding: 14px 18px 8px;
  border: 0;
  background: var(--bg);
}

.tg-chrome[data-view="home"] .chrome-title { display: none; }
.tg-chrome[data-view="home"] .header-bell-slot { grid-column: 2; }

.account-location { display: grid; justify-items: start; gap: 3px; text-align: left; }
.account-location strong {
  color: var(--text);
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -1px;
}
.account-location span { color: var(--muted); font-size: 12px; font-weight: 600; }
.chrome-action, .back-action { color: #555; font-size: 13px; font-weight: 700; }
.chrome-title strong { color: var(--text); font-size: 16px; font-weight: 800; }
.chrome-title span { margin-top: 2px; color: var(--muted); font-size: 9px; }
.chevron { width: 8px; height: 8px; border-width: 2px; }

.bell-button {
  width: 42px;
  height: 42px;
  padding: 10px;
  border: 0;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.bell-button svg { display: block !important; fill: none; stroke: currentColor; stroke-width: 1.8; }
.bell-button::before, .bell-button::after { display: none !important; }
.notification-badge { border-color: var(--bg); background: var(--accent); color: var(--text); }

.screen-home {
  display: flex;
  min-height: calc(100dvh - 86px);
  flex-direction: column;
  padding: 0 12px 36px;
  overflow: hidden;
  background: var(--bg);
}

.wallet-hero { order: 1; }

.screen-home .balance-block {
  display: block;
  min-height: 170px;
  margin: 0;
  padding: 24px 20px 18px;
  border: 1px solid var(--border);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 0 3px 14px rgba(0,0,0,.04);
}
.screen-home .balance-label {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}
.screen-home .balance-amount {
  color: var(--text);
  font-size: clamp(42px, 13vw, 54px);
  font-weight: 780;
  letter-spacing: -3px;
  line-height: 1;
}
.screen-home .balance-block .balance-amount,
.screen-home .balance-block .balance-amount span,
.screen-home .balance-amount span:last-child { color: var(--text); }
.screen-home .balance-footer {
  display: flex;
  margin-top: 18px;
  padding: 14px 0 0;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 11px;
}
.balance-footer i { width: 7px; height: 7px; background: var(--green); box-shadow: none; }

.screen-home .quick-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  overflow: visible;
  border: 0;
  background: transparent;
}
.shelf-heading { display: none; }
.screen-home .quick-actions button,
.screen-home .quick-actions button:first-of-type {
  display: flex;
  width: auto;
  min-width: 0;
  min-height: 82px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 5px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 2px 9px rgba(0,0,0,.035);
}
.screen-home .quick-actions button:first-of-type { background: var(--accent); border-color: var(--accent); }
.screen-home .quick-actions button:hover, .screen-home .quick-actions button:focus-visible {
  background: var(--soft-hover);
  transform: none;
}
.screen-home .quick-actions button:first-of-type:hover { background: var(--accent-hover); }
.screen-home .quick-actions .promo-duck { display: none; }
.screen-home .quick-actions .promo-duck + span {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  margin: 0;
  border-radius: 11px;
  background: var(--soft);
  color: var(--text);
}
.screen-home .quick-actions button:first-of-type .promo-duck + span { background: rgba(255,255,255,.6); }
.screen-home .quick-actions svg { width: 18px; height: 18px; }
.screen-home .quick-actions strong { color: var(--text); font-size: 10px; font-weight: 720; white-space: nowrap; }

.home-search {
  order: 2;
  display: grid;
  min-height: 46px;
  grid-template-columns: 21px 1fr;
  align-items: center;
  gap: 7px;
  margin: 20px 0 28px;
  padding: 0 13px;
  border: 0;
  border-radius: 14px;
  background: #e9e9e9;
}
.home-search svg { width: 18px; height: 18px; fill: none; stroke: #777; stroke-width: 2; }
.home-search input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 12px;
  font-weight: 600;
}
.home-search input::placeholder { color: #999; }

.screen-home .cards-section { order: 3; margin: 0; padding: 0; }
.screen-home .home-operations { order: 4; margin: 30px 0 0; padding: 0; }
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 3px 12px;
  padding: 0;
}
.section-heading h1, .screen-home .section-heading h1 {
  margin: 0;
  color: var(--text);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -.65px;
}
.section-heading span, .section-heading button {
  min-width: auto;
  height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: #3078d5;
  font-size: 11px;
  font-weight: 700;
}
.screen-home .cards-section .section-heading button {
  color: #3078d5;
  font-size: 11px;
}

.screen-home .cards-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 2px 10px rgba(0,0,0,.025);
}
.screen-home .card-row, .screen-home .card-row:nth-child(n) {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 0;
  min-height: 78px;
  grid-template-columns: 54px minmax(0,1fr) auto 10px;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent !important;
  text-align: left;
}
.screen-home .card-row:last-child { border-bottom: 0; }
.screen-home .card-row:hover, .screen-home .card-row:focus-visible { background: var(--soft) !important; transform: none; }
.card-preview {
  position: relative;
  display: grid;
  width: 54px;
  height: 44px;
  place-items: center;
  overflow: hidden;
  border-radius: 10px;
  background: var(--soft);
}
.card-preview::before, .card-preview b { display: none; }
.card-preview .card-logo {
  position: static;
  width: 32px;
  height: 32px;
  padding: 5px;
  border: 0;
  border-radius: 9px;
  background: #fff;
}
.card-preview .card-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.screen-home .wallet-card-copy { display: grid; grid-column: 2; gap: 3px; min-width: 0; }
.screen-home .wallet-card-copy strong {
  overflow: hidden;
  color: var(--text);
  font-size: 13px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.screen-home .wallet-card-copy small {
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.screen-home .card-status {
  display: block;
  grid-column: 3;
  padding: 0;
  background: transparent;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}
.screen-home .card-row[data-status="reissuing"] .card-status { color: #bf8000; }
.screen-home .card-row[data-status="expired"] .card-status { color: var(--muted); }
.screen-home .card-row[data-status="unavailable"] .card-status,
.screen-home .card-row[data-status="unavailable"] .card-state { color: #c43d4f; }

.screen-home .card-row[data-status="unavailable"] {
  opacity: 0.72;
}
.card-status::before, .screen-home .card-add { display: none; }
.screen-home .row-chevron { display: block; grid-column: 4; color: var(--muted); }
.screen-home .list-pagination { display: none !important; }

.home-transactions-list {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
}
.home-transaction {
  display: grid;
  min-height: 64px;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-bottom: 1px solid var(--border);
}
.home-transaction:last-child { border-bottom: 0; }
.home-transaction-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 12px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 18px;
  font-weight: 600;
}
.home-transaction-icon svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}
.home-transaction div { display: grid; gap: 2px; }
.home-transaction strong, .home-transaction b { color: var(--text); font-size: 11px; font-weight: 750; }
.home-transaction small, .home-transactions-empty { color: var(--muted); font-size: 9px; }
.home-transactions-empty {
  margin: 0;
  padding: 22px 12px;
  border: 1px dashed #d8d8d8;
  border-radius: 16px;
  background: var(--surface);
  text-align: center;
}

.cards-empty, .notifications-empty {
  min-height: 130px;
  border: 1px dashed #d8d8d8;
  border-radius: 18px;
  background: var(--surface);
  color: var(--muted);
}
.cards-empty strong, .notifications-empty strong { color: var(--text); }

.screen-issue, .screen-detail, .screen-topup, .screen-notifications {
  min-height: calc(100dvh - 66px);
  padding: 22px 14px 40px;
  background: var(--bg);
}
.screen-intro { margin-bottom: 22px; padding: 0; }
.screen-issue .screen-intro h1 {
  display: block;
  margin: 0 0 7px;
  color: var(--text);
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -.9px;
}
.screen-issue .screen-intro p { max-width: 330px; color: var(--muted); font-size: 13px; line-height: 1.4; }
.screen-issue .issue-stage, .screen-detail .detail-card,
.screen-topup .topup-panel, .screen-notifications .notifications-panel { max-width: none; margin: 0; padding: 0; }

.country-field, .provider-field { position: relative; margin-bottom: 16px; }
.country-field > span:first-child, .provider-field > span:first-child, .topup-field > span {
  display: block;
  margin: 0 0 7px 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}
.custom-select-trigger, .topup-field {
  min-height: 56px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
}
.screen-issue .custom-select-trigger {
  width: 100%;
  min-height: 56px;
  padding: 0 13px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}
.custom-select-trigger[aria-expanded="true"] {
  border-color: #d2b000;
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(255,221,45,.25);
}
.custom-select-menu {
  padding: 5px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: var(--surface);
  box-shadow: 0 16px 42px rgba(0,0,0,.13);
}
.custom-select-option { min-height: 46px; color: var(--text); }
.custom-select-option:not(:disabled):hover, .custom-select-option:not(:disabled):focus-visible,
.custom-select-option.selected { background: var(--soft); color: var(--text); }
.custom-select-option.selected .option-check { color: #9a8100; }

.screen-issue .issue-summary {
  display: block;
  width: 100%;
  margin-top: 22px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: var(--surface);
}
.screen-issue .issue-summary > span {
  min-height: 52px;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 0 13px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
}
.screen-issue .issue-summary > span:last-child { border-bottom: 0; }
.screen-issue .issue-summary small, .screen-issue .issue-note, .topup-note { color: var(--muted); }
.screen-issue .issue-summary strong, .screen-issue .issue-summary b { color: var(--text); }

.ui-button-primary, .screen-issue .bottom-cta, .screen-topup .topup-submit,
.screen-topup .topup-submit:not(:disabled) {
  position: static;
  width: 100%;
  min-height: 52px;
  margin-top: 22px;
  transform: none;
  border: 0;
  border-radius: 14px;
  background: var(--accent);
  color: var(--text);
  box-shadow: none;
  font-size: 13px;
  font-weight: 800;
}
.ui-button-primary:hover, .screen-issue .bottom-cta:hover,
.screen-topup .topup-submit:not(:disabled):hover { background: var(--accent-hover); box-shadow: none; transform: none; }
.ui-button-secondary, .ui-button-ghost { border: 0; background: var(--soft); color: var(--text); }

.screen-detail .issued-card {
  min-height: 204px;
  padding: 18px;
  border: 0;
  border-radius: 20px;
  background: #262626;
  box-shadow: none;
  color: #fff;
}
.flat-card-chip { background: var(--accent); }
.flat-card-eye { background: rgba(255,255,255,.12); color: #fff; }
.screen-detail .detail-actions {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin: 11px 0 28px;
  border: 0;
  background: transparent;
}
.screen-detail .detail-actions button {
  min-height: 54px;
  flex-direction: row;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
}
.screen-detail .detail-actions button:hover, .screen-detail .detail-actions button:focus-visible {
  background: var(--soft); box-shadow: none; transform: none;
}
.screen-detail .detail-actions span { width: 20px; height: 20px; background: transparent; }
.screen-detail .detail-card h2 {
  margin: 26px 0 10px;
  color: var(--text);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -.45px;
  text-transform: none;
}
.screen-detail .requisites {
  display: block;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}
.screen-detail .requisite, .screen-detail .requisite.full {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 62px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 4px;
  padding: 9px 46px 9px 13px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
  color: var(--text);
}
.screen-detail .requisite:last-child { border-bottom: 0; }
.screen-detail .requisite span { color: var(--muted); }
.screen-detail .requisite strong, .screen-detail .requisite.full strong { color: var(--text); }
.screen-detail .requisite .copy-icon {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 26px;
  height: 26px;
  padding: 5px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 8px;
  background: var(--soft);
  stroke: #666;
}
.screen-detail .requisite.copied { background: var(--green-soft); }

/* Detail polish: remove legacy blue hover states and align with the new home visual system. */
.screen-detail {
  background:
    radial-gradient(circle at 82% 54px, rgba(255, 79, 94, .09), transparent 130px),
    #fff;
}

.tg-chrome[data-view="detail"] {
  border-bottom: 0;
  background: #fff;
  box-shadow: none;
}

.tg-chrome[data-view="detail"] .back-action {
  color: #8b8e96;
}

.tg-chrome[data-view="detail"] .back-action:hover,
.tg-chrome[data-view="detail"] .back-action:focus-visible {
  color: #111;
  background: transparent;
  outline: none;
}

.tg-chrome[data-view="detail"] .chrome-title strong {
  color: #111;
  font-size: 15px;
  font-weight: 850;
}

.tg-chrome[data-view="detail"] .chrome-title span {
  color: #9da0a7;
}

.screen-detail .detail-card {
  padding-top: 10px;
}

.screen-detail .issued-card {
  position: relative;
  min-height: 216px;
  border-radius: 25px;
  overflow: hidden;
  background:
    radial-gradient(circle at 84% 82%, rgba(255,255,255,.15) 0 34%, transparent 35%),
    linear-gradient(145deg, #171717 0%, #242424 60%, #ff4f5e 170%);
  box-shadow: 0 22px 46px rgba(18, 18, 18, .14);
}

.screen-detail .issued-card::before {
  content: "";
  position: absolute;
  inset: -8px;
  background: var(--duck-bg, none) center / cover no-repeat;
  filter: blur(22px) saturate(0.6);
  opacity: 0.22;
  transform: scale(1.08);
  pointer-events: none;
  z-index: 0;
}
.screen-detail .issued-card > * {
  position: relative;
  z-index: 1;
}
.screen-detail .issued-card::after {
  content: "";
  position: absolute;
  right: -38px;
  bottom: -48px;
  width: 146px;
  height: 146px;
  border: 23px solid rgba(255,255,255,.08);
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
}

.screen-detail .flat-card-eye,
.screen-detail .flat-card-eye:hover,
.screen-detail .flat-card-eye:focus-visible {
  background: rgba(255,255,255,.13);
  color: #fff;
  outline: none;
  box-shadow: 0 0 0 4px rgba(255,255,255,.08);
}

.screen-detail .detail-actions {
  gap: 10px;
  margin: 14px 0 30px;
}

.screen-detail .detail-actions button,
.screen-detail .detail-actions button:not(:disabled) {
  min-height: 56px;
  border: 1px solid #ececef;
  border-radius: 18px;
  background: #fff;
  color: #111;
  box-shadow: 0 10px 26px rgba(20,24,32,.045);
}

.screen-detail .detail-actions button:hover,
.screen-detail .detail-actions button:focus-visible {
  border-color: rgba(255, 79, 94, .22);
  background: #fff7f8;
  color: #111;
  box-shadow: 0 12px 28px rgba(255, 79, 94, .1);
  transform: translateY(-1px);
  outline: none;
}

.screen-detail .detail-actions button:hover span,
.screen-detail .detail-actions button:focus-visible span {
  background: transparent;
  color: var(--accent);
}

.screen-detail .detail-actions button:disabled,
.screen-detail .detail-actions button:disabled:hover {
  border-color: #eeeeee;
  background: #f7f7f8;
  color: #a3a5aa;
  box-shadow: none;
  transform: none;
}

.screen-detail .detail-card h2 {
  margin-top: 30px;
  font-size: 24px;
  letter-spacing: 0;
}

.screen-detail .requisites {
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.screen-detail .requisite,
.screen-detail .requisite.full,
.screen-detail .requisite:last-child {
  min-height: 66px;
  margin-bottom: 8px;
  padding: 11px 52px 11px 16px;
  border: 1px solid #ececef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(20,24,32,.035);
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.screen-detail .requisite:hover,
.screen-detail .requisite:focus-visible {
  border-color: rgba(255, 79, 94, .24);
  background: #fff8f8;
  box-shadow: 0 12px 28px rgba(255, 79, 94, .09);
  transform: translateY(-1px);
  outline: none;
}

.screen-detail .requisite span {
  color: #8b8e96;
  font-size: 10px;
  font-weight: 750;
}

.screen-detail .requisite strong,
.screen-detail .requisite.full strong {
  max-width: 100%;
  overflow: hidden;
  color: #111;
  font-size: 15px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.screen-detail .requisite.full strong {
  font-size: 14px;
}

.screen-detail .requisite .copy-icon,
.screen-detail .requisite:hover .copy-icon,
.screen-detail .requisite:focus-visible .copy-icon {
  right: 14px;
  width: 28px;
  height: 28px;
  padding: 6px;
  border-radius: 10px;
  background: #f5f6f7;
  stroke: #7c8088;
  transition: background-color 160ms ease, stroke 160ms ease;
}

.screen-detail .requisite:hover .copy-icon,
.screen-detail .requisite:focus-visible .copy-icon {
  background: #ffe9eb;
  stroke: var(--accent);
}

.screen-detail .requisite.copied {
  border-color: rgba(36, 166, 90, .22);
  background: #f1fbf5;
}

.screen-detail .requisite.copied .copy-icon {
  background: #dff6e8;
  stroke: var(--green);
}

@media (max-width: 350px) {
  .screen-detail .requisite,
  .screen-detail .requisite.full,
  .screen-detail .requisite:last-child {
    min-height: 62px;
    padding: 10px 48px 10px 13px;
    border-radius: 16px;
  }
  .screen-detail .requisite strong,
  .screen-detail .requisite.full strong {
    font-size: 13px;
  }
}

.screen-topup {
  background:
    radial-gradient(circle at 88% 80px, rgba(255, 79, 94, .1), transparent 150px),
    #fff;
}

.tg-chrome[data-view="topup"] {
  border-bottom: 0;
  background: #fff;
  box-shadow: none;
}

.tg-chrome[data-view="topup"] .back-action { color: #8b8e96; }
.tg-chrome[data-view="topup"] .back-action:hover,
.tg-chrome[data-view="topup"] .back-action:focus-visible {
  color: #111;
  background: transparent;
  outline: none;
}
.tg-chrome[data-view="topup"] .chrome-title strong {
  color: #111;
  font-size: 15px;
  font-weight: 850;
}
.tg-chrome[data-view="topup"] .chrome-title span { color: #9da0a7; }

.screen-topup .topup-panel {
  padding-top: 10px;
}

.screen-topup .topup-hero {
  position: sticky;
  top: calc(env(safe-area-inset-top, 0px) + 58px);
  z-index: 4;
  display: grid;
  min-height: 168px;
  align-items: end;
  overflow: hidden;
  margin-bottom: 12px;
  padding: 22px 132px 22px 18px;
  border: 0;
  border-radius: 26px;
  background:
    radial-gradient(circle at 88% 28%, rgba(255,255,255,.18), transparent 34%),
    linear-gradient(145deg, #ff6a5c 0%, #ff4f5e 68%, #ff7b86 100%);
  box-shadow: 0 20px 44px rgba(255, 79, 94, .18);
}

.screen-topup .topup-hero::after {
  content: "";
  position: absolute;
  right: -44px;
  bottom: -52px;
  width: 152px;
  height: 152px;
  border: 24px solid rgba(255,255,255,.12);
  border-radius: 50%;
  pointer-events: none;
}

.screen-topup .topup-hero > div:first-child {
  position: relative;
  z-index: 2;
}

.screen-topup .topup-hero span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.18);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
}

.screen-topup .topup-hero h1 {
  max-width: 210px;
  margin-top: 14px;
  color: #fff;
  font-size: 27px;
  font-weight: 900;
  letter-spacing: -1.4px;
  line-height: 1;
}

.screen-topup .topup-hero p {
  max-width: 220px;
  margin-top: 10px;
  color: rgba(255,255,255,.82);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.45;
}

.screen-topup .money-duck {
  position: absolute;
  right: 14px;
  bottom: 10px;
  z-index: 1;
  display: block;
  width: 106px;
  height: 106px;
  opacity: .94;
  filter: drop-shadow(0 12px 22px rgba(79, 27, 32, .18));
  pointer-events: none;
}

.screen-topup .money-duck img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.screen-topup .topup-form {
  gap: 12px;
  margin-top: 18px;
}

.screen-topup .topup-field,
.screen-topup .topup-field.full {
  min-height: 72px;
  height: auto;
  padding: 13px 14px 11px;
  border: 1px solid #ececef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(20,24,32,.035);
}

.screen-topup .topup-field:hover {
  border-color: rgba(255, 79, 94, .2);
  background: #fffafa;
}

.screen-topup .topup-field:focus-within {
  border-color: rgba(255, 79, 94, .38);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 79, 94, .09);
}

.screen-topup .topup-field.invalid,
.screen-topup .topup-field.invalid:focus-within {
  border-color: rgba(255, 79, 94, .34);
  background: #fff8f8;
  box-shadow: 0 0 0 4px rgba(255, 79, 94, .08);
}

.screen-topup .topup-field > span {
  color: #8b8e96;
  font-size: 10px;
  font-weight: 800;
}

.screen-topup .topup-field input {
  color: #111;
  font-size: 15px;
  font-weight: 820;
  letter-spacing: -.2px;
}

.screen-topup .topup-field input::placeholder {
  color: #a1a4ab;
}

.screen-topup .field-error {
  min-height: 13px;
  color: #ff4f5e;
  font-size: 9px;
  font-weight: 750;
  line-height: 1.2;
}

.screen-topup .topup-submit,
.screen-topup .topup-submit:not(:disabled) {
  min-height: 58px;
  margin-top: 14px;
  border-radius: 21px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px rgba(255,79,94,.2);
}

.screen-topup .topup-submit:not(:disabled):hover,
.screen-topup .topup-submit:not(:disabled):focus-visible {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 16px 34px rgba(255,79,94,.24);
  transform: translateY(-1px);
  outline: none;
}

.screen-topup .topup-submit:disabled {
  border: 0;
  background: #eeeeef;
  color: #9b9ea5;
  box-shadow: none;
  opacity: 1;
}

.screen-topup .topup-note {
  max-width: 310px;
  margin-top: 16px;
  color: #8b8e96;
  font-size: 10px;
  line-height: 1.45;
}

.topup-cryptobot {
  display: grid;
  gap: 14px;
  margin-top: 14px;
}

.crypto-picker {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(248,250,252,.96));
  border: 1px solid rgba(15, 23, 42, .06);
  box-shadow: 0 10px 30px rgba(15, 23, 42, .05);
}

.crypto-picker-head {
  display: grid;
  gap: 4px;
}

.crypto-picker-title {
  font-size: 13px;
  font-weight: 780;
  color: #111827;
}

.crypto-picker-hint {
  font-size: 11px;
  color: #8b8e96;
}

.crypto-picker-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.crypto-picker-tab {
  flex: 0 0 auto;
  padding: 7px 12px;
  border: 1px solid #eceef2;
  border-radius: 999px;
  background: #fff;
  color: #667085;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.crypto-picker-tab.active {
  border-color: rgba(47, 111, 237, .18);
  background: rgba(47, 111, 237, .08);
  color: #1d4ed8;
}

.crypto-picker-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 280px;
  overflow: auto;
  padding-right: 2px;
}

.crypto-picker-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #eceef2;
  border-radius: 16px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.crypto-picker-item:hover {
  border-color: rgba(47, 111, 237, .22);
  box-shadow: 0 8px 18px rgba(15, 23, 42, .06);
}

.crypto-picker-item.active {
  border-color: rgba(47, 111, 237, .42);
  background: linear-gradient(180deg, rgba(47,111,237,.08), rgba(47,111,237,.03));
  box-shadow: 0 10px 22px rgba(47, 111, 237, .12);
}

.crypto-picker-icon {
  --crypto-accent: #607d8b;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid #eceef2;
  flex-shrink: 0;
  overflow: hidden;
}

.crypto-picker-icon-img,
.topup-cryptobot-create-icon-img,
.topup-cryptobot-pay-icon {
  width: 24px;
  height: 24px;
  object-fit: contain;
  display: block;
}

.topup-cryptobot-create-icon-img,
.topup-cryptobot-pay-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
}

.topup-cryptobot-create-icon-img.hidden,
.topup-cryptobot-pay-icon.hidden {
  display: none;
}

#topupCryptobotCreateBtn,
#topupCryptobotPayBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

#topupCryptobotCreateBtn {
  opacity: 0.72;
}

#topupCryptobotCreateBtn.is-ready {
  opacity: 1;
}

#topupCryptobotCreateBtn.is-loading {
  opacity: 0.85;
  pointer-events: none;
}

.topup-sbp {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.topup-method-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  margin-top: 14px;
  padding: 4px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f3f4f6;
}

.topup-method-switch button {
  min-width: 0;
  min-height: 42px;
  padding: 8px 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #6b7280;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
}

.topup-method-switch button.is-active {
  background: #15181d;
  color: #fff;
}

.topup-sbp-note {
  margin: 0;
  font-size: 13px;
  color: #6b7280;
}

.prepaid-card-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
  margin-top: 12px;
}

.prepaid-card-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.prepaid-remember-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #6b7280;
  cursor: pointer;
  padding: 4px 0;
}

.prepaid-remember-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #6c5ce7;
  cursor: pointer;
}

.prepaid-card-form input[type="text"] {
  width: 100%;
  padding: 12px 14px;
  background: #fff;
  border: 1.5px solid #d1d5db;
  border-radius: 10px;
  color: #111827;
  font-size: 15px;
  font-family: inherit;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.15s;
}

.prepaid-card-form input[type="text"]:focus {
  border-color: #6c5ce7;
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.prepaid-card-form input[type="text"]::placeholder {
  color: #9ca3af;
}

.topup-secure-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}

.topup-secure-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.topup-secure-card-head span {
  min-width: 0;
  color: #6b7280;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.topup-secure-card-head strong {
  min-width: 0;
  color: #111827;
  font-size: 13px;
  font-weight: 850;
  text-align: right;
}

.topup-secure-card p,
.topup-secure-card small {
  margin: 0;
  color: #6b7280;
  font-size: 12px;
  line-height: 1.35;
}

.topup-secure-card small {
  color: #111827;
  font-weight: 750;
}

.topup-sbp-session {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

.topup-sbp-status {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.topup-sbp-qr {
  width: min(240px, 100%);
  margin: 0 auto;
  border-radius: 12px;
  background: #fff;
}

.topup-sbp-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px 0;
}

.topup-sbp-spinner .spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #e5e7eb;
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: prepaid-spin 0.7s linear infinite;
}

@keyframes prepaid-spin {
  to { transform: rotate(360deg); }
}

.prepaid-error {
  color: #dc3545 !important;
  font-weight: 500;
}

.prepaid-info {
  color: #2563eb !important;
  font-weight: 500;
}



#topupAmountSection {
  margin-top: 12px;
}

.crypto-picker-meta {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.crypto-picker-meta strong {
  font-size: 12px;
  font-weight: 800;
  color: #111827;
}

.crypto-picker-meta small {
  font-size: 10px;
  color: #8b8e96;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.crypto-picker-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 18px 8px;
  text-align: center;
  color: #8b8e96;
  font-size: 12px;
}

.topup-cryptobot-note {
  margin: 0;
  font-size: 11px;
  line-height: 1.45;
  color: #8b8e96;
}

.topup-cryptobot-note a {
  color: var(--accent, #2f6fed);
}

.topup-cryptobot-create-icon {
  display: inline-flex;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  vertical-align: -3px;
}

.topup-cryptobot-create-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.topup-cryptobot-invoice {
  display: grid;
  gap: 12px;
}

.topup-cryptobot-invoice-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid #eceef2;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.topup-cryptobot-invoice-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.topup-cryptobot-invoice-badge {
  padding: 5px 11px;
  border-radius: 999px;
  background: #26a17b;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
}

.topup-cryptobot-status {
  margin: 0;
  font-size: 12px;
  line-height: 1.2;
  color: #8b8e96;
  font-weight: 600;
}

.topup-cryptobot-hash {
  display: grid;
  gap: 6px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #e8ebf0;
  border-radius: 16px;
  background: #f8fafc;
  text-align: center;
  cursor: pointer;
}

.topup-cryptobot-hash-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #8b8e96;
}

.topup-cryptobot-hash code {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #111827;
  word-break: break-all;
  white-space: normal;
}

.topup-cryptobot-qr {
  justify-self: center;
  width: min(200px, 64vw);
  height: auto;
  padding: 8px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #e5e7eb;
}

.topup-cryptobot-actions {
  display: grid;
  gap: 8px;
}

.topup-cryptobot-actions-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.topup-cryptobot-action {
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid #e3e6eb;
  border-radius: 14px;
  background: #fff;
  color: #111827;
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}

.topup-cryptobot-action:active {
  background: #f3f4f6;
  border-color: #d1d5db;
}

.topup-cryptobot.has-invoice .crypto-picker,
.topup-cryptobot.has-invoice + .topup-sbp {
  display: none;
}

.crypto-picker-glyph {
  font-size: 15px;
  font-weight: 800;
  color: var(--crypto-accent);
  line-height: 1;
}

@media (max-width: 350px) {
  .screen-topup .topup-hero {
    min-height: 154px;
    padding: 18px 106px 18px 15px;
    border-radius: 23px;
  }
  .screen-topup .topup-hero h1 { font-size: 24px; }
  .screen-topup .topup-hero p { font-size: 10px; }
  .screen-topup .money-duck {
    right: 4px;
    width: 94px;
    height: 94px;
  }
  .screen-topup .topup-field,
  .screen-topup .topup-field.full {
    min-height: 68px;
    padding: 11px 12px 10px;
    border-radius: 16px;
  }
}

.notifications-overview { align-items: center; padding: 0 0 12px; border: 0; }
.notifications-overview h1 { color: var(--text); font-size: 23px; font-weight: 800; letter-spacing: -.5px; }
.notifications-overview > span { border: 0; background: var(--accent); color: var(--text); }
.screen-notifications .notification-day { margin: 18px 0 6px; color: var(--muted); }
.screen-notifications .notification-item {
  min-height: 66px;
  padding: 9px 0;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: transparent;
}
.screen-notifications .notification-item::after { display: none; }
.screen-notifications .notification-icon, .screen-notifications .notification-item.unread .notification-icon {
  border: 0;
  border-radius: 11px;
  background: var(--soft);
  color: var(--text);
}
.screen-notifications .notification-item strong { color: var(--text); }
.screen-notifications .notification-item p, .screen-notifications .notification-item time { color: var(--muted); }

.modal { background: rgba(0,0,0,.38); }
.modal-panel, .delete-panel, .success-panel {
  border: 0;
  border-radius: 20px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 20px 60px rgba(0,0,0,.18);
}
.modal-panel h2, .success-panel h2 { color: var(--text); }
.modal-panel p, .delete-panel p, .success-panel p { color: var(--muted); }
.delete-panel .modal-actions button { border: 0; background: var(--soft); color: var(--text); }
.delete-panel .modal-actions .delete-confirm { background: var(--danger); color: #fff; }
.success-icon { background: var(--green-soft); color: var(--green); }
.success-close { border: 0; background: var(--accent); color: var(--text); }
.toast { background: #292929; color: #fff; }
.creation-loading { background: rgba(244,244,244,.95); }
.creation-loading strong { color: var(--text); }

@media (max-width: 350px) {
  .account-location strong { font-size: 22px; }
  .screen-home .balance-amount { font-size: 40px; }
  .screen-home .quick-actions { gap: 6px; }
  .screen-home .quick-actions button { padding: 8px 3px; }
  .screen-home .quick-actions strong { font-size: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 1ms !important; }
}

/* Fidelity pass: match the approved account-product concept. */
.account-location strong { font-size: 28px; }

.screen-home .balance-block {
  min-height: 252px;
  padding: 0;
}

.screen-home .balance-main {
  position: relative;
  min-height: 190px;
  padding: 36px 86px 28px 28px;
}

.screen-home .balance-label {
  margin-bottom: 8px;
  font-size: 14px;
}

.screen-home .balance-amount {
  font-size: clamp(43px, 13vw, 56px);
  white-space: nowrap;
}

.balance-account {
  display: block;
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.balance-product-icon {
  position: absolute;
  top: 50%;
  right: 24px;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  transform: translateY(-50%);
  border-radius: 18px;
  background: var(--accent);
  color: var(--text);
}

.balance-product-icon svg {
  width: 27px;
  height: 27px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.screen-home .balance-footer {
  min-height: 62px;
  align-items: center;
  justify-content: space-between;
  margin-top: 0;
  padding: 0 28px;
  color: var(--text);
  font-size: 12px;
  font-weight: 650;
}

.balance-footer strong {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--green);
  font-size: 11px;
}

.screen-home .quick-actions button,
.screen-home .quick-actions button:first-of-type {
  min-height: 108px;
}

.screen-home .quick-actions .promo-duck + span {
  width: 44px;
  height: 44px;
  border-radius: 15px;
}

.screen-home .quick-actions svg { width: 22px; height: 22px; }
.screen-home .quick-actions strong { font-size: 12px; }

.screen-home .card-row,
.screen-home .card-row:nth-child(n) {
  min-height: 86px;
  grid-template-columns: 64px minmax(0, 1fr) auto auto 10px;
}

.card-preview { width: 64px; height: 54px; }
.card-preview .card-logo { width: 42px; height: 42px; }
.screen-home .wallet-card-copy strong { font-size: 14px; }
.screen-home .wallet-card-copy small { font-size: 11px; }

.screen-home .card-state {
  display: block;
  grid-column: 3;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.screen-home .card-row[data-status="reissuing"] .card-state { color: #bf8000; }
.screen-home .card-row[data-status="expired"] .card-state { color: var(--muted); }

.screen-home .card-status {
  grid-column: 4;
  color: var(--text);
  font-size: 12px;
}

.screen-home .row-chevron { grid-column: 5; }

.home-transaction {
  min-height: 72px;
  grid-template-columns: 42px 1fr auto;
}

.home-transaction-icon { width: 40px; height: 40px; }
.home-transaction strong, .home-transaction b { font-size: 12px; }
.home-transaction small, .home-transactions-empty { font-size: 10px; }

@media (max-width: 350px) {
  .screen-home .balance-main {
    min-height: 176px;
    padding: 34px 68px 24px 22px;
  }
  .screen-home .balance-amount { font-size: 36px; letter-spacing: -2px; }
  .balance-product-icon {
    right: 18px;
    width: 48px;
    height: 48px;
    border-radius: 15px;
  }
  .screen-home .card-state { display: none; }
  .screen-home .card-row,
  .screen-home .card-row:nth-child(n) {
    grid-template-columns: 56px minmax(0, 1fr) auto 10px;
  }
  .screen-home .card-status { grid-column: 3; }
  .screen-home .row-chevron { grid-column: 4; }
}

/* Creative home: open editorial layout inspired by modern delivery super-apps. */
:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --soft: #f5f6f7;
  --soft-hover: #eef0f2;
  --text: #111111;
  --muted: #8a8d94;
  --border: #e9eaec;
  --accent: #ff4f5e;
  --accent-hover: #f34252;
  --sky: #c7ebff;
  --blue: #1683ff;
  --green: #24a65a;
}

html, body { background: #eeeeee; }
.app-shell, .screen, .tg-chrome[data-view="home"] { background: #fff; }
.app-shell { overflow-x: hidden; }

.tg-chrome[data-view="home"] {
  height: 78px;
  padding: 17px 20px 5px;
}
.account-location strong {
  font-size: 23px;
  font-weight: 850;
  letter-spacing: -1.2px;
}
.account-location span { display: none; }
.bell-button {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  box-shadow: 0 9px 24px rgba(20, 24, 32, .1);
}
.notification-badge { border-color: #fff; background: var(--accent); color: #fff; }

.screen-home {
  min-height: calc(100dvh - 78px);
  padding: 0 20px 44px;
  overflow: hidden;
  background: #fff;
}

.screen-home .balance-block {
  position: relative;
  min-height: 338px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.screen-home .balance-main {
  position: relative;
  display: block;
  min-height: 266px;
  padding: 31px 0 0;
  overflow: visible;
  text-align: left;
}
.screen-home .balance-label {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  color: #74777e;
  font-size: 13px;
  font-weight: 650;
}
.screen-home .balance-label b {
  padding: 5px 9px;
  border-radius: 999px;
  background: #e7f3ff;
  color: var(--blue);
  font-size: 10px;
  font-weight: 750;
}
.screen-home .balance-amount {
  position: relative;
  z-index: 3;
  max-width: 66%;
  color: #080808;
  font-size: clamp(45px, 12.1vw, 52px);
  font-weight: 880;
  letter-spacing: -4.6px;
  line-height: .95;
}
.screen-home .balance-account {
  position: relative;
  z-index: 3;
  display: block;
  margin-top: 13px;
  color: #93969d;
  font-size: 11px;
  font-weight: 600;
  text-align: left;
}
.hero-card-object {
  position: absolute;
  z-index: 2;
  top: 49px;
  right: 2px;
  width: 122px;
  height: 190px;
  padding: 19px 16px;
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(145deg, #ff6659, #ff3c55 70%);
  color: #fff;
  box-shadow: 0 24px 44px rgba(255, 62, 81, .22);
  transform: rotate(12deg);
  pointer-events: none;
}
.hero-card-object::after {
  content: "";
  position: absolute;
  right: -35px;
  bottom: -42px;
  width: 112px;
  height: 112px;
  border: 20px solid rgba(255,255,255,.13);
  border-radius: 50%;
}
.hero-card-object strong {
  position: absolute;
  top: 19px;
  right: 16px;
  font-size: 12px;
  letter-spacing: -.5px;
}
.hero-card-object small {
  position: absolute;
  bottom: 19px;
  left: 16px;
  font-size: 10px;
  font-weight: 700;
}
.hero-card-chip {
  display: block;
  width: 28px;
  height: 21px;
  margin-top: 48px;
  border: 1px solid rgba(255,255,255,.65);
  border-radius: 7px;
  background: rgba(255,255,255,.2);
}
.hero-orbit {
  position: absolute;
  z-index: 1;
  display: block;
  border-radius: 50%;
  pointer-events: none;
}
.hero-orbit-one {
  top: 34px;
  right: 11px;
  width: 116px;
  height: 116px;
  background: #f1f1ee;
}
.hero-orbit-two {
  top: 176px;
  right: 9px;
  width: 60px;
  height: 60px;
  background: var(--sky);
}
.hero-topup {
  position: absolute;
  z-index: 4;
  left: 0;
  bottom: 18px;
  display: flex;
  min-height: 58px;
  align-items: center;
  gap: 13px;
  padding: 8px 24px 8px 9px;
  border: 0;
  border-radius: 23px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px rgba(255,79,94,.22);
}
.hero-topup span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 16px;
  background: #fff;
  color: var(--accent);
}
.hero-topup svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 2.2; }
.hero-topup strong { font-size: 15px; font-weight: 800; }
.hero-topup:active { transform: scale(.97); }

.screen-home .quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin: 3px 0 0;
  overflow: hidden;
  border: 1px solid #eeeeee;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(25,30,38,.07);
}
.screen-home .quick-actions button,
.screen-home .quick-actions button:first-of-type {
  display: grid;
  width: 100%;
  min-height: 88px;
  grid-template-columns: 42px 1fr;
  align-items: center;
  justify-content: start;
  gap: 11px;
  padding: 15px;
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
  text-align: left;
}
.screen-home .quick-actions button + button { border-left: 1px solid #ededed; }
.screen-home .quick-actions button:hover,
.screen-home .quick-actions button:first-of-type:hover { background: #fafafa; }
.screen-home .quick-actions .promo-duck { display: none; }
.screen-home .quick-actions .promo-duck + span,
.screen-home .quick-actions button:first-of-type .promo-duck + span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 14px;
  background: #e5f3ff;
  color: var(--blue);
}
.screen-home .quick-actions button:last-child .promo-duck + span {
  background: #fff0f1;
  color: var(--accent);
}
.screen-home .quick-actions svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; }
.screen-home .quick-actions strong {
  display: grid;
  gap: 4px;
  color: #151515;
  font-size: 12px;
  font-weight: 800;
  white-space: normal;
}
.screen-home .quick-actions strong small {
  color: #989ba1;
  font-size: 8px;
  font-weight: 600;
  line-height: 1.25;
}

.home-search {
  min-height: 45px;
  margin: 24px 0 34px;
  padding: 0 0 0 3px;
  border: 0;
  border-bottom: 1px solid #dedfe1;
  border-radius: 0;
  background: transparent;
}
.home-search:focus-within { border-color: #111; box-shadow: none; }
.home-search svg { color: #a4a6aa; }
.home-search input { font-size: 12px; }

.screen-home .cards-section,
.screen-home .home-operations {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.screen-home .home-operations { margin-top: 42px; }
.section-heading { margin-bottom: 20px; }
.section-heading h1, .screen-home .section-heading h1 {
  font-size: 27px;
  font-weight: 850;
  letter-spacing: -1.7px;
}
.section-heading span, .section-heading button,
.screen-home .cards-section .section-heading button {
  padding: 6px 0 6px 8px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--blue);
  font-size: 11px;
  font-weight: 750;
}
.screen-home .section-heading button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(22, 131, 255, .12);
}

.cards-list { overflow: visible; }
.cards-showcase {
  display: grid;
  grid-template-columns: minmax(132px, .85fr) minmax(0, 1.15fr);
  align-items: center;
  gap: 18px;
}
.cards-visual-stack {
  position: relative;
  min-height: 174px;
}
.stacked-card {
  position: absolute;
  left: 0;
  width: 145px;
  height: 92px;
  padding: 13px;
  border: 0;
  border-radius: 17px;
  background: #141414;
  color: #fff;
  box-shadow: 0 13px 26px rgba(20,20,20,.17);
  text-align: left;
  transform-origin: center;
}
.stacked-card[data-stack-index="0"] { z-index: 3; top: 67px; transform: rotate(1deg); }
.stacked-card[data-stack-index="1"] { z-index: 2; top: 34px; background: #6db7ff; transform: rotate(-5deg); }
.stacked-card[data-stack-index="2"] { z-index: 1; top: 4px; background: var(--accent); transform: rotate(-11deg); }
.stacked-card strong { position: absolute; top: 13px; right: 13px; font-size: 10px; }
.stacked-card small { position: absolute; bottom: 13px; left: 13px; font-size: 9px; font-weight: 700; }
.stacked-card-brand {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  overflow: hidden;
  border-radius: 8px;
  background: rgba(255,255,255,.92);
}
.stacked-card-brand img { max-width: 21px; max-height: 21px; object-fit: contain; }
.cards-summary { min-width: 0; border-top: 1px solid #e8e8e8; }
.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  display: grid;
  min-height: 58px;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 3px 8px;
  padding: 9px 0;
  border: 0;
  border-bottom: 1px solid #e8e8e8;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.screen-home .card-row.card-summary-row:hover { background: transparent !important; opacity: .65; }
.card-summary-row .wallet-card-copy { display: contents; }
.card-summary-row .wallet-card-copy strong {
  grid-column: 1;
  grid-row: 1;
  overflow: hidden;
  color: #777b82;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.card-summary-row .wallet-card-copy small {
  grid-column: 2;
  grid-row: 1;
  color: #a0a3aa;
  font-size: 8px;
}
.card-summary-row .card-state { display: none; }
.card-summary-row .card-status {
  grid-column: 1;
  grid-row: 2;
  color: #171717;
  font-size: 15px;
  font-weight: 800;
}
.card-summary-row .row-chevron { display: none; }
.screen-home .cards-empty {
  display: grid;
  min-height: 112px;
  place-items: start;
  gap: 5px;
  padding: 24px;
  border: 0;
  border-radius: 22px;
  background: var(--sky);
  text-align: left;
}
.screen-home .cards-empty.hidden { display: none; }
.screen-home .cards-empty .empty-duck { display: none; }
.screen-home .cards-empty strong { color: #111; font-size: 16px; font-weight: 850; }
.screen-home .cards-empty span { max-width: 230px; color: #527387; font-size: 10px; line-height: 1.45; }
.reissue-status-row { border-radius: 20px; }

.home-transactions-list {
  position: relative;
  padding-left: 7px;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.home-transactions-list::before {
  content: "";
  position: absolute;
  top: 25px;
  bottom: 25px;
  left: 25px;
  width: 1px;
  background: #e7e8e9;
}
.home-transaction {
  position: relative;
  min-height: 67px;
  grid-template-columns: 38px 1fr auto;
  gap: 13px;
  padding: 7px 0;
  border: 0;
  background: transparent;
}
.home-transaction-icon {
  z-index: 1;
  width: 38px;
  height: 38px;
  border: 5px solid #fff;
  border-radius: 50%;
  background: var(--sky);
  color: var(--blue);
  box-sizing: content-box;
}
.home-transaction:nth-child(odd) .home-transaction-icon { background: #fff0f1; color: var(--accent); }
.home-transaction strong, .home-transaction b { font-size: 11px; }
.home-transaction small, .home-transactions-empty { font-size: 9px; }
.home-transaction b { align-self: center; }

@media (max-width: 360px) {
  .screen-home { padding-inline: 16px; }
  .screen-home .balance-main { min-height: 266px; }
  .screen-home .balance-block { min-height: 334px; }
  .screen-home .balance-amount { font-size: 46px; letter-spacing: -4.1px; }
  .hero-card-object { right: -13px; width: 116px; height: 184px; }
  .cards-showcase { grid-template-columns: 125px minmax(0, 1fr); gap: 12px; }
  .stacked-card { width: 130px; height: 83px; }
  .cards-visual-stack { min-height: 162px; }
  .screen-home .quick-actions button,
  .screen-home .quick-actions button:first-of-type {
    grid-template-columns: 36px 1fr;
    gap: 8px;
    padding: 11px;
  }
  .screen-home .quick-actions .promo-duck + span,
  .screen-home .quick-actions button:first-of-type .promo-duck + span {
    width: 36px;
    height: 36px;
  }
}

/* Absolute last overrides for card realism and compact card section. */
.hero-card-object {
  top: 108px !important;
  right: 6px !important;
  width: 150px !important;
  height: 94px !important;
  padding: 14px !important;
  border-radius: 20px !important;
  background:
    radial-gradient(circle at 82% 92%, rgba(255,255,255,.12), transparent 35%),
    linear-gradient(145deg, #ff6a5c 0%, #ff3f55 100%) !important;
  box-shadow: 0 18px 36px rgba(255, 79, 94, .18) !important;
  transform: rotate(7deg) !important;
}

.hero-card-object::before {
  content: "";
  position: absolute;
  top: 43px;
  left: 52px;
  width: 15px;
  height: 20px;
  border-right: 2px solid rgba(255,255,255,.7);
  border-radius: 50%;
}

.hero-card-object::after {
  display: none;
}

.hero-card-object strong {
  top: 13px !important;
  right: 14px !important;
  font-size: 11px !important;
}

.hero-card-object small {
  bottom: 13px !important;
  left: 14px !important;
  font-size: 9px !important;
}

.hero-card-chip {
  width: 27px !important;
  height: 20px !important;
  margin-top: 28px !important;
}

.hero-orbit-one {
  top: 82px !important;
  right: 38px !important;
  width: 104px !important;
  height: 104px !important;
}

.hero-orbit-two {
  top: 154px !important;
  right: 0 !important;
  width: 94px !important;
  height: 94px !important;
}

.cards-showcase {
  display: block !important;
  min-height: 0 !important;
  padding: 0 !important;
}

.cards-visual-stack {
  min-height: 148px !important;
  margin-bottom: 10px !important;
}

.stacked-card {
  width: 210px !important;
  height: 132px !important;
  border-radius: 22px !important;
  box-shadow: 0 16px 30px rgba(21, 24, 32, .14) !important;
}

.stacked-card::after {
  display: none !important;
}

.stacked-card[data-stack-index="0"] {
  top: 16px !important;
  left: 50% !important;
  transform: translateX(-50%) rotate(0deg) !important;
}

.stacked-card[data-stack-index="1"] {
  top: 8px !important;
  left: calc(50% + 9px) !important;
  transform: translateX(-50%) rotate(-4deg) !important;
}

.stacked-card[data-stack-index="2"] {
  top: 0 !important;
  left: calc(50% - 9px) !important;
  transform: translateX(-50%) rotate(-8deg) !important;
}

.cards-summary {
  display: block !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 10px 28px rgba(20, 24, 32, .04) !important;
}

@media (max-width: 360px) {
  .hero-card-object {
    top: 112px !important;
    right: -2px !important;
    width: 132px !important;
    height: 84px !important;
  }
  .hero-orbit-two {
    width: 82px !important;
    height: 82px !important;
  }
  .cards-visual-stack {
    min-height: 134px !important;
  }
  .stacked-card {
    width: 188px !important;
    height: 118px !important;
  }
}

/* Corrections after visual QA: no overlap, no home feed, stable notifications, realistic cards. */
.screen-home .home-operations {
  display: none !important;
}

.screen-home .balance-block {
  min-height: 320px;
}

.screen-home .balance-main {
  min-height: 246px;
}

.screen-home .balance-amount {
  max-width: 58%;
  font-size: clamp(39px, 10.2vw, 44px);
  letter-spacing: -3.4px;
}

.hero-card-object {
  top: 100px;
  right: 2px;
  width: 150px;
  height: 94px;
  padding: 14px;
  border-radius: 20px;
  background: linear-gradient(145deg, #ff6659 0%, #ff4357 100%);
  box-shadow: 0 18px 36px rgba(255, 79, 94, .2);
  transform: rotate(7deg);
}

.hero-card-object::after {
  right: -36px;
  bottom: -48px;
  width: 104px;
  height: 104px;
  border-width: 18px;
}

.hero-card-object strong {
  top: 13px;
  right: 14px;
  font-size: 11px;
}

.hero-card-object small {
  bottom: 13px;
  left: 14px;
  font-size: 9px;
}

.hero-card-chip {
  width: 27px;
  height: 20px;
  margin-top: 28px;
}

.hero-orbit-one {
  top: 78px;
  right: 40px;
  width: 104px;
  height: 104px;
}

.hero-orbit-two {
  top: 154px;
  right: 0;
  width: 94px;
  height: 94px;
}

.cards-section {
  overflow: visible;
}

.cards-list {
  overflow: visible;
}

.cards-showcase {
  display: block;
  min-height: 0;
  padding: 0;
}

.cards-visual-stack {
  position: relative;
  min-height: 176px;
  margin: 0 0 12px;
  overflow: visible;
}

.stacked-card {
  left: 50%;
  width: 236px;
  height: 146px;
  padding: 18px;
  border-radius: 24px;
  box-shadow: 0 18px 36px rgba(21, 24, 32, .16);
}

.stacked-card[data-stack-index="0"] {
  top: 26px;
  left: 50%;
  transform: translateX(-50%) rotate(0deg);
}

.stacked-card[data-stack-index="1"] {
  top: 14px;
  left: calc(50% + 10px);
  transform: translateX(-50%) rotate(-4deg);
}

.stacked-card[data-stack-index="2"] {
  top: 0;
  left: calc(50% - 10px);
  transform: translateX(-50%) rotate(-8deg);
}

.stacked-card-chip {
  top: 22px;
  left: 18px;
  width: 34px;
  height: 25px;
  border-radius: 9px;
}

.stacked-card-wave {
  top: 25px;
  left: 64px;
}

.stacked-card strong {
  top: 19px;
  right: 19px;
  font-size: 13px;
}

.stacked-card small {
  bottom: 18px;
  left: 18px;
  font-size: 12px;
}

.stacked-card-brand {
  right: 18px;
  bottom: 16px;
  width: 40px;
  height: 40px;
  border-radius: 13px;
}

.cards-summary {
  display: block;
  overflow: hidden;
  border: 1px solid #eeeeef;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(20, 24, 32, .04);
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 58px;
  grid-template-columns: minmax(0, 1fr) auto 14px;
  padding: 0 14px;
  border-bottom: 1px solid #eeeeef;
}

.screen-home .card-row.card-summary-row:last-child {
  border-bottom: 0;
}

.card-summary-row .wallet-card-copy strong {
  font-size: 13px;
  letter-spacing: -.3px;
}

.card-summary-row .card-status {
  display: block;
  grid-column: 2;
  color: #8f939b;
  font-size: 10px;
  font-weight: 750;
}

.card-summary-row .row-chevron {
  grid-column: 3;
}

.screen-notifications {
  min-height: calc(100dvh - 66px);
}

.screen-notifications .notifications-panel {
  display: flex;
  min-height: calc(100dvh - 66px);
  flex-direction: column;
}

.screen-notifications .notifications-list {
  flex: 1 1 auto;
}

.screen-notifications .list-pagination {
  position: sticky;
  bottom: 0;
  z-index: 4;
  margin-top: auto;
  padding: 14px 0 18px;
  border-top: 1px solid #f0f1f3;
  background: linear-gradient(180deg, rgba(255,255,255,.82), #fff 34%);
  backdrop-filter: blur(12px);
}

@media (max-width: 360px) {
  .screen-home .balance-block {
    min-height: 310px;
  }
  .screen-home .balance-main {
    min-height: 236px;
  }
  .screen-home .balance-amount {
    font-size: 37px;
    letter-spacing: -3px;
  }
  .hero-card-object {
    top: 102px;
    right: -4px;
    width: 132px;
    height: 84px;
    border-radius: 18px;
  }
  .hero-orbit-two {
    top: 150px;
    width: 82px;
    height: 82px;
  }
  .cards-visual-stack {
    min-height: 156px;
  }
  .stacked-card {
    width: 206px;
    height: 128px;
  }
  .screen-home .card-row.card-summary-row,
  .screen-home .card-row.card-summary-row:nth-child(n) {
    min-height: 54px;
    padding: 0 12px;
  }
}

/* Final polish pass: owned-card payments, realistic card stack, clean issue selects. */
.screen-home .balance-amount {
  max-width: 56%;
  font-size: clamp(40px, 10.7vw, 46px);
  letter-spacing: -3.8px;
}

.hero-card-object {
  top: 84px;
  right: 12px;
  width: 112px;
  height: 174px;
  border-radius: 22px;
}

.hero-card-object strong { font-size: 11px; }
.hero-card-object small { font-size: 9px; }
.hero-card-chip {
  width: 25px;
  height: 19px;
  margin-top: 43px;
}

.hero-orbit-one {
  top: 70px;
  right: 24px;
  width: 110px;
  height: 110px;
}

.hero-orbit-two {
  top: 188px;
  right: 7px;
  width: 86px;
  height: 86px;
  background: #b9e7ff;
}

.cards-showcase {
  min-height: 186px;
  grid-template-columns: 172px minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
  padding: 0;
}

.cards-visual-stack {
  min-height: 186px;
}

.stacked-card {
  width: 172px;
  height: 108px;
  padding: 14px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 16px 32px rgba(21, 24, 32, .16);
}

.stacked-card::after {
  content: "";
  position: absolute;
  right: -34px;
  bottom: -42px;
  width: 108px;
  height: 108px;
  border: 18px solid rgba(255,255,255,.1);
  border-radius: 50%;
}

.stacked-card[data-stack-index="0"] {
  z-index: 3;
  top: 72px;
  left: 2px;
  background: linear-gradient(145deg, #151515, #242424);
  transform: rotate(0deg);
}

.stacked-card[data-stack-index="1"] {
  z-index: 2;
  top: 38px;
  left: 18px;
  background: linear-gradient(145deg, #58b3ff, #8bd6ff);
  transform: rotate(-3deg);
}

.stacked-card[data-stack-index="2"] {
  z-index: 1;
  top: 7px;
  left: 4px;
  background: linear-gradient(145deg, #ff6659, #ff4f5e);
  transform: rotate(-9deg);
}

.stacked-card-chip {
  position: absolute;
  top: 18px;
  left: 15px;
  width: 29px;
  height: 22px;
  border: 1px solid rgba(255,255,255,.55);
  border-radius: 8px;
  background: rgba(255,255,255,.18);
}

.stacked-card-wave {
  position: absolute;
  top: 20px;
  left: 54px;
  width: 15px;
  height: 21px;
  border-right: 2px solid rgba(255,255,255,.72);
  border-radius: 50%;
}

.stacked-card strong {
  top: 14px;
  right: 14px;
  z-index: 1;
  font-size: 11px;
}

.stacked-card small {
  bottom: 14px;
  left: 15px;
  z-index: 1;
  font-size: 10px;
  letter-spacing: .04em;
}

.stacked-card-brand {
  position: absolute;
  right: 13px;
  bottom: 12px;
  z-index: 1;
  width: 34px;
  height: 34px;
  border-radius: 11px;
}

.cards-summary {
  display: grid;
  align-content: center;
  min-width: 0;
  border-top: 0;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 52px;
  grid-template-columns: minmax(0, 1fr) 12px;
  grid-template-rows: auto;
  align-items: center;
  padding: 0 0 0 4px;
  gap: 8px;
}

.card-summary-row .wallet-card-copy strong {
  grid-column: 1;
  grid-row: 1;
  color: #111;
  font-size: 12px;
  font-weight: 850;
}

.card-summary-row .wallet-card-copy small,
.card-summary-row .card-state,
.card-summary-row .card-status {
  display: none;
}

.card-summary-row .row-chevron {
  display: block;
  grid-column: 2;
  width: 7px;
  height: 7px;
  border-color: #a7abb2;
}

.screen-topup .external-card-field.hidden {
  display: none !important;
}

.screen-topup .topup-hero {
  min-height: 150px;
  padding-right: 116px;
}

.screen-topup .money-duck {
  right: 7px;
  bottom: 5px;
  width: 122px;
  height: 122px;
}

.screen-issue .custom-select-trigger {
  min-height: 58px;
  border: 1px solid #e8eaee;
  border-radius: 19px;
  background: #fff;
  box-shadow: 0 10px 25px rgba(20,24,32,.045);
}

.screen-issue .custom-select-trigger:hover,
.screen-issue .custom-select-trigger:focus-visible,
.screen-issue .custom-select-trigger[aria-expanded="true"] {
  border-color: rgba(255, 79, 94, .28);
  background: #fffafa;
  box-shadow: 0 0 0 4px rgba(255, 79, 94, .08);
  outline: none;
}

.screen-issue .custom-select-menu {
  overflow: hidden;
  margin-top: 8px;
  border: 1px solid #e8eaee;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 20px 44px rgba(20,24,32,.12);
}

.screen-issue .custom-select-option {
  min-height: 58px;
  padding: 10px 12px;
  border-bottom: 1px solid #f0f1f3;
  background: #fff;
  color: #111;
}

.screen-issue .custom-select-option:last-child {
  border-bottom: 0;
}

.screen-issue .custom-select-option:not(:disabled):hover,
.screen-issue .custom-select-option:not(:disabled):focus-visible,
.screen-issue .custom-select-option.selected {
  background: #fff8f8;
  color: #111;
}

.screen-issue .custom-select-option:disabled {
  background: #fafafa;
  color: #a9adb4;
  opacity: 1;
}

.screen-issue .custom-select-option small {
  color: #a9adb4;
}

.screen-issue .custom-select-option.selected .option-check {
  color: var(--accent);
}

.tg-chrome[data-view="issue"] {
  border-bottom: 0;
  background: #fff;
  box-shadow: none;
}

.tg-chrome[data-view="issue"] .back-action {
  color: #8b8e96;
}

.tg-chrome[data-view="issue"] .back-action:hover,
.tg-chrome[data-view="issue"] .back-action:focus-visible {
  color: #111;
  background: transparent;
  outline: none;
}

.tg-chrome[data-view="issue"] .chrome-title strong {
  color: #111;
  font-size: 15px;
  font-weight: 850;
}

.tg-chrome[data-view="issue"] .chrome-title span {
  color: #9da0a7;
}

.screen-issue .bottom-cta,
.screen-issue .bottom-cta:not(:disabled) {
  min-height: 54px;
  border-radius: 20px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px rgba(255,79,94,.2);
}

.screen-issue .bottom-cta:hover,
.screen-issue .bottom-cta:focus-visible {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 16px 34px rgba(255,79,94,.24);
  outline: none;
}

@media (max-width: 360px) {
  .screen-home .balance-amount {
    font-size: 39px;
    letter-spacing: -3.4px;
  }
  .hero-card-object {
    top: 88px;
    right: 2px;
    width: 104px;
    height: 164px;
  }
  .hero-orbit-two {
    width: 78px;
    height: 78px;
  }
  .cards-showcase {
    grid-template-columns: 152px minmax(0, 1fr);
    gap: 8px;
  }
  .stacked-card {
    width: 152px;
    height: 96px;
  }
  .stacked-card[data-stack-index="0"] { top: 70px; }
  .stacked-card[data-stack-index="1"] { left: 14px; }
  .screen-topup .topup-hero {
    padding-right: 98px;
  }
  .screen-topup .money-duck {
    width: 102px;
    height: 102px;
  }
}

/* Final cards layout: left visual stack + right compact list, without overlap. */
.cards-showcase {
  display: grid !important;
  grid-template-columns: 168px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 14px !important;
  min-height: 166px !important;
  padding: 0 !important;
}

.cards-visual-stack {
  position: relative !important;
  min-height: 154px !important;
  margin: 0 !important;
  overflow: visible !important;
}

.stacked-card {
  width: 166px !important;
  height: 104px !important;
  padding: 13px !important;
  border-radius: 20px !important;
  box-shadow: 0 15px 30px rgba(21, 24, 32, .15) !important;
}

.stacked-card::after {
  display: none !important;
}

.stacked-card[data-stack-index="0"] {
  top: 48px !important;
  left: 0 !important;
  transform: rotate(0deg) !important;
}

.stacked-card[data-stack-index="1"] {
  top: 25px !important;
  left: 12px !important;
  transform: rotate(-4deg) !important;
}

.stacked-card[data-stack-index="2"] {
  top: 4px !important;
  left: 0 !important;
  transform: rotate(-8deg) !important;
}

.stacked-card-chip {
  top: 16px !important;
  left: 14px !important;
  width: 28px !important;
  height: 21px !important;
}

.stacked-card-wave {
  top: 18px !important;
  left: 52px !important;
}

.stacked-card strong {
  top: 14px !important;
  right: 14px !important;
  font-size: 10px !important;
}

.stacked-card small {
  bottom: 13px !important;
  left: 14px !important;
  font-size: 9px !important;
}

.stacked-card-brand {
  right: 12px !important;
  bottom: 11px !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 11px !important;
}

.cards-summary {
  display: block !important;
  overflow: hidden !important;
  border: 1px solid #eeeeef !important;
  border-radius: 20px !important;
  background: #fff !important;
  box-shadow: 0 10px 26px rgba(20, 24, 32, .035) !important;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 50px !important;
  grid-template-columns: minmax(0, 1fr) 12px !important;
  padding: 0 10px 0 12px !important;
}

.card-summary-row .wallet-card-copy strong {
  font-size: 11px !important;
  letter-spacing: -.25px !important;
}

.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row .row-chevron {
  display: block !important;
  grid-column: 2 !important;
}

@media (max-width: 360px) {
  .cards-showcase {
    grid-template-columns: 142px minmax(0, 1fr) !important;
    gap: 10px !important;
    min-height: 144px !important;
  }

  .cards-visual-stack {
    min-height: 134px !important;
  }

  .stacked-card {
    width: 140px !important;
    height: 88px !important;
    border-radius: 18px !important;
  }

  .stacked-card[data-stack-index="0"] { top: 42px !important; }
  .stacked-card[data-stack-index="1"] { top: 22px !important; left: 9px !important; }
  .stacked-card[data-stack-index="2"] { top: 4px !important; }

  .screen-home .card-row.card-summary-row,
  .screen-home .card-row.card-summary-row:nth-child(n) {
    min-height: 46px !important;
    padding: 0 8px 0 10px !important;
  }

  .card-summary-row .wallet-card-copy strong {
    font-size: 10px !important;
  }
}

/* UX completion pass, applied after legacy overrides. */
.screen-home .cards-section .section-heading > div {
  display: grid;
  gap: 2px;
}

.cards-meta {
  display: block !important;
  color: #8c9199 !important;
  font-size: 10px !important;
  font-weight: 750 !important;
}

.screen-home .cards-list {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

.cards-showcase {
  display: block !important;
  min-height: 0 !important;
  padding: 0 !important;
}

.cards-showcase-top {
  display: grid !important;
  grid-template-columns: 150px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 14px !important;
  min-height: 158px !important;
  margin-bottom: 10px !important;
}

.cards-visual-stack {
  position: relative !important;
  min-height: 150px !important;
  margin: 0 !important;
  overflow: visible !important;
}

.stacked-card {
  width: 148px !important;
  height: 94px !important;
  border-radius: 20px !important;
  box-shadow: 0 18px 36px rgba(21, 24, 32, .16) !important;
}

.stacked-card[data-stack-index="0"] {
  top: 52px !important;
  left: 0 !important;
  transform: rotate(0deg) !important;
}

.stacked-card[data-stack-index="1"] {
  top: 29px !important;
  left: 13px !important;
  transform: rotate(-4deg) !important;
}

.stacked-card[data-stack-index="2"] {
  top: 7px !important;
  left: 0 !important;
  transform: rotate(-8deg) !important;
}

.cards-focus-card {
  display: grid !important;
  width: 100% !important;
  min-height: 118px !important;
  align-content: center !important;
  gap: 5px !important;
  padding: 16px !important;
  border: 1px solid #eeeeef !important;
  border-radius: 24px !important;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 79, 94, .11), transparent 52%),
    #fff !important;
  text-align: left !important;
  box-shadow: 0 14px 34px rgba(20, 24, 32, .055) !important;
}

.cards-focus-card span {
  color: #9297a0 !important;
  font-size: 9px !important;
  font-weight: 850 !important;
  text-transform: uppercase !important;
  letter-spacing: .05em !important;
}

.cards-focus-card strong {
  color: #111 !important;
  font-size: 17px !important;
  font-weight: 900 !important;
  letter-spacing: -.55px !important;
}

.cards-focus-card small {
  color: #747b87 !important;
  font-size: 11px !important;
  font-weight: 750 !important;
}

.cards-focus-card b {
  width: max-content !important;
  margin-top: 7px !important;
  padding: 6px 10px !important;
  border-radius: 999px !important;
  background: #fff0f1 !important;
  color: var(--accent) !important;
  font-size: 10px !important;
  font-weight: 900 !important;
}

.cards-summary {
  display: block !important;
  width: 100% !important;
  border-radius: 22px !important;
  box-shadow: 0 12px 30px rgba(20, 24, 32, .045) !important;
}

.screen-home .card-row.card-summary-row,
.screen-home .card-row.card-summary-row:nth-child(n) {
  min-height: 54px !important;
  grid-template-columns: minmax(0, 1fr) 12px !important;
  gap: 7px !important;
  padding: 0 10px 0 12px !important;
}

.card-summary-row .wallet-card-copy {
  display: grid !important;
  grid-column: 1 !important;
  min-width: 0 !important;
  gap: 2px !important;
}

.card-summary-row .wallet-card-copy strong {
  color: #111 !important;
  font-size: 12px !important;
  font-weight: 850 !important;
}

.card-summary-row .wallet-card-copy small {
  display: block !important;
  color: #8f939b !important;
  font-size: 9px !important;
  font-weight: 700 !important;
}

.card-summary-row .card-status {
  display: none !important;
}

.card-summary-row[data-status="reissuing"] .card-status {
  background: #fff5df !important;
  color: #b47700 !important;
}

.card-summary-row[data-status="expired"] .card-status {
  background: #f1f2f4 !important;
  color: #8f939b !important;
}

.card-summary-row .row-chevron {
  grid-column: 2 !important;
}

.screen-topup .topup-target {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  gap: 11px;
  margin: 14px 0 12px;
  padding: 12px;
  border: 1px solid #eeeeef;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(20, 24, 32, .04);
}

.topup-target-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 15px;
  background: #fff0f1;
  color: var(--accent);
  font-size: 22px;
  font-weight: 650;
}

.topup-target div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.topup-target small {
  color: #9297a0;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.topup-target strong {
  overflow: hidden;
  color: #111;
  font-size: 14px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topup-target span:last-child {
  color: #7e8490;
  font-size: 11px;
  font-weight: 650;
}

.quick-amounts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 0 0 14px;
}

.quick-amounts button {
  min-height: 42px;
  border: 1px solid #eeeeef;
  border-radius: 15px;
  background: #fff;
  color: #111;
  font-size: 12px;
  font-weight: 850;
  box-shadow: 0 8px 20px rgba(20, 24, 32, .035);
}

.quick-amounts button:hover,
.quick-amounts button:focus-visible {
  border-color: rgba(255, 79, 94, .24);
  background: #fff8f8;
  outline: none;
}

.notification-filters {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  margin: 0 0 14px;
  padding: 2px 0 10px;
}

.notification-filters::-webkit-scrollbar { display: none; }

.notification-filters button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 34px;
  padding: 0 13px;
  border: 0;
  border-radius: 20px;
  background: #f3f4f6;
  color: #8f949d;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.notification-filters button.active {
  background: #111;
  color: #fff;
  box-shadow: 0 4px 12px rgba(20, 24, 32, .14);
}

.notification-filters .filter-icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.notification-filters .filter-count {
  display: none;
  align-items: center;
  justify-content: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .1);
  font-size: 9px;
  font-weight: 900;
  line-height: 1;
}

.notification-filters button.active .filter-count {
  background: rgba(255, 255, 255, .22);
}

.notification-item.unread {
  background: linear-gradient(90deg, #fff8f8, #fff);
}

.notification-item.unread strong::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--accent);
  vertical-align: 1px;
}

.topup-confirm-panel {
  border-radius: 26px;
}

.topup-confirm-panel h2 {
  margin-bottom: 8px;
  color: #111;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -.65px;
}

.topup-confirm-panel p {
  color: #737985;
  font-size: 13px;
  line-height: 1.45;
}

.topup-confirm {
  background: var(--accent) !important;
  color: #fff !important;
  box-shadow: 0 14px 30px rgba(255, 79, 94, .2) !important;
}

.topup-confirm:hover,
.topup-confirm:focus-visible {
  background: var(--accent-hover) !important;
  color: #fff !important;
  outline: none;
}

@media (max-width: 360px) {
  .cards-showcase {
    grid-template-columns: 136px minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .stacked-card {
    width: 136px !important;
    height: 86px !important;
  }

  .screen-home .card-row.card-summary-row,
  .screen-home .card-row.card-summary-row:nth-child(n) {
    min-height: 50px !important;
    padding-left: 10px !important;
  }

  .card-summary-row .wallet-card-copy strong {
    font-size: 10px !important;
  }

  .card-summary-row .wallet-card-copy small,
  .card-summary-row .card-status {
    font-size: 8px !important;
  }

  .quick-amounts,
  .notification-filters {
    gap: 5px;
  }
}
