@font-face {
  font-family: Inter;
  font-weight: 700;
  src: url('/static/media/Inter-Bold.9aab1ebe6bd16660e37e.ttf') format('truetype');
}

@font-face {
  font-family: Inter;
  font-weight: 500;
  src: url('/static/media/Inter-Medium.9d1fd4235eeb376c5f96.ttf') format('truetype');
}

@font-face {
  font-family: Inter;
  font-weight: 400;
  src: url('/static/media/Inter-Light.185c75d22f414005c8b1.ttf') format('truetype');
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: Inter, sans-serif;
    background: #f4f7fb;
    color: #10213f;
}

body {
    min-height: 100vh;
}

button,
input,
select,
textarea {
    font: inherit;
}

.portal {
    display: flex;
    min-height: 100vh;
}



.sidebar-brand {
    padding: 30px 24px 26px;
    border-bottom: 1px solid rgba(255,255,255,.1);
}

.sidebar-brand h2 {
    margin: 0;
    font-size: 25px;
    line-height: 1.25;
    letter-spacing: .5px;
}

.sidebar-brand p {
    margin: 8px 0 0;
    color: #a9c0df;
    font-size: 12px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.sidebar-section {
    padding: 24px 14px 0;
}

.sidebar-section-title {
    padding: 0 12px 10px;
    color: #7895bc;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.sidebar-menu button {
    width: 100%;
    border: 0;
    background: transparent;
    color: #dce8f8;
    text-align: left;
    padding: 14px 13px;
    border-radius: 9px;
    cursor: pointer;
    font-size: 15px;
    transition: .2s ease;
}

.sidebar-menu button:hover {
    background: rgba(255,255,255,.07);
}

.sidebar-menu button.active {
    background: #1c4778;
    color: #fff;
    font-weight: 600;
}

.sidebar-bottom {
    margin-top: auto;
    padding: 18px 14px;
    border-top: 1px solid rgba(255,255,255,.1);
}

.sidebar-bottom button {
    width: 100%;
    padding: 14px;
    border: 0;
    border-radius: 9px;
    background: #18395f;
    color: #fff;
    cursor: pointer;
}

.main {
    margin-left: 0;
    width: auto;
    min-height: 100vh;
}

.topbar {
    height: 79px;
    background: #fff;
    border-bottom: 1px solid #e3e9f2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
}

.topbar-title {
    font-size: 21px;
    font-weight: 700;
}

.user-mini {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #183f6b;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

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

.user-mini span {
    display: block;
    margin-top: 3px;
    color: #71809a;
    font-size: 12px;
}

.content {
    padding: 34px;
    max-width: 1500px;
}

.page-title {
    margin: 0;
    font-size: 40px;
    line-height: 1.15;
    letter-spacing: -.7px;
}

.page-subtitle {
    margin: 12px 0 28px;
    color: #63728a;
    font-size: 16px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 7px 13px;
    border-radius: 999px;
    background: #e7f6ec;
    color: #18733b;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 24px;
}

/* DASHBOARD STATISTICS */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 28px;
}

.stat-card {
    background: #fff;
    border: 1px solid #e3e9f2;
    border-radius: 14px;
    padding: 23px;
    min-height: 145px;
    box-shadow: 0 4px 15px rgba(16,33,63,.04);
}

.stat-card .stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #edf3fa;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
    color: #173e69;
    font-size: 18px;
    font-weight: 700;
}

.stat-card .stat-label {
    color: #71809a;
    font-size: 13px;
    margin-bottom: 7px;
}

.stat-card .stat-value {
    color: #10213f;
    font-size: 22px;
    font-weight: 700;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(300px, .8fr);
    gap: 22px;
}

.card {
    background: #fff;
    border: 1px solid #e3e9f2;
    border-radius: 14px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(16,33,63,.04);
}

.card h2,
.card h3 {
    margin: 0 0 8px;
    color: #10213f;
}

