.legacy-stats-card--mobile-bottom {
  display: none;
}

@media (max-width: 640px) {
  .legacy-embed-shell--statement .legacy-osv-captionbar {
    display: none !important;
  }

  .legacy-dashboard-grid {
    display: flex !important;
    flex-direction: column !important;
  }

  .legacy-dashboard-grid > .legacy-stack:not(.legacy-sidebar-stack) {
    order: 20 !important;
  }

  .legacy-sidebar-stack {
    display: contents !important;
  }

  .legacy-sidebar-stack > .legacy-auth-card {
    order: 10 !important;
    margin-top: 0 !important;
  }

  .legacy-stats-card--desktop {
    display: none !important;
  }

  .legacy-stats-card--mobile-bottom {
    display: block !important;
    margin-top: 1rem !important;
    margin-bottom: 0 !important;
  }

  .legacy-embed-shell--statement .legacy-section-body,
  .legacy-embed-shell--statement .legacy-card-body,
  .legacy-embed-shell--statement .legacy-embed-body {
    padding-left: 0.45rem !important;
    padding-right: 0.45rem !important;
  }

  .legacy-osv-mobile-view {
    padding: 0.35rem !important;
    gap: 0.85rem !important;
  }

  .legacy-osv-mobile-view > .legacy-osv-mobile-period {
    display: grid !important;
  }

  .legacy-osv-mobile-period,
  .legacy-osv-mobile-account,
  .legacy-osv-mobile-section,
  .legacy-osv-mobile-final {
    width: 100% !important;
    max-width: 100% !important;
  }

  .legacy-osv-mobile-period {
    padding: 0.85rem !important;
  }

  .legacy-osv-mobile-view--empty-period {
    display: block !important;
    padding: 0.35rem 0.45rem 0 !important;
    margin: 0 !important;
  }

  .legacy-osv-mobile-period__actions,
  .legacy-embed-shell--statement .legacy-osv-caption-controls {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.72rem !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    justify-items: stretch !important;
    align-items: stretch !important;
  }

  .legacy-osv-mobile-period__actions .button,
  .legacy-osv-mobile-period__actions select,
  .legacy-embed-shell--statement .legacy-osv-caption-controls .button,
  .legacy-embed-shell--statement .legacy-osv-caption-controls select {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 3.45rem !important;
    box-sizing: border-box !important;
    text-align: center !important;
  }

  .legacy-osv-mobile-account__main {
    padding: 1rem !important;
  }

  .legacy-osv-mobile-account__main strong,
  .legacy-osv-mobile-account__main p {
    max-width: 100% !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
  }

  .legacy-osv-mobile-balance {
    margin: 0 1rem 1rem !important;
  }

  .legacy-osv-mobile-cards {
    padding: 0.75rem !important;
  }

  .legacy-osv-mobile-charge > strong {
    padding: 0.95rem 1rem !important;
  }

  .legacy-osv-mobile-charge > div,
  .legacy-mobile-data-grid > div {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.32rem !important;
    padding: 0.85rem 1rem !important;
    box-sizing: border-box !important;
    text-align: left !important;
  }

  .legacy-mobile-data-grid > div {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .legacy-osv-mobile-charge span,
  .legacy-osv-mobile-charge b,
  .legacy-mobile-data-grid span,
  .legacy-mobile-data-grid strong {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    text-align: left !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
  }

  .legacy-osv-mobile-charge b,
  .legacy-mobile-data-grid strong {
    font-size: 1.06rem !important;
    line-height: 1.2 !important;
  }

  .legacy-embed-shell--statement .legacy-osv-data-table td {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.3rem !important;
    padding: 0.85rem 1rem !important;
    text-align: left !important;
  }

  .legacy-embed-shell--statement .legacy-osv-data-table td::before,
  .legacy-embed-shell--statement .legacy-osv-data-table td,
  .legacy-embed-shell--statement .legacy-osv-data-table td * {
    max-width: 100% !important;
    text-align: left !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
  }

  .legacy-embed-shell--statement .legacy-osv-empty {
    margin: 0.85rem 0.45rem 0.45rem !important;
    padding: 1.2rem 1rem !important;
    border-radius: 1.35rem !important;
    box-sizing: border-box !important;
  }

  .legacy-embed-shell--statement .legacy-osv-empty-badge {
    margin: 0 0 0.9rem !important;
  }

  .legacy-embed-shell--statement .legacy-osv-empty-title {
    margin: 0 0 0.65rem !important;
    line-height: 1.18 !important;
  }

  .legacy-embed-shell--statement .legacy-osv-empty-copy {
    margin: 0 !important;
    line-height: 1.32 !important;
  }
}
