:root {
    --wallet-bg: rgba(4, 15, 25, 0.98);
    --wallet-panel: rgba(10, 27, 38, 0.9);
    --wallet-panel-2: rgba(8, 26, 35, 0.88);
    --wallet-card: rgba(17, 37, 48, 0.9);
    --wallet-card-hover: rgba(22, 46, 60, 0.96);
    --wallet-line: rgba(180, 209, 230, 0.12);
    --wallet-soft: rgba(145, 183, 206, 0.7);
    --wallet-input: rgba(18, 35, 46, 0.9);
    --wallet-accent: #4fb8ff;
    --wallet-accent-soft: rgba(79, 184, 255, 0.2);
    --wallet-highlight: #83cbff;
    --wallet-text: #edf5ff;
    --wallet-muted: rgba(237, 245, 255, 0.72);
}

.page-shell .topbar {
    display: none !important;
}

.page-shell {
    padding-top: 0 !important;
}

.hero-content {
    padding-top: 0 !important;
}

.wallet-page {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 0 0 32px;
}

.wallet-panel {
    width: min(1200px, 100%);
    background: linear-gradient(180deg, rgba(3, 16, 26, 0.92) 0%, rgba(6, 22, 35, 0.95) 100%);
    border: 1px solid rgba(128, 169, 203, 0.16);
    border-radius: 18px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
    padding: 24px 22px 28px;
    position: relative;
    overflow: hidden;
}

.wallet-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(82, 142, 255, 0.06), transparent 26%, transparent 72%, rgba(82, 142, 255, 0.05));
    pointer-events: none;
}

.wallet-warning,
.wallet-stats,
.wallet-searchbar,
.wallet-filters,
.wallet-toolbar,
.wallet-section-heading,
.wallet-section-subhead,
.wallet-grid {
    position: relative;
    z-index: 1;
}

.wallet-warning {
    background: rgba(53, 82, 109, 0.28);
    border: 1px solid rgba(111, 152, 188, 0.16);
    border-radius: 12px;
    padding: 18px 20px;
    margin-bottom: 24px;
}

.wallet-warning p {
    margin: 0;
    color: rgba(228, 240, 255, 0.8);
    line-height: 1.75;
    font-size: 0.97rem;
}

.wallet-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.wallet-stat {
    background: rgba(19, 41, 58, 0.75);
    border: 1px solid rgba(146, 179, 212, 0.12);
    border-radius: 12px;
    padding: 18px 12px 16px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wallet-stat strong {
    font-size: clamp(1.3rem, 2vw, 2.05rem);
    font-weight: 700;
    color: var(--wallet-text);
}

.wallet-stat span {
    color: rgba(232, 243, 255, 0.75);
    font-size: 0.8rem;
}

.wallet-searchbar {
    display: flex;
    align-items: center;
    background: rgba(14, 31, 44, 0.9);
    border: 1px solid rgba(149, 181, 214, 0.12);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 18px;
}

.wallet-searchbar input {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--wallet-text);
    padding: 18px 18px 18px 20px;
    font-size: 1rem;
    outline: none;
}

.wallet-searchbar input::placeholder {
    color: rgba(229, 238, 248, 0.65);
}

.wallet-searchbar button {
    background: transparent;
    border: none;
    color: rgba(239, 245, 255, 0.82);
    width: 50px;
    height: 100%;
    font-size: 1.1rem;
    cursor: pointer;
}

.wallet-filters {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 26px;
}

.wallet-filters button {
    background: rgba(17, 38, 49, 0.72);
    border: 1px solid rgba(145, 176, 204, 0.12);
    border-radius: 999px;
    color: rgba(239, 245, 255, 0.76);
    padding: 9px 16px;
    font-size: 0.86rem;
    font-weight: 600;
    transition: 0.2s ease;
}

.wallet-filters button.active {
    background: rgba(74, 125, 176, 0.22);
    border-color: rgba(90, 171, 255, 0.6);
    box-shadow: inset 0 0 0 1px rgba(118, 201, 255, 0.25), 0 0 18px rgba(60, 170, 255, 0.18);
    color: var(--wallet-text);
}

.wallet-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
    padding-top: 8px;
    border-top: 1px solid rgba(160, 192, 220, 0.08);
}

