/* ======================================================
   WALLET PAGE LAYOUT
====================================================== */
.wallet-page {
    position: relative;
    padding: 110px 0 70px;
    background:
        radial-gradient(circle at top left, rgba(14, 165, 233, 0.10), transparent 22%),
        radial-gradient(circle at bottom right, rgba(14, 165, 233, 0.08), transparent 24%),
        linear-gradient(180deg, #ffffff 0%, #f4fbff 46%, #edf8ff 100%);
    overflow: hidden;
    margin-top: 30px;
}

.wallet-page-shape {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(10px);
}

.wallet-page-shape-one {
    top: 120px;
    left: -120px;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.14), transparent 70%);
}

.wallet-page-shape-two {
    right: -110px;
    bottom: 40px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.10), transparent 72%);
}

.account-container {
    width: 100%;
    max-width: 1380px;
    margin: 0 auto;
    padding: 0 14px;
    position: relative;
    z-index: 2;
}

.account-layout {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.account-main {
    min-width: 0;
}

/* ======================================================
   FORCE HIDDEN STATES
====================================================== */
.wallet-hidden-message {
    display: none !important;
}

.input-error.wallet-hidden-message {
    display: none !important;
}

#walletAjaxMessage.wallet-hidden-message {
    display: none !important;
}

/* ======================================================
   MESSAGES
====================================================== */
.wallet-message {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 16px;
    border-radius: 18px;
    margin-bottom: 16px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.04);
    border: 1px solid transparent;
    width: 100%;
}

.wallet-message i {
    font-size: 18px;
    flex-shrink: 0;
}

.wallet-message.success {
    background: linear-gradient(180deg, #f0fdf4, #ecfdf5);
    color: #166534;
    border-color: #bbf7d0;
}

.wallet-message.error {
    background: linear-gradient(180deg, #fff7f7, #fff1f2);
    color: #b91c1c;
    border-color: #fecaca;
}

/* ======================================================
   MAIN GRID
====================================================== */
.wallet-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 20px;
    align-items: start;
}

/* ======================================================
   CARD
====================================================== */
.account-card {
    padding: 24px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid rgba(14, 165, 233, 0.12);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.07);
    backdrop-filter: blur(12px);
}

.wallet-topup-card {
    position: relative;
    overflow: hidden;
}

.wallet-topup-card::before {
    content: "";
    position: absolute;
    top: -70px;
    right: -80px;
    width: 170px;
    height: 170px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.08), transparent 70%);
    pointer-events: none;
}

.wallet-card-header {
    position: relative;
    z-index: 2;
    margin-bottom: 22px;
}

.wallet-card-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.10);
    color: #0284c7;
    font-size: 11px;
    font-weight: 800;
    margin-bottom: 12px;
}

.account-card-title {
    margin: 0 0 8px;
    font-size: 30px;
    line-height: 1.15;
    font-weight: 900;
    color: #0f172a;
    letter-spacing: -0.02em;
}

.wallet-card-subtitle {
    font-size: 14px;
    line-height: 1.8;
    color: #64748b;
    max-width: 620px;
    margin: 0;
}

/* ======================================================
   FORM
====================================================== */
.account-form-group {
    margin-bottom: 18px;
}

.account-form-group label {
    display: block;
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 800;
    color: #0f172a;
}

.wallet-input-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 62px;
    padding: 8px;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid rgba(14, 165, 233, 0.14);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
    transition: all 0.28s ease;
}

.wallet-input-wrap:focus-within {
    border-color: rgba(2, 132, 199, 0.28);
    box-shadow:
        0 0 0 4px rgba(14, 165, 233, 0.10),
        0 14px 24px rgba(2, 132, 199, 0.08);
}

.wallet-currency-pill {
    min-width: 58px;
    height: 44px;
    padding: 0 12px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e0f7ff, #f4fbff);
    color: #0284c7;
    font-size: 14px;
    font-weight: 900;
    flex-shrink: 0;
}

#amountInput {
    flex: 1;
    min-width: 0;
    height: 46px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 16px;
    color: #0f172a;
    padding-right: 6px;
}

#amountInput::placeholder {
    color: #94a3b8;
}

#amountInput.is-invalid {
    color: #b91c1c;
}

