:root {
  --bg: #06100e;
  --bg-soft: #0a1512;
  --panel: rgba(14, 27, 23, .86);
  --panel-strong: #0e1d19;
  --border: rgba(255,255,255,.075);

  --text: #f3f8f6;
  --muted: #82958e;
  --muted-dark: #5d716a;

  --green: #24e59d;
  --green-light: #92ffd5;
  --green-soft: rgba(36,229,157,.10);

  --yellow: #f6c761;
  --yellow-soft: rgba(246,199,97,.10);

  --red: #ff707b;
  --red-soft: rgba(255,112,123,.10);

  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 14px;

  --shadow: 0 30px 80px rgba(0,0,0,.30);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;

  font-family:
    Inter,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;

  color: var(--text);

  background:
    radial-gradient(
      circle at 15% 0%,
      rgba(36,229,157,.10),
      transparent 28%
    ),
    radial-gradient(
      circle at 100% 90%,
      rgba(50,90,255,.08),
      transparent 30%
    ),
    var(--bg);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(30px,4vw,44px);
  letter-spacing: -.045em;
}

h2 {
  margin: 7px 0 0;
  font-size: clamp(20px,2.5vw,27px);
  letter-spacing: -.035em;
}

.ambient {
  position: fixed;
  pointer-events: none;
  filter: blur(90px);
  opacity: .16;
}

.ambient-a {
  width: 350px;
  height: 350px;
  top: -160px;
  right: 15%;
  background: var(--green);
}

.ambient-b {
  width: 320px;
  height: 320px;
  left: 18%;
  bottom: -150px;
  background: #245cff;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 245px minmax(0,1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 20;

  height: 100vh;
  padding: 28px 20px;

  display: flex;
  flex-direction: column;

  border-right: 1px solid var(--border);

  background: rgba(5,14,12,.77);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;

  padding: 4px 5px 30px;
}

.brand-mark {
  width: 40px;
  height: 40px;

  display: grid;
  place-items: center;

  border-radius: 13px;

  color: #06100e;
  background:
    linear-gradient(
      135deg,
      var(--green-light),
      var(--green)
    );

  font-size: 13px;
  font-weight: 900;

  box-shadow:
    0 10px 30px
    rgba(36,229,157,.18);
}

.brand strong {
  display: block;
  font-size: 14px;
}

.brand small {
  display: block;
  margin-top: 3px;

  color: var(--muted);

  font-size: 8px;
  font-weight: 800;
  letter-spacing: .14em;
}

.desktop-nav {
  display: grid;
  gap: 6px;
}

.nav-button {
  width: 100%;
  padding: 12px 14px;

  border: 0;
  border-radius: 13px;

  background: transparent;
  color: var(--muted);

  text-align: left;
  font-size: 13px;
  font-weight: 650;

  transition:
    background .2s ease,
    color .2s ease,
    transform .2s ease;
}

.nav-button:hover {
  color: var(--text);
  background: rgba(255,255,255,.035);
}

.nav-button.active {
  color: var(--green-light);
  background: var(--green-soft);
}

.sidebar-bottom {
  margin-top: auto;
  padding: 16px 8px 4px;

  border-top: 1px solid var(--border);
}

.sidebar-bottom > small {
  display: block;
  margin-top: 12px;

  color: var(--muted-dark);

  font-size: 8px;
  font-weight: 800;
  letter-spacing: .13em;
}

.system-status {
  display: flex;
  align-items: center;
  gap: 8px;

  color: var(--muted);

  font-size: 10px;
  font-weight: 700;
}

.status-dot {
  width: 7px;
  height: 7px;

  border-radius: 50%;
  background: var(--yellow);

  box-shadow:
    0 0 12px
    rgba(246,199,97,.55);
}

.system-status.online .status-dot {
  background: var(--green);

  box-shadow:
    0 0 12px
    rgba(36,229,157,.55);
}

.main-content {
  width: 100%;
  max-width: 1450px;

  margin: 0 auto;

  padding:
    30px
    clamp(24px,4vw,60px)
    45px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;

  margin-bottom: 30px;
}

.eyebrow {
  color: var(--green);

  font-size: 9px;
  font-weight: 850;
  letter-spacing: .17em;
}

.profile {
  display: flex;
  align-items: center;
  gap: 10px;

  padding: 7px 12px 7px 7px;

  border: 1px solid var(--border);
  border-radius: 999px;

  background: rgba(255,255,255,.025);
}

.avatar {
  width: 34px;
  height: 34px;

  display: grid;
  place-items: center;

  border-radius: 50%;

  color: #06100e;
  background: var(--green);

  font-size: 12px;
  font-weight: 900;
}