.card-subtitle {
    margin: 0 0 22px;
    color: #71809a;
    font-size: 14px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.info-item {
    padding: 15px;
    background: #f7f9fc;
    border-radius: 10px;
}

.info-item label {
    display: block;
    color: #78869a;
    font-size: 12px;
    margin-bottom: 6px;
}

.info-item strong {
    font-size: 14px;
    color: #172b49;
    word-break: break-word;
}

.quick-actions {
    display: grid;
    gap: 10px;
}

.quick-actions button {
    border: 1px solid #dce4ef;
    background: #fff;
    padding: 13px 15px;
    border-radius: 9px;
    text-align: left;
    cursor: pointer;
    color: #173e69;
    font-weight: 600;
}

.quick-actions button:hover {
    background: #f3f7fb;
}

.activity-list {
    display: flex;
    flex-direction: column;
}

.activity-item {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #edf0f5;
}

.activity-item:last-child {
    border-bottom: 0;
}

.activity-title {
    font-weight: 600;
    font-size: 14px;
}

.activity-date {
    color: #8190a4;
    font-size: 12px;
    margin-top: 4px;
}

.activity-amount {
    font-weight: 700;
    white-space: nowrap;
}

.empty-state {
    padding: 30px 15px;
    text-align: center;
    color: #7a8799;
}

/* TABLES / LIST PAGES */

.table-card {
    background: #fff;
    border: 1px solid #e3e9f2;
    border-radius: 14px;
    overflow: visible;
    box-shadow: 0 4px 15px rgba(16,33,63,.04);
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 15px 18px;
    border-bottom: 1px solid #edf0f5;
    text-align: left;
    font-size: 14px;
}

th {
    background: #f7f9fc;
    color: #61718a;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .4px;
}

td {
    color: #243754;
}

/* FORMS */

.form-card {
    max-width: 850px;
    background: #fff;
    border: 1px solid #e3e9f2;
    border-radius: 14px;
    padding: 28px;
    box-shadow: 0 4px 15px rgba(16,33,63,.04);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group.full {
    grid-column: 1 / -1;
}

.form-group label {
    display: block;
    margin-bottom: 7px;
    color: #40516b;
    font-size: 13px;
    font-weight: 600;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    border: 1px solid #d8e0eb;
    border-radius: 8px;
    padding: 12px 13px;
    outline: none;
    background: #fff;
    color: #172b49;
}

.form-group textarea {
    min-height: 110px;
    resize: vertical;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #37628d;
    box-shadow: 0 0 0 3px rgba(55,98,141,.1);
}

.primary-btn {
    border: 0;
    border-radius: 8px;
    background: #173e69;
    color: #fff;
    padding: 12px 20px;
    cursor: pointer;
    font-weight: 600;
}

.primary-btn:hover {
    background: #0f3157;
}

/* INVESTMENT CARDS */

.investment-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.investment-card {
    background: #fff;
    border: 1px solid #e3e9f2;
    border-radius: 14px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(16,33,63,.04);
}

.investment-card h3 {
    margin: 0 0 8px;
}

.investment-card .roi {
    font-size: 27px;
    font-weight: 700;
    color: #173e69;
    margin: 15px 0;
}

.investment-detail {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid #edf0f5;
    font-size: 13px;
}

.investment-detail span:first-child {
    color: #71809a;
}

.investment-detail strong {
    text-align: right;
}

/* RESPONSIVE */

@media (max-width: 1100px) {
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

@media (max-width: 800px) {
    .sidebar {
        width: 220px;
    }

    .main {
        margin-left: 220px;
        width: calc(100% - 220px);
    }

    .content {
        padding: 22px;
    }

    .page-title {
        font-size: 31px;
    }

    .info-grid,
    .form-grid,
    .investment-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .sidebar {
        width: 100%;
        min-height: auto;
        position: relative;
    }

    .main {
        margin-left: 0;
        width: 100%;
    }

    .portal {
        display: block;
    }

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

    .sidebar-bottom {
        margin-top: 10px;
    }

    .topbar {
        padding: 0 18px;
    }

    .content {
        padding: 18px;
    }

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

    .user-mini > div:not(.user-avatar) {
        display: none;
    }
}


/* DASHBOARD WELCOME */
.dashboard-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.dashboard-welcome h2 {
    margin: 0 0 7px;
    font-size: 24px;
    font-weight: 700;
}

.dashboard-welcome p {
    margin: 0;
    color: #64748b;
    font-size: 15px;
}

.dashboard-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    border-radius: 999px;
    background: #ecfdf3;
    color: #15803d;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    display: inline-block;
}

.dashboard-status {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 9px 15px !important;
    border-radius: 999px !important;
    background: #ecfdf3 !important;
    color: #15803d !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    white-space: nowrap !important;
}

.status-dot {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    background: #22c55e !important;
    display: inline-block !important;
}



.invest-button {
    width: 100%;
    margin-top: 16px;
    padding: 13px 18px;
    border: none;
    border-radius: 8px;
    background: #0b1f3a;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.invest-button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.invest-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.investment-form-wrap {
    max-width: 720px;
    margin: 0 auto;
}

.investment-form-plan {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 25px;
}

.investment-form-plan > div {
    padding: 16px;
    background: #f6f8fb;
    border: 1px solid #e6ebf2;
    border-radius: 8px;
}

.investment-form-plan strong {
    display: block;
    margin-bottom: 7px;
    color: #697589;
    font-size: 11px;
    text-transform: uppercase;
}

.investment-form-plan span {
    display: block;
    color: #263449;
    font-size: 14px;
    font-weight: 700;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #263449;
    font-size: 13px;
    font-weight: 700;
}

.form-group input {
    width: 100%;
    box-sizing: border-box;
    padding: 13px 14px;
    border: 1px solid #dce2ea;
    border-radius: 8px;
    background: #ffffff;
    color: #263449;
    font-size: 14px;
    outline: none;
}

.form-group input:focus {
    border-color: #0b1f3a;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.form-actions .invest-button,
.form-actions .secondary-button {
    flex: 1;
    margin-top: 0;
}

.secondary-button {
    padding: 13px 18px;
    border: 1px solid #dce2ea;
    border-radius: 8px;
    background: #ffffff;
    color: #263449;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

.secondary-button:hover {
    background: #f6f8fb;
}

@media (max-width: 700px) {
    .investment-form-plan {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }
}




.portal {
  display: grid;
  grid-template-columns: 16rem minmax(0, 1fr);
  width: 97%;
  min-height: 97vh;
  overflow: visible;
  border-radius: 2rem;
  background: rgba(255,255,255,.61);
  box-shadow: 0 19px 60px rgba(0,0,0,.08);
}

.sidebar {
  display: flex;
  flex-direction: column;
  position: relative;
  padding-top: 4rem;
  background: transparent !important;
}

.brand {
  height: 4%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .35rem;
}

.brand-title {
  color: #00bfa6;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.5px;
}

.brand-subtitle {
  color: #021e12;
  font-size: 12px;
  font-weight: 500;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 4rem;
}

.nav-title {
  margin-left: 2rem;
  color: #788097;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  height: 2.8rem;
  margin: 0;
  padding: 0 1.5rem 0 2rem;
  border: 0;
  border-radius: .7rem;
  background: transparent;
  color: #242d49;
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: all .3s ease;
}

.nav-button:hover {
  background: rgba(255,255,255,.55);
}

.nav-button.active {
  margin-left: 0;
  background: #26683c;
  color: #fff;
}

.nav-button.active::before {
  content: "";
  width: 8px;
  height: 100%;
  margin-left: -2rem;
  margin-right: .35rem;
  border-radius: 0 4px 4px 0;
  background: #00bfa6;
}

.nav-icon {
  width: 22px;
  min-width: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 700;
}

.sidebar-bottom {
  margin-top: auto;
  padding: 0 1.5rem 2rem;
}

.logout-button {
  width: 100%;
  padding: 12px 15px;
  border: 0;
  border-radius: .7rem;
  background: rgba(255,255,255,.55);
  color: #242d49;
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .3s ease;
}

.logout-button:hover {
  background: #26683c;
  color: #fff;
}

.main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: rgba(255,255,255,.18);
}

.topbar {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 34px;
  background: rgba(255,255,255,.25);
  border-bottom: 1px solid rgba(255,255,255,.35);
}

.user-mini {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-mini-name {
  color: #021e12;
  font-size: 14px;
  font-weight: 700;
}

.user-mini-email {
  margin-top: 3px;
  color: #788097;
  font-size: 12px;
}

.avatar {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #26683c;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}

.mobile-menu {
  display: none;
}

@media screen and (max-width: 900px) {
  .portal {
    width: 100%;
    height: 100vh;
    border-radius: 0;
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    padding-top: 3rem;
    z-index: 100;
    background: #022413;
    transition: left .3s ease;
  }

  .sidebar.open {
    left: 0;
  }

  .brand-title,
  .brand-subtitle,
  .nav-button,
  .nav-title {
    color: #fff;
  }

  .nav-button.active {
    background: #26683c;
  }

  .mobile-menu {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 10px;
    background: rgba(255,255,255,.7);
    color: #021e12;
    font-size: 20px;
    cursor: pointer;
  }

  .topbar {
    padding: 0 18px;
  }
}



html,
body {
    height: auto !important;
    min-height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
}

.portal {
    height: auto !important;
    min-height: 100vh !important;
    overflow: visible !important;
}

.main {
    height: auto !important;
    min-height: 100vh !important;
    overflow: visible !important;
}

.content {
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
}



.main {
    width: calc(100% - 17rem) !important;
}

.content {
    width: 100% !important;
    max-width: 1500px !important;
    margin: 0 auto !important;
    padding: 36px 38px 50px !important;
}

.page-title {
    font-size: 24px !important;
    font-weight: 700 !important;
}

.dashboard-welcome,
.welcome {
    padding: 30px 32px !important;
    min-height: 78px;
}

.dashboard-welcome h2,
.welcome h1 {
    font-size: 28px !important;
}

.dashboard-welcome p,
.welcome p {
    font-size: 15px !important;
}

.stats,
.stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 20px !important;
    margin-bottom: 28px !important;
}

.stat-card {
    min-height: 145px !important;
    padding: 24px !important;
}

.stat-label {
    font-size: 13px !important;
}

.stat-value,
.stat-card strong {
    font-size: 22px !important;
}

.dashboard-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, .75fr) !important;
    gap: 24px !important;
}

.section-card,
.dashboard-card,
.card {
    padding: 26px !important;
    border-radius: 1.25rem !important;
}

.section-title {
    font-size: 18px !important;
}

.section-subtitle {
    font-size: 13px !important;
}

.quick-action,
.action-card {
    min-height: 70px;
}

@media (max-width: 1100px) {
    .stats,
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .dashboard-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 700px) {
    .content {
        padding: 24px 18px 40px !important;
    }

    .stats,
    .stats-grid {
        grid-template-columns: 1fr !important;
    }

    .dashboard-welcome,
    .welcome {
        padding: 24px !important;
    }

    .dashboard-welcome h2,
    .welcome h1 {
        font-size: 23px !important;
    }

    .stat-card {
        min-height: 125px !important;
    }
}



.sidebar {
    overflow: visible !important;
    scrollbar-width: thin;
}

.sidebar-bottom {
    flex-shrink: 0 !important;
    margin-top: auto !important;
    padding-bottom: 22px !important;
}

.nav {
    min-height: 0 !important;
}



/* PERMANENT SINGLE PAGE SCROLL */
html,
body {
    height: auto !important;
    min-height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
}

.portal {
    height: auto !important;
    min-height: 100vh !important;
    overflow: visible !important;
    align-items: stretch !important;
}

.sidebar {
    height: auto !important;
    min-height: 100vh !important;
    overflow: visible !important;
}

.main {
    height: auto !important;
    min-height: 100vh !important;
    overflow: visible !important;
}


@media (min-width: 701px) {
    .portal {
        grid-template-columns: 14rem minmax(0, 1fr) !important;
    }

    .portal > .sidebar {
        width: 14rem !important;
    }

    .main {
        width: calc(100% - 15rem) !important;
    }
}

/* FINAL DESKTOP WIDTH BALANCE */
@media (min-width: 701px) {
    .portal {
        display: grid !important;
        grid-template-columns: 12rem minmax(0, 1fr) !important;
        width: 97% !important;
    }

    .portal > .sidebar {
        width: 12rem !important;
        min-width: 12rem !important;
        max-width: 12rem !important;
    }

    .main {
        width: 100% !important;
        min-width: 0 !important;
    }
}

/* FINAL DESKTOP SIDEBAR WIDTH — REMOVE OLD 272PX OFFSET */
@media (min-width: 701px) {
    .portal {
        display: grid !important;
        grid-template-columns: 12rem minmax(0, 1fr) !important;
        width: 97% !important;
    }

    .portal > .sidebar {
        width: 12rem !important;
        min-width: 12rem !important;
        max-width: 12rem !important;
        margin: 0 !important;
    }

    .portal > .main {
        width: auto !important;
        min-width: 0 !important;
        max-width: none !important;
        margin-left: 0 !important;
    }
}



@media (min-width: 701px) {

    html,
    body {
        width: 100%;
        overflow-x: hidden !important;
        overflow-y: auto !important;
    }

    .portal {
        display: grid !important;
        grid-template-columns: 220px minmax(0, 1fr) !important;
        width: 100% !important;
        max-width: none !important;
        min-height: 100vh !important;
        height: auto !important;
        margin: 0 !important;
        padding: 24px !important;
        box-sizing: border-box !important;
        overflow: visible !important;
    }

    .portal > .sidebar {
        position: relative !important;
        left: auto !important;
        top: auto !important;
        right: auto !important;
        bottom: auto !important;
        width: 220px !important;
        min-width: 220px !important;
        max-width: 220px !important;
        height: auto !important;
        min-height: calc(100vh - 48px) !important;
        margin: 0 !important;
        padding: 64px 0 24px !important;
        box-sizing: border-box !important;
        overflow: visible !important;
        align-self: stretch !important;
    }

    .portal > .main {
        width: auto !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        min-height: calc(100vh - 48px) !important;
        margin: 0 !important;
        padding: 0 !important;
        box-sizing: border-box !important;
        overflow: visible !important;
    }

    .portal > .main > .content {
        width: 100% !important;
        max-width: none !important;
        box-sizing: border-box !important;
    }
}



@media (min-width: 701px) {

    .portal {
        display: flex !important;
        width: 100% !important;
        max-width: none !important;
        min-height: 100vh !important;
        height: auto !important;
        margin: 0 !important;
        padding: 24px !important;
        box-sizing: border-box !important;
        gap: 24px !important;
        overflow: visible !important;
    }

    .portal > .sidebar {
        flex: 0 0 240px !important;
        width: 240px !important;
        min-width: 240px !important;
        max-width: 240px !important;
        height: auto !important;
        min-height: calc(100vh - 48px) !important;
        margin: 0 !important;
        position: relative !important;
        left: auto !important;
        top: auto !important;
        bottom: auto !important;
        overflow: visible !important;
    }

    .portal > .main {
        flex: 1 1 auto !important;
        width: auto !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        min-height: calc(100vh - 48px) !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
    }

    .portal > .main > .content {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }

    .dashboard-grid {
        width: 100% !important;
    }

    .stats-grid {
        width: 100% !important;
    }
}


/* FINAL FIX — DASHBOARD USES ALL AVAILABLE SPACE */
@media (min-width: 701px) {
    .portal > .main {
        margin-left: 0 !important;
        width: auto !important;
        flex: 1 1 auto !important;
        min-width: 0 !important;
    }
}



.stats-grid {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 18px !important;
    margin-bottom: 24px !important;
}

.stat-card {
    min-width: 0 !important;
    min-height: 108px !important;
    height: 108px !important;
    padding: 20px !important;
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    box-sizing: border-box !important;
}

.stat-card > div:last-child {
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    gap: 5px !important;
}

.stat-icon {
    flex: 0 0 44px !important;
    width: 44px !important;
    height: 44px !important;
    margin: 0 !important;
}

.stat-label {
    display: block !important;
    margin: 0 !important;
    font-size: 12px !important;
    line-height: 1.2 !important;
}

.stat-value,
.stat-card strong {
    display: block !important;
    margin: 0 !important;
    font-size: 20px !important;
    line-height: 1.25 !important;
    white-space: nowrap !important;
}

@media (max-width: 1100px) {
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 700px) {
    .stats-grid {
        grid-template-columns: 1fr !important;
    }

    .stat-card {
        height: 100px !important;
        min-height: 100px !important;
    }
}



.dashboard-grid {
    align-items: stretch !important;
}

.dashboard-card {
    min-height: 0 !important;
    height: auto !important;
    box-sizing: border-box !important;
}

.dashboard-card .card-header {
    margin-bottom: 22px !important;
}

.dashboard-card .card-header h3 {
    margin: 0 0 6px !important;
    font-size: 19px !important;
    font-weight: 700 !important;
    color: #263653 !important;
}

.dashboard-card .card-header p {
    margin: 0 !important;
    font-size: 14px !important;
    color: #68758c !important;
    line-height: 1.5 !important;
}

.info-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 0 !important;
}

.info-row {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 24px !important;
    padding: 15px 0 !important;
    border-bottom: 1px solid #edf1f5 !important;
}

.info-row:first-child {
    padding-top: 4px !important;
}

.info-row:last-child {
    border-bottom: 0 !important;
    padding-bottom: 4px !important;
}

.info-row > span {
    color: #78869a !important;
    font-size: 13px !important;
    font-weight: 500 !important;
}

.info-row > strong {
    color: #172b49 !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-align: right !important;
    word-break: break-word !important;
}

.account-status {
    color: #15803d !important;
}

.quick-actions {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
}

.quick-actions button {
    width: 100% !important;
    min-height: 64px !important;
    box-sizing: border-box !important;
    padding: 14px 16px !important;
    border: 1px solid #dfe8e3 !important;
    border-radius: 12px !important;
    background: rgba(255,255,255,.75) !important;
    color: #26683c !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.45 !important;
    text-align: left !important;
    transition: all .2s ease !important;
}

.quick-actions button:hover {
    background: #f5fbf7 !important;
    border-color: #b9d9c4 !important;
    transform: translateY(-1px) !important;
}

@media (max-width: 700px) {
    .info-row {
        align-items: flex-start !important;
        flex-direction: column !important;
        gap: 5px !important;
    }

    .info-row > strong {
        text-align: left !important;
    }
}




.dashboard-grid {
    align-items: start !important;
}

.dashboard-grid > .dashboard-card {
    align-self: start !important;
    height: fit-content !important;
    min-height: 0 !important;
}

.dashboard-grid > .dashboard-card:first-child {
    min-height: 0 !important;
}

.dashboard-grid > .dashboard-card:last-child {
    min-height: 0 !important;
}

.dashboard-card .info-list {
    margin-bottom: 0 !important;
}

.dashboard-card .info-row {
    min-height: 48px !important;
}

.quick-actions button {
    min-height: 58px !important;
}




.recent-card {
    margin-top: 24px !important;
    padding: 26px !important;
}

.recent-card .card-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 20px !important;
    margin-bottom: 18px !important;
}