.input-hint {
    display: block;
    margin-top: 10px;
    font-size: 12px;
    color: #64748b;
    line-height: 1.6;
}

.input-error {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    font-weight: 700;
    color: #b91c1c;
    line-height: 1.6;
}

/* ======================================================
   QUICK BUTTONS
====================================================== */
.wallet-quick-amounts {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0 22px;
}

.wallet-quick-btn {
    min-height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.08);
    border: 1px solid rgba(14, 165, 233, 0.10);
    color: #0369a1;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.25s ease;
}

.wallet-quick-btn:hover {
    transform: translateY(-2px);
    background: rgba(14, 165, 233, 0.14);
    border-color: rgba(14, 165, 233, 0.18);
    color: #0f172a;
}

/* ======================================================
   SUBMIT BUTTON
====================================================== */
.account-btn {
    width: 100%;
    min-height: 56px;
    padding: 0 18px;
    border: none;
    border-radius: 18px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.28s ease;
}

.wallet-submit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: #ffffff;
    box-shadow: 0 16px 32px rgba(2, 132, 199, 0.22);
}

.wallet-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 40px rgba(2, 132, 199, 0.28);
}

.wallet-submit-btn:disabled {
    cursor: not-allowed;
}

#walletBtn .btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    display: none;
    flex-shrink: 0;
}

#walletBtn.loading .btn-spinner {
    display: inline-block;
    animation: walletBtnSpin .7s linear infinite;
}

@keyframes walletBtnSpin {
    to {
        transform: rotate(360deg);
    }
}

/* ======================================================
   SIDE INFO
====================================================== */
.wallet-side-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.wallet-info-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 18px 16px;
    border-radius: 22px;
    background: rgba(255,255,255,0.82);
    border: 1px solid rgba(14, 165, 233, 0.10);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.04);
    transition: all 0.28s ease;
}

.wallet-info-card:hover {
    transform: translateY(-4px);
    border-color: rgba(14, 165, 233, 0.18);
    box-shadow: 0 18px 30px rgba(2, 132, 199, 0.09);
}

.wallet-info-icon {
    width: 46px;
    height: 46px;
    border-radius: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: linear-gradient(135deg, #e0f7ff, #f4fbff);
    color: #0284c7;
    font-size: 18px;
}

.wallet-info-text h4 {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 800;
    color: #0f172a;
}

.wallet-info-text p {
    margin: 0;
    font-size: 13px;
    line-height: 1.75;
    color: #64748b;
}

/* ======================================================
   RESPONSIVE
====================================================== */
@media (max-width: 1200px) {
    .wallet-grid {
        grid-template-columns: 1fr;
    }

    .wallet-side-info {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .wallet-page {
        padding: 95px 0 55px;
    }

    .account-layout {
        grid-template-columns: 1fr;
    }

    .wallet-side-info {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .account-container {
        padding: 0 10px;
    }

    .wallet-page {
        padding: 88px 0 46px;
    }

    .account-card {
        padding: 16px;
        border-radius: 22px;
    }

    .account-card-title {
        font-size: 24px;
    }

    .wallet-card-subtitle {
        font-size: 13px;
    }

    .wallet-input-wrap {
        flex-wrap: wrap;
        align-items: stretch;
        gap: 10px;
    }

    .wallet-currency-pill {
        width: 100%;
        min-width: 100%;
    }

    #amountInput {
        width: 100%;
    }

    .wallet-quick-amounts {
        gap: 8px;
    }

    .wallet-quick-btn {
        flex: 1 1 calc(50% - 8px);
        justify-content: center;
    }

    .wallet-message {
        padding: 14px;
        font-size: 13px;
        border-radius: 16px;
    }
}

@media (max-width: 560px) {
    .wallet-page {
        padding: 82px 0 40px;
    }

    .wallet-card-badge {
        font-size: 10px;
    }

    .wallet-info-card {
        padding: 15px 13px;
    }

    .wallet-info-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .wallet-info-text h4 {
        font-size: 14px;
    }

    .wallet-info-text p {
        font-size: 12px;
    }

    .account-card-title {
        font-size: 21px;
    }

    .account-btn {
        min-height: 52px;
        font-size: 14px;
    }
}