.profile strong {
  display: block;
  font-size: 11px;
}

.profile small {
  display: block;
  margin-top: 2px;

  color: var(--muted);
  font-size: 9px;
}

.page {
  display: none;
}

.page.active {
  display: block;
  animation: pageIn .25s ease;
}

@keyframes pageIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.hero {
  min-height: 315px;
  padding: clamp(28px,5vw,54px);

  display: grid;
  grid-template-columns:
    minmax(0,1.45fr)
    minmax(280px,.55fr);

  gap: 45px;
  align-items: center;

  border: 1px solid var(--border);
  border-radius: var(--radius-xl);

  background:
    radial-gradient(
      circle at 75% 0%,
      rgba(36,229,157,.15),
      transparent 35%
    ),
    linear-gradient(
      145deg,
      rgba(18,37,31,.97),
      rgba(7,17,14,.97)
    );

  box-shadow: var(--shadow);
}

.hero-amount {
  margin-top: 15px;

  font-size: clamp(48px,8vw,88px);
  line-height: .95;

  font-weight: 850;
  letter-spacing: -.07em;
}

.hero-main p {
  max-width: 570px;

  margin:
    14px
    0
    0;

  color: #abc0b8;

  font-size: 13px;
  line-height: 1.65;
}

.risk-badge {
  width: fit-content;

  margin-top: 26px;
  padding: 8px 12px;

  border-radius: 999px;

  font-size: 9px;
  font-weight: 850;
  letter-spacing: .08em;
}

.risk-badge.green {
  color: var(--green-light);
  background: var(--green-soft);
}

.risk-badge.orange {
  color: #ffe2a4;
  background: var(--yellow-soft);
}

.risk-badge.red {
  color: #ffb6bc;
  background: var(--red-soft);
}

.risk-badge.neutral {
  color: var(--muted);
  background: rgba(255,255,255,.045);
}

.safe-spend-card {
  padding: 25px;

  border:
    1px solid
    rgba(36,229,157,.17);

  border-radius: 23px;

  background: rgba(3,13,10,.58);
}

.safe-spend-card > small {
  color: #a2b5ae;

  font-size: 8px;
  font-weight: 850;
  letter-spacing: .12em;
}

.safe-spend-card > strong {
  display: block;

  margin-top: 8px;

  color: var(--green-light);

  font-size: clamp(30px,4vw,45px);
  letter-spacing: -.05em;
}

.safe-spend-card > span {
  color: var(--muted);
  font-size: 10px;
}

.safe-spend-card hr {
  height: 1px;

  margin: 21px 0;

  border: 0;
  background: var(--border);
}

.mini-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;

  margin-top: 10px;

  color: var(--muted);
  font-size: 10px;
}

.mini-row b {
  color: var(--text);
  text-align: right;
}

.money-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);

  gap: 14px;

  margin-top: 14px;
}

.money-card {
  padding: 21px;

  border: 1px solid var(--border);
  border-radius: var(--radius-lg);

  background: var(--panel);
}

.money-card.highlight {
  border-color:
    rgba(36,229,157,.16);

  background:
    linear-gradient(
      145deg,
      rgba(36,229,157,.08),
      rgba(14,27,23,.85)
    );
}

.money-card small {
  color: var(--muted);

  font-size: 8px;
  font-weight: 850;
  letter-spacing: .12em;
}

.money-card strong {
  display: block;

  margin-top: 8px;

  font-size: clamp(25px,3vw,34px);
  letter-spacing: -.045em;
}

.money-card span {
  display: block;

  margin-top: 7px;

  color: var(--muted);

  font-size: 9px;
}

.home-grid {
  display: grid;
  grid-template-columns: 1.25fr .75fr;

  gap: 14px;

  margin-top: 14px;
}

.panel {
  padding: clamp(22px,3vw,29px);

  border: 1px solid var(--border);
  border-radius: var(--radius-lg);

  background: var(--panel);
}

.panel-heading {
  margin-bottom: 24px;
}


label {
  display: block;

  color: #b3c3bd;

  font-size: 10px;
  font-weight: 650;
}

input,
select {
  width: 100%;

  margin-top: 8px;
  padding: 13px 14px;

  border:
    1px solid
    rgba(255,255,255,.085);

  border-radius: 13px;

  outline: none;

  background: rgba(2,10,8,.52);
  color: var(--text);
}

input:focus,
select:focus {
  border-color:
    rgba(36,229,157,.45);

  box-shadow:
    0 0 0 3px
    rgba(36,229,157,.07);
}

input::placeholder {
  color: #52635d;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 105px;

  gap: 12px;

  margin-top: 14px;
}