.recent-card .card-header h3 {
    margin: 0 0 5px !important;
    font-size: 19px !important;
    font-weight: 700 !important;
    color: #263653 !important;
}

.recent-card .card-header p {
    margin: 0 !important;
    color: #78869a !important;
    font-size: 13px !important;
}

.recent-card .text-button {
    border: 1px solid #d9e5dd !important;
    background: #fff !important;
    color: #26683c !important;
    border-radius: 9px !important;
    padding: 9px 15px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
}

.recent-card .text-button:hover {
    background: #f3faf5 !important;
    border-color: #b9d9c4 !important;
}

.recent-card #recentActivity {
    border-top: 1px solid #edf1f5 !important;
}

.recent-card .activity-item {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 20px !important;
    padding: 18px 4px !important;
    border-bottom: 1px solid #edf1f5 !important;
}

.recent-card .activity-item:last-child {
    border-bottom: 0 !important;
}

.recent-card .activity-item > div:first-child {
    min-width: 0 !important;
}

.recent-card .activity-item > div:last-child {
    flex-shrink: 0 !important;
    text-align: right !important;
}

.recent-card .activity-item strong {
    display: block !important;
    color: #263653 !important;
    font-size: 14px !important;
    font-weight: 700 !important;
}

.recent-card .activity-meta {
    margin-top: 5px !important;
    color: #8793a6 !important;
    font-size: 12px !important;
}

