.profile-header {
    position: relative;
    height: 170px;
    animation: fadeIn 0.5s ease-out;
}

.header-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 130px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 0 0 30px 30px;
}

.user-info-card {
    position: absolute;
    top: 60px;
    left: 20px;
    right: 20px;
    background: var(--card-bg);
    border-radius: 20px;
    padding: 18px;
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: center;
    gap: 15px;
    animation: slideUp 0.6s ease-out;
}

.avatar-wrapper {
    position: relative;
}

.avatar,
.avatar-default {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 4px solid white;
    box-shadow: var(--shadow-md);
}

.avatar-default {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.user-details {
    flex: 1;
    min-width: 0;
}

.user-name {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.vip-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px 4px 8px;
    border-radius: 20px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 40%, #0f3460 100%);
    border: 1px solid rgba(255, 215, 0, 0.5);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25), inset 0 1px 0 rgba(255,255,255,0.08);
    vertical-align: middle;
    white-space: nowrap;
}

.vip-icon {
    font-size: 14px;
    line-height: 1;
}

.vip-name {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #ffd700 0%, #ffaa00 50%, #ff8c00 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.vip-stars {
    font-size: 10px;
    color: #ffd700;
    letter-spacing: 1px;
    text-shadow: 0 0 4px rgba(255, 215, 0, 0.6);
}

.user-phone {
    font-size: 14px;
    color: var(--text-secondary);
}

.balance-card {
    margin: 15px 20px 20px;
    padding: 20px;
    border-radius: 18px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: var(--shadow-xl);
    animation: fadeInUp 0.6s ease-out;
}

.balance-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.balance-title {
    font-size: 13px;
    opacity: 0.9;
}

.balance-refresh {
    font-size: 12px;
    padding: 3px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}

.balance-refresh:active {
    transform: scale(0.94);
    background: rgba(255, 255, 255, 0.35);
}

.balance-amount {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.3;
    margin: 6px 0 16px;
    transition: opacity 0.3s ease;
}

.balance-amount.loading {
    opacity: 0.4;
}

.balance-actions {
    display: flex;
    gap: 12px;
}

.balance-btn {
    flex: 1;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: none;
    border-radius: 21px;
    background: rgba(255, 255, 255, 0.22);
    color: white;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
}

.balance-btn:active {
    transform: scale(0.97);
    background: rgba(255, 255, 255, 0.35);
}

.balance-btn-icon {
    font-size: 17px;
}

.transfer-balance {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    margin-bottom: 18px;
    border-radius: 12px;
    background: var(--bg-color);
    font-size: 14px;
    color: var(--text-secondary);
}

.transfer-balance-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
}

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

.modal-body label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.modal-body input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-primary);
    background: var(--bg-color);
    outline: none;
    transition: all 0.3s ease;
}

.modal-body input:focus {
    background: var(--card-bg);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
}

.modal-body select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-primary);
    background: var(--bg-color);
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23999' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-body select:focus {
    background-color: var(--card-bg);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
}

.submit-button {
    width: 100%;
    height: 50px;
    margin-top: 8px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 17px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-button:active {
    transform: scale(0.98);
}

.submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.menu-section {
    margin: 0 20px 30px;
    background: var(--card-bg);
    border-radius: 15px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    animation: fadeInUp 0.6s ease-out;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 1px solid var(--border-color);
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item:active {
    background: var(--bg-color);
}

.menu-icon {
    font-size: 24px;
    margin-right: 15px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-color);
    border-radius: 10px;
}

.menu-text {
    flex: 1;
    font-size: 16px;
    color: var(--text-primary);
}

.menu-arrow {
    font-size: 24px;
    color: var(--text-secondary);
}

.logout-button {
    margin: 0 20px 30px;
    width: calc(100% - 40px);
    padding: 15px;
    border: none;
    background: var(--card-bg);
    color: var(--danger-color);
    font-size: 16px;
    font-weight: 600;
    border-radius: 15px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.logout-button:active {
    transform: scale(0.98);
    background: var(--danger-color);
    color: white;
}