:root {
  --navy: #052b49;
  --blue: #0759d2;
  --ink: #142b3d;
  --muted: #506478;
  --bg: #f3f6fa;
  --line: #dce5ed;
  --app-width: 460px;
  --nav-height: calc(72px + env(safe-area-inset-bottom));
}

html, body {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

body {
  display: grid;
  place-items: center;
  padding: 0;
  background: #e4edf4;
}

html, body, button, input, textarea, select {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#app {
  position: relative;
  width: min(100%, var(--app-width));
  height: 100dvh;
  overflow: hidden;
}

body #app > .app {
  position: relative;
  inset: auto;
  width: 100%;
  max-width: none;
  height: 100%;
  min-height: 0;
  margin: 0;
  border-radius: 0;
  box-shadow: none;
  transform: none;
}

@media (min-width: 580px) {
  #app {
    height: min(920px, calc(100dvh - 40px));
    border: 1px solid #ccdce9;
    border-radius: 30px;
    box-shadow: 0 24px 76px #18355035;
  }
}

.app button, .demo-sheet button { touch-action: manipulation; }
.app input, .app textarea { font-size: max(16px, 1em); }

.v6-home .home-scroll {
  height: calc(100% - var(--nav-height));
  scrollbar-width: none;
}

.v6-home-content { padding-bottom: 56px; }
.v6-home-content:before { height: 48px; }

.v6-home .v6-header {
  min-height: 96px;
  padding: calc(14px + env(safe-area-inset-top)) 18px 14px;
  align-items: center;
}

.v6-home .v11-customer { min-width: 0; }

.v6-home .v6-header h1 {
  font-size: clamp(17px, 5vw, 22px);
  font-weight: 650;
  letter-spacing: -.035em;
}

.mobile-brand {
  display: block;
  color: #b7e5ec;
  font-size: .8125rem;
  font-weight: 650;
  margin-bottom: 2px;
}

.v6-home .v6-header-actions { gap: 2px; }

.v6-home .v6-header-icon {
  width: 44px;
  height: 44px;
}

.v6-home .v6-header-icon img { width: 24px; height: 24px; }

.mobile-demo {
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: #d0e8fb;
  font-size: .8125rem;
  font-weight: 600;
}

.v6-home .v6-account-card,
.v6-home .v6-account-card-body {
  border-radius: 20px;
}

.v6-home .v6-account-card {
  border: 1px solid #d8e4f0;
  box-shadow: 0 4px 8px #1337570b;
}

.v6-home .v6-account-card-body {
  background: radial-gradient(ellipse at top right, #eaf4fc, #fff 72%);
}

.v6-home .v6-account-title,
.v6-home .v6-account-selector,
.v6-home .v6-card-balance strong { letter-spacing: -.025em; }

.v6-home .v6-card-balance strong {
  font-size: clamp(20px, 5.5vw, 27px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.v6-home .v6-section-head h2 {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -.025em;
}

.v6-home .v6-quick {
  min-height: 92px;
  height: auto;
  padding: 10px 4px 7px;
  border: 1px solid #e1e9f1;
  border-radius: 16px;
  gap: 5px;
}

.v6-home .v6-quick > img {
  width: 38px;
  height: 38px;
  padding: 5px;
  border-radius: 13px;
  background: #eef5ff;
}

.v6-home .v6-quick > span {
  height: auto;
  font-size: .8125rem;
  line-height: 1.25;
  text-wrap: balance;
}

.v6-home .v6-quick:active,
.nav-btn:active { background: #edf5ff; }

#app .bottom-nav {
  height: var(--nav-height);
  border-top: 1px solid #e1e9f1;
  box-shadow: 0 -6px 24px #19334d09;
}

#app .bottom-nav .nav-btn {
  justify-content: flex-start;
  min-width: 0;
  padding: 10px 2px 5px;
  gap: 4px;
  font-size: .75rem;
  font-weight: 600;
  line-height: 1.3;
}

#app .bottom-nav .nav-icon { width: 24px; height: 24px; }
#app .bottom-nav .nav-btn.active:before {
  inset: 8px auto auto 50%;
  width: 42px;
  height: 28px;
  border-radius: 12px;
  background: #e4efff;
  transform: translateX(-50%);
}

#app .bottom-nav .nav-btn.active .nav-icon { position: relative; }

#app .bottom-nav .nav-btn.qr { padding-top: 39px; }
#app .bottom-nav .qr-bubble {
  top: -17px;
  width: 52px;
  height: 52px;
  border: 3px solid #fff;
  box-shadow: 0 4px 14px #1459ad37;
}

#app .bottom-nav .qr-bubble img { width: 23px; height: 23px; }

.demo-sheet {
  position: fixed;
  inset: auto 0 0;
  width: min(100%, var(--app-width));
  max-width: none;
  max-height: min(78dvh, 680px);
  margin: 0 auto;
  padding: 18px 20px calc(16px + env(safe-area-inset-bottom));
  border: 0;
  border-radius: 24px 24px 0 0;
  background: white;
  color: var(--ink);
  overflow: auto;
}

.demo-sheet::backdrop { background: #09233799; }
.demo-sheet-header { display: flex; justify-content: space-between; align-items: center; }
.demo-sheet-header h2 { margin: 0; font-size: 1.25rem; }
.demo-sheet-header button {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: var(--bg);
  font-size: 24px;
}

.demo-sheet .prototype-controls {
  position: relative;
  top: auto;
  left: auto;
  width: 100%;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  box-shadow: none;
}

.demo-sheet .prototype-more { display: flex; flex-direction: column; gap: 8px; }
.demo-sheet .prototype-toggle { display: none; }
.demo-sheet #prototype-reset {
  top: 0;
  right: 0;
  min-height: 44px;
}

@media (max-width: 350px) {
  .v6-home .v6-header { padding-inline: 12px; gap: 2px; }
  .v6-home .v6-section, .v6-home .v6-insight-section { padding-inline: 14px; }
}