.recent-card .activity-item > div:last-child strong {
    color: #172b49 !important;
    font-size: 15px !important;
}

.recent-card .empty-state {
    padding: 30px 15px !important;
    color: #78869a !important;
    font-size: 13px !important;
}

@media (max-width: 600px) {
    .recent-card .card-header {
        align-items: flex-start !important;
        flex-direction: column !important;
    }

    .recent-card .activity-item {
        align-items: flex-start !important;
    }
}


/* =========================================================

.card-header {
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    gap: 20px !important;
    margin-bottom: 20px !important;
}

.card-header h3 {
    margin: 0 0 6px !important;
    color: #24314d !important;
    font-size: 20px !important;
    font-weight: 700 !important;
}

.card-header p {
    margin: 0 !important;
    color: #7888a3 !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.text-button {
    border: 1px solid #d7e3df !important;
    background: #ffffff !important;
    color: #26683c !important;
    padding: 10px 16px !important;
    border-radius: 10px !important;
    font-family: Inter, sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    transition: all .2s ease !important;
}

.text-button:hover {
    background: #26683c !important;
    color: #ffffff !important;
    border-color: #26683c !important;
}

.recent-card {
    width: 100% !important;
}

.recent-card #recentActivity {
    width: 100% !important;
}

.recent-card .activity-item {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    gap: 20px !important;
    padding: 18px 0 !important;
    border-bottom: 1px solid #edf1f0 !important;
}

.recent-card .activity-item:last-child {
    border-bottom: 0 !important;
}

.recent-card .activity-item strong {
    color: #24314d !important;
    font-size: 15px !important;
    font-weight: 700 !important;
}

.recent-card .activity-meta {
    margin-top: 5px !important;
    color: #7888a3 !important;
    font-size: 13px !important;
}

.recent-card .activity-item > div:last-child {
    text-align: right !important;
}

.recent-card .activity-item > div:last-child strong {
    color: #021e12 !important;
    font-size: 15px !important;
}

@media (max-width: 700px) {
    .card-header {
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    .recent-card .activity-item {
        align-items: flex-start !important;
    }
}

/* Quick Actions - professional layout */
.quick-actions {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
}