.primary-button {
  margin-top: 16px;
  padding: 13px 18px;

  border: 0;
  border-radius: 13px;

  background:
    linear-gradient(
      135deg,
      var(--green-light),
      var(--green)
    );

  color: #06100e;

  font-size: 11px;
  font-weight: 850;
}

.primary-button:hover {
  transform: translateY(-1px);

  box-shadow:
    0 10px 28px
    rgba(36,229,157,.16);
}

.primary-button:disabled {
  opacity: .6;
  cursor: wait;
}

.commitments {
  margin-top: 22px;
}

.commitments > div {
  display: flex;
  justify-content: space-between;
  gap: 14px;

  padding: 11px 0;

  border-bottom: 1px solid var(--border);

  color: var(--muted);

  font-size: 11px;
}

.commitments strong {
  color: var(--text);
}

.commitments .commitment-total {
  padding-top: 15px;

  border-bottom: 0;

  font-weight: 800;
}

.income-card {
  margin-top: 20px;
  padding: 15px;

  border-radius: 14px;

  background: rgba(36,229,157,.055);
}

.income-card small {
  display: block;

  color: var(--green);

  font-size: 8px;
  font-weight: 850;
  letter-spacing: .11em;
}

.income-card strong {
  display: block;
  margin-top: 7px;
}

.income-card span {
  display: block;

  margin-top: 5px;

  color: var(--muted);

  font-size: 10px;
}

.decision-box {
  margin-top: 19px;
  padding: 18px;

  border-radius: 15px;
}

.decision-box.green {
  border:
    1px solid
    rgba(36,229,157,.20);

  background: var(--green-soft);
}

.decision-box.orange {
  border:
    1px solid
    rgba(246,199,97,.20);

  background: var(--yellow-soft);
}

.decision-box.red {
  border:
    1px solid
    rgba(255,112,123,.20);

  background: var(--red-soft);
}

.decision-title {
  font-size: 16px;
  font-weight: 850;
}

.decision-box.green .decision-title {
  color: var(--green-light);
}

.decision-box.orange .decision-title {
  color: #ffe2a4;
}

.decision-box.red .decision-title {
  color: #ffb6bc;
}

.decision-text {
  margin-top: 8px;

  color: #bdcbc6;

  font-size: 11px;
  line-height: 1.6;
}

.decision-grid {
  display: grid;
  grid-template-columns: repeat(2,1fr);

  gap: 8px;

  margin-top: 14px;
}

.decision-metric {
  padding: 11px;

  border-radius: 11px;

  background: rgba(0,0,0,.15);
}

.decision-metric span {
  display: block;

  color: var(--muted);

  font-size: 8px;
}

.decision-metric strong {
  display: block;

  margin-top: 4px;

  font-size: 13px;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 25px;

  margin-bottom: 24px;
}

.section-heading p {
  max-width: 420px;

  margin-bottom: 2px;

  color: var(--muted);

  text-align: right;
  font-size: 11px;
  line-height: 1.6;
}

.wallet-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));

  gap: 14px;
}

.wallet-card {
  min-height: 185px;
  padding: 24px;

  border: 1px solid var(--border);
  border-radius: var(--radius-lg);

  background:
    linear-gradient(
      145deg,
      rgba(17,33,28,.96),
      rgba(8,18,15,.96)
    );
}

.wallet-type {
  color: var(--muted);

  font-size: 8px;
  font-weight: 850;
  letter-spacing: .13em;
}

.wallet-name {
  margin-top: 8px;

  font-size: 16px;
  font-weight: 780;
}

.wallet-balance {
  margin-top: 29px;

  font-size: 29px;
  font-weight: 850;
  letter-spacing: -.045em;
}

.wallet-base {
  margin-top: 5px;

  color: var(--muted);

  font-size: 9px;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr auto;

  gap: 10px;
}

.search-row input,
.search-row button {
  margin-top: 0;
}

.price-results {
  margin-top: 14px;
}

.empty-state {
  padding: 42px;

  border:
    1px dashed
    rgba(255,255,255,.10);

  border-radius: var(--radius-lg);

  color: var(--muted);

  text-align: center;
  font-size: 11px;
}

.price-card {
  display: grid;

  grid-template-columns:
    minmax(170px,1.2fr)
    .7fr
    .8fr
    .7fr;

  gap: 17px;
  align-items: center;

  margin-bottom: 8px;
  padding: 16px 19px;

  border: 1px solid var(--border);
  border-radius: 14px;

  background: var(--panel);
}

.price-name {
  font-size: 12px;
  font-weight: 760;
}

.price-value {
  font-size: 13px;
  font-weight: 850;
}

.price-meta {
  margin-top: 4px;

  color: var(--muted);

  font-size: 9px;
}