.wallet-toolbar h2 {
    margin: 0;
    font-size: clamp(1.3rem, 1.6vw, 2rem);
    color: var(--wallet-text);
    font-weight: 700;
}

.toggle-wrap {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: rgba(236, 245, 255, 0.65);
    font-size: 0.85rem;
}

.toggle {
    position: relative;
    width: 42px;
    height: 22px;
    background: rgba(160, 175, 188, 0.28);
    border: none;
    border-radius: 999px;
    padding: 0;
    cursor: pointer;
}

.toggle-knob {
    position: absolute;
    left: 4px;
    top: 3px;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: rgba(255,255,255,0.95);
    transition: 0.2s ease;
}

.wallet-section-heading {
    margin-top: 8px;
    color: rgba(239, 245, 255, 0.9);
    font-weight: 700;
    font-size: 1.08rem;
}

.wallet-section-subhead {
    color: rgba(239, 245, 255, 0.88);
    margin: 16px 0 18px;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.wallet-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px 16px;
}

.wallet-card {
    appearance: none;
    background: linear-gradient(180deg, rgba(18, 40, 52, 0.9) 0%, rgba(13, 32, 44, 0.92) 100%);
    border: 1px solid rgba(122, 164, 197, 0.15);
    border-radius: 14px;
    min-height: 100px;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 18px 18px 16px;
    color: var(--wallet-text);
    text-align: left;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
    cursor: pointer;
}

.wallet-card:hover {
    transform: translateY(-1px);
    border-color: rgba(122, 201, 255, 0.42);
    box-shadow: 0 0 0 1px rgba(111, 200, 255, 0.12), 0 14px 24px rgba(0, 0, 0, 0.2);
}

.wallet-card.selected {
    border-color: rgba(96, 193, 255, 0.82);
    box-shadow: inset 0 0 0 1px rgba(96, 193, 255, 0.24), 0 0 20px rgba(78, 168, 255, 0.12);
}

.wallet-logo {
    width: 46px;
    height: 46px;
    min-width: 46px;
    min-height: 46px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 1.2rem;
    font-weight: 800;
    color: #f5fbff;
    box-shadow: inset 0 2px 8px rgba(255,255,255,0.12);
    background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.3), transparent 32%), linear-gradient(135deg, #3a3d59, #1d425a);
}
.wallet-logo img{
    width:100%;
    height:100%;
      border-radius: 50%;
}