.quick-actions button {
    width: 100% !important;
    min-height: 68px !important;
    height: auto !important;
    padding: 14px 16px !important;
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    text-align: left !important;
    box-sizing: border-box !important;
}

.quick-actions button > span {
    flex: 0 0 38px !important;
    width: 38px !important;
    height: 38px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 10px !important;
    background: #eef7f1 !important;
    color: #26683c !important;
    font-size: 18px !important;
    font-weight: 700 !important;
}

.quick-actions button > div {
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
}

.quick-actions button strong {
    display: block !important;
    color: #26683c !important;
    font-family: Inter, sans-serif !important;
    font-size: 14px !important;
    line-height: 1.3 !important;
    font-weight: 700 !important;
}

.quick-actions button small {
    display: block !important;
    color: #78869a !important;
    font-family: Inter, sans-serif !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    font-weight: 400 !important;
}


/* Investment Plans - professional customer portal design */
.investment-grid {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 20px !important;
}

.investment-card {
    position: relative !important;
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    background: rgba(255,255,255,.92) !important;
    border: 1px solid #e3ebe6 !important;
    border-radius: 20px !important;
    padding: 26px !important;
    box-shadow: 0 12px 35px rgba(16,33,63,.06) !important;
    overflow: hidden !important;
    transition: transform .2s ease, box-shadow .2s ease !important;
}