.freshness {
  width: fit-content;
  padding: 5px 8px;

  border-radius: 999px;

  color: var(--muted);
  background: rgba(255,255,255,.045);

  font-size: 8px;
  font-weight: 800;
}

.freshness.fresh,
.freshness.recent {
  color: var(--green-light);
  background: var(--green-soft);
}

.freshness.aging {
  color: #ffe2a4;
  background: var(--yellow-soft);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(2,1fr);

  gap: 14px;
}

.service-list {
  margin-top: 20px;

  display: grid;
  gap: 5px;
}

.service-row {
  display: flex;
  justify-content: space-between;
  gap: 15px;

  padding: 10px 0;

  border-bottom: 1px solid var(--border);

  color: var(--muted);

  font-size: 10px;
}

.service-row strong {
  color: var(--text);
}

.bundles-panel {
  margin-top: 14px;
}

.bundle-grid {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));

  gap: 10px;

  margin-top: 20px;
}

.bundle-card {
  padding: 16px;

  border: 1px solid var(--border);
  border-radius: 13px;

  background: rgba(255,255,255,.018);
}

.bundle-provider {
  color: var(--green);

  font-size: 8px;
  font-weight: 850;
}

.bundle-name {
  margin-top: 7px;

  font-size: 11px;
  font-weight: 760;
}

.bundle-volume {
  margin-top: 17px;

  font-size: 19px;
  font-weight: 850;
}

.bundle-details {
  margin-top: 5px;

  color: var(--muted);

  font-size: 8px;
  line-height: 1.5;
}

.error-banner {
  margin-bottom: 17px;
  padding: 12px 15px;

  border:
    1px solid
    rgba(255,112,123,.20);

  border-radius: 12px;

  color: #ffb6bc;
  background: var(--red-soft);

  font-size: 10px;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;

  margin-top: 35px;
  padding-top: 18px;

  border-top: 1px solid var(--border);

  color: var(--muted-dark);

  font-size: 8px;
}

.hidden {
  display: none !important;
}

.mobile-nav {
  display: none;
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1000px) {

  .app-shell {
    grid-template-columns: 84px minmax(0,1fr);
  }

  .sidebar {
    padding-inline: 13px;
  }

  .brand {
    justify-content: center;
  }

  .brand > div:last-child,
  .sidebar-bottom {
    display: none;
  }

  .nav-button {
    padding-inline: 4px;

    text-align: center;
    font-size: 9px;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .money-grid {
    grid-template-columns: 1fr 1fr;
  }

  .money-card.highlight {
    grid-column: 1 / -1;
  }

  .home-grid,
  .service-grid {
    grid-template-columns: 1fr;
  }

  .bundle-grid {
    grid-template-columns: repeat(2,1fr);
  }
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 680px) {

  body {
    padding-bottom: 75px;
  }

  .app-shell {
    display: block;
  }

  .sidebar {
    display: none;
  }

  .main-content {
    padding:
      19px
      13px
      35px;
  }

  .topbar {
    margin-bottom: 21px;
  }

  .profile {
    padding-right: 7px;
  }

  .profile > div:last-child {
    display: none;
  }

  .hero {
    min-height: 0;
    padding: 24px 19px;

    grid-template-columns: 1fr;

    border-radius: 23px;
  }

  .hero-amount {
    font-size: 51px;
  }

  .money-grid {
    grid-template-columns: 1fr;
  }

  .money-card.highlight {
    grid-column: auto;
  }

  .form-row {
    grid-template-columns: 1fr 88px;
  }

  .wallet-grid,
  .service-grid,
  .bundle-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .section-heading p {
    margin-top: 12px;
    text-align: left;
  }

  .price-card {
    grid-template-columns: 1fr 1fr;
  }

  .price-card > div:first-child {
    grid-column: 1 / -1;
  }

  .footer {
    display: block;
  }

  .footer span {
    display: block;
    margin-top: 4px;
  }

  .mobile-nav {
    position: fixed;

    left: 10px;
    right: 10px;
    bottom: 10px;

    z-index: 50;

    display: grid;
    grid-template-columns: repeat(4,1fr);

    padding: 5px;

    border: 1px solid var(--border);
    border-radius: 16px;

    background: rgba(7,17,14,.94);
    backdrop-filter: blur(18px);

    box-shadow:
      0 15px 50px
      rgba(0,0,0,.40);
  }

  .mobile-nav-button {
    padding: 10px 3px;

    border: 0;
    border-radius: 10px;

    background: transparent;
    color: var(--muted);

    font-size: 8px;
    font-weight: 800;
  }

  .mobile-nav-button.active {
    color: var(--green-light);
    background: var(--green-soft);
  }

}
