/* AdaWang performance + polish v1 — load LAST */
html { scroll-behavior: smooth; }
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Smooth interactive elements */
a, button, .btn, .dash-action, .side-link, .vp-logo-option,
.dash-card, .aw-stat, input, select, textarea {
  transition: background-color .15s ease, color .15s ease, border-color .15s ease,
              box-shadow .15s ease, transform .12s ease, opacity .15s ease;
}

/* Material Icons — never show ligature names as text */
.material-icons-outlined,
.material-icons,
span.material-icons-outlined {
  font-family: "Material Icons Outlined" !important;
  font-weight: normal !important;
  font-style: normal !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  white-space: nowrap !important;
  display: inline-block;
  line-height: 1;
  font-feature-settings: "liga" !important;
  -webkit-font-smoothing: antialiased;
  speak: never;
  -webkit-text-fill-color: currentColor !important;
}
.material-icons { font-family: "Material Icons" !important; }

/* Readable text defaults */
.card, .dash-card, .panel, .aw-stat, .instruction-list li,
.manual-payment-card, .copy-row {
  color: #0f172a;
}
.muted, .section-sub { color: #64748b !important; }
.transaction-page-hero .muted, .transaction-page-hero .section-sub,
.la-hero-main .muted, .usecases-section .muted {
  color: #ffffff !important; -webkit-text-fill-color: #ffffff !important;
}

/* Compact professional cards */
.dash-card, .card, .aw-stat {
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(15,23,42,.04);
}

/* Stats: don't restyle icon spans */
.aw-stat .material-icons-outlined {
  font-size: 18px !important;
  text-transform: none !important;
  letter-spacing: normal !important;
  font-weight: normal !important;
}

/* Dark heroes — white text */
.dash-profile, .dash-wallet, .duitnow-hero, .p2p-wallet-copy,
.bank-page-hero > div:first-child, .ia-hero-main {
  color: #fff !important;
}
.dash-profile h1, .dash-wallet strong, .duitnow-hero h1,
.p2p-wallet-copy h1 {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

/* Buttons on dark */
.dash-profile .dash-btn-primary {
  background: #f0b90b !important;
  color: #0f172a !important;
  -webkit-text-fill-color: #0f172a !important;
}
.dash-profile .dash-btn-outline {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  border-color: rgba(255,255,255,.5) !important;
}

/* Sidebar desktop */
@media (min-width: 993px) {
  body.customer-portal-body .portal-sidebar {
    position: fixed !important;
    top: 0; left: 0; bottom: 0;
    width: 270px !important;
    height: 100vh !important;
    overflow-y: auto !important;
    z-index: 100;
  }
  body.customer-portal-body .portal-main {
    margin-left: 270px !important;
    width: calc(100% - 270px) !important;
    min-height: 100vh;
  }
}

/* Long lists — skip offscreen layout work */
.loan-row, .wallet-row, .application-row {
  content-visibility: auto;
  contain-intrinsic-size: 72px;
}

/* Images */
img { max-width: 100%; height: auto; }
img[loading="lazy"] { content-visibility: auto; }

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* Footer readable */
footer, .site-footer, .aw-footer, .aw-footer a {
  color: inherit;
}

/* Form controls */
input, select, textarea {
  color: #0f172a !important;
  -webkit-text-fill-color: #0f172a !important;
}

/* Compact spacing */
.portal-main { padding-bottom: 24px; }
.dash-actions { gap: 10px; }