.investment-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 18px 40px rgba(16,33,63,.10) !important;
}

.investment-card h3 {
    margin: 0 0 8px !important;
    color: #24314d !important;
    font-family: Inter, sans-serif !important;
    font-size: 21px !important;
    line-height: 1.3 !important;
    font-weight: 700 !important;
}

.investment-card .roi {
    margin: 14px 0 20px !important;
    color: #26683c !important;
    font-family: Inter, sans-serif !important;
    font-size: 30px !important;
    line-height: 1 !important;
    font-weight: 700 !important;
}

.investment-detail {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 15px !important;
    padding: 13px 0 !important;
    border-bottom: 1px solid #edf1f5 !important;
    font-family: Inter, sans-serif !important;
    font-size: 13px !important;
}

.investment-detail:last-of-type {
    border-bottom: 0 !important;
}

.investment-detail span:first-child {
    color: #78869a !important;
    font-weight: 500 !important;
}

.investment-detail span:last-child,
.investment-detail strong {
    color: #24314d !important;
    font-weight: 700 !important;
    text-align: right !important;
}

.invest-button {
    width: 100% !important;
    margin-top: 20px !important;
    padding: 14px 18px !important;
    border: 0 !important;
    border-radius: 11px !important;
    background: #26683c !important;
    color: #fff !important;
    font-family: Inter, sans-serif !important;
    font-size: 14px !important;
    line-height: 1.2 !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: background .2s ease, transform .2s ease !important;
}

