/* ========================================
 * 💰 TESOURARIA DO CLÃ
 * ======================================== */

body.page-clan {
    background: #09090b;
    color: #e4e4e7;
    font-family: 'Inter', Arial, sans-serif;
    min-height: 100vh;
    opacity: 0;
    transition: opacity 0.15s ease;
}

body.page-clan.ready {
    opacity: 1;
}


/* ========================================
 * 📦 WRAPPER
 * ======================================== */

.treasury-wrapper {
    width: 100%;
    max-width: 650px;
    margin: 0 auto;
    box-sizing: border-box;
    padding: 10px 12px 100px;
}


/* ========================================
 * 💰 HEADER
 * ======================================== */

.treasury-header {
    background: #111113;
    border: 1px solid #27272a;
    border-radius: 12px;
    padding: 18px 14px;
    text-align: center;
    margin-bottom: 10px;
}

.treasury-icon {
    font-size: 34px;
    line-height: 1;
    margin-bottom: 8px;
}

.treasury-title {
    color: #facc15;
    font-size: 16px;
    font-weight: 900;
    letter-spacing: 0.5px;
}

.treasury-clan-name {
    margin-top: 6px;
    color: #a1a1aa;
    font-size: 12px;
    font-weight: 700;
}


/* ========================================
 * 🗂️ CARDS
 * ======================================== */

.treasury-card {
    background: #111113;
    border: 1px solid #27272a;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 10px;
    box-sizing: border-box;
}

.section-title {
    color: #facc15;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}


/* ========================================
 * 🪙 SALDO DO CLÃ
 * ======================================== */

.clan-balance-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.balance-box {
    background: #18181b;
    border: 1px solid #27272a;
    border-radius: 9px;
    padding: 12px 10px;
    text-align: center;
}

.balance-label {
    color: #a1a1aa;
    font-size: 10px;
    font-weight: 800;
    margin-bottom: 6px;
}

.balance-value {
    font-size: 18px;
    font-weight: 900;
}

.gold-box .balance-value {
    color: #facc15;
}

.silver-box .balance-value {
    color: #d4d4d8;
}


/* ========================================
 * 👤 STATUS DO MEMBRO
 * ======================================== */

.member-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid #27272a;
    font-size: 12px;
}

.member-row:last-of-type {
    border-bottom: 0;
}

.member-row span {
    color: #a1a1aa;
}

.member-row strong {
    color: #e4e4e7;
    font-weight: 900;
    text-align: right;
}

.status-loading {
    color: #a1a1aa !important;
}

.status-available {
    color: #22c55e !important;
}

.status-waiting {
    color: #facc15 !important;
}

.member-wait {
    color: #71717a;
    font-size: 10px;
    line-height: 1.5;
    text-align: right;
    margin-top: 5px;
}


/* ========================================
 * 💰 CONTRIBUIÇÕES
 * ======================================== */

.contribution-card {
    padding-bottom: 15px;
}

.contribution-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.contribution-title {
    color: #e4e4e7;
    font-size: 12px;
    font-weight: 900;
}

.daily-limit {
    color: #71717a;
    font-size: 10px;
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
}

.contribution-stats {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
    margin-bottom: 12px;
}

.contribution-stats > div {
    background: #18181b;
    border: 1px solid #27272a;
    border-radius: 8px;
    padding: 9px 6px;
    text-align: center;
    min-width: 0;
}

.contribution-stats span {
    display: block;
    color: #71717a;
    font-size: 9px;
    line-height: 1.3;
    margin-bottom: 5px;
}

.contribution-stats strong {
    display: block;
    color: #e4e4e7;
    font-size: 12px;
    font-weight: 900;
    overflow: hidden;
    text-overflow: ellipsis;
}

.deposit-area {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.deposit-input {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    background: #09090b;
    color: #e4e4e7;
    border: 1px solid #3f3f46;
    border-radius: 8px;
    padding: 11px 10px;
    font-size: 12px;
    font-weight: 700;
    outline: none;
}

.deposit-input:focus {
    border-color: #71717a;
}

.deposit-input::placeholder {
    color: #52525b;
}

.deposit-btn {
    flex: 0 0 145px;
    border: 1px solid #3f3f46;
    border-radius: 8px;
    padding: 0 8px;
    font-size: 10px;
    font-weight: 900;
    cursor: pointer;
    background: #18181b;
    color: #e4e4e7;
}

.deposit-btn:active {
    transform: scale(0.98);
}

.deposit-btn:disabled {
    opacity: 0.45;
    cursor: default;
    transform: none;
}

.gold-btn {
    color: #facc15;
}

.silver-btn {
    color: #d4d4d8;
}

.deposit-message {
    min-height: 15px;
    margin-top: 7px;
    color: #71717a;
    font-size: 10px;
    line-height: 1.4;
}

.deposit-message.success {
    color: #22c55e;
}

.deposit-message.error {
    color: #ef4444;
}


/* ========================================
 * ℹ️ INFORMAÇÕES
 * ======================================== */

.information-card {
    padding-bottom: 10px;
}

.info-line {
    color: #71717a;
    font-size: 10px;
    line-height: 1.55;
    margin-bottom: 5px;
}


/* ========================================
 * 🔙 VOLTAR
 * ======================================== */

.back-btn {
    display: block;
    box-sizing: border-box;
    width: 100%;
    background: #111113;
    border: 1px solid #27272a;
    border-radius: 10px;
    padding: 12px;
    color: #a1a1aa;
    text-decoration: none;
    text-align: center;
    font-size: 11px;
    font-weight: 800;
}

.back-btn:active {
    transform: scale(0.99);
}


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

@media (max-width: 400px) {

    .treasury-wrapper {
        padding-left: 8px;
        padding-right: 8px;
    }

    .contribution-header {
        display: block;
    }

    .daily-limit {
        margin-top: 5px;
        text-align: left;
    }

    .contribution-stats {
        gap: 4px;
    }

    .deposit-area {
        display: grid;
        grid-template-columns: 1fr;
    }

    .deposit-btn {
        flex: none;
        min-height: 40px;
    }

}