.wallet-name {
    font-size: 1.03rem;
    font-weight: 600;
    color: rgba(237, 245, 255, 0.92);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.exodus { background: linear-gradient(135deg, #5a3ec8, #5f80ff); }
.trust { background: linear-gradient(135deg, #1a222e, #5aa8ff); }
.wallet-connect { background: linear-gradient(135deg, #0d5adf, #57a3ff); }
.metamask { background: linear-gradient(135deg, #f58220, #f5bf03); color: #17181a; }
.coinbase { background: linear-gradient(135deg, #2e63ff, #7d9cff); }
.phantom { background: linear-gradient(135deg, #7a3ef3, #b889ff); }
.nano { background: linear-gradient(135deg, #f4f4f4, #c8d2e3); color: #0f172a; }
.tangem { background: linear-gradient(135deg, #1b1f2d, #0ea5e9); }
.arc { background: linear-gradient(135deg, #f5f5f5, #c7d1e9); color: #111827; }
.trezor { background: linear-gradient(135deg, #f5f5f5, #d8d8dc); color: #0f172a; }
.ledger { background: linear-gradient(135deg, #1f2332, #6aa3ff); }
.bitbox { background: linear-gradient(135deg, #f5f5f5, #d6d9e2); color: #0f172a; }
.xaman { background: linear-gradient(135deg, #0e1f31, #1aa7ff); }
.lobster { background: linear-gradient(135deg, #31c7ff, #92d9ff); color: #0f172a; }
.atomic { background: linear-gradient(135deg, #fff, #dfeaf8); color: #0f172a; }
.rainbow { background: linear-gradient(135deg, #ff6b6b, #ffd166, #06d6a0, #118ab2); color: #111827; }
.argent { background: linear-gradient(135deg, #fbfbfb, #d8dde8); color: #0f172a; }
.safepal { background: linear-gradient(135deg, #1c6fff, #aae0ff); }
.myetherwallet { background: linear-gradient(135deg, #0d2f34, #3ec9b8); }
.enjin { background: linear-gradient(135deg, #193cb1, #7ec8ff); }
.coinomi { background: linear-gradient(135deg, #e10980, #ff9bcb); }
.edge { background: linear-gradient(135deg, #1d7d59, #72e9c0); }
.zelcore { background: linear-gradient(135deg, #3a465f, #7b8dff); }
.guarda { background: linear-gradient(135deg, #0d1c2e, #7bc1ff); }
.mathwallet { background: linear-gradient(135deg, #f3f3f3, #d3dde7); color: #0f172a; }
.tokenpocket { background: linear-gradient(135deg, #1d3a8a, #6ab1ff); }
.alpha { background: linear-gradient(135deg, #f5f5f5, #dfe9f7); color: #0f172a; }

@media (max-width: 980px) {
    .wallet-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .wallet-panel {
        padding-left: 14px;
        padding-right: 14px;
    }

    .wallet-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wallet-toolbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .wallet-grid {
        grid-template-columns: 1fr;
    }
}
/* --- Wallet modal (append to wallet.css) --- */


.wallet-modal .modal-content {
    background: linear-gradient(180deg, rgba(6, 20, 32, 0.98), rgba(8, 26, 38, 0.98));
    border: 1px solid rgba(128, 169, 203, 0.16);
    border-radius: 16px;
    color: var(--wallet-text);
}

.wallet-modal .modal-header {
    border-bottom: 1px solid var(--wallet-line);
    align-items: center;
    height:auto !important;
    gap: 10px;
    padding-left: 10px;
    padding-bottom: 10px;
}
.wallet-modal .modal-header:nth-child(2){
    justify-content: flex-start;
    padding-left: 0px;
    padding-top: 0px;
    gap:0;
    padding-bottom: 0px;

}
.wallet-modal .modal-header:nth-child(2) button{
    background: transparent;
    outline: none;
    border:none;
    color: gray;
    text-align: center;
    padding: 10px;
    height: 100%;
}
.wallet-modal .modal-header:nth-child(2)  .activebtn{
    border-bottom: 2px solid #4D97B8;
    background: #152A3C;
}
.input-invalid {
  border-color: #ff4d4f !important;
  box-shadow: 0 0 0 2px rgba(255,77,79,0.06);
}
.validation-error {
  line-height: 1.2;
}



.wallet-modal-logo {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 50%;
    overflow: hidden;
    display: inline-block;
}
.wallet-modal-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wallet-modal .modal-title {
    color: var(--wallet-text);
    font-weight: 500;
    font-size: 20px;
}

.wallet-modal .modal-footer {
    border-top: 1px solid var(--wallet-line);
}

.wallet-step-text {
    font-weight: 600;
    margin: 4px 0;
    color: var(--wallet-text);
}

.wallet-step-sub {
    color: var(--wallet-muted);
    font-size: 0.88rem;
    margin: 0;
}

.wallet-btn-primary {
    background: var(--wallet-accent);
    color: #08131c;
    border: none;
    border-radius: 10px;
    padding: 9px 18px;
    font-weight: 600;
}

.wallet-btn-secondary {
    background: transparent;
    border: 1px solid var(--wallet-line);
    color: var(--wallet-text);
    border-radius: 80px;
    padding: 9px 18px;
}
.proceed{
    background: #3A7A99;
     color: var(--wallet-text);
    border-radius: 80px;
    padding: 9px 18px;
    outline: none;
    border: none;
}

.modal-body{
    padding-top: 0px !important;
    padding-left: 10px !important ;
    padding-right: 10px !important;
    padding-bottom: 0px !important;
}
.modal-body label{
    font-weight: 500;
    margin-top: 4px;
    margin-bottom: 4px;
}
.modal-body input{
    width: 100%;
    padding: 10px;
    background: #0d1c2ea1;
    border: 1px solid gray;
    border-radius: 10px;
    outline: none;
    color: white;
}
.modal-body textarea{
        width: 100%;
        height: 10vh;
          background: #0d1c2ea1;
    border: 1px solid gray;
    border-radius: 10px;
    outline: none;
    padding: 3px;
    color: white;
}
.wallet-modal-logo {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
}

/* Custom modal show/hide (independent of Bootstrap JS) */
.wallet-modal {
    display: none;
}
.wallet-modal.show {
    display: block;
}