.invest-button:hover {
    background: #1e5732 !important;
    opacity: 1 !important;
    transform: translateY(-1px) !important;
}

.invest-button:disabled {
    opacity: .6 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

@media (max-width: 1100px) {
    .investment-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 700px) {
    .investment-grid {
        grid-template-columns: 1fr !important;
    }

    .investment-card {
        padding: 22px !important;
    }
}


.investment-form-wrap {
    width: 100% !important;
    max-width: 820px !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
}

.investment-form-wrap > .card,
.investment-form-wrap .form-card {
    background: rgba(255,255,255,.94) !important;
    border: 1px solid #e3ebe6 !important;
    border-radius: 20px !important;
    padding: 30px !important;
    box-shadow: 0 12px 35px rgba(16,33,63,.06) !important;
}

.investment-form-plan {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0,1fr)) !important;
    gap: 14px !important;
    margin-bottom: 28px !important;
}

.investment-form-plan > div {
    min-width: 0 !important;
    padding: 18px !important;
    background: #f5faf7 !important;
    border: 1px solid #e0ebe4 !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

.investment-form-plan strong {
    display: block !important;
    margin-bottom: 7px !important;
    color: #78869a !important;
    font-family: Inter, sans-serif !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: .4px !important;
}

.investment-form-plan span {
    display: block !important;
    color: #24314d !important;
    font-family: Inter, sans-serif !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
}

.form-group {
    margin-bottom: 22px !important;
}

.form-group label {
    display: block !important;
    margin-bottom: 9px !important;
    color: #24314d !important;
    font-family: Inter, sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
}

.form-group input {
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 15px 16px !important;
    border: 1px solid #d9e5dd !important;
    border-radius: 11px !important;
    background: #fff !important;
    color: #24314d !important;
    font-family: Inter, sans-serif !important;
    font-size: 15px !important;
    outline: none !important;
    transition: border-color .2s ease, box-shadow .2s ease !important;
}

.form-group input:focus {
    border-color: #26683c !important;
    box-shadow: 0 0 0 3px rgba(38,104,60,.10) !important;
}

.form-actions {
    display: flex !important;
    gap: 14px !important;
    margin-top: 24px !important;
}

.form-actions .invest-button,
.form-actions .secondary-button {
    flex: 1 1 0 !important;
    margin-top: 0 !important;
    min-height: 50px !important;
}

.secondary-button {
    padding: 14px 18px !important;
    border: 1px solid #d7e3df !important;
    border-radius: 11px !important;
    background: #fff !important;
    color: #26683c !important;
    font-family: Inter, sans-serif !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: background .2s ease, border-color .2s ease !important;
}

.secondary-button:hover {
    background: #f3faf5 !important;
    border-color: #b9d9c4 !important;
}

@media (max-width: 700px) {
    .investment-form-plan {
        grid-template-columns: 1fr !important;
    }

    .form-actions {
        flex-direction: column !important;
    }

    .investment-form-wrap > .card,
    .investment-form-wrap .form-card {
        padding: 22px !important;
    }
}


/* =========================================================
   FINAL MOBILE CUSTOMER PORTAL FIX
   ========================================================= */

@media (max-width: 700px) {

    html,
    body {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
    }

    .portal {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: 100vh !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
    }

    .portal > .sidebar {
        position: fixed !important;
        left: 0 !important;
        top: 0 !important;
        bottom: 0 !important;
        width: 280px !important;
        min-width: 280px !important;
        max-width: 280px !important;
        height: 100vh !important;
        min-height: 100vh !important;
        z-index: 1000 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        transform: translateX(-105%) !important;
        transition: transform .25s ease !important;
    }

    .portal > .sidebar.open {
        transform: translateX(0) !important;
    }

    .portal > .main {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        min-height: 100vh !important;
        height: auto !important;
        margin: 0 !important;
        overflow: visible !important;
    }

    .topbar {
        width: 100% !important;
        box-sizing: border-box !important;
        padding: 16px 18px !important;
    }

    .mobile-menu {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .content {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        padding: 22px 16px 40px !important;
        margin: 0 !important;
    }

    .dashboard-welcome,
    .welcome {
        width: 100% !important;
        box-sizing: border-box !important;
        padding: 22px !important;
    }

    .dashboard-welcome h2,
    .welcome h1 {
        font-size: 23px !important;
    }

    .stats,
    .stats-grid {
        width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .stat-card {
        width: 100% !important;
        min-width: 0 !important;
        height: auto !important;
        min-height: 100px !important;
        box-sizing: border-box !important;
    }

    .dashboard-grid {
        width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .dashboard-card,
    .section-card,
    .card {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .investment-grid {
        width: 100% !important;
        grid-template-columns: 1fr !important;
    }

    .investment-card {
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .investment-form-wrap {
        width: 100% !important;
        max-width: 100% !important;
    }

    .investment-form-plan {
        grid-template-columns: 1fr !important;
    }

    .form-actions {
        flex-direction: column !important;
    }

    .form-actions button {
        width: 100% !important;
    }

    .recent-card {
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .recent-card .activity-item {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px !important;
    }

    .recent-card .activity-item > div:last-child {
        text-align: left !important;
    }
}


/* FINAL MOBILE SIDEBAR - SOLID BACKGROUND */
@media (max-width: 700px) {
    .portal > .sidebar {
        background: #e8f4a8 !important;
        background-color: #e8f4a8 !important;
        opacity: 1 !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: 8px 0 30px rgba(0,0,0,.12) !important;
    }

    .portal > .sidebar * {
        opacity: 1 !important;
    }
}


/* FINAL MOBILE SIDEBAR READABILITY */
@media (max-width: 700px) {

    .portal > .sidebar {
        background: #e8f4a8 !important;
        color: #172b49 !important;
    }

    .portal > .sidebar .brand-title {
        color: #00bfa6 !important;
    }

    .portal > .sidebar .brand-subtitle,
    .portal > .sidebar .nav-title {
        color: #24314d !important;
    }

    .portal > .sidebar .nav-button {
        color: #172b49 !important;
        background: transparent !important;
    }

    .portal > .sidebar .nav-button .nav-icon {
        color: #172b49 !important;
    }

    .portal > .sidebar .nav-button.active {
        background: #26683c !important;
        color: #ffffff !important;
    }

    .portal > .sidebar .nav-button.active .nav-icon {
        color: #ffffff !important;
    }

    .portal > .sidebar .logout-button {
        background: #173e69 !important;
        color: #ffffff !important;
    }
}

